diff options
author | Pratyush Anand <panand@redhat.com> | 2015-08-20 11:35:01 +0300 |
---|---|---|
committer | Wim Van Sebroeck <wim@iguana.be> | 2015-09-09 22:39:22 +0300 |
commit | 6551881c86c791237a3bebf11eb3bd70b60ea782 (patch) | |
tree | 5cabc7c23f588551e777080504336d0acf0b293a /drivers/watchdog/da9052_wdt.c | |
parent | bf5125d5e0759a0f513b1bcd33c15edc0cf4c17b (diff) | |
download | linux-6551881c86c791237a3bebf11eb3bd70b60ea782.tar.xz |
Watchdog: Fix parent of watchdog_devices
/sys/class/watchdog/watchdogn/device/modalias can help to identify the
driver/module for a given watchdog node. However, many wdt devices do not
set their parent and so, we do not see an entry for device in sysfs for
such devices.
This patch fixes parent of watchdog_device so that
/sys/class/watchdog/watchdogn/device is populated.
Exceptions: booke, diag288, octeon, softdog and w83627hf -- They do not
have any parent. Not sure, how we can identify driver for these devices.
Signed-off-by: Pratyush Anand <panand@redhat.com>
Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de>
Acked-by: Guenter Roeck <linux@roeck-us.net>
Acked-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Acked-by: Lee Jones <lee.jones@linaro.org>
Acked-by: Lubomir Rintel <lkundrak@v3.sk>
Acked-by: Maxime Coquelin <maxime.coquelin@st.com>
Acked-by: Thierry Reding <treding@nvidia.com>
Acked-by: Viresh Kumar <viresh.kumar@linaro.org>
Acked-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
Diffstat (limited to 'drivers/watchdog/da9052_wdt.c')
-rw-r--r-- | drivers/watchdog/da9052_wdt.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/watchdog/da9052_wdt.c b/drivers/watchdog/da9052_wdt.c index 2e9589652e1e..67e67977bd29 100644 --- a/drivers/watchdog/da9052_wdt.c +++ b/drivers/watchdog/da9052_wdt.c @@ -195,6 +195,7 @@ static int da9052_wdt_probe(struct platform_device *pdev) da9052_wdt->timeout = DA9052_DEF_TIMEOUT; da9052_wdt->info = &da9052_wdt_info; da9052_wdt->ops = &da9052_wdt_ops; + da9052_wdt->parent = &pdev->dev; watchdog_set_drvdata(da9052_wdt, driver_data); kref_init(&driver_data->kref); |