I have spent some more time getting ECP with DMA to work.
For reference, I am using an HP vectra with a National PC 97317 Super I/O chip
and the 2.3.99pre6 kernel.
In the bios of the machine I leave the parallel port set to auto with ECP.
If I insmod the parport_pc with no options, it doesn't come up with an
interrupt or dma to use with ECP.
But if I set irq=5 and dma=1, it doesn't complain and looks like this:
0x278: FIFO is 16 bytes
0x278: writeIntrThreshold is 8
0x278: readIntrThreshold is 8
0x278: PWord is 8 bits
0x278: Interrupts are ISA-Pulses
0x278: ECP port cfgA=0x14 cfgB=0x40
0x278: ECP settings irq=<none or set by other means> dma=<none or set by other
parport0: PC-style at 0x278 (0x678), irq 5, dma 1 [PCSPP,TRISTATE,EPP,ECP,DMA]
This all makes sense because of the cfgB value that is read from the super I/O
chip. Maybe something has to be added for picking an IRQ, DMA channel, if the
bios is in auto.
So continuing... After the device is initialized, I try to write some data,
then read some data from the device from the user space ppdev driver. The
write seems to use dma but the read doesn't.
I really need read DMA for my device. So looking at parport_pc and the rest of
the parport code I realize that parport_pc_ecp_read_block_pio is never used.
So I added
p->ops->ecp_read_data = parport_pc_ecp_read_block_pio;
in the function parport_pc_probe_port (about line 2050 of parport_pc)
Then, I can see on the scope that it uses hardware switching because my data
rate is about 1 byte/usec, but then the machine freezes. So far it is hard to
tell where it gets to, but I was wondering if this code has been tested, since
I couldn't find it being called from anywhere...
Am I on the right track?
Tim Waugh wrote:
> On Tue, May 09, 2000 at 07:00:15PM -0400, Derek Bouius wrote:
> > How can I confirm that the ppdev is using the DMA?
> If you are using the ppdev backport to 2.2, it isn't using DMA but is
> doing it all in software. The current development kernel uses DMA,
> and has ppdev integrated.
> The SIIG cards only do EPP in hardware I think (they were quite
> helpful when I spoke to them---guess you have to pick a good time of
> Part 1.2Type: application/pgp-signature
-- Derek Bouius | American Biometric Company | Tel:(613)736-5100x281 firstname.lastname@example.org | 3429 Hawthorne Rd,Ottawa,ON | Fax:(613)736-1742
-- To unsubscribe, send mail to: email@example.com -- -- with the single word "unsubscribe" in the body of the message. --
This archive was generated by hypermail 2b29 : Thu May 11 2000 - 14:26:08 EDT