From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:60209) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V34gL-0002ue-Nz for qemu-devel@nongnu.org; Sat, 27 Jul 2013 09:37:18 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1V34gJ-0008ET-R3 for qemu-devel@nongnu.org; Sat, 27 Jul 2013 09:37:13 -0400 Received: from cantor2.suse.de ([195.135.220.15]:36052 helo=mx2.suse.de) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V34gJ-0008E7-G7 for qemu-devel@nongnu.org; Sat, 27 Jul 2013 09:37:11 -0400 From: =?UTF-8?q?Andreas=20F=C3=A4rber?= Date: Sat, 27 Jul 2013 15:36:48 +0200 Message-Id: <1374932223-7490-6-git-send-email-afaerber@suse.de> In-Reply-To: <1374932223-7490-1-git-send-email-afaerber@suse.de> References: <1374932223-7490-1-git-send-email-afaerber@suse.de> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Subject: [Qemu-devel] [PATCH qom-next for-1.6 05/20] etraxfs_timer: Rename etrax_timer to ETRAXTimerState List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: "Edgar E. Iglesias" , =?UTF-8?q?Andreas=20F=C3=A4rber?= Signed-off-by: Andreas F=C3=A4rber --- hw/timer/etraxfs_timer.c | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/hw/timer/etraxfs_timer.c b/hw/timer/etraxfs_timer.c index 6dd1072..7e9807d 100644 --- a/hw/timer/etraxfs_timer.c +++ b/hw/timer/etraxfs_timer.c @@ -42,7 +42,7 @@ #define R_INTR 0x50 #define R_MASKED_INTR 0x54 =20 -struct etrax_timer { +typedef struct ETRAXTimerState { SysBusDevice busdev; MemoryRegion mmio; qemu_irq irq; @@ -72,12 +72,12 @@ struct etrax_timer { uint32_t rw_ack_intr; uint32_t r_intr; uint32_t r_masked_intr; -}; +} ETRAXTimerState; =20 static uint64_t timer_read(void *opaque, hwaddr addr, unsigned int size) { - struct etrax_timer *t =3D opaque; + ETRAXTimerState *t =3D opaque; uint32_t r =3D 0; =20 switch (addr) { @@ -103,7 +103,7 @@ timer_read(void *opaque, hwaddr addr, unsigned int si= ze) return r; } =20 -static void update_ctrl(struct etrax_timer *t, int tnum) +static void update_ctrl(ETRAXTimerState *t, int tnum) { unsigned int op; unsigned int freq; @@ -167,7 +167,7 @@ static void update_ctrl(struct etrax_timer *t, int tn= um) } } =20 -static void timer_update_irq(struct etrax_timer *t) +static void timer_update_irq(ETRAXTimerState *t) { t->r_intr &=3D ~(t->rw_ack_intr); t->r_masked_intr =3D t->r_intr & t->rw_intr_mask; @@ -178,21 +178,21 @@ static void timer_update_irq(struct etrax_timer *t) =20 static void timer0_hit(void *opaque) { - struct etrax_timer *t =3D opaque; + ETRAXTimerState *t =3D opaque; t->r_intr |=3D 1; timer_update_irq(t); } =20 static void timer1_hit(void *opaque) { - struct etrax_timer *t =3D opaque; + ETRAXTimerState *t =3D opaque; t->r_intr |=3D 2; timer_update_irq(t); } =20 static void watchdog_hit(void *opaque) { - struct etrax_timer *t =3D opaque; + ETRAXTimerState *t =3D opaque; if (t->wd_hits =3D=3D 0) { /* real hw gives a single tick before reseting but we are a bit friendlier to compensate for our slower execution. */ @@ -206,7 +206,7 @@ static void watchdog_hit(void *opaque) t->wd_hits++; } =20 -static inline void timer_watchdog_update(struct etrax_timer *t, uint32_t= value) +static inline void timer_watchdog_update(ETRAXTimerState *t, uint32_t va= lue) { unsigned int wd_en =3D t->rw_wd_ctrl & (1 << 8); unsigned int wd_key =3D t->rw_wd_ctrl >> 9; @@ -245,7 +245,7 @@ static void timer_write(void *opaque, hwaddr addr, uint64_t val64, unsigned int size) { - struct etrax_timer *t =3D opaque; + ETRAXTimerState *t =3D opaque; uint32_t value =3D val64; =20 switch (addr) @@ -298,7 +298,7 @@ static const MemoryRegionOps timer_ops =3D { =20 static void etraxfs_timer_reset(void *opaque) { - struct etrax_timer *t =3D opaque; + ETRAXTimerState *t =3D opaque; =20 ptimer_stop(t->ptimer_t0); ptimer_stop(t->ptimer_t1); @@ -311,7 +311,7 @@ static void etraxfs_timer_reset(void *opaque) =20 static int etraxfs_timer_init(SysBusDevice *dev) { - struct etrax_timer *t =3D FROM_SYSBUS(typeof (*t), dev); + ETRAXTimerState *t =3D FROM_SYSBUS(typeof (*t), dev); =20 t->bh_t0 =3D qemu_bh_new(timer0_hit, t); t->bh_t1 =3D qemu_bh_new(timer1_hit, t); @@ -340,7 +340,7 @@ static void etraxfs_timer_class_init(ObjectClass *kla= ss, void *data) static const TypeInfo etraxfs_timer_info =3D { .name =3D "etraxfs,timer", .parent =3D TYPE_SYS_BUS_DEVICE, - .instance_size =3D sizeof (struct etrax_timer), + .instance_size =3D sizeof(ETRAXTimerState), .class_init =3D etraxfs_timer_class_init, }; =20 --=20 1.8.1.4