summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHervé Poussineau2016-12-29 23:12:13 +0100
committerDavid Gibson2017-01-31 00:10:13 +0100
commit5904bca84ed3b41b983e14a5adc388400cf737e6 (patch)
treed6acef2fcde2d9f336980193c2e275f5bd91cae4
parenthw/ppc/spapr: Fix boot path of usb-host storage devices (diff)
downloadqemu-5904bca84ed3b41b983e14a5adc388400cf737e6.tar.gz
qemu-5904bca84ed3b41b983e14a5adc388400cf737e6.tar.xz
qemu-5904bca84ed3b41b983e14a5adc388400cf737e6.zip
prep: do not use global variable to access nvram
Signed-off-by: Hervé Poussineau <hpoussin@reactos.org> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
-rw-r--r--hw/ppc/prep.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/hw/ppc/prep.c b/hw/ppc/prep.c
index 054af1e8b4..9fb89d3a45 100644
--- a/hw/ppc/prep.c
+++ b/hw/ppc/prep.c
@@ -339,13 +339,13 @@ static PortioList prep_port_list;
/* NVRAM helpers */
static inline uint32_t nvram_read(Nvram *nvram, uint32_t addr)
{
- NvramClass *k = NVRAM_GET_CLASS(sysctrl->nvram);
+ NvramClass *k = NVRAM_GET_CLASS(nvram);
return (k->read)(nvram, addr);
}
static inline void nvram_write(Nvram *nvram, uint32_t addr, uint32_t val)
{
- NvramClass *k = NVRAM_GET_CLASS(sysctrl->nvram);
+ NvramClass *k = NVRAM_GET_CLASS(nvram);
(k->write)(nvram, addr, val);
}