autofs: fix print format for ioctl warning message
authorTomohiro Kusumi <[email protected]>
Tue, 11 Oct 2016 20:53:08 +0000 (13:53 -0700)
committerLinus Torvalds <[email protected]>
Tue, 11 Oct 2016 22:06:31 +0000 (15:06 -0700)
All other warnings use "cmd(0x%08x)" and this is the only one with
"cmd(%d)".  (below comes from my userspace debug program, but not
automount daemon)

[ 1139.905676] autofs4:pid:1640:check_dev_ioctl_version: ioctl control interface version mismatch: kernel(1.0), user(0.0), cmd(-1072131215)

Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Tomohiro Kusumi <[email protected]>
Signed-off-by: Ian Kent <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
fs/autofs4/dev-ioctl.c

index 7289216708d2f02cba14c88d019f487e1ad13b4f..e89d6bbf268df44da748ae879c979f834a1dbeb7 100644 (file)
@@ -75,7 +75,7 @@ static int check_dev_ioctl_version(int cmd, struct autofs_dev_ioctl *param)
        if ((param->ver_major != AUTOFS_DEV_IOCTL_VERSION_MAJOR) ||
            (param->ver_minor > AUTOFS_DEV_IOCTL_VERSION_MINOR)) {
                pr_warn("ioctl control interface version mismatch: "
-                       "kernel(%u.%u), user(%u.%u), cmd(%d)\n",
+                       "kernel(%u.%u), user(%u.%u), cmd(0x%08x)\n",
                        AUTOFS_DEV_IOCTL_VERSION_MAJOR,
                        AUTOFS_DEV_IOCTL_VERSION_MINOR,
                        param->ver_major, param->ver_minor, cmd);