[lkml]   [2019]   [May]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH v4 1/3] USB: use genalloc for USB HCs with local memory
On Tue, May 21, 2019 at 10:16:57AM +0200, Greg KH wrote:
> > + if (hcd->driver->flags & HCD_LOCAL_MEM)
> > + return gen_pool_dma_alloc(hcd->localmem_pool, size, dma);
> Does this patch now break things? hcd->localmem_pool at this point in
> time is NULL, so this call will fail. There's no chance for any host
> controller driver to actually set up this pool in this patch, so is
> bisection broken?
> I think you fix this up in later patches, right?
> And if so, why do we even need HCD_LOCAL_MEM anymore? Can't we just
> test for the presence of hcd->localmem_pool in order to determine which
> allocation method to use?

True. And that also sound like a good bisectability strategy:

- first add hcd->localmem_pool and test for it
- convert drivers over to it
- remove HCD_LOCAL_MEM

 \ /
  Last update: 2019-05-21 12:30    [W:0.031 / U:8.640 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site