pcibr_dma_map(struct pcidev_info * pcidev_info, unsigned long phys_addr, size_t size, unsigned int flags) 
pcibr_dma_map(struct pci_dev * hwdev, unsigned long phys_addr, size_t size) 
pcibr_dma_map(struct pcidev_info * pcidev_info, unsigned long phys_addr,	      size_t size, unsigned int flags){	dma_addr_t dma_handle;	struct pci_dev *pcidev = pcidev_info->pdi_linux_pcidev;	if (flags & SN_PCIDMA_CONSISTENT) {		/* sn_pci_alloc_consistent interfaces */		if (pcidev->dev.coherent_dma_mask == ~0UL) {			dma_handle =			    pcibr_dmatrans_direct64(pcidev_info, phys_addr,						    PCI64_ATTR_BAR);		} else {			dma_handle =			    (dma_addr_t) pcibr_dmamap_ate32(pcidev_info,							    phys_addr, size,							    PCI32_ATE_BAR);		}	} else {		/* map_sg/map_single interfaces */		/* SN cannot support DMA addresses smaller than 32 bits. */		if (pcidev->dma_mask < 0x7fffffff) {			return 0;		}		if (pcidev->dma_mask == ~0UL) {			/*			 * Handle the most common case: 64 bit cards.  This			 * call should always succeed.			 */			dma_handle =			    pcibr_dmatrans_direct64(pcidev_info, phys_addr,						    PCI64_ATTR_PREF);		} else {			/* Handle 32-63 bit cards via direct mapping */			dma_handle =			    pcibr_dmatrans_direct32(pcidev_info, phys_addr,						    size, 0);			if (!dma_handle) {				/*				 * It is a 32 bit card and we cannot do direct mapping,				 * so we use an ATE.				 */				dma_handle =				    pcibr_dmamap_ate32(pcidev_info, phys_addr,						       size, PCI32_ATE_PREF);			}		}	}	return dma_handle;}
4520	/local/tlutelli/issta_data/temp/c/2005_temp/2005/4520/e955d82543fea76b02aa243b182e782f71bda82c/pcibr_dma.c/clean/arch/ia64/sn/pci/pcibr/pcibr_dma.c