diff options
author | j_mayer <j_mayer@c046a42c-6fe2-441c-8c8c-71466251a162> | 2007-11-03 14:23:07 +0000 |
---|---|---|
committer | j_mayer <j_mayer@c046a42c-6fe2-441c-8c8c-71466251a162> | 2007-11-03 14:23:07 +0000 |
commit | 2e13d23ac089e554fc0efd285ec2176ca36576c7 (patch) | |
tree | 3f9fa9cf3b128358f7f1ab58d0786832e1beaa5b /target-ppc | |
parent | faadf50e2962dd54175647a80bd6fc4319c91973 (diff) |
Fix PowerPC high BATs access: BAT number was incorrect.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3519 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'target-ppc')
-rw-r--r-- | target-ppc/translate_init.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/target-ppc/translate_init.c b/target-ppc/translate_init.c index dcf1e1fd04..0d648de0c1 100644 --- a/target-ppc/translate_init.c +++ b/target-ppc/translate_init.c @@ -241,7 +241,7 @@ static void spr_read_dbat (void *opaque, int sprn) static void spr_read_dbat_h (void *opaque, int sprn) { - gen_op_load_dbat(sprn & 1, (sprn - SPR_DBAT4U) / 2); + gen_op_load_dbat(sprn & 1, ((sprn - SPR_DBAT4U) / 2) + 4); } static void spr_write_dbatu (void *opaque, int sprn) @@ -251,7 +251,7 @@ static void spr_write_dbatu (void *opaque, int sprn) static void spr_write_dbatu_h (void *opaque, int sprn) { - gen_op_store_dbatu((sprn - SPR_DBAT4U) / 2); + gen_op_store_dbatu(((sprn - SPR_DBAT4U) / 2) + 4); } static void spr_write_dbatl (void *opaque, int sprn) @@ -261,7 +261,7 @@ static void spr_write_dbatl (void *opaque, int sprn) static void spr_write_dbatl_h (void *opaque, int sprn) { - gen_op_store_dbatl((sprn - SPR_DBAT4L) / 2); + gen_op_store_dbatl(((sprn - SPR_DBAT4L) / 2) + 4); } /* SDR1 */ |