diff options
author | Daniel R. Carvalho <odanrc@yahoo.com.br> | 2019-02-12 14:20:42 +0100 |
---|---|---|
committer | Daniel Carvalho <odanrc@yahoo.com.br> | 2019-04-19 16:34:00 +0000 |
commit | 5fabb992ffa9cbde09105ec21c45e8cff282949e (patch) | |
tree | 5594245bff576134eceb5a6ca84cb491b1d8da3d /src/mem/dram_ctrl.cc | |
parent | 22abf7916e1bce66469020c6fa4d458a13ae84f3 (diff) | |
download | gem5-5fabb992ffa9cbde09105ec21c45e8cff282949e.tar.xz |
mem: Make DRAMCtrl::decodeAddr const
DRAMCtrl's decodeAddr does not need to modify the packet it
receives, nor should it modify the contents of the class,
and therefore both the packet and the function are made const.
Change-Id: I577f48d9a43611ba54878a9a793cb7b4fbb326f4
Signed-off-by: Daniel R. Carvalho <odanrc@yahoo.com.br>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/17540
Tested-by: kokoro <noreply+kokoro@google.com>
Maintainer: Nikos Nikoleris <nikos.nikoleris@arm.com>
Reviewed-by: Nikos Nikoleris <nikos.nikoleris@arm.com>
Diffstat (limited to 'src/mem/dram_ctrl.cc')
-rw-r--r-- | src/mem/dram_ctrl.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mem/dram_ctrl.cc b/src/mem/dram_ctrl.cc index e89a47a72..429e9ef5e 100644 --- a/src/mem/dram_ctrl.cc +++ b/src/mem/dram_ctrl.cc @@ -303,8 +303,8 @@ DRAMCtrl::writeQueueFull(unsigned int neededEntries) const } DRAMCtrl::DRAMPacket* -DRAMCtrl::decodeAddr(PacketPtr pkt, Addr dramPktAddr, unsigned size, - bool isRead) +DRAMCtrl::decodeAddr(const PacketPtr pkt, Addr dramPktAddr, unsigned size, + bool isRead) const { // decode the address based on the address mapping scheme, with // Ro, Ra, Co, Ba and Ch denoting row, rank, column, bank and |