Re: [PATCH] media: vb2: dma-sg allocator: change scatterlist allocation method

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

 



Hi Marek,

On Tuesday 16 August 2011 07:35:05 Marek Szyprowski wrote:
> On Friday, August 12, 2011 11:55 PM Laurent Pinchart wrote:
> > On Wednesday 10 August 2011 10:23:37 Marek Szyprowski wrote:
> > > From: Andrzej Pietrasiewicz <andrzej.p@xxxxxxxxxxx>
> > > 
> > > Scatter-gather lib provides a helper functions to allocate scatter
> > > list, so there is no need to use vmalloc for it. sg_alloc_table()
> > > splits allocation into page size chunks and links them together into a
> > > chain.
> > 
> > Last time I check ARM platforms didn't support SG list chaining. Has that
> > been fixed ?
> 
> DMA-mapping code for ARM platform use for_each_sg() macro which has no
> problems with chained SG lists.

for_each_sg() is fine, but sg_alloc_table() doesn't seem to be. 
__sg_alloc_table(), called from sg_alloc_table(), starts with

#ifndef ARCH_HAS_SG_CHAIN
        BUG_ON(nents > max_ents);
#endif

It also calls sg_chain() internally, which starts with

#ifndef ARCH_HAS_SG_CHAIN
        BUG();
#endif

ARCH_HAS_SG_CHAIN is defined on ARM if CONFIG_ARM_HAS_SG_CHAIN is set. That's 
a boolean Kconfig option that is currently never set.

-- 
Regards,

Laurent Pinchart
--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux