Loading
rtc: loongson: clear TOY_MATCH0_REG in loongson_rtc_isr()
stable inclusion from stable-v6.6.76 commit 20f0f55e6d686eae7934e28358ea446e36cff77f category: bugfix bugzilla: https://gitee.com/openeuler/kernel/issues/IBQ4JL CVE: NA Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=20f0f55e6d686eae7934e28358ea446e36cff77f -------------------------------- The TOY_MATCH0_REG should be cleared to 0 in the RTC interrupt handler, otherwise the interrupt cannot be cleared, which will cause the loongson_rtc_isr() to be triggered multiple times. The previous code cleared TOY_MATCH0_REG in the loongson_rtc_handler(), which is an ACPI interrupt. This did not prevent loongson_rtc_isr() from being triggered multiple times. This commit moves the clearing of TOY_MATCH0_REG to the loongson_rtc_isr() to ensure that the interrupt is properly cleared. Fixes: 1b733a9e ("rtc: Add rtc driver for the Loongson family chips") Signed-off-by:Ming Wang <wangming01@loongson.cn> Reviewed-by:
Huacai Chen <chenhuacai@loongson.cn> Reviewed-by: Keguang Zhang <keguang.zhang@gmail.com> # on LS1B Tested-by:
Keguang Zhang <keguang.zhang@gmail.com>