]> git.apps.os.sepia.ceph.com Git - xfsprogs-dev.git/commit
libxfs: print the device name if flush-on-close fails
authorDarrick J. Wong <djwong@kernel.org>
Wed, 17 Apr 2024 23:16:50 +0000 (16:16 -0700)
committerCarlos Maiolino <cem@kernel.org>
Tue, 23 Apr 2024 13:16:05 +0000 (15:16 +0200)
commitfa70379081a903b2ebe502e4d3ad8ebffbe30bee
treec0e58dc1633f7a7890934325143c4bfa25bb014c
parentd03b73d240dc7f5b4c02700c79c2c4eeeb94b08b
libxfs: print the device name if flush-on-close fails

Print the name of the device if persisting the write cache fails.
Printing a pointer does not help the user at all, and this causes the
32-bit build to complain:

init.c: In function ‘libxfs_device_close’:
init.c:178:35: error: cast from pointer to integer of different size [-Werror=pointer-to-int-cast]
  178 |                         progname, (long long)dev, ret);
      |                                   ^
cc1: all warnings being treated as errors

Fixes: fc83c7574b1f ("libxfs: split out a libxfs_dev structure from struct libxfs_init")
Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>
libxfs/init.c