> From: David Brownell <[EMAIL PROTECTED]>
> To: [EMAIL PROTECTED]
> Date: Thu, 19 Apr 2001 10:30:53 -0700
> > > *buffer = 0x12345f00;
> > > dma_addr = pci_map_single(dev,buffer,len,PCI_DMA_TODEVICE);
> > > pci_write_config_dword(dev,reg,dma_addr);
> > >
> > > If caching is write-back my feeling is there is nothing that guarantees
> > > the modification went to physmem before the device starts reading from it.
> >
> > Exactly. That's why you must call pci_dma_sync_single before the
> > transfer, if you used pci_map_single.
>
> I didn't see that in DMA-mapping.txt ... if it's needed, I'd expect
> that pci_map_single would do that. The sync_single call is mentioned
> in the context of reusing mappings.
David is absolutely right for the code snippet above,
e.g. if accesses happen _before_ the map, no sync is needed.
-- Pete
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
http://lists.sourceforge.net/lists/listinfo/linux-usb-devel