Skip to content

Commit d0bac0e

Browse files
bvanasschemartinkpetersen
authored andcommitted
scsi: ufs: Fix the build for the old ARM OABI
All structs and unions are word aligned when using the OABI. Mark the union in struct utp_upiu_header as packed to prevent that the compiler inserts padding bytes. Cc: Arnd Bergmann <[email protected]> Reported-by: kernel test robot <[email protected]> Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/ Fixes: 617bfaa ("scsi: ufs: Simplify response header parsing") Signed-off-by: Bart Van Assche <[email protected]> Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Arnd Bergmann <[email protected]> Reviewed-by: Bean Huo <[email protected]> Signed-off-by: Martin K. Petersen <[email protected]>
1 parent d478180 commit d0bac0e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

include/uapi/scsi/scsi_bsg_ufs.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ struct utp_upiu_header {
8383
union {
8484
__u8 tm_function;
8585
__u8 query_function;
86-
};
86+
} __attribute__((packed));
8787
__u8 response;
8888
__u8 status;
8989
__u8 ehs_length;

0 commit comments

Comments
 (0)