iomap.c 859 B

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. /*
  2. * linux/arch/arm/mm/iomap.c
  3. *
  4. * Map IO port and PCI memory spaces so that {read,write}[bwl] can
  5. * be used to access this memory.
  6. */
  7. #include <linux/module.h>
  8. #include <linux/pci.h>
  9. #include <linux/ioport.h>
  10. #include <linux/io.h>
  11. unsigned long vga_base;
  12. EXPORT_SYMBOL(vga_base);
  13. #ifdef __io
  14. void __iomem *ioport_map(unsigned long port, unsigned int nr)
  15. {
  16. return __io(port);
  17. }
  18. EXPORT_SYMBOL(ioport_map);
  19. void ioport_unmap(void __iomem *addr)
  20. {
  21. }
  22. EXPORT_SYMBOL(ioport_unmap);
  23. #endif
  24. #ifdef CONFIG_PCI
  25. unsigned long pcibios_min_io = 0x1000;
  26. EXPORT_SYMBOL(pcibios_min_io);
  27. unsigned long pcibios_min_mem = 0x01000000;
  28. EXPORT_SYMBOL(pcibios_min_mem);
  29. void pci_iounmap(struct pci_dev *dev, void __iomem *addr)
  30. {
  31. if ((unsigned long)addr >= VMALLOC_START &&
  32. (unsigned long)addr < VMALLOC_END)
  33. iounmap(addr);
  34. }
  35. EXPORT_SYMBOL(pci_iounmap);
  36. #endif