diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/parport/share.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/parport/share.c b/drivers/parport/share.c index b68f19480dcf..3308427ed9f7 100644 --- a/drivers/parport/share.c +++ b/drivers/parport/share.c @@ -1120,7 +1120,8 @@ int parport_claim(struct pardevice *dev) /* Preempt any current device */ write_lock_irqsave(&port->cad_lock, flags); - if ((oldcad = port->cad) != NULL) { + oldcad = port->cad; + if (oldcad) { if (oldcad->preempt) { if (oldcad->preempt(oldcad->private)) goto blocked; |