diff options
author | Martin K. Petersen <martin.petersen@oracle.com> | 2019-01-15 16:49:59 -0800 |
---|---|---|
committer | Martin K. Petersen <martin.petersen@oracle.com> | 2019-01-22 21:18:27 -0500 |
commit | ec029758a10095c66fd24398f742c695c2e6ec2c (patch) | |
tree | 4eb233e879a02f4b8b1ebf38d9a837491938d3a4 /ipc/compat.c | |
parent | c6c93fdd3451cc0de393dad891d6b0be71e50888 (diff) |
scsi: sd: Simplify misaligned I/O check
Avoid open coding the checks for the supported logical block sizes and use
a mask to check for misaligned I/O. Use our helper functions to scale lba
and block count.
Reviewed-by: Hannes Reinecke <hare@suse.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
[ bvanassche: ported this patch from kernel v4.11 to kernel v5.0 ]
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'ipc/compat.c')
0 files changed, 0 insertions, 0 deletions