summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorGabe Black <gblack@eecs.umich.edu>2009-02-25 10:22:49 -0800
committerGabe Black <gblack@eecs.umich.edu>2009-02-25 10:22:49 -0800
commit4a644931589499a444cafe8a7c6eeec614b8bdb7 (patch)
treece2ca12f7dd53c58878378a2a074afcec7a7015a /src
parent7400769768d847b4d7b8f2c27eb78f463c3887a2 (diff)
downloadgem5-4a644931589499a444cafe8a7c6eeec614b8bdb7.tar.xz
Devices: Make the RTC device reflect the use of BCD in its status registers.
Diffstat (limited to 'src')
-rw-r--r--src/dev/mc146818.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/dev/mc146818.cc b/src/dev/mc146818.cc
index 7b219e30c..c01d945b3 100644
--- a/src/dev/mc146818.cc
+++ b/src/dev/mc146818.cc
@@ -49,7 +49,9 @@ MC146818::MC146818(EventManager *em, const string &n, const struct tm time,
{
memset(clock_data, 0, sizeof(clock_data));
stat_regA = RTCA_32768HZ | RTCA_1024HZ;
- stat_regB = RTCB_PRDC_IE |RTCB_BIN | RTCB_24HR;
+ stat_regB = RTCB_PRDC_IE | RTCB_24HR;
+ if (!bcd)
+ stat_regB |= RTCB_BIN;
year = time.tm_year;