mirror of
https://github.com/izzy2lost/xemu.git
synced 2026-07-06 00:20:22 -07:00
hw/timer: Refactor NPCM7XX Timer to use CLK clock
This patch makes NPCM7XX Timer to use a the timer clock generated by the CLK module instead of the magic number TIMER_REF_HZ. Reviewed-by: Havard Skinnemoen <hskinnemoen@google.com> Reviewed-by: Tyrone Ting <kfting@nuvoton.com> Signed-off-by: Hao Wu <wuhaotsh@google.com> Message-id: 20210108190945.949196-3-wuhaotsh@google.com Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
@@ -101,6 +101,7 @@ struct NPCM7xxTimerCtrlState {
|
||||
|
||||
uint32_t tisr;
|
||||
|
||||
Clock *clock;
|
||||
NPCM7xxTimer timer[NPCM7XX_TIMERS_PER_CTRL];
|
||||
NPCM7xxWatchdogTimer watchdog_timer;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user