AnsweredAssumed Answered

How to add Watchdog in U-boot for 2014 version yocto source

Question asked by Bandaru Lavanya on Aug 3, 2016
Latest reply on Aug 5, 2016 by igorpadykov

Hi All,

 

I added watchdog timer in u boot like below .

in include/configs/imx6dl-sabresd.h

     #define CONFIG_IMX_CONFIG

in /board/freescale/imx6dl-sabresd/imx6dl-sabresd.c

 

int board_late_init(void)

{

        int ret = 0;

#ifdef CONFIG_CMD_BMODE

        add_board_boot_modes(board_boot_modes);

#endif

 

#ifdef CONFIG_SYS_I2C_MXC

        setup_i2c(1, CONFIG_SYS_I2C_SPEED,

                        0x7f, &i2c_pad_info1);

        ret = setup_pmic_voltages();

        if (ret)

                return -1;

#endif

 

#ifdef CONFIG_ENV_IS_IN_MMC

        board_late_mmc_env_init();

#endif

#ifdef CONFIG_IMX_WATCHDOG

        hw_watchdog_init();

#endif

 

        return 0;

}

 

like this.

 

If i stop in u-boot after my time out it is rebooting . if any crash occur in kernel in that time also it is rebooting.

But if file system is not mounted then it is not rebooting how can i achieve that.

and after enabling watchdog in u boot. my wdt_driver_test.out in unit-tests is not working.

unit-tests$ ./wdt_driver_test.out 10 5 0

Here after i given ctrl+c also it is not rebooting.

 

unit-tests$ ./wdt_driver_test.out 1 2 0

In this case also after 1 sec it should reboot but it is not.How can i solve this issue please if any one knows kindly suggest me.

Thanks & Regards,
Lavany

Outcomes