On 14:51 Fri 20 Feb , Ralf Baechle wrote:
> You can find the resources either by something like:
> # lspci -vvv -s 1d.1
> 00:1d.1 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI
> Controller #2 (rev 02) (prog-if 00 [UHCI])
> Subsystem: Dell Device 01fe
> 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: 0
> Interrupt: pin B routed to IRQ 21
> Region 4: I/O ports at 6f60 [size=32]
> Kernel driver in use: uhci_hcd
> Now let's see how to find this in sysfs:
After careful thought, I think this may be not what I need.
Actually libpciaccess, which is a integral component of X now, need this
mmap-able resourceN (N=1,2,3..) file. And previously mips don't have these file.
This patch just solved this problem.
What I need is access to this address in userspace:
#define LOONGSON2E_IO_PORT_BASE 0x1fd00000UL
which is defined in arch/mips/include/asm/mach-lemote/pci.h
Or maybe a better idea is to implement ioperm/iopl for mips, as discussed 7