diff options
author | Tom Hughes <tomhughes@chromium.org> | 2022-10-11 13:58:46 -0700 |
---|---|---|
committer | Chromeos LUCI <chromeos-scoped@luci-project-accounts.iam.gserviceaccount.com> | 2022-10-12 19:51:40 +0000 |
commit | 65da9cc08766e307e5d288e1d7848c83384dae21 (patch) | |
tree | 41d555c2174abf1ecb135c501ce92dd7870ac80a /zephyr/test/drivers/default/CMakeLists.txt | |
parent | 7047f8ffb2dc3382a1dabe16d15a3e36db479f3f (diff) | |
download | chrome-ec-65da9cc08766e307e5d288e1d7848c83384dae21.tar.gz |
include/ec_commands.h: Fix unaligned access warnings
When building with clang, it now warns if there is an unpacked struct
nested in a packed struct:
include/ec_commands.h:3053:4: error: field within 'struct
ec_params_motion_sense::(unnamed at include/ec_commands.h:3044:3)' is
less aligned than 'union ec_params_motion_sense::(anonymous at
include/ec_commands.h:3053:4)' and is usually due to 'struct
ec_params_motion_sense::(unnamed at include/ec_commands.h:3044:3)' being
packed, which can lead to unaligned accesses
[-Werror,-Wunaligned-access]
union {
^
See https://github.com/llvm/llvm-project/issues/55520.
BRANCH=none
BUG=b:172020503
TEST=./util/compare_build.sh -b all -j 120
=> MATCH
Signed-off-by: Tom Hughes <tomhughes@chromium.org>
Change-Id: I5c89746d7e2e93183f4706376e6cda0be4589c01
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3946036
Reviewed-by: Daisuke Nojiri <dnojiri@chromium.org>
Diffstat (limited to 'zephyr/test/drivers/default/CMakeLists.txt')
0 files changed, 0 insertions, 0 deletions