libxl/arm: Fix build on arm64 + acpi w/ gcc 8.2
authorChristopher Clark <christopher.w.clark@gmail.com>
Thu, 16 Aug 2018 20:22:41 +0000 (13:22 -0700)
committerHans van Kranenburg <hans@knorrie.org>
Tue, 26 May 2020 12:03:18 +0000 (14:03 +0200)
commit5488a01ec33a13389ed6ac06f8b39259098cd8eb
tree1393530f4a8a65f59d7397d8d0f19d0405f288b0
parenta8daf4608a0f3ca01ff900ff6c96aca659c5673a
libxl/arm: Fix build on arm64 + acpi w/ gcc 8.2

Add zero-padding to #defined ACPI table strings that are copied.
Provides sufficient characters to satisfy the length required to
fully populate the destination and prevent array-bounds warnings.
Add BUILD_BUG_ON sizeof checks for compile-time length checking.

Signed-off-by: Christopher Clark <christopher.clark6@baesystems.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
Acked-by: Wei Liu <wei.liu2@citrix.com>
(cherry picked from commit b8f33431f3dd23fb43a879f4bdb4283fdc9465ad)
tools/libxl/libxl_arm_acpi.c