diff options
Diffstat (limited to 'sound/pci/asihpi/hpios.c')
-rw-r--r-- | sound/pci/asihpi/hpios.c | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/sound/pci/asihpi/hpios.c b/sound/pci/asihpi/hpios.c index de615cfdb950..742ee12a9e17 100644 --- a/sound/pci/asihpi/hpios.c +++ b/sound/pci/asihpi/hpios.c | |||
@@ -89,26 +89,3 @@ u16 hpios_locked_mem_free(struct consistent_dma_area *p_mem_area) | |||
89 | void hpios_locked_mem_free_all(void) | 89 | void hpios_locked_mem_free_all(void) |
90 | { | 90 | { |
91 | } | 91 | } |
92 | |||
93 | void __iomem *hpios_map_io(struct pci_dev *pci_dev, int idx, | ||
94 | unsigned int length) | ||
95 | { | ||
96 | HPI_DEBUG_LOG(DEBUG, "mapping %d %s %08llx-%08llx %04llx len 0x%x\n", | ||
97 | idx, pci_dev->resource[idx].name, | ||
98 | (unsigned long long)pci_resource_start(pci_dev, idx), | ||
99 | (unsigned long long)pci_resource_end(pci_dev, idx), | ||
100 | (unsigned long long)pci_resource_flags(pci_dev, idx), length); | ||
101 | |||
102 | if (!(pci_resource_flags(pci_dev, idx) & IORESOURCE_MEM)) { | ||
103 | HPI_DEBUG_LOG(ERROR, "not an io memory resource\n"); | ||
104 | return NULL; | ||
105 | } | ||
106 | |||
107 | if (length > pci_resource_len(pci_dev, idx)) { | ||
108 | HPI_DEBUG_LOG(ERROR, "resource too small for requested %d \n", | ||
109 | length); | ||
110 | return NULL; | ||
111 | } | ||
112 | |||
113 | return ioremap(pci_resource_start(pci_dev, idx), length); | ||
114 | } | ||