Re: [RFC 1/2] scsi core: alloc_cmnd

2007-10-23 Thread Christoph Hellwig
On Fri, Oct 19, 2007 at 12:33:31PM -0600, Matthew Wilcox wrote: > > This fairly naive patch introduces alloc_cmnd and destroy_cmnd. I'm not > exactly happy about passing down the gfp_mask -- I'd prefer to be able > to allocate scsi_cmnds before we grab the queue_lock (and hence get > rid of the p

Re: [RFC 1/2] scsi core: alloc_cmnd

2007-10-23 Thread Boaz Harrosh
On Tue, Oct 23 2007 at 21:15 +0200, Matthew Wilcox <[EMAIL PROTECTED]> wrote: > On Tue, Oct 23, 2007 at 08:46:52PM +0200, Boaz Harrosh wrote: >>> We could also add an alloc_bidi_cmnd/destroy_bidi_cmnd to the shost >>> template. Presumably most commands won't be bidi for any given host, >>> so it'd

Re: [RFC 1/2] scsi core: alloc_cmnd

2007-10-23 Thread Christoph Hellwig
On Tue, Oct 23, 2007 at 11:48:04AM -0600, Matthew Wilcox wrote: > On Tue, Oct 23, 2007 at 06:49:17PM +0200, Boaz Harrosh wrote: > > You know Matthew when you first talked about this, I envisioned > > something else. > > Right, so did I. Christoph felt that alloc_cmnd/destroy_cmnd a la the > VFS l

Re: [RFC 1/2] scsi core: alloc_cmnd

2007-10-23 Thread Matthew Wilcox
On Tue, Oct 23, 2007 at 08:46:52PM +0200, Boaz Harrosh wrote: > > We could also add an alloc_bidi_cmnd/destroy_bidi_cmnd to the shost > > template. Presumably most commands won't be bidi for any given host, > > so it'd be a waste of space to allocate them for all commands. > > Well no one really

Re: [RFC 1/2] scsi core: alloc_cmnd

2007-10-23 Thread Boaz Harrosh
On Tue, Oct 23 2007 at 19:48 +0200, Matthew Wilcox <[EMAIL PROTECTED]> wrote: > On Tue, Oct 23, 2007 at 06:49:17PM +0200, Boaz Harrosh wrote: >> You know Matthew when you first talked about this, I envisioned >> something else. > > Right, so did I. Christoph felt that alloc_cmnd/destroy_cmnd a la

Re: [RFC 1/2] scsi core: alloc_cmnd

2007-10-23 Thread Matthew Wilcox
On Tue, Oct 23, 2007 at 06:49:17PM +0200, Boaz Harrosh wrote: > You know Matthew when you first talked about this, I envisioned > something else. Right, so did I. Christoph felt that alloc_cmnd/destroy_cmnd a la the VFS layer's alloc_inode/destroy_inode was a better route. I didn't have a strong

Re: [RFC 1/2] scsi core: alloc_cmnd

2007-10-23 Thread Boaz Harrosh
On Fri, Oct 19 2007 at 20:33 +0200, Matthew Wilcox <[EMAIL PROTECTED]> wrote: > This fairly naive patch introduces alloc_cmnd and destroy_cmnd. I'm not > exactly happy about passing down the gfp_mask -- I'd prefer to be able > to allocate scsi_cmnds before we grab the queue_lock (and hence get > r