summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSamuel Iglesias Gonsálvez <siglesias@igalia.com>2012-09-11 13:35:06 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-09-11 12:18:11 -0700
commit7273b88ebfc1b3ea5387e37fae8b1d77e59e169f (patch)
tree649843aae4f12dc51f8108b856cefbc3e60135ab
parentb442bf738454d5eeaf695e45051e9fa7242bb9a3 (diff)
Staging: ipack/bridges/tpci200: fix the uninstall the ipack device
Using the call to the ipack_device_unregister() function to avoid the strange way it was doing, as the device model will take care of calling the bus's .remove function when a device is being unregistered. Signed-off-by: Samuel Iglesias Gonsálvez <siglesias@igalia.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/staging/ipack/bridges/tpci200.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/staging/ipack/bridges/tpci200.c b/drivers/staging/ipack/bridges/tpci200.c
index b92814067061..77e6392fee08 100644
--- a/drivers/staging/ipack/bridges/tpci200.c
+++ b/drivers/staging/ipack/bridges/tpci200.c
@@ -385,7 +385,6 @@ static int tpci200_slot_unregister(struct ipack_device *dev)
return -ERESTARTSYS;
tpci200->slots[dev->slot].dev = NULL;
- ipack_device_unregister(dev);
mutex_unlock(&tpci200->mutex);
return 0;
@@ -614,7 +613,7 @@ static void tpci200_uninstall(struct tpci200_board *tpci200)
int i;
for (i = 0; i < TPCI200_NB_SLOT; i++)
- tpci200_slot_unregister(tpci200->slots[i].dev);
+ ipack_device_unregister(tpci200->slots[i].dev);
tpci200_unregister(tpci200);
kfree(tpci200->slots);