summary refs log tree commit diff stats
path: root/include/hw/misc/aspeed_sdmc.h
diff options
context:
space:
mode:
authorJoel Stanley <joel@jms.id.au>2018-08-16 14:05:29 +0100
committerPeter Maydell <peter.maydell@linaro.org>2018-08-16 14:29:58 +0100
commitd131bc28a6094191471fb935a0535ae5a4df4ab3 (patch)
treeddc47471697066cefdd21ff836e5e5fbda0f8a7e /include/hw/misc/aspeed_sdmc.h
parenta40085d2ee5fc4482d95e91c22212a228175a73d (diff)
downloadfocaccia-qemu-d131bc28a6094191471fb935a0535ae5a4df4ab3.tar.gz
focaccia-qemu-d131bc28a6094191471fb935a0535ae5a4df4ab3.zip
aspeed_sdmc: Fix saved values
This fixes the intended protection of read-only values in the
configuration register. They were being always set to zero by mistake.

The read-only fields depend on the configured memory size of the system,
so they cannot be fixed at compile time. The most straight forward
option was to store them in the state structure.

Signed-off-by: Joel Stanley <joel@jms.id.au>
Reviewed-by: Cédric Le Goater <clg@kaod.org>
Tested-by: Cédric Le Goater <clg@kaod.org>
Message-id: 20180807075757.7242-3-joel@jms.id.au
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'include/hw/misc/aspeed_sdmc.h')
-rw-r--r--include/hw/misc/aspeed_sdmc.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/hw/misc/aspeed_sdmc.h b/include/hw/misc/aspeed_sdmc.h
index 682f0f5d56..e079c66a7d 100644
--- a/include/hw/misc/aspeed_sdmc.h
+++ b/include/hw/misc/aspeed_sdmc.h
@@ -27,6 +27,7 @@ typedef struct AspeedSDMCState {
     uint32_t silicon_rev;
     uint32_t ram_bits;
     uint64_t ram_size;
+    uint32_t fixed_conf;
 
 } AspeedSDMCState;