By setting .impl.unaligned = true, we allow QEMU to pass along unaligned requests directly as-is, rather than splitting them into multiple aligned sub-requests that might cause repeated device callbacks or unintended side effects.
Signed-off-by: CJ Chen <cjc...@igel.co.jp> Tested-by: CJ Chen <cjc...@igel.co.jp> Acked-by: Tomoyuki Hirose <hrstmyk8...@gmail.com> Reported-by: Tomoyuki Hirose <hrstmyk8...@gmail.com> --- hw/ssi/npcm7xx_fiu.c | 3 +++ hw/xtensa/mx_pic.c | 3 +++ 2 files changed, 6 insertions(+) diff --git a/hw/ssi/npcm7xx_fiu.c b/hw/ssi/npcm7xx_fiu.c index 056ce13394..10ee4deb31 100644 --- a/hw/ssi/npcm7xx_fiu.c +++ b/hw/ssi/npcm7xx_fiu.c @@ -255,6 +255,9 @@ static const MemoryRegionOps npcm7xx_fiu_flash_ops = { .max_access_size = 8, .unaligned = true, }, + .impl = { + .unaligned = true, + }, }; /* Control register read handler. */ diff --git a/hw/xtensa/mx_pic.c b/hw/xtensa/mx_pic.c index 8211c993eb..6bf524a918 100644 --- a/hw/xtensa/mx_pic.c +++ b/hw/xtensa/mx_pic.c @@ -270,6 +270,9 @@ static const MemoryRegionOps xtensa_mx_pic_ops = { .valid = { .unaligned = true, }, + .impl = { + .unaligned = true, + }, }; MemoryRegion *xtensa_mx_pic_register_cpu(XtensaMxPic *mx, -- 2.25.1