Watchdog on verdin with Linux

Hi all,

  1. I’m trying to understand which device is used on verdin to implement the HW watchdog. Is it a device inside the i.mx8m?

  2. How can I change the watchdog timeout?

  3. Is it possible to start the timeout already in uboot to guard the boot sequence?

Ok, forget about Q1, I looked in the device tree and I see it’s WDOG1,2,3 of the i.mx8m

Greetings @klausci,

Unfortunately the watchdog interface is something that we have done no extra work on internally. What this means is that anything NXP supports about the i.MX8M Mini’s watchdog “should” be supported by our BSP and standard Linux drivers/interfaces. I apologize for not being able to provide more information here.

Best Regards,
Jeremias

Hello Jermias,
Honestly, I think every serious embedded project needs a watchdog to restart the board if the software hangs, so I’m really surprised that the Watchdog seems to be untested on Verdin.
Are there any plans when Toradex will test it and provide more information?
Thanks, Klaus

Hi @klausci,

Currently we do have it planned with the Verdin to verify and document it’s Watchdog. I can’t give any rough time/roadmap estimates here as this work is dependent on some other tasks as well as pending possible future hardware changes to the Verdin that could affect the work surrounding the Watchdog.

Best Regards,
Jeremias

Hi @jeremias.tx ,
I did some investigation. I can confirm that the watchdog is basically working.

It is using the imx2 driver, which supports the IMX8M internal Watchdog1. The watchdog default timeout is 60s:

imx2-wdt 30280000.wdog: timeout 60 sec (nowayout=0)

When I do an “echo >/dev/watchdog”, the device resets after 60s.

What I still couldn’t find out:

  • How to enable the watchdog already in uboot to guard the boot sequence

Best Regards, Klaus

Hi @klausci,

About bringing up the Watchdog early during U-Boot. This is actually an interesting question we have asked internally recently. Let me check with our development teams and see if they had put anymore thought into this, that I can share with you.

Best Regards,
Jeremias

HI @klausci

Sorry for the delayed answer.

Regarding Watchdog in U-Boot, one can integrate the watchdog driver in U-Boot or much easier use some I2C commands to trigger the watchdog.

However you should not do anything regarding watchdog in current hardware version since the Watchdog will different in next Hardware version.

Best regards,
Jaski

Hello @jaski.tx ,

Thanks for your reply, but it confuses me.

  1. You said, one could use I2C commands to trigger the watchdog. From my understanding, the watchdog of the verdin is an IMX8M chip internal watchdog, and its registers are memory mapped. So I2C commands would not work.

  2. Regarding the mentioned hardware change: We are using the verdin module. Are you talking also about the verdin? If yes: What is the reason to change the watchog? When is this change planned?

BR, Klaus

Hi

you are welcome.

I was talking more about the PMIC Watchdog which is currently Rohm BD71847 and in future it will be NXP PCA9450 for the next hardware version.

Regarding the hardware changes, it will be introduced in next hardware version.

Best regards,
Jaski

Hello @jaski.tx ,

  1. But the /dev/watchdog is not servicing the PMIC watchdog. It is servicing the I.MX8M internal watchdog. So if we stick to this watchdog, no change is required with the next hardware version. Correct?

  2. Can you provide a date, when the next hardware version will be available?

Regards, Klaus

Hi @klausci

If you stick to /dev/watchdog then you can map the internal or external watchdog to it. Unfortunately I cannot say more about this topic.
The next hardware version is planned for end of November.

Best regards,
Jaski

Hi @jaski.tx
Can we get an update on this question? I have just designed a WDT onto our carrier board to manage this. Would be better if we can use the IMX8MM internal one.
Also, the PCA9450 does not appear to have a WDT function. I think it is just a PMIC, ideally the IMX8MM internal WDT would control the signals to it to power cycle the board.
Can you share the roadmap for this function if it is not in place already?
Thanks
Ed

Hi @jaski.tx
Can we get an update on this question? I have just designed a WDT onto our carrier board to manage this. Would be better if we can use the IMX8MM internal one.
Also, the PCA9450 does not appear to have a WDT function. I think it is just a PMIC, ideally the IMX8MM internal WDT would control the signals to it to power cycle the board.
Can you share the roadmap for this function if it is not in place already?
Thanks
Ed

Hi @edwaugh

Can we get an update on this question?

Yes, the Watchdog is working on the Verdin iMX8MM V1.1A.

I have just designed a WDT onto our carrier board to manage this

This choice will depend on the Safety Level of your Product.

Would be better if we can use the IMX8MM internal one.

We are using the internal Watchdog of SoC to reset the SoM.

Also, the PCA9450 does not appear to have a WDT function. I think it is just a PMIC, ideally the IMX8MM internal WDT would control the signals to it to power cycle the board

Yes, that’s true. Currently, we are triggering the PMIC to pull the Reset Line of the SoC and we do a complete power down/up of the PowerRails.

Can you share the roadmap for this function if it is not in place already?

It is already implemented. You would need the V1.1A of the Verdin iMX8MM module and the newest nightly Build from CI-Feeds.

Best regards,
Jaski