Re: [PATCH rdma-next v1 1/4] lib/scatterlist: Refactor sg_alloc_table_from_pages

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

 



On Tue, Sep 15, 2020 at 06:16:43PM +0200, Christoph Hellwig wrote:
> On Thu, Sep 10, 2020 at 04:42:56PM +0300, Leon Romanovsky wrote:
> > From: Maor Gottlieb <maorg@xxxxxxxxxx>
> >
> > Currently, sg_alloc_table_from_pages doesn't support dynamic chaining of
> > SG entries. Therefore it requires from user to allocate all the pages in
> > advance and hold them in a large buffer. Such a buffer consumes a lot of
> > temporary memory in HPC systems which do a very large memory registration.
> >
> > The next patches introduce API for dynamically allocation from pages and
> > it requires us to do the following:
> >  * Extract the code to alloc_from_pages_common.
> >  * Change the build of the table to iterate on the chunks and not on the
> >    SGEs. It will allow dynamic allocation of more SGEs.
> >
> > Since sg_alloc_table_from_pages allocate exactly the number of chunks,
> > therefore chunks are equal to the number of SG entries.
> >
> > Signed-off-by: Maor Gottlieb <maorg@xxxxxxxxxx>
> > Signed-off-by: Leon Romanovsky <leonro@xxxxxxxxxx>
>
> I really don't think this refactoring on its own adds any value,
> it just makes reading the rest of the series harder.

We expected this type of the comment, but decided to send "splitted"
version because it is much easier to squash patches instead of splitting
them later.

We will squash and resubmit.

>
> (functionally it looks correct, though)

Thanks



[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux