RDMA/srp: Apply the __packed attribute to members instead of structures
authorBart Van Assche <bvanassche@acm.org>
Mon, 24 May 2021 04:12:09 +0000 (21:12 -0700)
committerJason Gunthorpe <jgg@nvidia.com>
Fri, 28 May 2021 23:21:20 +0000 (20:21 -0300)
commit6dc26498e1d3d702b5321f380e24d3368765b351
tree79967f6b6efe7d7bc8f8d6adda4d76b5cafaa8ee
parentc838de1af141ee3bd23ea1781a7033375b54f35a
RDMA/srp: Apply the __packed attribute to members instead of structures

Applying the __packed attribute to an entire data structure results in
suboptimal code on architectures that do not support unaligned accesses.
Hence apply the __packed attribute only to those data members that are
not naturally aligned.

Link: https://lore.kernel.org/r/20210524041211.9480-4-bvanassche@acm.org
Cc: Nicolas Morey-Chaisemartin <nmoreychaisemartin@suse.com>
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
include/scsi/srp.h