diff options
author | Andreas Färber <afaerber@suse.de> | 2013-07-26 17:21:21 +0200 |
---|---|---|
committer | Andreas Färber <afaerber@suse.de> | 2013-07-29 21:06:46 +0200 |
commit | ee663e96e4db735d19dc2672150b6ccc87cc29fe (patch) | |
tree | bb394ec7cf76e9e94042b8464a5bfa9e41cc4c63 /hw/gpio | |
parent | 74d1e352be53d8208996772bb51c5a965fae7d06 (diff) | |
download | qemu-ee663e96e4db735d19dc2672150b6ccc87cc29fe.zip qemu-ee663e96e4db735d19dc2672150b6ccc87cc29fe.tar.gz qemu-ee663e96e4db735d19dc2672150b6ccc87cc29fe.tar.bz2 |
pl061: Rename pl061_state to PL061State
Signed-off-by: Andreas Färber <afaerber@suse.de>
Diffstat (limited to 'hw/gpio')
-rw-r--r-- | hw/gpio/pl061.c | 62 |
1 files changed, 31 insertions, 31 deletions
diff --git a/hw/gpio/pl061.c b/hw/gpio/pl061.c index a0bbf08..e97ad8a 100644 --- a/hw/gpio/pl061.c +++ b/hw/gpio/pl061.c @@ -28,7 +28,7 @@ static const uint8_t pl061_id[12] = static const uint8_t pl061_id_luminary[12] = { 0x00, 0x00, 0x00, 0x00, 0x61, 0x00, 0x18, 0x01, 0x0d, 0xf0, 0x05, 0xb1 }; -typedef struct { +typedef struct PL061State { SysBusDevice busdev; MemoryRegion iomem; uint32_t locked; @@ -55,39 +55,39 @@ typedef struct { qemu_irq irq; qemu_irq out[8]; const unsigned char *id; -} pl061_state; +} PL061State; static const VMStateDescription vmstate_pl061 = { .name = "pl061", .version_id = 2, .minimum_version_id = 1, .fields = (VMStateField[]) { - VMSTATE_UINT32(locked, pl061_state), - VMSTATE_UINT32(data, pl061_state), - VMSTATE_UINT32(old_data, pl061_state), - VMSTATE_UINT32(dir, pl061_state), - VMSTATE_UINT32(isense, pl061_state), - VMSTATE_UINT32(ibe, pl061_state), - VMSTATE_UINT32(iev, pl061_state), - VMSTATE_UINT32(im, pl061_state), - VMSTATE_UINT32(istate, pl061_state), - VMSTATE_UINT32(afsel, pl061_state), - VMSTATE_UINT32(dr2r, pl061_state), - VMSTATE_UINT32(dr4r, pl061_state), - VMSTATE_UINT32(dr8r, pl061_state), - VMSTATE_UINT32(odr, pl061_state), - VMSTATE_UINT32(pur, pl061_state), - VMSTATE_UINT32(pdr, pl061_state), - VMSTATE_UINT32(slr, pl061_state), - VMSTATE_UINT32(den, pl061_state), - VMSTATE_UINT32(cr, pl061_state), - VMSTATE_UINT32(float_high, pl061_state), - VMSTATE_UINT32_V(amsel, pl061_state, 2), + VMSTATE_UINT32(locked, PL061State), + VMSTATE_UINT32(data, PL061State), + VMSTATE_UINT32(old_data, PL061State), + VMSTATE_UINT32(dir, PL061State), + VMSTATE_UINT32(isense, PL061State), + VMSTATE_UINT32(ibe, PL061State), + VMSTATE_UINT32(iev, PL061State), + VMSTATE_UINT32(im, PL061State), + VMSTATE_UINT32(istate, PL061State), + VMSTATE_UINT32(afsel, PL061State), + VMSTATE_UINT32(dr2r, PL061State), + VMSTATE_UINT32(dr4r, PL061State), + VMSTATE_UINT32(dr8r, PL061State), + VMSTATE_UINT32(odr, PL061State), + VMSTATE_UINT32(pur, PL061State), + VMSTATE_UINT32(pdr, PL061State), + VMSTATE_UINT32(slr, PL061State), + VMSTATE_UINT32(den, PL061State), + VMSTATE_UINT32(cr, PL061State), + VMSTATE_UINT32(float_high, PL061State), + VMSTATE_UINT32_V(amsel, PL061State, 2), VMSTATE_END_OF_LIST() } }; -static void pl061_update(pl061_state *s) +static void pl061_update(PL061State *s) { uint8_t changed; uint8_t mask; @@ -116,7 +116,7 @@ static void pl061_update(pl061_state *s) static uint64_t pl061_read(void *opaque, hwaddr offset, unsigned size) { - pl061_state *s = (pl061_state *)opaque; + PL061State *s = (PL061State *)opaque; if (offset >= 0xfd0 && offset < 0x1000) { return s->id[(offset - 0xfd0) >> 2]; @@ -173,7 +173,7 @@ static uint64_t pl061_read(void *opaque, hwaddr offset, static void pl061_write(void *opaque, hwaddr offset, uint64_t value, unsigned size) { - pl061_state *s = (pl061_state *)opaque; + PL061State *s = (PL061State *)opaque; uint8_t mask; if (offset < 0x400) { @@ -246,7 +246,7 @@ static void pl061_write(void *opaque, hwaddr offset, pl061_update(s); } -static void pl061_reset(pl061_state *s) +static void pl061_reset(PL061State *s) { s->locked = 1; s->cr = 0xff; @@ -254,7 +254,7 @@ static void pl061_reset(pl061_state *s) static void pl061_set_irq(void * opaque, int irq, int level) { - pl061_state *s = (pl061_state *)opaque; + PL061State *s = (PL061State *)opaque; uint8_t mask; mask = 1 << irq; @@ -274,7 +274,7 @@ static const MemoryRegionOps pl061_ops = { static int pl061_init(SysBusDevice *dev, const unsigned char *id) { - pl061_state *s = FROM_SYSBUS(pl061_state, dev); + PL061State *s = FROM_SYSBUS(PL061State, dev); s->id = id; memory_region_init_io(&s->iomem, OBJECT(s), &pl061_ops, s, "pl061", 0x1000); sysbus_init_mmio(dev, &s->iomem); @@ -307,7 +307,7 @@ static void pl061_class_init(ObjectClass *klass, void *data) static const TypeInfo pl061_info = { .name = "pl061", .parent = TYPE_SYS_BUS_DEVICE, - .instance_size = sizeof(pl061_state), + .instance_size = sizeof(PL061State), .class_init = pl061_class_init, }; @@ -323,7 +323,7 @@ static void pl061_luminary_class_init(ObjectClass *klass, void *data) static const TypeInfo pl061_luminary_info = { .name = "pl061_luminary", .parent = TYPE_SYS_BUS_DEVICE, - .instance_size = sizeof(pl061_state), + .instance_size = sizeof(PL061State), .class_init = pl061_luminary_class_init, }; |