[PATCH 2/2] watchdog: mtk_wdt: Add support for MT6735 WDT
Guenter Roeck
linux at roeck-us.net
Thu Oct 17 07:09:45 PDT 2024
On 10/16/24 23:43, yassine.oudjana at gmail.com wrote:
...
>>>
>>> Say I don't want to use the watchdog (which I don't, all I need from TOPRGU is the resets, I don't care about the watchdog). Not starting the watchdog means I can't reset the system because all mtk_wdt_restart will do is make TOPRGU send me an IRQ that I have no use for.
>>
>> If you don't want to use the watchdog, then you don't need to care about bark
>> interrupts and you don't need any mtk_wdt_restart() functionality at all :-)
>
> I need mtk_wdt_restart to restart my system. I shouldn't need to take off my phone's back cover and remove the battery every time :)
>
>>
> I think what Guenter said makes sense. We should make sure the watchdog is started when calling mtk_wdt_restart or at least configured in such a way that we are sure it will issue a system reset.
>
It is more than that. There is no limitation in the watchdog API that says
"you must only use the watchdog kernel driver to reset the system if the
watchdog has been activated from userspace". Such a limitation would be
completely arbitrary and not make any sense. It is perfectly fine to enable
the watchdog from the restart callback if needed. Actually, all restart
handlers in watchdog drivers have to do that if they indeed use a watchdog
to reset the system.
Actually, I am not entirely sure I understand what we are arguing about.
Guenter
More information about the Linux-mediatek
mailing list