mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-07-23 23:32:14 +00:00
MIPS: Octeon: Rewrite DMA mapping functions.
All Octeon chips can support more than 4GB of RAM. Also due to how Octeon PCI is setup, even some configurations with less than 4GB of RAM will have portions that are not accessible from 32-bit devices. Enable the swiotlb code to handle the cases where a device cannot directly do DMA. This is a complete rewrite of the Octeon DMA mapping code. Signed-off-by: David Daney <ddaney@caviumnetworks.com> Patchwork: http://patchwork.linux-mips.org/patch/1639/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
This commit is contained in:
parent
ee71b7d2f8
commit
b93b2abce4
6 changed files with 408 additions and 320 deletions
|
@ -35,6 +35,16 @@
|
|||
extern int (*octeon_pcibios_map_irq)(const struct pci_dev *dev,
|
||||
u8 slot, u8 pin);
|
||||
|
||||
/*
|
||||
* For PCI (not PCIe) the BAR2 base address.
|
||||
*/
|
||||
#define OCTEON_BAR2_PCI_ADDRESS 0x8000000000ull
|
||||
|
||||
/*
|
||||
* For PCI (not PCIe) the base of the memory mapped by BAR1
|
||||
*/
|
||||
extern u64 octeon_bar1_pci_phys;
|
||||
|
||||
/*
|
||||
* The following defines are used when octeon_dma_bar_type =
|
||||
* OCTEON_DMA_BAR_TYPE_BIG
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue