Re: [Qemu-devel] [PATCH v5 12/16] target-or32: Add system instructions

2012-06-19 Thread Jia Liu
Hi Blue, On Wed, Jun 20, 2012 at 2:25 AM, Blue Swirl wrote: > On Tue, Jun 19, 2012 at 8:02 AM, Jia Liu wrote: >> Hi Blue, >> >> Thank you for review. >> Is this code OK? >> >> void HELPER(mtspr)(CPUOpenRISCState * env, >>                   target_ulong ra, target_ulong rb, target_ulong offset) >

Re: [Qemu-devel] [PATCH v5 12/16] target-or32: Add system instructions

2012-06-19 Thread Blue Swirl
On Tue, Jun 19, 2012 at 8:02 AM, Jia Liu wrote: > Hi Blue, > > Thank you for review. > Is this code OK? > > void HELPER(mtspr)(CPUOpenRISCState * env, >                   target_ulong ra, target_ulong rb, target_ulong offset) > { > #ifndef CONFIG_USER_ONLY >    int spr = (ra | offset); >    int id

Re: [Qemu-devel] [PATCH v5 12/16] target-or32: Add system instructions

2012-06-19 Thread Jia Liu
Hi Blue, Thank you for review. Is this code OK? void HELPER(mtspr)(CPUOpenRISCState * env, target_ulong ra, target_ulong rb, target_ulong offset) { #ifndef CONFIG_USER_ONLY int spr = (ra | offset); int idx; switch (spr) { case TO_SPR(0, 0): /* VR */ env

Re: [Qemu-devel] [PATCH v5 12/16] target-or32: Add system instructions

2012-06-18 Thread Blue Swirl
On Mon, Jun 18, 2012 at 1:03 AM, Jia Liu wrote: > Add OpenRISC system instruction support. > > Signed-off-by: Jia Liu > --- >  target-openrisc/Makefile.objs |    3 +- >  target-openrisc/helper.h      |    4 + >  target-openrisc/sys_helper.c  |  233 > + >  

[Qemu-devel] [PATCH v5 12/16] target-or32: Add system instructions

2012-06-17 Thread Jia Liu
Add OpenRISC system instruction support. Signed-off-by: Jia Liu --- target-openrisc/Makefile.objs |3 +- target-openrisc/helper.h |4 + target-openrisc/sys_helper.c | 233 + target-openrisc/translate.c | 20 4 files changed, 259 ins