Skip to content

Commit df1b8d6

Browse files
FlyGoattsbogend
authored andcommitted
MIPS: pci-legacy: Override pci_address_to_pio
pci-legacy systems are not using logic_pio to managed PIO allocations, thus the generic pci_address_to_pio won't work when PCI_IOBASE is defined. Override the function to use architecture implementation to fix the problem. Cc: [email protected] Fixes: 4bfb53e ("mips: add <asm-generic/io.h> including") Reported-by: Mateusz Jończyk <[email protected]> Closes: https://lore.kernel.org/r/[email protected]/ Signed-off-by: Jiaxun Yang <[email protected]> Signed-off-by: Thomas Bogendoerfer <[email protected]>
1 parent a3c4afc commit df1b8d6

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

arch/mips/pci/pci-legacy.c

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,14 @@ static LIST_HEAD(controllers);
2929

3030
static int pci_initialized;
3131

32+
unsigned long pci_address_to_pio(phys_addr_t address)
33+
{
34+
if (address > IO_SPACE_LIMIT)
35+
return (unsigned long)-1;
36+
37+
return (unsigned long) address;
38+
}
39+
3240
/*
3341
* We need to avoid collisions with `mirrored' VGA ports
3442
* and other strange ISA hardware, so we always want the

0 commit comments

Comments
 (0)