Skip to contentSkip to conversation

watchdog: ar9344-wdt: disable watchdog in probe

PATCH Applied Oleksij Rempel 2 participants 4 messages Feb 28, 2018 – Mar 1, 2018

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/2 watchdog: ar9344-wdt: disable watchdog in probe

This should avoid of triggering reset if we boot barebox from barebox.

---
 drivers/watchdog/ar9344_wdt.c | 2 ++
 1 file changed, 2 insertions(+)
drivers/watchdog/ar9344_wdt.c +2 -0
index d570cb40f..b61786b1b 100644
@@ -101,6 +101,8 @@ static int ar9344_wdt_probe(struct device_d *dev)
 	dev->priv = priv;
 
 	ar9344_watchdog_detect_reset_source(priv);
+	/* disable watchdog on probe */
+	iowrite32be(0, priv->base + AR9344_WD_REG_CTRL);
 
 	priv->clk = clk_get(dev, NULL);
 	if (IS_ERR(priv->clk)) {
Signature · 7 lines
2.14.1


_______________________________________________
barebox mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/barebox
#1 lore raw

PATCH 2/2 MIPS: dts: enable heartbeat led for ar9331-dptechnics-dpt-module

---
 arch/mips/dts/ar9331-dptechnics-dpt-module.dts | 6 ++++++
 1 file changed, 6 insertions(+)
arch/mips/dts/ar9331-dptechnics-dpt-module.dts +6 -0
index 39eb36600..2c38bbc09 100644
@@ -12,6 +12,12 @@
 			device-path = &spiflash, "partname:barebox-environment";
 		};
 	};
+
+	leds {
+		system {
+			barebox,default-trigger = "heartbeat";
+		};
+	};
 };
 
 &spiflash {
Signature · 7 lines
2.14.1


_______________________________________________
barebox mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/barebox
Applied
#2 lore raw

Re: [PATCH v1 2/2] MIPS: dts: enable heartbeat led for ar9331-dptechnics-dpt-module

Quoted 5 lines · Oleksij Rempel
---
 arch/mips/dts/ar9331-dptechnics-dpt-module.dts | 6 ++++++
 1 file changed, 6 insertions(+)

Applied, thanks

Sascha

Quoted 26 lines
arch/mips/dts/ar9331-dptechnics-dpt-module.dts +6 -0
index 39eb36600..2c38bbc09 100644
@@ -12,6 +12,12 @@
 			device-path = &spiflash, "partname:barebox-environment";
 		};
 	};
+
+	leds {
+		system {
+			barebox,default-trigger = "heartbeat";
+		};
+	};
 };
 
 &spiflash {
Signature · 7 lines
2.14.1


_______________________________________________
barebox mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/barebox
Signature · 9 lines
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/barebox
#3 lore raw
In reply to Oleksij Rempel
Quoted 13 lines · Oleksij Rempel

This should avoid of triggering reset if we boot barebox from barebox.

---
 drivers/watchdog/ar9344_wdt.c | 2 ++
 1 file changed, 2 insertions(+)
drivers/watchdog/ar9344_wdt.c +0 -0
index d570cb40f..b61786b1b 100644

drivers/watchdog/ar9344_wdt.c static int ar9344_wdt_probe(struct device_d *dev) · line 105

Quoted 5 lines
drivers/watchdog/ar9344_wdt.c +2 -0
@@ -101,6 +101,8 @@ static int ar9344_wdt_probe(struct device_d *dev)
 	dev->priv = priv;
 
 	ar9344_watchdog_detect_reset_source(priv);
+	/* disable watchdog on probe */
+	iowrite32be(0, priv->base + AR9344_WD_REG_CTRL);

Do we really want this? I would assume that if the watchdog is enabled here, then it is enabled on purpose and disabling it just bypasses this purpose.

Sascha

Signature · 9 lines
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/barebox