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.

PROCESSOR-SDK-AM335X: Unable to enable watchdog in SPL in SDK 8.02

Part Number: PROCESSOR-SDK-AM335X

I am unable to find a way to build my SPL/MLO with the watchdog being enabled.

When linking I get unresolved references to hw_watchdog_reset and hw_watchdog_init.

I have tried a lot of different combinations in my defconfig. Right now I think I have all configs that I can find enabled:

CONFIG_WDT=y
CONFIG_WATCHDOG=y
CONFIG_SPL_WATCHDOG_SUPPORT=y
CONFIG_OMAP_WATCHDOG=y
CONFIG_HW_WATCHDOG=y
CONFIG_WDT_OMAP3=y
CONFIG_SPL_WDT=y
I am not sure all are required, but for testing. I can link in some combinations, but then the watchdot are not enabled.
Does anyone have a hint on how to get the watchdog running already in SPL.

  • I think the right combination is:

    CONFIG_WDT=y
    CONFIG_WATCHDOG=n
    CONFIG_WDT_OMAP3=y
    CONFIG_SPL_WDT=y
    This seems to activate the DM and remove calls to the hw_watchdog_? functions.
    But still outputs "WDT:   Not found!" in MLO
  • Hello Thomas,
    I tested SDK8.2 WDT on AM335x GP EVM.
    The attached screenshot lists where WDT is enabled in SPL.

    I'm also attaching the matching call flow for your reference.
    Best,
    -Hong

    B::Register
    N _  R0          0  R8   4030CDCC  ^S+ ^Stack_+
    Z Z  R1          0  R9   81FFFF20
    C _  R2       4444  R10  00029940
    V _  R3   44E35000  R11  00029940
    Q _  R4          2  R12  4030F734
         R5   402F047C  R13  81FFFEC8
    0 _  R6          2  R14  403019BB
    1 _  R7   4030CB7C  PC   40301A12
    2 _  SPSR        0  CPSR 400001B3
    3 _
    4 _  USR:           FIQ:
         R8   4030CDCC  R8   10800008
         R9   81FFFF20  R9       0100
    I I  R10  00029940  R10         0
    F _  R11  00029940  R11  18200000
         R12  4030F734  R12  08040080
    T T  R13         0  R13         0
    J _  R14         0  R14         0
    svc                 SPSR        0
    nsec
         SVC:           IRQ:
    A A  R13  81FFFEC8  R13  C95FBFF8
    E _  R14  403019BB  R14  D53FBBB5
         SPSR        0  SPSR        0
    0 _
    1 _  UND:           ABT:
    2 _  R13  00108000  R13         0
    3 _  R14      10C0  R14         0
         SPSR        0  SPSR        0
    
         MON:
         R13
         R14
         SPSR
    B::Var.Frame_/Locals_/Caller
    -000|hw_watchdog_init()
        |  wdt = 0x44E35000
        |  __v = 0x4444
        |
    -001|spl_board_init()
        |
        |#endif
        |#if defined(CONFIG_HW_WATCHDOG) || defined(CONFIG_WATCHDOG)
     303|        hw_watchdog_init();
    -002|board_init_r(dummy1 = ?, dummy2 = ?)
        |  dummy1 = ?
        |  dummy2 = ?
        |  spl_boot_list = (0x0, 0x0, 0x0, 0x0, 0x0)
        |  spl_image = (name = 0x0, os = 0x11, load_addr = 0x80800000, entry_point = 0x80800000, fdt_addr = 0x8088508C, boot_device = 0x8, size = 0x0008508C, flags = 0x2, arg = 0x88000000)
        |
        |#endif
        |        if (CONFIG_IS_ENABLED(BLOBLIST)) {
        |                ret = bloblist_init();
        |                if (ret) {
        |                        debug("%s: Failed to set up bloblist: ret=%d\n",
        |                              __func__, ret);
        |                        puts(SPL_TPL_PROMPT "Cannot set up bloblist\n");
        |                        hang();
        |                }
        |        }
        |        if (CONFIG_IS_ENABLED(HANDOFF)) {
        |...
        |                ret = setup_spl_handoff();
        |                if (ret) {
        |                        puts(SPL_TPL_PROMPT "Cannot set up SPL handoff\n");
        |                        hang();
        |                }
        |        }
        |
        |#if CONFIG_IS_ENABLED(BOARD_INIT)
     641|        spl_board_init();
    -003|board_init_r(dummy1 = ???, dummy2 = ???)
        |  dummy1 = ???
        |  dummy2 = ???
        |  spl_boot_list = (0x0, 0x0, 0x0, 0x0, 0x0)
        |  spl_image = (name = 0x0, os = 0x11, load_addr = 0x80800000, entry_point = 0x80800000, fdt_addr = 0x8088508C, boot_device = 0x8, size = 0x0008508C, flags = 0x2, arg = 0x88000000)
        |
        |}
        |
        |#ifndef BOOT_DEVICE_NONE
        |#define BOOT_DEVICE_NONE 0xdeadbeef
        |#endif
    

  • What was the defconfig settings used for this?

  • Hello Thomas,
    am335x_evm_defconfig
    Best,
    -Hong