Bug 195933

Summary: invalid BAR, PCI_IO legacy problem
Product: Drivers Reporter: carlojpisani
Component: PCIAssignee: drivers_pci (drivers_pci)
Status: NEW ---    
Severity: high CC: bjorn
Priority: P1    
Hardware: PPC-32   
OS: Linux   
Kernel Version: 2.6.39..4.11 Subsystem:
Regression: Yes Bisected commit-id:
Attachments: device tree
bootwrapper for walnut (cuImage)
screenshot, kernel 2.6.39
screenshot, kernel 4.11.0
screenshot, kernel 2.6.22

Description carlojpisani 2017-05-30 19:22:13 UTC
Created attachment 256785 [details]
device tree

I am a student of Politecnico of Milano (italy), who needs to use a
PowerPC405GP based board, loaded with uboot v1.2. This board derives
from the Development Board made by IBM under the name "Walnut".

Here (1) you can see a picture of the board

The difference between "Walnut" and "DHT-Walnut" are
Walnut has a soldered PS/2 keyboard controller, DHT-Walnut doesn't have
Walnut has a soldered fpga, DHT-Walnut doesn't have
Walnut has a soldered RTC-chip, DHT-Walnut doesn't have
Walnut has no soldered pATA chip, Walnut comes with PDC20265

So, as these two boards are similar, I am using the profile "Walnut".

I started with linux 2.6.22, which was the last kernel known of having
been tested, and everything (including PDC20265) works as expected!

Unfortunately this kernel is "too old" for modern stage3-glibc rootfs (gentoo)
So I moved into more modern kernels, and I switched into 2.6.39, and
4.11 where I found problems with PCI_IO

Moving from 2.6.22 required a special support: arch/powerpc/boot/cuboot-walnut.c

which provides

void my_platform_init(void);
void walnut_init(void *mac0);
void platform_init(unsigned long r3, unsigned long r4, unsigned long
r5, unsigned long r6, unsigned long r7);


This way the kenrel can boot from uboot v1.2, but there are problems
with the soldered PDC20265 128 Pin, PQFP ASIC chip by Promise
Technologies. This chip is a PCI bus (32-bit PCI interface compliant
to PCI Rev 2.2) mastering ATA/ATAPI controller which supports complete
UDMA/100 specifications. Its datasheet says it communicates with the
PCI bus using a burst bus mastering and advanced scatter/gather engine
for better overall system performance.

On Kernel 2.6.22 I can grab the following

----------------- dmesg: ----------------------------------------------------
PCI: Probing PCI hardware
PCI: Cannot allocate resource region 4 of device 0000:00:04.0

Uniform Multi-Platform E-IDE driver Revision: 7.00alpha2
ide: Assuming 33MHz system bus speed for PIO modes; override with idebus=xx
PDC20265: IDE controller at PCI slot 0000:00:04.0
PDC20265: chipset revision 2
PDC20265: not 100% native mode: will probe irqs later
PDC20265: (U)DMA Burst Bit DISABLED Primary PCI Mode Secondary PCI Mode.
    ide0: BM-DMA at 0x1000-0x1007, BIOS settings: hda:DMA, hdb:pio
    ide1: BM-DMA at 0x1008-0x100f, BIOS settings: hdc:pio, hdd:pio

----------------- lspci: ----------------------------------------------------
00:04.0 Class 0101: Device 105a:0d30 (rev 02) (prog-if 8a [Master SecP PriP])
        Subsystem: Device 105a:4d33
        Flags: bus master, medium devsel, latency 128, IRQ 31
        I/O ports at 121f0 [size=8]
        I/O ports at 123f4 [size=1]
        I/O ports at 12170 [size=8]
        I/O ports at 12374 [size=1]
        I/O ports at 13000 [size=64]
        Memory at 81000000 (32-bit, non-prefetchable) [size=128K]
        Expansion ROM at <ignored> [disabled]
        Capabilities: [58] Power Management version 1
        Kernel driver in use: Promise_Old_IDE

See what is reported by kernel 4.11

