Skip to content
Commit daeaa9df authored by Sreekanth Reddy's avatar Sreekanth Reddy Committed by Christoph Hellwig
Browse files

mpt2sas: Avoid type casting for direct I/O commands



A type casting error caused the max volume LBA to be truncated from 64
to 32 bits. The virtual LBA would also get truncated to 32 bits in the
case of a 16-byte READ/WRITE command.

Rewrite entire function to get rid of code duplication and type casts.
Use get/put_unaligned wrappers to extract and replace the LBA field in
the MPI request CDB.

Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
Tested-by: default avatarSreekanth Reddy <Sreekanth.Reddy@avagotech.com>
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
parent 49563e1e
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment