Browse Source

staging: comedi: comedi_bond: no need to free dev->private on detach

The comedi core will free `dev->private` if it is non-NULL after calling
the "detach" handler (`bonding_detach()`), so don't bother freeing it in
`bonding_detach()`.

Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Ian Abbott 12 years ago
parent
commit
c2af5b9681
1 changed files with 0 additions and 2 deletions
  1. 0 2
      drivers/staging/comedi/drivers/comedi_bond.c

+ 0 - 2
drivers/staging/comedi/drivers/comedi_bond.c

@@ -355,8 +355,6 @@ static void bonding_detach(struct comedi_device *dev)
 		}
 		kfree(devpriv->devs);
 		devpriv->devs = NULL;
-		kfree(devpriv);
-		dev->private = NULL;
 	}
 }