----------------- dmesg: ----------------------------------------------------
PCI host bridge /plb/pci@ec000000 (primary) ranges:
 MEM 0x0000000080000000..0x000000009fffffff -> 0x0000000080000000
  IO 0x00000000b0000000..0xffc10000b000ffff -> 0x0000000000000000
4xx PCI DMA offset set to 0x00000000
4xx PCI DMA window base to 0x0000000000000000
DMA window size 0x0000000080000000
PCI: Probing PCI hardware
PCI host bridge to bus 0008:00
pci_bus 0008:00: root bus resource [io  0x0000-0xffffff]
pci_bus 0008:00: root bus resource [mem 0x80000000-0x9fffffff]
pci_bus 0008:00: root bus resource [bus 00-ff]
PCI: Hiding 4xx host bridge resources 0008:00:00.0
pci 0008:00:04.0: [Firmware Bug]: reg 0x10: invalid BAR (can't size)
pci 0008:00:04.0: [Firmware Bug]: reg 0x14: invalid BAR (can't size)
pci 0008:00:04.0: [Firmware Bug]: reg 0x18: invalid BAR (can't size)
pci 0008:00:04.0: [Firmware Bug]: reg 0x1c: invalid BAR (can't size)
pci 0008:00:04.0: legacy IDE quirk: reg 0x10: [io  0x01f0-0x01f7]
pci 0008:00:04.0: legacy IDE quirk: reg 0x14: [io  0x03f6]
pci 0008:00:04.0: legacy IDE quirk: reg 0x18: [io  0x0170-0x0177]
pci 0008:00:04.0: legacy IDE quirk: reg 0x1c: [io  0x0376]
pci 0008:00:00.0: of_irq_parse_pci: failed with rc=-22
pci 0008:00:03.0: BAR 1: assigned [mem 0x80000000-0x807fffff pref]
pci 0008:00:04.0: BAR 5: assigned [mem 0x80800000-0x8081ffff]
pci 0008:00:03.0: BAR 6: assigned [mem 0x80820000-0x8082ffff pref]
pci 0008:00:03.0: BAR 0: assigned [mem 0x80830000-0x80833fff]
pci 0008:00:04.0: BAR 6: assigned [mem 0x80834000-0x80837fff pref]
pci 0008:00:02.0: BAR 0: assigned [mem 0x80838000-0x80838fff]
pci 0008:00:02.1: BAR 0: assigned [mem 0x80839000-0x808390ff]
pci 0008:00:04.0: BAR 4: assigned [io  0x1000-0x103f]
pci 0008:00:03.0: vgaarb: setting as boot VGA device
pci 0008:00:03.0: vgaarb: VGA device added:
decodes=io+mem,owns=io+mem,locks=none
pci 0008:00:03.0: vgaarb: bridge control possible

pata_pdc202xx_old 0008:00:04.0: can't enable device: BAR 0 [io  size
0x0008] not assigned
pata_pdc202xx_old: probe of 0008:00:04.0 failed with error -22

--------------- devicetree lines about PCI
------------------------------------------------
ranges = <
0x02000000 0x00000000 0x80000000
0x80000000 0x00000000 0x20000000

0x01000000 0x00000000 0x00000000
0x00001000 0x00000000 0x00001000>;


It seems to me a problem related to "legacy PCI_IO", but I am not sure
about the meaning of "quirks"

I am lost, I am neither an expert of PCI, nor of linux, I don't know
if the problem is related to

a) the boot-wrapper I need to support in order to make dht-walnut to
bootstrap (cuImage, uImage legacy) -> arch/powerpc/boot/cuboot-$board
b) the DeviceTree setup (arch/powerpc/boot/dts/walnut.dts)
c) something wrong with new kernels


I can say that everything PCI_MEM_ONLY (e.g. MGA Matrox1 ) I tried worked

any tips/tricks/advice/opinion?

thanks
Carlo


(1) a picture of the board
http://elinux.org/images/5/5a/Com1191.jpg
Comment 1 carlojpisani 2017-05-30 19:24:05 UTC
Created attachment 256787 [details]
bootwrapper for walnut (cuImage)
Comment 2 carlojpisani 2017-05-30 19:27:23 UTC
Created attachment 256789 [details]
screenshot, kernel 2.6.39
Comment 3 carlojpisani 2017-05-30 19:32:03 UTC
Created attachment 256791 [details]
screenshot, kernel 4.11.0
Comment 4 carlojpisani 2017-05-30 19:33:41 UTC
uc-walnut-earlyrootfs ~ # insmod pata_pdc202xx_old.ko
pata_pdc202xx_old: no symbol version for module_layout
pATA_PROMISE_PDC20265 0008:00:04.0: can't enable device: BAR 0 [io  size 0x0008] not assigned
pATA_PROMISE_PDC20265: probe of 0008:00:04.0 failed with error -22
Comment 5 carlojpisani 2017-05-30 19:34:45 UTC
uc-walnut-earlyrootfs ~ # cat /proc/ioports
00000000-0000ffff : /plb/pci@ec000000
00000000-00000fff : Legacy IO
000003c0-000003df : Matrox
00001000-0000103f : 0008:00:04.0
00001040-0000104f : 0008:00:02.0
00001050-00001057 : 0008:00:02.0
00001058-0000105f : 0008:00:02.0
00001060-00001063 : 0008:00:02.0
00001064-00001067 : 0008:00:02.0
Comment 6 carlojpisani 2017-05-30 19:38:42 UTC
kernel build-up 
host=x86/32bit
target=powerpc-unknown-linux-gnu-4.2.4


kernel 2.6.22: mymake-ppc uImage
kernel 4.11.0: mymake-powerpc cuImage.walnut

---------------------------------------------------------------
cat /usr/bin/mymake-ppc
myarch="ppc"
myccandclib="powerpc-unknown-linux-gnu-"
make ARCH=$myarch CROSS_COMPILE=$myccandclib $1 $2 $3 $4 $5 $6 $7
---------------------------------------------------------------
myarch="powerpc"
myccandclib="powerpc-unknown-linux-gnu-"
make ARCH=$myarch CROSS_COMPILE=$myccandclib $1 $2 $3 $4 $5 $6 $7
---------------------------------------------------------------
Comment 7 carlojpisani 2017-05-30 19:41:41 UTC
cat /usr/bin/mymake-powerpc

> myarch="powerpc"
> myccandclib="powerpc-unknown-linux-gnu-"
> make ARCH=$myarch CROSS_COMPILE=$myccandclib $1 $2 $3 $4 $5 $6 $7
> ---------------------------------------------------------------
Comment 8 carlojpisani 2017-05-30 19:44:55 UTC
Created attachment 256793 [details]
screenshot, kernel 2.6.22
Comment 9 Bjorn Helgaas 2017-05-30 20:54:10 UTC
Marking as regression; worked in 2.6.22, worked in 2.6.39 (I think; based on comment #2), broken in v4.11.
Comment 10 Bjorn Helgaas 2017-05-30 21:35:27 UTC
Can you confirm that 2.6.39 works?  That would narrow down the stretch where the problem was introduced.

Can you attach the output of "lspci -vvxxx" and "lspci -vb" from v4.11?
Comment 11 carlojpisani 2017-05-30 21:40:52 UTC
sorry no, probably a misunderstanding: 2.6.39 doesn't work, it simply doesn't show the quirks, but PDC20265 isn't registered.

2.6.39 seems to have a different mapping for the PCI_IO
Comment 12 carlojpisani 2017-05-30 21:51:44 UTC
2.6.19: PDC20265 working
2.6.22: PDC20265 working
2.6.24: PDC20265 working
2.6.32: PDC20265 doesn't work, BAR problem
2.6.39: PDC20265 doesn't work, BAR problem
4.11.0: PDC20265 doesn't work, BAR problem


about lspci: I will try and report tomorrow. 
I need to cross-compile pci-utils.
Comment 13 carlojpisani 2017-05-30 21:55:52 UTC
kernel 2.6.39, says the following 
uc-walnut-earlyrootfs ~ # insmod pata_pdc202xx_old.ko

PROMISE PDC20265 0000:00:04.0: device not available (can't reserve [io  0x01f0-0x01f7])
PROMISE PDC20265: probe of 0000:00:04.0 failed with error -22




kernel 4.11.0, says the following 
pata_pdc202xx_old: no symbol version for module_layout
pATA_PROMISE_PDC20265 0008:00:04.0: can't enable device: BAR 0 [io  size 0x0008] not assigned
pATA_PROMISE_PDC20265: probe of 0008:00:04.0 failed with error -22
Comment 14 carlojpisani 2017-05-31 11:06:54 UTC
> Can you attach the output of "lspci -vvxxx" and "lspci -vb" from v4.11?


uc-walnut-earlyrootfs ~ # lspci
0008:00:00.0 Class 0600: Device 1014:0156 (rev 01)
0008:00:02.0 Class 0104: Device 1095:3114 (rev 02)
0008:00:03.0 Class 0300: Device 102b:0519 (rev 01)
0008:00:04.0 Class 0101: Device 105a:0d30 (rev 02)

uc-walnut-earlyrootfs ~ # lspci -vvxxx
0008:00:00.0 Class 0600: Device 1014:0156 (rev 01)
        Subsystem: Device 10e8:cafe
        Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx-
        Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort+ >SERR- <PERR- INTx-
        Latency: 7
        Interrupt: pin A routed to IRQ 0
        Region 1: Memory at <unassigned> (32-bit, prefetchable)
        Capabilities: [58] Power Management version 2
                Flags: PMEClk- DSI- D1+ D2- AuxCurrent=0mA PME(D0-,D1-,D2-,D3hot-,D3cold-)
                Status: D0 NoSoftRst- PME-Enable- DSel=0 DScale=0 PME-
00: 14 10 56 01 06 00 10 22 01 00 00 06 00 07 00 00
10: 00 00 00 00 08 00 00 00 00 00 00 00 00 00 00 00
20: 00 00 00 00 00 00 00 00 00 00 00 00 e8 10 fe ca
30: 00 00 00 00 58 00 00 00 00 00 00 00 00 01 00 00
40: 00 00 00 00 00 00 00 00 00 00 60 ff 00 00 00 00
50: 00 00 00 00 00 00 00 00 01 00 02 02 00 00 00 00
60: 01 01 00 00 10 00 00 00 00 00 00 00 00 00 00 00
70: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
90: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
b0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
c0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
e0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00

0008:00:02.0 Class 0104: Device 1095:3114 (rev 02)
        Subsystem: Device 1095:7114
        Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx-
        Status: Cap+ 66MHz+ UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-
        Latency: 128, Cache Line Size: 32 bytes
        Interrupt: pin A routed to IRQ 29
        Region 0: I/O ports at 1050 [size=8]
        Region 1: I/O ports at 1060 [size=4]
        Region 2: I/O ports at 1058 [size=8]
        Region 3: I/O ports at 1064 [size=4]
        Region 4: I/O ports at 1040 [size=16]
        Region 5: Memory at 808b8000 (32-bit, non-prefetchable) [size=1K]
        [virtual] Expansion ROM at 80800000 [disabled] [size=512K]
        Capabilities: [60] Power Management version 2
                Flags: PMEClk- DSI+ D1+ D2+ AuxCurrent=0mA PME(D0-,D1-,D2-,D3hot-,D3cold-)
                Status: D0 NoSoftRst- PME-Enable- DSel=0 DScale=2 PME-
        Kernel driver in use: sata_sil
00: 95 10 14 31 07 00 b0 02 02 00 04 01 08 80 00 00
10: 51 10 00 00 61 10 00 00 59 10 00 00 65 10 00 00
20: 41 10 00 00 00 80 8b 80 00 00 00 00 95 10 14 71
30: 00 00 00 00 60 00 00 00 00 00 00 00 1b 01 00 00
40: 00 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00
50: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
60: 01 00 22 06 00 40 00 64 00 00 00 00 00 00 00 00
70: 00 00 00 00 00 00 00 00 00 00 00 00 00 60 bb 02
80: 22 00 00 00 03 00 00 00 00 00 00 00 e9 72 6f 6d
90: 00 00 00 0c 00 00 00 00 00 00 00 18 00 00 00 00
a0: 01 01 15 65 dd 62 dd 62 92 43 92 43 09 40 09 40
b0: 01 01 15 65 dd 62 dd 62 92 43 92 43 09 40 09 40
c0: 00 00 00 00 aa aa aa aa 00 00 00 00 00 00 00 00
d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
e0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00

0008:00:03.0 Class 0300: Device 102b:0519 (rev 01)
        Control: I/O+ Mem+ BusMaster- SpecCycle- MemWINV- VGASnoop- ParErr- Stepping+ SERR- FastB2B- DisINTx-
        Status: Cap- 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-
        Interrupt: pin A routed to IRQ 30
        Region 0: Memory at 808b0000 (32-bit, non-prefetchable) [size=16K]
        Region 1: Memory at 80000000 (32-bit, prefetchable) [size=8M]
        Expansion ROM at 808a0000 [disabled] [size=64K]
        Kernel driver in use: matroxfb
00: 2b 10 19 05 83 00 80 02 01 00 00 03 00 00 00 00
10: 00 00 8b 80 08 00 00 80 00 00 00 00 00 00 00 00
20: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
30: 00 00 8a 80 00 00 00 00 00 00 00 00 1c 01 00 00
40: 00 11 2c 5f 00 3c 00 00 00 00 ff 00 00 00 00 00
50: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
60: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
70: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
90: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
b0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
c0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
e0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00

0008:00:04.0 Class 0101: Device 105a:0d30 (rev 02) (prog-if 8a [Master SecP PriP])
        Subsystem: Device 105a:4d33
        Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx-
        Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-
        Latency: 128
        Interrupt: pin A routed to IRQ 31
        Region 0: I/O ports at 0000 [size=8]
        Region 1: I/O ports at 0000
        Region 2: I/O ports at 0000 [size=8]
        Region 3: I/O ports at 0000
        Region 4: I/O ports at 1000 [size=64]
        Region 5: Memory at 80880000 (32-bit, non-prefetchable) [size=128K]
        Expansion ROM at 808b4000 [disabled] [size=16K]
        Capabilities: [58] Power Management version 1
                Flags: PMEClk- DSI- D1- D2- AuxCurrent=0mA PME(D0-,D1-,D2-,D3hot-,D3cold-)
                Status: D0 NoSoftRst- PME-Enable- DSel=0 DScale=0 PME-
00: 5a 10 30 0d 07 00 10 02 02 8a 01 01 00 80 00 00
10: f1 01 00 00 f5 03 00 00 71 01 00 00 75 03 00 00
20: 01 10 00 00 00 00 88 80 00 00 00 00 5a 10 33 4d
30: 00 c0 0d 00 58 00 00 00 00 00 00 00 1d 01 00 00
40: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
50: cb 33 00 00 00 00 00 00 01 00 01 00 00 00 00 00
60: 04 f3 4f 00 04 f3 4f 00 04 f3 4f 00 04 f3 4f 00
70: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
90: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
b0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
c0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
e0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Comment 15 carlojpisani 2017-05-31 11:20:04 UTC
0008:00:02.0 Class 0104: Device 1095:3114 (rev 02)
        Subsystem: Device 1095:7114
        Flags: bus master, 66MHz, medium devsel, latency 128, IRQ 29
        I/O ports at 1050 [size=8]
        I/O ports at 1060 [size=4]
        I/O ports at 1058 [size=8]
        I/O ports at 1064 [size=4]
        I/O ports at 1040 [size=16]
        Memory at 808b8000 (32-bit, non-prefetchable) [size=1K]
        [virtual] Expansion ROM at 80800000 [disabled] [size=512K]
        Capabilities: [60] Power Management version 2
        Kernel driver in use: sata_sil

The above device is a sATA controller by Silicon Silicon Image. As far as I have tested it has always worked good with both kernel 2.6.39 and kernel 4.11.0! I note it's not PCI_MEM only, it also uses some PCI_IO.
Comment 16 carlojpisani 2017-05-31 11:22:29 UTC
uc-walnut-earlyrootfs ~ # lspci -vb

0008:00:00.0 Class 0600: Device 1014:0156 (rev 01)
        Subsystem: Device 10e8:cafe
        Flags: bus master, medium devsel, latency 7
        Memory at <unassigned> (32-bit, prefetchable)
        Capabilities: [58] Power Management version 2

0008:00:02.0 Class 0104: Device 1095:3114 (rev 02)
        Subsystem: Device 1095:7114
        Flags: bus master, 66MHz, medium devsel, latency 128, IRQ 27
        I/O ports at 1050
        I/O ports at 1060
        I/O ports at 1058
        I/O ports at 1064
        I/O ports at 1040
        Memory at 808b8000 (32-bit, non-prefetchable)
        Capabilities: [60] Power Management version 2
        Kernel driver in use: sata_sil

0008:00:03.0 Class 0300: Device 102b:0519 (rev 01)
        Flags: stepping, medium devsel, IRQ 28
        Memory at 808b0000 (32-bit, non-prefetchable)
        Memory at 80000000 (32-bit, prefetchable)
        Expansion ROM at 808a0000 [disabled]
        Kernel driver in use: matroxfb

0008:00:04.0 Class 0101: Device 105a:0d30 (rev 02) (prog-if 8a [Master SecP PriP])
        Subsystem: Device 105a:4d33
        Flags: bus master, medium devsel, latency 128, IRQ 29
        I/O ports at 01f0
        I/O ports at 03f4
        I/O ports at 0170
        I/O ports at 0374
        I/O ports at 1000
        Memory at 80880000 (32-bit, non-prefetchable)
        Expansion ROM at 000dc000 [disabled]
        Capabilities: [58] Power Management version 1
Comment 17 carlojpisani 2017-05-31 15:06:19 UTC
I don't know if it is related or not, I have also cross-emerged a mini =x11-base/xorg-server-1.19.2 + twm + xterm, and I sometimes get this warning


uc-walnut-earlyrootfs ~ # Process X (pid:956) mapped non-existing PCI legacy memory for 00008:00


Sometimes the following lines also appear in console=/dev/ttyS0


uc-walnut-earlyrootfs ~ # Oops: Exception in kernel mode, sig: 4 [#1]
Walnut
Modules linked in:
CPU: 0 PID: 12 Comm: kcompactd0 Not tainted 4.11.0-walnut #56
task: c2823700 task.stack: c286c000
NIP: c00dfef0 LR: c00b82d4 CTR: 00000000
REGS: c286dd60 TRAP: 0700   Not tainted  (4.11.0-walnut)
MSR: 00029030 <EE,ME,IR,DR>
  CR: 2286da22  XER: 20000000

GPR00: 00000000 c286de10 c2823700 00000000 00000003 000000dc 00000000 00000000
GPR08: 00003000 c066421c 00000000 00000000 00000000 00000000 c004d780 c2859c80
GPR16: 00000000 c286de88 c0670000 c286de18 c286de1c 00000000 c286c000 00000000
GPR24: 014000c0 c286de80 c0670000 c0664218 00000001 c286de80 00000000 00000004
NIP [c00dfef0] migrate_prep_local+0x0/0x30
LR [c00b82d4] compact_zone+0xc4/0x610
Call Trace:
[c286de10] [c00b8264] compact_zone+0x54/0x610 (unreliable)
[c286de70] [c00b8d48] kcompactd+0x1c8/0x2f0
[c286df10] [c004d898] kthread+0x118/0x120
[c286df40] [c000d79c] ret_from_kernel_thread+0x5c/0x64
Instruction dump:
00501b00 d718ff7a 4801000b 0fe49a80 03f926a0 01fc9350 52000242 ba6bbffe
01fc9350 00000000 00000000 00000001 <00000000> 9421fff0 90010014 4bfc2735
---[ end trace 80dafb14966aac9b ]---

Process X (pid:783) mapped non-existing PCI legacy memory for 00008:00




It doesn't happen (never happened) with 2.6.39 with the same ramrootf.
Comment 18 carlojpisani 2018-12-03 13:02:30 UTC
anyone?
Comment 19 Bjorn Helgaas 2018-12-03 23:24:25 UTC
Probably best to ask on linux-pci@vger.kernel.org and mention this bugzilla.  I don't think anybody really monitors the bugzilla.