linux/drivers/gpu/drm/amd/display/dmub
Jonathan Gray 6e60cba666 drm/amd/display: avoid unaligned access warnings
When building on OpenBSD/arm64 with clang 15, unaligned access
warnings are seen when a union is embedded inside a packed struct.

drm/amd/display/dmub/inc/dmub_cmd.h:941:18: error: field
  cursor_copy_src within 'struct dmub_rb_cmd_mall' is less aligned than
  'union dmub_addr' and is usually due to 'struct dmub_rb_cmd_mall'
  being packed, which can lead to unaligned accesses
  [-Werror,-Wunaligned-access]
        union dmub_addr cursor_copy_src; /**< Cursor copy address */
                        ^
drm/amd/display/dmub/inc/dmub_cmd.h:942:18: error: field cursor_copy_dst
  within 'struct dmub_rb_cmd_mall' is less aligned than
  'union dmub_addr' and is usually due to 'struct dmub_rb_cmd_mall'
  being packed, which can lead to unaligned accesses
  [-Werror,-Wunaligned-access]
        union dmub_addr cursor_copy_dst; /**< Cursor copy destination */
                        ^

Add pragma pack around dmub_addr to avoid this.

Signed-off-by: Jonathan Gray <jsg@jsg.id.au>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2023-02-15 22:24:56 -05:00
..
inc drm/amd/display: avoid unaligned access warnings 2023-02-15 22:24:56 -05:00
src drm/amd/display: Reset DMUB mailbox SW state after HW reset 2023-01-31 14:03:36 -05:00
dmub_srv.h drm/amd/display: Update dmub header to match DMUB 2023-01-13 14:59:41 -05:00
dmub_srv_stat.h drm/amd/display: Support for DMUB AUX 2021-03-02 14:05:41 -05:00