Gentoo Archives: gentoo-user

From: Hogren <hogren@×××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] Problems with /dev/parport0
Date: Fri, 03 May 2019 12:09:57
Message-Id: a41c6976-e385-c4ac-12e7-9a44d4a7e71f@iiiha.com
In Reply to: [gentoo-user] Problems with /dev/parport0 by karl@aspodata.se
1 Hello,
2
3 I try to help you without parallel port, sorry.
4
5 Do you have parport installed as a module or directly in the kernel ?
6 Did you try the two methods ?
7
8 If this is a module, did you run «insmod partport» ?
9
10 Do you follow a documentation ? Can you give a link ?
11
12
13 Regards,
14
15 Hogren
16
17
18
19 On 02/05/2019 17:33, karl@××××××××.se wrote:
20 > Where is the proper place to ask about parports ?
21 >
22 > ///
23 >
24 > I get:
25 > # echo -n 1 > /dev/parport0
26 > bash: echo: write error: Invalid argument
27 >
28 > i.e. error 22 (EINVAL), as if there isn't any write routine
29 > in the driver. I have tested two identical cards, same story.
30 >
31 > Same thing with reading:
32 > $ dd if=/dev/parport0 count=1 bs=1
33 > dd: error reading '/dev/parport0': Invalid argument
34 > 0+0 records in
35 > 0+0 records out
36 > 0 bytes copied, 6.2359e-05 s, 0.0 kB/s
37 >
38 > open() and close() works without errors.
39 >
40 > How can I make it functional ?
41 >
42 > ///
43 >
44 > I have two Delock 1x par, 2x ser pcie cards (only one installed).
45 > The parport one show up (lspci -vn) as:
46 > 05:00.2 0701: 9710:9912 (prog-if 03 [IEEE1284])
47 > Subsystem: a000:2000
48 > Flags: bus master, fast devsel, latency 0, IRQ 17
49 > I/O ports at ad00 [size=8]
50 > I/O ports at ac00 [size=8]
51 > Memory at fd8fb000 (32-bit, non-prefetchable) [size=4K]
52 > Memory at fd8fa000 (32-bit, non-prefetchable) [size=4K]
53 > Capabilities: [50] MSI: Enable- Count=1/1 Maskable- 64bit+
54 > Capabilities: [78] Power Management version 3
55 > Capabilities: [80] Express Legacy Endpoint, MSI 00
56 > Capabilities: [100] Advanced Error Reporting
57 > Kernel driver in use: parport_serial
58 > Kernel modules: parport_serial
59 >
60 > it matches:
61 > { PCI_VENDOR_ID_NETMOS, PCI_DEVICE_ID_NETMOS_9912,
62 > 0xA000, 0x2000, 0, 0, netmos_99xx_1p }
63 > i.e. lines 176-177 in drivers/parport/parport_serial.c
64 > in the kernel source, last changed ages ago:
65 > commit b9b24558f7d36c550b5cf0b550a8926f8c03cdbd
66 > Author: Frédéric Brière <fbriere@×××××××.net>
67 > Date: Sun May 29 15:08:04 2011 -0400
68 >
69 > It shows up in the log as:
70 > parport0: PC-style at 0xad00 (0xac00), irq 17, using FIFO [PCSPP,TRISTATE,COMPAT,EPP,ECP]
71 > or
72 > parport0: PC-style at 0xad00 (0xac00), irq 17 [PCSPP,TRISTATE,EPP]
73 > depending if I have CONFIG_PARPORT_PC_FIFO set or not in the kernel
74 >
75 > I cannot set irq to none, it shows up as irq 17 even though I do:
76 > # modprobe parport_pc irq=none
77 > # modprobe parport_serial irq=none
78 >
79 > The device file has sensible maj/min numbers:
80 > # ls -l /dev/parport0
81 > crw-rw---- 1 root users 99, 0 Jan 18 2016 /dev/parport0
82 >
83 > Regards,
84 > /Karl Hammar
85 >
86 >

Replies

Subject Author
Re: [gentoo-user] Problems with /dev/parport0 karl@××××××××.se