Re: [RFT][PATCH v2 3/9] vfio/ccw: Only pass in contiguous pages

2022-07-08 Thread Eric Farman
On Wed, 2022-07-06 at 14:05 -0300, Jason Gunthorpe wrote: > On Tue, Jul 05, 2022 at 11:27:53PM -0700, Nicolin Chen wrote: > > This driver is the only caller of vfio_pin/unpin_pages that might > > pass > > in a non-contiguous PFN list, but in many cases it has a contiguous > > PFN > > list to proces

Re: [RFT][PATCH v2 3/9] vfio/ccw: Only pass in contiguous pages

2022-07-08 Thread Eric Farman
On Tue, 2022-07-05 at 23:27 -0700, Nicolin Chen wrote: > This driver is the only caller of vfio_pin/unpin_pages that might > pass > in a non-contiguous PFN list, but in many cases it has a contiguous > PFN > list to process. So letting VFIO API handle a non-contiguous PFN list > is actually counter

Re: [RFT][PATCH v2 3/9] vfio/ccw: Only pass in contiguous pages

2022-07-06 Thread Jason Gunthorpe
On Tue, Jul 05, 2022 at 11:27:53PM -0700, Nicolin Chen wrote: > This driver is the only caller of vfio_pin/unpin_pages that might pass > in a non-contiguous PFN list, but in many cases it has a contiguous PFN > list to process. So letting VFIO API handle a non-contiguous PFN list > is actually coun

[RFT][PATCH v2 3/9] vfio/ccw: Only pass in contiguous pages

2022-07-05 Thread Nicolin Chen
This driver is the only caller of vfio_pin/unpin_pages that might pass in a non-contiguous PFN list, but in many cases it has a contiguous PFN list to process. So letting VFIO API handle a non-contiguous PFN list is actually counterproductive. Add a pair of simple loops to pass in contiguous PFNs