Re: [PATCH 07/24] arm: scsi convert to accessors and !use_sg cleanup

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, 2007-09-12 at 08:42 +0100, Russell King wrote:
> On Wed, Sep 12, 2007 at 02:55:19AM +0300, Boaz Harrosh wrote:
> > -		if (SCpnt->request_bufflen != len)
> > +		if (scsi_bufflen(SCpnt) != len) {
> > +			WARN_ON(1);
> 
> NAK.  The call trace generally doesn't provide any additional information
> on the cause of the error.
> 
> >  			printk(KERN_WARNING "scsi%d.%c: bad request buffer "
> >  			       "length %d, should be %ld\n", SCpnt->device->host->host_no,
> > -			       '0' + SCpnt->device->id, SCpnt->request_bufflen, len);
> > -		SCpnt->request_bufflen = len;
> > +			       '0' + SCpnt->device->id, scsi_bufflen(SCpnt), len);
> > +		}
> >  #endif
> >  	} else {
> > -		SCpnt->SCp.ptr = (unsigned char *)SCpnt->request_buffer;
> > -		SCpnt->SCp.this_residual = SCpnt->request_bufflen;
> > -		SCpnt->SCp.phase = SCpnt->request_bufflen;
> > -	}
> > -
> > -	/*
> > -	 * If the upper SCSI layers pass a buffer, but zero length,
> > -	 * we aren't interested in the buffer pointer.
> > -	 */
> > -	if (SCpnt->SCp.this_residual == 0 && SCpnt->SCp.ptr) {
> > -#if 0 //def BELT_AND_BRACES
> > -		printk(KERN_WARNING "scsi%d.%c: zero length buffer passed for "
> > -		       "command ", SCpnt->host->host_no, '0' + SCpnt->target);
> > -		__scsi_print_command(SCpnt->cmnd);
> > -#endif
> >  		SCpnt->SCp.ptr = NULL;
> > +		SCpnt->SCp.this_residual = 0;
> > +		SCpnt->SCp.phase = 0;
> >  	}
> >  }
> 
> Also NAK.  This was added due to bad behaviour of the SCSI layer and
> was found to be necessary.

Time is up on this one: this driver now won't build in mainline because
of the promised sg_table updates.  Either you ack the changes or provide
your own.  If not, I'll mark the driver BROKEN.

James


-
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux