[PATCH 2/2] watchdog: imxwd: populate device pointer when registering restart handler

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



To make it possible to select a specific i.MX watchdog by device name,
when multiple were registered, populate the new optional
struct restart_handler::dev member.

Signed-off-by: Ahmad Fatoum <a.fatoum@xxxxxxxxxxxxxx>
---
 drivers/watchdog/imxwd.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/watchdog/imxwd.c b/drivers/watchdog/imxwd.c
index 616248af3863..2ec9d0d59635 100644
--- a/drivers/watchdog/imxwd.c
+++ b/drivers/watchdog/imxwd.c
@@ -306,6 +306,7 @@ static int imx_wd_probe(struct device *dev)
 	priv->restart.name = "imxwd";
 	priv->restart.restart = imxwd_force_soc_reset;
 	priv->restart.priority = RESTART_DEFAULT_PRIORITY;
+	priv->restart.dev = &priv->wd.dev;
 
 	restart_handler_register(&priv->restart);
 
-- 
2.39.2





[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux