From: Arnd Bergmann <arnd@arndb.de>
Date: Fri, 29 Nov 2019 10:28:22 +0000 (+0100)
Subject: compat_ioctl: block: handle BLKREPORTZONE/BLKRESETZONE
X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=673bdf8ce0a387ef585c13b69a2676096c6edfe9;p=linux.git

compat_ioctl: block: handle BLKREPORTZONE/BLKRESETZONE

These were added to blkdev_ioctl() but not blkdev_compat_ioctl,
so add them now.

Cc: <stable@vger.kernel.org> # v4.10+
Fixes: 3ed05a987e0f ("blk-zoned: implement ioctls")
Reviewed-by: Damien Le Moal <damien.lemoal@wdc.com>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
---

diff --git a/block/compat_ioctl.c b/block/compat_ioctl.c
index 6ca015f92766e..830f91e05fe37 100644
--- a/block/compat_ioctl.c
+++ b/block/compat_ioctl.c
@@ -354,6 +354,8 @@ long compat_blkdev_ioctl(struct file *file, unsigned cmd, unsigned long arg)
 	 * but we call blkdev_ioctl, which gets the lock for us
 	 */
 	case BLKRRPART:
+	case BLKREPORTZONE:
+	case BLKRESETZONE:
 		return blkdev_ioctl(bdev, mode, cmd,
 				(unsigned long)compat_ptr(arg));
 	case BLKBSZSET_32: