|
@@ -482,7 +482,7 @@ int comedi_device_attach(struct comedi_device *dev, struct comedi_devconfig *it)
|
|
ret = comedi_device_postconfig(dev);
|
|
ret = comedi_device_postconfig(dev);
|
|
if (ret < 0) {
|
|
if (ret < 0) {
|
|
comedi_device_detach(dev);
|
|
comedi_device_detach(dev);
|
|
- module_put(dev->driver->module);
|
|
|
|
|
|
+ module_put(driv->module);
|
|
}
|
|
}
|
|
/* On success, the driver module count has been incremented. */
|
|
/* On success, the driver module count has been incremented. */
|
|
return ret;
|
|
return ret;
|