Re: inconsistent use of saa7146_pgtable_free?

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

 



Jon Burgess wrote:
> On Wed, 2007-05-02 at 02:32 +0200, Oliver Endriss wrote:
> > Jon Burgess wrote:
> > > Sorry for the delay. I wanted to track down the DMA sync bug before I
> > > came back to look at this again.
> > > 
> > > I have added saa7146_vmalloc_destroy_pgtable() which frees the resources
> > 
> > Shouldn't it better be called saa7146_vfree_destroy_pgtable()?
> >                                     ^^^^^
> 
> Sounds good. Implemented in the attached patch.

Thanks, commited to HG.

> > > allocated by saa7146_vmalloc_build_pgtable() and updated the callers in
> > > budget-core.c and av711o.c. I have also been through the updated
> > > functions and updated the error paths to ensure they free all allocated
> > > resources on error.
> > > 
> > > Also included in this patch are the previous fixes for pci_unmap_sg()
> > > and syncing the PCI streamed data to work with a SWIOTLB and match the
> > > requirements documented in DMA-API.txt.
> > 
> > Thanks, looks perfect.
> > 
> > @all:
> > Any comments?
> > 
> > Btw, why did DMA work without pci_dma_sync_sg_for_cpu()
> > on most machines?
> 
> It is probably the CPU cache snooping which happens on x86 to ensure
> cache coherency. Most non-x86 architectures require manual cache
> writeback and invalidation. Having cache coherency costs transistors,
> power, design complexity etc. so RISC architectures avoid it at the
> expense of a slightly more complex driver.
> 
> The 2003 OLS presentation "Integrating DMA Into the Generic Device
> Model" has some more details and background. 
> http://licensing.steeleye.com/support/papers/ols_2003_dma.pdf 

Interesting article, thanks.

CU

Oliver

-- 
--------------------------------------------------------
VDR Remote Plugin 0.3.9 available at
http://www.escape-edv.de/endriss/vdr/
--------------------------------------------------------


_______________________________________________
linux-dvb mailing list
linux-dvb@xxxxxxxxxxx
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb

[Index of Archives]     [Linux Media]     [Video 4 Linux]     [Asterisk]     [Samba]     [Xorg]     [Xfree86]     [Linux USB]

  Powered by Linux