sandbox: Rework readX/writeX macros to be more like ARM
authorTom Rini <trini@konsulko.com>
Wed, 1 Oct 2025 20:30:35 +0000 (14:30 -0600)
committerTom Rini <trini@konsulko.com>
Fri, 10 Oct 2025 19:58:49 +0000 (13:58 -0600)
commitb30155c08e95550296668766bfd7d3da27c970fe
treea7dfcc4109959ae96cc6a77d713b6aa2fee7e67f
parent9de2fc9878e7a79752fab26312f9d160b4103e3e
sandbox: Rework readX/writeX macros to be more like ARM

The way that the current readX/writeX macros are implemented on sandbox
means that when IO_TRACE is not enabled some code will throw up
incorrect warnings due to how sandbox_{read,write} is implemented. We
instead need to do the "uX __v; __v = sandbox..(..v); __v;" trick that
ARM does.

Signed-off-by: Tom Rini <trini@konsulko.com>
arch/sandbox/include/asm/io.h