diff options
author | Arnd Bergmann <arnd@arndb.de> | 2020-10-30 17:44:21 +0100 |
---|---|---|
committer | Martin K. Petersen <martin.petersen@oracle.com> | 2020-11-05 03:56:17 +0100 |
commit | bba84aeccafb57f3f175bbab0658a7facd611d18 (patch) | |
tree | 2098b42207d478584b8b17d04fe2f87c6fe592ab /drivers/target | |
parent | scsi: megaraid_sas: Check user-provided offsets (diff) | |
download | linux-bba84aeccafb57f3f175bbab0658a7facd611d18.tar.xz linux-bba84aeccafb57f3f175bbab0658a7facd611d18.zip |
scsi: megaraid_sas: Simplify compat_ioctl handling
There have been several attempts to fix serious problems in the compat
handling in megasas_mgmt_compat_ioctl_fw(), and it also uses the
compat_alloc_user_space() function.
Folding the compat handling into the regular ioctl function with
in_compat_syscall() simplifies it a lot and avoids some of the remaining
problems:
- missing handling of unaligned pointers
- overflowing the ioc->frame.raw array from invalid input
- compat_alloc_user_space()
Link: https://lore.kernel.org/r/20201030164450.1253641-3-arnd@kernel.org
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/target')
0 files changed, 0 insertions, 0 deletions