[PATCH] Staging: comedi: dyna_pci10xx: add mutex_destroy to detach
From: Prashant P. Shah
Date: Thu Jun 09 2011 - 08:19:27 EST
Add mutex_destroy() call to driver detach callback
Signed-off-by: Prashant P. Shah <pshah.mumbai@xxxxxxxxx>
---
drivers/staging/comedi/drivers/dyna_pci10xx.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/drivers/staging/comedi/drivers/dyna_pci10xx.c b/drivers/staging/comedi/drivers/dyna_pci10xx.c
index d8821b9..b561a43 100644
--- a/drivers/staging/comedi/drivers/dyna_pci10xx.c
+++ b/drivers/staging/comedi/drivers/dyna_pci10xx.c
@@ -410,8 +410,10 @@ found:
static int dyna_pci10xx_detach(struct comedi_device *dev)
{
- if (devpriv && devpriv->pci_dev)
+ if (devpriv && devpriv->pci_dev) {
comedi_pci_disable(devpriv->pci_dev);
+ mutex_destroy(&devpriv->mutex);
+ }
return 0;
}
--
1.7.1
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/