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

Re: [Xen-devel] [RESEND PATCH] xen/blkfront: convert to blk-mq APIs



On Mon, Jul 06, 2015 at 05:56:48PM +0800, Bob Liu wrote:
> From: Arianna Avanzini <avanzini.arianna@xxxxxxxxx>
> 
> This patch converts xen-blkfront driver to use the block multiqueue APIs.
> Only one hardware queue is used now, so there is no performance change.
> 
> The legacy non-mq code was deleted completely which is the same as other 
> drivers
> like virtio, mtip, and nvme.
> 
> Also dropped unnecessary holding of info->io_lock when calling into blk-mq 
> APIs.

Yeey!

Two points:

 - The io_lock is now used to guard against concurrent access to the ring.
   We should rename it to 'ring_lock'.

 - The kick_pending_request_queues should have an extra argument - 'bool 
locked'.
   This is so that you don't drop and immediately grab the lock from the 
blkif_interrupt.

   See:

> @@ -1243,9 +1243,8 @@ static irqreturn_t blkif_interrupt(int irq, void 
> *dev_id)
>       } else
>               info->ring.sring->rsp_event = i + 1;
>  
> -     kick_pending_request_queues(info);
> -
>       spin_unlock_irqrestore(&info->io_lock, flags);
> +     kick_pending_request_queues(info);
>  
>       return IRQ_HANDLED;
>  }

Otherwise Reviewed-by: Konrad Rzeszutek Wilk <konrad.wilk@xxxxxxxxxx>

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.