]> git.baikalelectronics.ru Git - kernel.git/commit
loop: fix ioctl calls using compat_loop_info
authorCarlos Llamas <cmllamas@google.com>
Tue, 29 Mar 2022 20:18:15 +0000 (20:18 +0000)
committerJens Axboe <axboe@kernel.dk>
Wed, 30 Mar 2022 14:54:32 +0000 (08:54 -0600)
commit96e08b5e0c6f992183f34bf8d00347ae20acd5ad
treed39cb8cab63c284cb6db354b1d9606a243a6a411
parent3ff1cada5d4e75cb31498c98894732466beb21d3
loop: fix ioctl calls using compat_loop_info

Support for cryptoloop was deleted in commit 4edc575348fd ("block:
remove support for cryptoloop and the xor transfer"), making the usage
of loop_info->lo_encrypt_type obsolete. However, this member was also
removed from the compat_loop_info definition and this breaks userspace
ioctl calls for 32-bit binaries and CONFIG_COMPAT=y.

This patch restores the compat_loop_info->lo_encrypt_type member and
marks it obsolete as well as in the uapi header definitions.

Fixes: 4edc575348fd ("block: remove support for cryptoloop and the xor transfer")
Signed-off-by: Carlos Llamas <cmllamas@google.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Link: https://lore.kernel.org/r/20220329201815.1347500-1-cmllamas@google.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/block/loop.c
include/uapi/linux/loop.h