This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

AM335X Omap watchdog timer -Bootstatus

Hello sir,

I am working on am335x based omap-watchdog timer(kernel 3.12,omap_wdt.c). I just need to see the bootstatus or last reboot reason. Currently i can see a parameter "omap_wdt->bootstatus" used to give the bootstatus. But when i try to print it , it always shows  a value of 0.

-------------------------------------------------------------------

if (pdata && pdata->read_reset_sources)
rs = pdata->read_reset_sources();

else
rs = 0;
omap_wdt->bootstatus = (rs & (1 << OMAP_MPU_WD_RST_SRC_ID_SHIFT)) ?
WDIOF_CARDRESET : 0;
pr_info("-----RESET STATUS------- %0x",omap_wdt->bootstatus);

---------------------------------------------------------

 Any help is highly appreciable.

Regards

Surya

  • I will forward this to the software team. They will respond here.
  • Hi Surya,

    the problem is that the function read_reset_sources() is not defined for am33xx in <kernel>/arch/arm/mach-omap2/prm33xx.c.
    You may check this thread for more detailed description of the issue:

    e2e.ti.com/.../419216

    You may try to declare and assign read_reset_sources() in <kernel>/arch/arm/mach-omap2/prm33xx.c in a similar manner as it is done in
    <kernel>/arch/arm/mach-omap2/prm44xx.c and <kernel>/arch/arm/mach-omap2/prm3xxx.c (look for omap44xx_prm_read_reset_sources() and omap3xxx_prm_read_reset_sources() there).

    Also with the command "devmem2 0x44E00F08" from linux console you can get the value of the PRM_RSTST, this may be useful to compare with what you get in the kernel to see if you read the register correctly there.

    Regards,
    Yordan