Fix setting RTC

Fixed an issue where setting RTC upper or lower doesn't adjust the other (since the current time has changed since the last timestamp).
This commit is contained in:
joevt 2022-09-15 20:59:56 -07:00
parent 50dbd5eccd
commit ed424ad544

View File

@ -930,12 +930,12 @@ void dppc_interpreter::ppc_mtspr() {
switch (ref_spr) {
case SPR::RTCL_S:
calc_rtcl_value();
rtc_lo = val & 0x3FFFFF80UL;
rtc_timestamp = get_virt_time_ns();
break;
case SPR::RTCU_S:
calc_rtcl_value();
rtc_hi = val;
rtc_timestamp = get_virt_time_ns();
break;
case SPR::TBL_S:
update_timebase(0xFFFFFFFF00000000ULL, val);