generic/233,270: unlimit the max locked memory size for io_uring
[xfstests-dev.git] / tests / btrfs / 047
1 #! /bin/bash
2 # SPDX-License-Identifier: GPL-2.0
3 # Copyright (c) 2017 Facebook.  All Rights Reserved.
4 #
5 # FS QA Test 047
6 #
7 # Test that we can't set xattrs on subvolume placeholder directories.
8 # Regression test for Btrfs: disable xattr operations on subvolume directories.
9 #
10 seq=`basename $0`
11 seqres=$RESULT_DIR/$seq
12 echo "QA output created by $seq"
13
14 here=`pwd`
15 tmp=/tmp/$$
16 status=1        # failure is the default!
17 trap "_cleanup; exit \$status" 0 1 2 3 15
18
19 _cleanup()
20 {
21         cd /
22         rm -f $tmp.*
23 }
24
25 # get standard environment, filters and checks
26 . ./common/rc
27 . ./common/filter
28 . ./common/attr
29
30 # remove previous $seqres.full before test
31 rm -f $seqres.full
32
33 # real QA test starts here
34
35 _supported_fs btrfs
36 _require_attrs
37 _require_scratch
38
39 _scratch_mkfs >/dev/null 2>&1
40 _scratch_mount
41
42 $BTRFS_UTIL_PROG subvolume create "$SCRATCH_MNT/parent" >>$seqres.full
43 $BTRFS_UTIL_PROG subvolume create "$SCRATCH_MNT/parent/child" >>$seqres.full
44 $BTRFS_UTIL_PROG subvolume snapshot "$SCRATCH_MNT/parent" "$SCRATCH_MNT/snapshot" >>$seqres.full
45
46 $SETFATTR_PROG -n user.test -v foo "$SCRATCH_MNT/snapshot/child" |& _filter_scratch
47
48 # The original bug resulted in bogus delayed inodes being inserted, so run the
49 # delayed inodes by doing a commit.
50 $BTRFS_UTIL_PROG filesystem sync "$SCRATCH_MNT" >>$seqres.full
51
52 status=0
53 exit