dev-arm: Fix the address range for some I/O devices
authorNikos Nikoleris <nikos.nikoleris@arm.com>
Mon, 4 Jun 2018 16:50:46 +0000 (17:50 +0100)
committerNikos Nikoleris <nikos.nikoleris@arm.com>
Fri, 15 Jun 2018 10:51:28 +0000 (10:51 +0000)
Previously, many devices were incorrecty configured to respond to an
address range of size 0xfff. This changes fixes this and sets it to
0x1000.

Change-Id: I4b027a27adf60ceae4859e287d7f34443b398752
Reviewed-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/11116
Reviewed-by: Jason Lowe-Power <jason@lowepower.com>
Maintainer: Andreas Sandberg <andreas.sandberg@arm.com>

src/dev/arm/amba_fake.cc
src/dev/arm/kmi.cc
src/dev/arm/pl011.cc
src/dev/arm/rtc_pl031.cc
src/dev/arm/timer_sp804.cc
src/dev/i2c/bus.cc

index 3f8fcd6eebb02e8dc6ff0b99ef94cbbd8379cce5..475ff768a3ea2770785139e5bcaff66a0e8bca0a 100644 (file)
@@ -48,7 +48,7 @@
 #include "mem/packet_access.hh"
 
 AmbaFake::AmbaFake(const Params *p)
-    : AmbaPioDevice(p, 0xfff)
+    : AmbaPioDevice(p, 0x1000)
 {
 }
 
index 70c64e47b7f3237ece2edbe6059a6a4567092603..8055afe2e21232b42b8b56b6ebccf20af34f1c7c 100644 (file)
@@ -52,7 +52,7 @@
 #include "mem/packet_access.hh"
 
 Pl050::Pl050(const Pl050Params *p)
-    : AmbaIntDevice(p, 0xfff), control(0), status(0x43), clkdiv(0),
+    : AmbaIntDevice(p, 0x1000), control(0), status(0x43), clkdiv(0),
       rawInterrupts(0),
       ps2(p->ps2)
 {
index b6b41f9c3b2e3563f41a4888708f12706dab60dc..e47cc6753dc006ac75d95d364e32f7406ef852f4 100644 (file)
@@ -54,7 +54,7 @@
 #include "sim/sim_exit.hh"
 
 Pl011::Pl011(const Pl011Params *p)
-    : Uart(p, 0xfff),
+    : Uart(p, 0x1000),
       intEvent([this]{ generateInterrupt(); }, name()),
       control(0x300), fbrd(0), ibrd(0), lcrh(0), ifls(0x12),
       imsc(0), rawInt(0),
index 3d8e677b98d0a9919f71401897246fdd7394797b..5b6ce52888029c43c104f03743b92609d7e97cb4 100644 (file)
@@ -49,7 +49,7 @@
 #include "mem/packet_access.hh"
 
 PL031::PL031(Params *p)
-    : AmbaIntDevice(p, 0xfff), timeVal(mkutctime(&p->time)),
+    : AmbaIntDevice(p, 0x1000), timeVal(mkutctime(&p->time)),
       lastWrittenTick(0), loadVal(0), matchVal(0),
       rawInt(false), maskInt(false), pendingInt(false),
       matchEvent([this]{ counterMatch(); }, name())
index 86fbc7f057451003dcd1fd2bd894366a4f63dc55..f28ba7bf036969d68cf235ec3da8afe086c01d62 100644 (file)
@@ -48,7 +48,7 @@
 #include "mem/packet_access.hh"
 
 Sp804::Sp804(Params *p)
-    : AmbaPioDevice(p, 0xfff), gic(p->gic),
+    : AmbaPioDevice(p, 0x1000), gic(p->gic),
       timer0(name() + ".timer0", this, p->int_num0, p->clock0),
       timer1(name() + ".timer1", this, p->int_num1, p->clock1)
 {
index af5d6c825a4a2365714021463d8e7cfa606b63bc..bf8cb8701b1bfeed7a26316b8fbd68d833604f59 100644 (file)
@@ -53,7 +53,7 @@ using std::map;
  * http://infocenter.arm.com/help/topic/com.arm.doc.dui0440b/Bbajihec.html
  */
 I2CBus::I2CBus(const I2CBusParams *p)
-    : BasicPioDevice(p, 0xfff), scl(1), sda(1), state(IDLE), currBit(7),
+    : BasicPioDevice(p, 0x1000), scl(1), sda(1), state(IDLE), currBit(7),
       i2cAddr(0x00), message(0x00)
 {
     vector<I2CDevice*> devs = p->devices;