Deleted Added
sdiff udiff text old ( 3885:fd4067a5b903 ) new ( 3932:62e915bb6704 )
full compact
1/*
2 * Copyright (c) 2004-2005 The Regents of The University of Michigan
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are
7 * met: redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer;

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

80 const std::string &name() const { return _name; }
81
82 /** RTC periodic interrupt event */
83 RTCEvent event;
84
85 /** Current RTC register address/index */
86 int addr;
87
88 /** Data for real-time clock function */
89 union {
90 uint8_t clock_data[10];
91
92 struct {
93 uint8_t sec;
94 uint8_t sec_alrm;
95 uint8_t min;

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

105
106 /** RTC status register A */
107 uint8_t stat_regA;
108
109 /** RTC status register B */
110 uint8_t stat_regB;
111
112 public:
113 RTC(const std::string &name, Tsunami* tsunami, time_t t, Tick i);
114
115 /** RTC address port: write address of RTC RAM data to access */
116 void writeAddr(const uint8_t data);
117
118 /** RTC write data */
119 void writeData(const uint8_t data);
120
121 /** RTC read data */
122 uint8_t readData();
123
124 /**
125 * Serialize this object to the given output stream.
126 * @param base The base name of the counter object.
127 * @param os The stream to serialize to.
128 */
129 void serialize(const std::string &base, std::ostream &os);
130
131 /**

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

308 * @return interrupt rate of the RTC
309 */
310 Tick frequency() const;
311
312 struct Params : public BasicPioDevice::Params
313 {
314 Tick frequency;
315 Tsunami *tsunami;
316 time_t init_time;
317 };
318 protected:
319 const Params *params() const { return (const Params*)_params; }
320
321 public:
322 /**
323 * Initialize all the data for devices supported by Tsunami I/O.
324 * @param p pointer to Params struct
325 */

--- 33 unchanged lines hidden ---