Re: [PATCH] ion: scatterlist offset not used for buffer map

2016-04-11 Thread John Einar Reitan
> I don't think this is right. A compound_page still has a page struct > for every page, you should be passing the page struct where your data > starts. Using an offset > PAGE_SIZE is going to break lots of places, > for example anywhere that uses kmap(sg_page(sg)). Was kind-of expecting that re

Re: [PATCH] ion: scatterlist offset not used for buffer map

2016-04-08 Thread Colin Cross
On Thu, Apr 7, 2016 at 11:56 PM, John Einar Reitan wrote: > On Thu, Apr 07, 2016 at 12:37:50PM -0700, Laura Abbott wrote: >> On 04/07/2016 04:29 AM, John Einar Reitan wrote: >> > ion's default user/kernel page mapping code don't honor the offset >> > option for scatterlists. It uses sg_page and ex

Re: [PATCH] ion: scatterlist offset not used for buffer map

2016-04-08 Thread Laura Abbott
On 04/07/2016 11:56 PM, John Einar Reitan wrote: On Thu, Apr 07, 2016 at 12:37:50PM -0700, Laura Abbott wrote: On 04/07/2016 04:29 AM, John Einar Reitan wrote: ion's default user/kernel page mapping code don't honor the offset option for scatterlists. It uses sg_page and expect the whole page t

Re: [PATCH] ion: scatterlist offset not used for buffer map

2016-04-07 Thread John Einar Reitan
On Thu, Apr 07, 2016 at 12:37:50PM -0700, Laura Abbott wrote: > On 04/07/2016 04:29 AM, John Einar Reitan wrote: > > ion's default user/kernel page mapping code don't honor the offset > > option for scatterlists. It uses sg_page and expect the whole page to be > > mapped, while the offset could dic

Re: [PATCH] ion: scatterlist offset not used for buffer map

2016-04-07 Thread Laura Abbott
On 04/07/2016 04:29 AM, John Einar Reitan wrote: ion's default user/kernel page mapping code don't honor the offset option for scatterlists. It uses sg_page and expect the whole page to be mapped, while the offset could dictate an offset within a large page. sg_phys correctly accounts for the of

[PATCH] ion: scatterlist offset not used for buffer map

2016-04-07 Thread John Einar Reitan
ion's default user/kernel page mapping code don't honor the offset option for scatterlists. It uses sg_page and expect the whole page to be mapped, while the offset could dictate an offset within a large page. sg_phys correctly accounts for the offset, so should be used instead. Signed-off-by: Jo