Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

parport and irq question

67 views
Skip to first unread message

Jan Engelhardt

unread,
May 31, 2006, 6:38:01 AM5/31/06
to Linux Kernel Mailing List
Hello,

standard parport probing gives:

# modprobe parport_pc
pnp: Device 00:0a activated.
parport: PnPBIOS parport detected.
parport0: PC-style at 0x378 (0x778), irq 7, dma 3
[PCSPP,TRISTATE,COMPAT,ECP,DMA]
ACPI: PCI Interrupt 0000:00:0c.0[A] -> GSI 16 (level, low) -> IRQ 185
PCI parallel port detected: 9710:9805, I/O at 0xc800(0xc400)
parport1: PC-style at 0xc800 (0xc400) [PCSPP,TRISTATE]
PCI parallel port detected: 9710:9805, I/O at 0xc000(0xbc00)
parport2: PC-style at 0xc000 (0xbc00) [PCSPP,TRISTATE]

Since I do not use parport0 but parport2 for regular work, I wanted to make
parport2 have the DMA channel, so I tried

# rmmod parport_pc
pnp: Device 00:0a disabled.

# modprobe parport_pc io=0x378,0xc800,0xc000 irq=100,101,7
parport 0x378 (WARNING): CTR: wrote 0x0c, read 0xff
parport 0x378 (WARNING): DATA: wrote 0xaa, read 0xff
parport 0x378: You gave this address, but there is probably no parallel
port there!
parport0: PC-style at 0x378, irq 100 [PCSPP,TRISTATE]
parport0: irq 100 in use, resorting to polled operation
parport1: PC-style at 0xc800, irq 101 [PCSPP,TRISTATE,EPP]
parport1: irq 101 in use, resorting to polled operation
parport2: PC-style at 0xc000 (0xc400), irq 7, dma 7
[PCSPP,TRISTATE,COMPAT,ECP,DMA]


Looks good so far, but what irq am I supposed to hand to the irq= parameter
for parport0 and parport1? Giving irq=-1,-1,7 is rejected. And what about
the "You gave this address, but there is probably no parallel port there?"
- there is one. It also appears when I try 0x778 instead of 0x378.

Jan Engelhardt
--
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majo...@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

Brown, Len

unread,
May 31, 2006, 12:56:33 PM5/31/06
to Jan Engelhardt, Linux Kernel Mailing List
> what irq am I supposed to hand to the irq= parameter

does "auto" work any better?

Jan Engelhardt

unread,
Jun 5, 2006, 6:11:46 AM6/5/06
to Brown, Len, Linux Kernel Mailing List
>> what irq am I supposed to hand to the irq= parameter
>
>does "auto" work any better?
>
Unfortunately no.

This is the default output:
# modprobe parport_pc
[42949457.300000] pnp: Device 00:0a activated.
[42949457.300000] parport: PnPBIOS parport detected.
[42949457.300000] parport0: PC-style at 0x378 (0x778), irq 7, dma 3
[PCSPP,TRISTATE,COMPAT,ECP,DMA]
[42949457.390000] ACPI: PCI Interrupt 0000:00:0c.0[A] -> GSI 16
(level, low) -> IRQ 217
[42949457.390000] PCI parallel port detected: 9710:9805, I/O at
0xc800(0xc400)
[42949457.390000] parport1: PC-style at 0xc800 (0xc400) [PCSPP,TRISTATE]
[42949457.470000] PCI parallel port detected: 9710:9805, I/O at
0xc000(0xbc00)
[42949457.470000] parport2: PC-style at 0xc000 (0xbc00) [PCSPP,TRISTATE]
Why don't parport1 and p2 get an IRQ and DMA (and therefore ECP/EPP and all the
fun)?

There is one side thing that seems wrong:
# modprobe parport_pc io=0x378
[42949610.790000] parport 0x378 (WARNING): CTR: wrote 0x0c, read 0xff
[42949610.790000] parport 0x378 (WARNING): DATA: wrote 0xaa, read 0xff
[42949610.790000] parport 0x378: You gave this address, but there is


probably no parallel port there!

But the parport is there (see above). The kernel does not seem to active the
pnp device.

When specifying irq=auto,auto,auto, I also need to pass in io=. Automatic IRQ
allocation seems to take place (note the delay in the timestamps), but no IRQ
is assigned in the end:
# modprobe parport_pc irq=auto,auto,auto io=0x378,0xc800,0xc000
[42949815.890000] parport 0x378 (WARNING): CTR: wrote 0x0c, read 0xff
[42949815.890000] parport 0x378 (WARNING): DATA: wrote 0xaa, read 0xff
[42949815.890000] parport 0x378: You gave this address, but there is


probably no parallel port there!

[42949815.890000] parport0: PC-style at 0x378 [PCSPP,TRISTATE]
[42949815.970000] parport1: PC-style at 0xc800 [PCSPP,TRISTATE,EPP]
[42949816.050000] parport2: PC-style at 0xc000 (0xc400) [PCSPP,TRISTATE]
Plus, the io_hi part has only been detected for parport2. It is wrong too, as
0xc400 belongs to parport1 (see automatic detection above). Strange!

And now for the only command that successfully allocates IRQs (and DMA),
with the exception of 0x378...:
# modprobe parport_pc irq=3,5,7 io=0x378,0xc800,0xc000
io_hi=0x778,0xc400,0xbc00
[42950056.090000] parport 0x378 (WARNING): CTR: wrote 0x0c, read 0xff
[42950056.090000] parport 0x378 (WARNING): DATA: wrote 0xaa, read 0xff
[42950056.090000] parport 0x378: You gave this address, but there is


probably no parallel port there!

[42950056.090000] parport0: PC-style at 0x378, irq 3 [PCSPP,TRISTATE]
[42950056.170000] parport1: PC-style at 0xc800 (0xc400), irq 5, dma 5
[PCSPP,TRISTATE,COMPAT,ECP,DMA]
[42950056.250000] parport2: PC-style at 0xc000 (0xbc00), irq 7, dma 7
[PCSPP,TRISTATE,COMPAT,ECP,DMA]

Hopefully, someone can clear this up.


Jan Engelhardt
--

0 new messages