diff options
| -rw-r--r-- | drivers/misc/tifm_core.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/misc/tifm_core.c b/drivers/misc/tifm_core.c index ee326136d03b..d61df5c3ac36 100644 --- a/drivers/misc/tifm_core.c +++ b/drivers/misc/tifm_core.c | |||
| @@ -219,8 +219,9 @@ static int tifm_device_remove(struct device *dev) | |||
| 219 | struct tifm_driver *drv = fm_dev->drv; | 219 | struct tifm_driver *drv = fm_dev->drv; |
| 220 | 220 | ||
| 221 | if (drv) { | 221 | if (drv) { |
| 222 | if (drv->remove) drv->remove(fm_dev); | 222 | if (drv->remove) |
| 223 | fm_dev->drv = 0; | 223 | drv->remove(fm_dev); |
| 224 | fm_dev->drv = NULL; | ||
| 224 | } | 225 | } |
| 225 | 226 | ||
| 226 | put_device(dev); | 227 | put_device(dev); |
