Commit 09471d8f authored by Ming Wang's avatar Ming Wang Committed by Alexandre Belloni
Browse files

rtc: loongson: clear TOY_MATCH0_REG in loongson_rtc_isr()



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: default avatarMing Wang <wangming01@loongson.cn>
Reviewed-by: default avatarHuacai Chen <chenhuacai@loongson.cn>
Reviewed-by: Keguang Zhang <keguang.zhang@gmail.com> # on LS1B
Tested-by: default avatarKeguang Zhang <keguang.zhang@gmail.com>
Link: https://lore.kernel.org/r/20241205114307.1891418-1-wangming01@loongson.cn


Signed-off-by: default avatarAlexandre Belloni <alexandre.belloni@bootlin.com>
parent 3ab8c5ed
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment