Re: [PATCH] block: fix q->max_segment_size checking in blk_recalc_rq_segments about VMERGE

!MAILaRCHIVE_VOTE_RePLACE
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: James Bottomley <James.Bottomley@...>
Cc: FUJITA Tomonori <fujita.tomonori@...>, <jens.axboe@...>, <linux-kernel@...>, <linux-scsi@...>, <davem@...>, <linux-parisc@...>
Date: Tuesday, July 15, 2008 - 11:58 am

You are mixing two ideas here:

(1) virtual merging --- IOMMU maps discontinuous segments into continuous 
area that it presents to the device.

(2) virtual merge accounting --- block layer tries to guess how many 
segments will be created by (1) and merges small requests into big ones. 
The resulting requests are as big that they can't be processed by the 
device if (1) weren't in effect.


--- for these devices virtual merging (1) improves performance, but 
virtual merge accounting (2) doesn't.


Virtual merge accounting (2) is about fitting a request. It is block layer 
technique.


The purpose of (1) virtual merging is to save device's sg slots. The 
purpose of (2) virtual merge accounting is to allow block layer to build 
larger requests. If you remove virtual merge accounting, it will cause no 
increase in number of sg slots used.


That's why I'm proposing to remove virtual merge accounting (2), but leave 
virtual merging (1) itself. The accounting doesn't reduce number of sg 
slots.

Mikulas

--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Re: [PATCH] block: fix q->max_segment_size checking in bl..., Mikulas Patocka, (Tue Jul 15, 11:58 am)
Re: [PATCH] block: fix q-&gt;max_segment_size checking in bl..., John David Anglin, (Thu Jul 24, 10:40 pm)