Deleted Added
sdiff udiff text old ( 9808:13ffc0066b76 ) new ( 9958:48eb085bc9ab )
full compact
1/*
2 * Copyright (c) 2010 ARM Limited
3 * All rights reserved
4 *
5 * The license below extends only to copyright in the software and shall
6 * not be construed as granting a license to any other intellectual
7 * property including but not limited to intellectual property relating
8 * to a hardware implementation of the functionality of the software
9 * licensed hereunder. You may use the software subject to the license
10 * terms below provided that you ensure that this notice is replicated

--- 22 unchanged lines hidden (view full) ---

33 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
34 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
35 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
36 *
37 * Authors: Ali Saidi
38 */
39
40#include "base/trace.hh"
41#include "dev/arm/rv_ctrl.hh"
42#include "mem/packet.hh"
43#include "mem/packet_access.hh"
44
45RealViewCtrl::RealViewCtrl(Params *p)
46 : BasicPioDevice(p, 0xD4), flags(0)
47{
48}
49
50Tick
51RealViewCtrl::read(PacketPtr pkt)
52{
53 assert(pkt->getAddr() >= pioAddr && pkt->getAddr() < pioAddr + pioSize);
54 assert(pkt->getSize() == 4);

--- 45 unchanged lines hidden (view full) ---

100 pkt->set<uint32_t>(flags);
101 break;
102 case IdReg:
103 pkt->set<uint32_t>(params()->idreg);
104 break;
105 case CfgStat:
106 pkt->set<uint32_t>(1);
107 break;
108 default:
109 warn("Tried to read RealView I/O at offset %#x that doesn't exist\n",
110 daddr);
111 break;
112 }
113 pkt->makeAtomicResponse();
114 return pioDelay;
115
116}
117
118Tick

--- 15 unchanged lines hidden (view full) ---

134 sysLock.lockVal = pkt->get<uint16_t>();
135 break;
136 case Flags:
137 flags = pkt->get<uint32_t>();
138 break;
139 case FlagsClr:
140 flags = 0;
141 break;
142 default:
143 warn("Tried to write RVIO at offset %#x that doesn't exist\n",
144 daddr);
145 break;
146 }
147 pkt->makeAtomicResponse();
148 return pioDelay;
149}
150
151void
152RealViewCtrl::serialize(std::ostream &os)

--- 15 unchanged lines hidden ---