diff options
author | Tomas Winkler <tomas.winkler@intel.com> | 2012-11-01 21:17:17 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-11-01 12:31:19 -0700 |
commit | c7d3df354dcb7477900b29a1200744a8c976c03a (patch) | |
tree | 173ff046ddf47c3a20267d052f5d15ea08ffb2dd /drivers/misc/mei/wd.c | |
parent | 15ea19105bdeef36820ade6754b9b7f1e3511e98 (diff) |
mei: use internal watchdog device registration tracking
remove bool wd_interface_reg as watchdog device already
keeps track of its registration
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/misc/mei/wd.c')
-rw-r--r-- | drivers/misc/mei/wd.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/misc/mei/wd.c b/drivers/misc/mei/wd.c index 8edb054d4b36..4fc2b3d4680a 100644 --- a/drivers/misc/mei/wd.c +++ b/drivers/misc/mei/wd.c @@ -360,23 +360,20 @@ void mei_watchdog_register(struct mei_device *dev) if (watchdog_register_device(&amt_wd_dev)) { dev_err(&dev->pdev->dev, "wd: unable to register watchdog device.\n"); - dev->wd_interface_reg = false; return; } dev_dbg(&dev->pdev->dev, "wd: successfully register watchdog interface.\n"); - dev->wd_interface_reg = true; watchdog_set_drvdata(&amt_wd_dev, dev); } void mei_watchdog_unregister(struct mei_device *dev) { - if (!dev->wd_interface_reg) + if (test_bit(WDOG_UNREGISTERED, &amt_wd_dev.status)) return; watchdog_set_drvdata(&amt_wd_dev, NULL); watchdog_unregister_device(&amt_wd_dev); - dev->wd_interface_reg = false; } |