#! /bin/bash
+# SPDX-License-Identifier: GPL-2.0
+# Copyright (c) 2006 Silicon Graphics, Inc. All Rights Reserved.
+#
# FS QA Test No. 122
#
# pv#952498
# Keep an eye on some of the xfs type sizes
# Motivation from differing ondisk types for 32 and 64 bit word versions.
#
-#-----------------------------------------------------------------------
-# Copyright (c) 2006 Silicon Graphics, Inc. All Rights Reserved.
-#
-# This program is free software; you can redistribute it and/or
-# modify it under the terms of the GNU General Public License as
-# published by the Free Software Foundation.
-#
-# This program is distributed in the hope that it would be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write the Free Software Foundation,
-# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
-#
-#-----------------------------------------------------------------------
-#
-
seq=`basename $0`
seqres=$RESULT_DIR/$seq
echo "QA output created by $seq"
xfs_fsop_getparents_handlereq_t
xfs_dinode_core_t
struct xfs_iext_cursor
+struct xfs_ino_geometry
EOF
echo 'int main(int argc, char *argv[]) {' >>$cprog
awk '
/typedef struct xfs_sb/ { structon = 1; next }
structon && $2 ~ /^sb_/ { sub(/[;,]/,"",$2)
+ sub(/XFSLABEL_MAX/,"12",$2)
printf("printf(\"offsetof(xfs_sb_t, %s) = \\%zu\\n\", offsetof(xfs_sb_t, %s));", $2, $2); next}
structon && /}/ { structon = 0; next}
'>>$cprog