2 # SPDX-License-Identifier: GPL-2.0
3 # Copyright (c) 2018 Oracle, Inc.
7 # Make sure pretty printed XFS geometry is the same across all programs.
10 seqres=$RESULT_DIR/$seq
11 echo "QA output created by $seq"
16 trap "_cleanup; exit \$status" 0 1 2 3 15
26 # get standard environment, filters and checks
30 # real QA test starts here
34 _require_scratch_nocheck
36 # Geometry printing wasn't unified until xfs_spaceman grew an 'info'
37 # command, so skip this test if there is no spaceman or it doesn't
38 # know what 'info' is.
39 _require_xfs_spaceman_command "info"
40 _require_command "$XFS_GROWFS_PROG" xfs_growfs
42 _scratch_mkfs > $tmp.mkfs
43 echo MKFS >> $seqres.full
44 cat $tmp.mkfs >> $seqres.full
46 _scratch_xfs_db -c "info" > $tmp.dbinfo
47 echo DB >> $seqres.full
48 cat $tmp.dbinfo >> $seqres.full
49 diff -u $tmp.mkfs $tmp.dbinfo
53 $XFS_SPACEMAN_PROG -c "info" $SCRATCH_MNT > $tmp.spaceman
54 echo SPACEMAN >> $seqres.full
55 cat $tmp.spaceman >> $seqres.full
56 diff -u $tmp.mkfs $tmp.spaceman
58 $XFS_GROWFS_PROG -n $SCRATCH_MNT > $tmp.growfs
59 echo GROWFS >> $seqres.full
60 cat $tmp.growfs >> $seqres.full
61 diff -u $tmp.mkfs $tmp.growfs
63 $XFS_INFO_PROG $SCRATCH_MNT > $tmp.info
64 echo INFO >> $seqres.full
65 cat $tmp.info >> $seqres.full
66 diff -u $tmp.mkfs $tmp.info
68 echo "Silence is golden."