2 * Copyright (C) 2016 SiFive
4 * This program is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU General Public License
6 * as published by the Free Software Foundation, version 2.
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
14 #ifndef __ASM_RISCV_PCI_H
15 #define __ASM_RISCV_PCI_H
17 #include <linux/types.h>
18 #include <linux/slab.h>
19 #include <linux/dma-mapping.h>
23 #define PCIBIOS_MIN_IO 0
24 #define PCIBIOS_MIN_MEM 0
26 /* RISC-V shim does not initialize PCI bus */
27 #define pcibios_assign_all_busses() 1
29 /* We do not have an IOMMU */
30 #define PCI_DMA_BUS_IS_PHYS 1
32 extern int isa_dma_bridge_buggy
;
35 static inline int pci_get_legacy_ide_irq(struct pci_dev
*dev
, int channel
)
37 /* no legacy IRQ on risc-v */
41 static inline int pci_proc_domain(struct pci_bus
*bus
)
43 /* always show the domain in /proc */
46 #endif /* CONFIG_PCI */
48 #endif /* __ASM_PCI_H */