]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
imx: imx8mm-cl-iot-gate: enable pinctrl_wdog in SPL
authorPeng Fan <peng.fan@nxp.com>
Sat, 11 Jun 2022 12:21:03 +0000 (20:21 +0800)
committerStefano Babic <sbabic@denx.de>
Tue, 14 Jun 2022 19:33:14 +0000 (21:33 +0200)
Mark pinctrl_wdog as u-boot,dm-spl to clean up board code,

The set_wdog_reset() function is not necessary as this is handled by
the imx_watchdog.c driver due to the 'fsl,ext-reset-output' property
being set.

Signed-off-by: Peng Fan <peng.fan@nxp.com>
arch/arm/dts/imx8mm-cl-iot-gate-u-boot.dtsi
board/compulab/imx8mm-cl-iot-gate/spl.c

index 433b02cceeef069dcdf68318bd76dfcc8050b173..a7044b63699ff04c77e6ca4c1c6c3409d460ef3b 100644 (file)
        u-boot,dm-spl;
 };
 
+&pinctrl_wdog {
+       u-boot,dm-spl;
+};
+
 &uart3 {
        u-boot,dm-spl;
 };
index f183704c9d2f3be74e6a76115a30677474fe2721..d2d20269ba07ea1df40071dc9ab010c2482f67d3 100644 (file)
@@ -83,23 +83,6 @@ int board_fit_config_name_match(const char *name)
 }
 #endif
 
-#define WDOG_PAD_CTRL  (PAD_CTL_DSE6 | PAD_CTL_ODE | PAD_CTL_PUE | PAD_CTL_PE)
-
-static iomux_v3_cfg_t const wdog_pads[] = {
-       IMX8MM_PAD_GPIO1_IO02_WDOG1_WDOG_B  | MUX_PAD_CTRL(WDOG_PAD_CTRL),
-};
-
-int board_early_init_f(void)
-{
-       struct wdog_regs *wdog = (struct wdog_regs *)WDOG1_BASE_ADDR;
-
-       imx_iomux_v3_setup_multiple_pads(wdog_pads, ARRAY_SIZE(wdog_pads));
-
-       set_wdog_reset(wdog);
-
-       return 0;
-}
-
 static int power_init_board(void)
 {
        struct udevice *dev;
@@ -141,8 +124,6 @@ void board_init_f(ulong dummy)
 
        arch_cpu_init();
 
-       board_early_init_f();
-
        init_uart_clk(2);
 
        timer_init();