Re: [PATCH, RFC]: move full command queue handling into fabric drivers

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

 



On Wed, 2011-11-30 at 05:17 -0500, Christoph Hellwig wrote:
> On Tue, Nov 29, 2011 at 11:27:13PM -0800, Nicholas A. Bellinger wrote:
> > So I'm still undecided if pushing this completely out into fabric
> > drivers in order to drop the current complexity of queue full with
> > target-core is a better tradeoff for not..
> > 
> > This type of core internal queue-full handling is used by ib_srpt and
> > other fabrics potentially using ACK_KREF, so I think we want to at least
> > still handle generically for fabrics (if necessary) that need it atm.
> 
> How exactly do they use it?
> 

WRITEs signal a requeue of se_cmd with write-pending payload in another
transport_processing_thread context after the initial process context
returned -EAGAIN or -ENOMEM..

For READs + non GOOD status, use the same errnos to queue up attempts in
transport_processing_thread context to get a hardware fabric descriptor
resource.

> Note that we really can't do better than the dumb busy waiting done now
> in the core code. 

...

>  The ressources generally are per-hba, and without
> introducing a huge mess of methods for waiting and wakeups it's
> impossible to get this right outside the drivers.  Now that we use
> workqueues for the submission and completion pathes blocing inside
> ->queue_data_in and ->queue_status isn't a problem, and all these issues
> can be fixed pretty trivially by adding a waitqueue in the driver.
> 

Don't we still want to be able to enforce target_submit_cmd() write
ordering on queue-full, instead of leaving this completely up being done
by fabrics..?

> > > +	}
> > > +
> > > +	return error;
> > >  }
> > >  EXPORT_SYMBOL(qla_tgt_xmit_response);
> > >  
> > 
> > Note outgoing TFO->write_pending() -> qla_tgt_rdy_to_xfer() failures
> > will also need to be addressed for this to work as expected for FCP
> > WRITE.
> 
> Indeed.  But it's just another waiter on the waitqueue.  What's more
> important is finding out where it should be woken.
> 
> Given that you wrote the initial code - what is the actual resource
> the we run out of, and where does it get used/released? 

Running out of HW fabric descriptors for HW target mode fabrics.
Anyways, I'm fine with it once write_pending for qla2xxx and ib_srpt can
be sorted out as well.

--nab


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


[Index of Archives]     [Linux SCSI]     [Kernel Newbies]     [Linux SCSI Target Infrastructure]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Device Mapper]

  Powered by Linux