Stephen Hemminger wrote:
Jeff Garzik <[EMAIL PROTECTED]> wrote:
| > +
| > + paddr = pci_map_single(sky2->hw->pdev, re->skb->data,
| > + rx_buf_size, PCI_DMA_FROMDEVICE);
| > +
| > + pci_unmap_len_set(re, maplen, rx_buf_size);
| > + pci_unmap_addr_set(re, mapaddr, paddr);
|
| pci_unmap???
This is book keeping for iommu systems. see other drivers.
It's just highly irregular to use pci_unmap_xxx functions immediately
after calling a pci_map_xxx function.
Did you know that pci_unmap_addr_set() is a macro that hides the fact
that some arch need iommu but for many it is a no-op. This is the expected
usage.
#define pci_unmap_addr_set(PTR, ADDR_NAME, VAL) \
(((PTR)->ADDR_NAME) = (VAL))
Yes, I know. Think in English. You use a macro called "unmap" at
mapping time.
Jeff
-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html