Remove the check for NULL which makes no sense. Suggested by Al. Signed-off-by: Pete Zaitcev <[EMAIL PROTECTED]>
--- linux-2.6.17-rc2/drivers/block/ub.c 2006-04-23 21:05:39.000000000 -0700 +++ linux-2.6.17-rc2-lem/drivers/block/ub.c 2006-04-28 20:19:12.000000000 -0700 @@ -1648,15 +1649,11 @@ static void ub_revalidate(struct ub_dev static int ub_bd_open(struct inode *inode, struct file *filp) { struct gendisk *disk = inode->i_bdev->bd_disk; - struct ub_lun *lun; - struct ub_dev *sc; + struct ub_lun *lun = disk->private_data; + struct ub_dev *sc = lun->udev; unsigned long flags; int rc; - if ((lun = disk->private_data) == NULL) - return -ENXIO; - sc = lun->udev; - spin_lock_irqsave(&ub_lock, flags); if (atomic_read(&sc->poison)) { spin_unlock_irqrestore(&ub_lock, flags); ------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ linux-usb-devel@lists.sourceforge.net To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel