Re: [BUG] cannot access IO ports in CMI8738 sound chip.

Katsuya MATSUBARA
2008-01-21T07:39:04Z

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="windows-1254", Size: 8940 bytes --]

Hi Paul,

From: Paul Mundt <lethal@linux-sh.org>
Date: Mon, 21 Jan 2008 15:41:57 +0900

> On Mon, Jan 21, 2008 at 03:25:50PM +0900, Katsuya MATSUBARA wrote:
> > Unfortunately CMI8738 cannot treat (large) memory addresses
> > as IO port numers because some upper bits of 'Base Address
> > Register 0' in the PCI configuration space cannot be updated.
> > (pcibios_setup_bars() in arch/sh/drivers/pci/pci-auto.c
> > updates the register with the memory address.)
> >
> > How should I fix the problem?
>
> Disable PCI_AUTO_UPDATE_RESOURCES like the dreamcast does?

I did it.
Any PCI devices, include an ethernet, cannot be accessed
if PCI_AUTO_UPDATE_RESOURCES is disabled.

[ 0.000000] Linux version 2.6.23.14 (matsu@sh4master) (gcc version 4.2-SH4-LINUX_v0701) #2 PREEMPT Mon Jan 21 16:28:00 JST 2008

[ 0.000000] console [sercon0] enabled
[ 0.000000] Booting machvec: RTS7751R2D
[ 0.000000] Renesas Technology Sales RTS7751R2D support.
[ 0.000000] FPGA version:1 (revision:0)
[ 0.000000] Node 0: start_pfn = 0xc000, low = 0x10000
[ 0.000000] Zone PFN ranges:
[ 0.000000] Normal 49152 -> 65536
[ 0.000000] Movable zone start PFN for each node
[ 0.000000] early_node_map[1] active PFN ranges
[ 0.000000] 0: 49152 -> 65536
[ 0.000000] Built 1 zonelists in Zone order. Total pages: 16256
[ 0.000000] Kernel command line: console=tty0 console=ttySC0,115200 root=/dev/nfs ip=bootp earlyprintk=serial
[ 0.000000] VoyagerGX configured at 0xb3e00000 on irq 4(mapped into 50 to 81)
[ 0.000000] PID hash table entries: 256 (order: 8, 1024 bytes)
[ 0.000000] Using tmu for system timer
[ 0.004086] Using 15.000 MHz high precision timer.
[ 0.009487] Console: colour dummy device 80x25
[ 0.014324] console [tty0] enabled
[ 0.000000] Linux version 2.6.23.14 (matsu@sh4master) (gcc version 4.2-SH4-LINUX_v0701) #2 PREEMPT Mon Jan 21 16:28:00 JST 2008
[ 0.000000] console [sercon0] enabled
[ 0.000000] Booting machvec: RTS7751R2D
[ 0.000000] Renesas Technology Sales RTS7751R2D support.
[ 0.000000] FPGA version:1 (revision:0)
[ 0.000000] Node 0: start_pfn = 0xc000, low = 0x10000
[ 0.000000] Zone PFN ranges:
[ 0.000000] Normal 49152 -> 65536
[ 0.000000] Movable zone start PFN for each node
[ 0.000000] early_node_map[1] active PFN ranges
[ 0.000000] 0: 49152 -> 65536
[ 0.000000] Built 1 zonelists in Zone order. Total pages: 16256
[ 0.000000] Kernel command line: console=tty0 console=ttySC0,115200 root=/dev/nfs ip=bootp earlyprintk=serial
[ 0.000000] VoyagerGX configured at 0xb3e00000 on irq 4(mapped into 50 to 81)
[ 0.000000] PID hash table entries: 256 (order: 8, 1024 bytes)
[ 0.000000] Using tmu for system timer
[ 0.004086] Using 15.000 MHz high precision timer.
[ 0.009487] Console: colour dummy device 80x25
[ 0.014324] console [tty0] enabled
[ 0.124666] Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)
[ 0.132573] Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)
[ 0.146738] Memory: 62464k/65536k available (1641k kernel code, 574k data, 88k init)
[ 0.155237] PVR\x04050005 CVR 480000 PRR\0000113
[ 0.160474] I-cache : n_ways=2 n_sets%6 way_incr92
[ 0.166184] I-cache : entry_mask=0x00001fe0 alias_mask=0x00001000 n_aliases=2
[ 0.173968] D-cache : n_ways=2 n_setsQ2 way_incr\x16384
[ 0.179772] D-cache : entry_mask=0x00003fe0 alias_mask=0x00003000 n_aliases=4
[ 0.271376] Mount-cache hash table entries: 512
[ 0.277227] CPU: SH7751R
[ 0.282806] NET: Registered protocol family 16
[ 0.299833] SCSI subsystem initialized
[ 0.305614] Autoconfig PCI channel 0x8c22001c
[ 0.310461] Scanning bus 00, I/O 0xfe240000:0xfe280000, Mem 0xfd000000:0xfe000000
[ 0.318774] 00:00.0 Class 0401: 13f6:0111 (rev 10)
[ 0.324051] I/O at 0xfe240000 [size=0x100]
[ 0.329356] 00:01.0 Class 0200: 10ec:8139 (rev 10)
[ 0.334619] I/O at 0xfe240100 [size=0x100]
[ 0.339911] Mem at 0xfd000000 [size=0x100]
[ 0.345214] 00:02.0 Class 0607: 104c:ac55 (rev 01)
[ 0.350470] CARDBUS Bridge: primary\0, secondary\x01
[ 0.356192] PCI Autoconfig: Found CardBus bridge, device 2 function 0
[ 0.363240] Mem at 0xfd001000 [size=0x1000]
[ 0.368611] Scanning sub bus 01, I/O 0xfe240200, Mem 0xfd002000
[ 0.375162] Back to bus 00, sub_bus is 1
[ 0.379501] 00:02.1 Class 0607: 104c:ac55 (rev 01)
[ 0.384758] CARDBUS Bridge: primary\0, secondary\x02
[ 0.390480] PCI Autoconfig: Found CardBus bridge, device 2 function 1
[ 0.397526] Mem at 0xfd003000 [size=0x1000]
[ 0.402923] Scanning sub bus 02, I/O 0xfe240204, Mem 0xfd004000
[ 0.409474] Back to bus 00, sub_bus is 2
[ 0.413821] 00:03.0 Class 0200: 10ec:8139 (rev 10)
[ 0.419112] I/O at 0xfe240300 [size=0x100]
[ 0.424373] Mem at 0xfd005000 [size=0x100]
[ 0.434450] PCI: Using configuration type 1
[ 0.458393] Time: SuperH clocksource has been installed.
[ 0.464660] NET: Registered protocol family 2
[ 0.502443] IP route cache hash table entries: 1024 (order: 0, 4096 bytes)
[ 0.510441] TCP established hash table entries: 2048 (order: 2, 16384 bytes)
[ 0.518379] TCP bind hash table entries: 2048 (order: 1, 8192 bytes)
[ 0.525454] TCP: Hash tables configured (established 2048 bind 2048)
[ 0.532399] TCP reno registered
[ 0.553074] io scheduler noop registered
[ 0.557457] io scheduler anticipatory registered (default)
[ 0.563533] io scheduler deadline registered
[ 0.568309] io scheduler cfq registered
[ 0.573083] pci_hotplug: PCI Hot Plug PCI Core version: 0.5
[ 0.902813] Serial: 8250/16550 driver $Revision: 1.90 $ 4 ports, IRQ sharing disabled
[ 0.935891] serial8250.0: ttyS0 at MMIO 0xb3e30000 (irq = 62) is a ST16654
[ 0.944849] SuperH SCI(F) driver initialized
[ 0.950185] sh-sci: ttySC0 at MMIO 0xffe80000 (irq = 43) is a scif
[ 0.957782] console handover: boot [sercon0] -> real [ttySC0]
[ 0.972391] RAMDISK driver initialized: 16 RAM disks of 4096K size 1024 blocksize
[ 0.979685] sm501 sm501: SM501 At b3e00000: Version 050100a0, 8 Mb, IRQ 32
[ 0.986054] sm501-fb[0] flags 00000200: 13e80000..13e8ffff
[ 0.991600] sm501-fb[1] flags 00000200: 13f00000..13f4ffff
[ 0.996929] sm501-fb[2] flags 00000200: 10000000..107fffff
[ 1.002383] sm501-fb[3] flags 00000400: 00000020..00000020
[ 1.008469] sm501-fb sm501-fb: using default configuration data
[ 1.013811] sm501-fb sm501-fb: fb sm501fb-crt disabled at start
[ 1.019721] sm501 sm501: gate 00021987, clock 2a090a09, mode 00000001
[ 1.044299] sm501-fb sm501-fb: fb sm501fb-panel disabled at start
[ 1.049684] sm501 sm501: gate 00021987, clock 09090a09, mode 00000000
[ 1.103343] sm501 sm501: gate 00021987, clock 09090a09, mode 00000001
[ 1.131911] Console: switching to colour frame buffer device 80x25
[ 1.167224] sm501-fb sm501-fb: fb0: sm501fb-crt frame buffer device
[ 1.179274] sm501-fb sm501-fb: fb1: sm501fb-panel frame buffer device
[ 1.193215] 8139too Fast Ethernet driver 0.9.28
[ 1.203222] PCI: Device 0000:00:01.0 not available because of resource collisions
[ 1.222452] Trying to free nonexistent resource <0000000000002000-00000000000020ff>
[ 1.242071] Trying to free nonexistent resource <0000000000000000-00000000000000ff>
[ 1.261898] 8139too: probe of 0000:00:01.0 failed with error -22
[ 1.274109] PCI: Device 0000:00:03.0 not available because of resource collisions
[ 1.295385] Trying to free nonexistent resource <0000000000000000-00000000000000ff>
[ 1.317670] Trying to free nonexistent resource <0000000000000000-00000000000000ff>
[ 1.340581] 8139too: probe of 0000:00:03.0 failed with error -22
[ 1.355876] scsi0 : pata_platform
[ 1.367483] ata1: PATA max PIO0 cmd 0xb4001000 ctl 0xb400080c bmdma 0x00000000 irq 1
[ 1.558327] sh-rtc sh-rtc: rtc core: registered sh as rtc0
[ 1.572290] heartbeat: version 0.1.0 loaded
[ 1.584803] oprofile: using timer interrupt.
[ 1.596925] TCP cubic registered
[ 1.607571] NET: Registered protocol family 1
[ 1.619138] NET: Registered protocol family 17
[ 1.631201] sh-rtc sh-rtc: invalid date
[ 1.641633] sh-rtc sh-rtc: hctosys: invalid date/time
[ 2.153025] IP-Config: No network devices available.
[ 2.164942] Root-NFS: No NFS server available, giving up.
[ 2.176653] VFS: Unable to mount root fs via NFS, trying floppy.
[ 2.189462] VFS: Cannot open root device "nfs" or unknown-block(2,0)
[ 2.201886] Please append a correct "root=" boot option; here are the available partitions:
[ 2.222794] Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(2,0)
---
Katsuya Matsubara
-
To unsubscribe from this list: send the line "unsubscribe linux-sh" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html