From: Narthorn Date: Sat, 7 May 2022 05:43:02 +0000 (+0200) Subject: fstrim: check for ENOSYS when using --quiet-unsupported X-Git-Tag: v2.38.1~52 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=cfc1b128431386a6608e34080c668b838d53ca2f;p=thirdparty%2Futil-linux.git fstrim: check for ENOSYS when using --quiet-unsupported Some filesystems like bindfs report ENOSYS (Function not implemented) for the trim ioctl, which should be caught by --quiet-unsupported. --- diff --git a/sys-utils/fstrim.c b/sys-utils/fstrim.c index 0d6cabeb96..88333e91db 100644 --- a/sys-utils/fstrim.c +++ b/sys-utils/fstrim.c @@ -122,6 +122,7 @@ static int fstrim_filesystem(struct fstrim_control *ctl, const char *path, const case EBADF: case ENOTTY: case EOPNOTSUPP: + case ENOSYS: rc = 1; break; default: