UPSTREAM: mainboard/emulation/qemu-i440fx/fw_cfg: Fix undefined behavior

Fixes 2 reports found by undefined behavior sanitizer. Dereferencing
pointers that are not aligned to the size of access is undefiend
behavior.

BUG=none
BRANCH=none
TEST=none

Change-Id: I9f58f4d389569df7a5fa3625b420cd512257582a
Signed-off-by: Patrick Georgi <pgeorgi@google.com>
Original-Commit-Id: d4f994bbc4f9fbe807f808d761aaa7d04b8f5133
Original-Change-Id: Iaa3845308171c307f1ddc7937286aacbd00e3a10
Original-Signed-off-by: Ryan Salsamendi <rsalsamendi@hotmail.com>
Original-Reviewed-on: https://review.coreboot.org/20155
Original-Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Original-Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/539526
Commit-Ready: Patrick Georgi <pgeorgi@chromium.org>
Tested-by: Patrick Georgi <pgeorgi@chromium.org>
Reviewed-by: Patrick Georgi <pgeorgi@chromium.org>
1 file changed