- From: Eran Tromer <comedi2eran_at_tromer.org>
- Date: Thu, 15 Jul 2004 09:21:54 +0300
(Sorry if this is a dup; I didn't see my prev post appear on the list.)
Hi,
I'm trying to use Comedi with an NI PCI-6052E card on a Fedora Core 2
box running the latest Fedora Core kernel (2.6.6-1.435.2.3).
Comedi 0.7.68 won't compile:
../../include/linux/comedilib.h:33:2: #error linux/comedilib.h should
not be included by non-kernel-space code
With the current Comedi and Comedilib CVS snapshot, compilation and
installation go smoothly. However, comedi_test segfaults and causes a
kernel oops. See full transcript below (lines beginning with "%" are
kernel messages). The error is consistent and reproducible on this
machine. It also occurs with a slightly older Fedora Core 2 kernel
(2.6.5-1.358).
# modprobe ni_pcimio
% comedi: version 0.7.68.1 - David Schleef <ds_at_schleef.org>
% Available NI device IDs: 0x18b0
# comedi_config /dev/comedi0 ni_pcimio
% comedi0: ni_pcimio: pci-6052ePCI: Enabling device 0000:00:0e.0 (0114
-> 0116)
% PCI: Found IRQ 5 for device 0000:00:0e.0
% PCI: Setting latency timer of device 0000:00:0e.0 to 64
% MITE:0xf4009000 mapped to 16977000 DAQ:0xf4008000 mapped to 16a24000
% ( irq = 5 )
# comedi_test -v -f /dev/comedi0
I: Comedi version: 0.7.68
I: Comedilib version: unknown =)
I: driver name: ni_pcimio
I: device name: pci-6052e
I:
I: subdevice 0
I: testing info...
rev 1
I: subdevice type: 1 (analog input)
number of channels: 16
max data value: 65535
ranges:
all chans: [-10,10] [-5,5] [-2.5,2.5] [-1,1] [-0.5,0.5] [-0.25,0.25]
[-0.1,0.1] [-0.05,0.05] [0,20] [0,10] [0,5] [0,
2] [0,1] [0,0.5] [0,0.2] [0,0.1]
I: testing insn_read...
rev 1
comedi_do_insn returned 1, good
I: testing insn_read_0...
comedi_do_insn returned 0, good
I: testing insn_read_time...
rev 1
comedi_do_insn: 3
read time: 10 us
I: testing cmd_no_cmd...
not applicable
I: testing cmd_probe_src_mask...
rev 1
command source mask:
start: now|ext|int
scan_begin: timer|ext
convert: timer|ext
scan_end: count
stop: none|count
I: testing cmd_probe_fast_1chan...
command fast 1chan:
start: now 0
scan_begin: timer 3000
convert: timer 3000
scan_end: count 1
stop: count 2
I: testing cmd_read_fast_1chan...
read 2000 2000
read 2000 4000
read 140 4140
read 2000 6140
read 2000 8140
read 86 8226
read 2000 10226
read 2000 12226
read 102 12328
read 2000 14328
read 2000 16328
read 88 16416
read 2000 18416
read 2000 20416
read 96 20512
read 2000 22512
read 2000 24512
read 96 24608
read 2000 26608
read 2000 28608
read 98 28706
read 2000 30706
read 2000 32706
read 94 32800
read 2000 34800
read 2000 36800
read 86 36886
read 2000 38886
read 2000 40886
read 102 40988
read 2000 42988
read 2000 44988
read 94 45082
read 2000 47082
read 2000 49082
read 98 49180
read 2000 51180
read 2000 53180
read 94 53274
read 2000 55274
read 2000 57274
read 94 57368
read 2000 59368
read 2000 61368
read 100 61468
read 2000 63468
read 2000 65468
read 68 65536
read 22 65558
read 2000 67558
read 2000 69558
read 106 69664
read 2000 71664
read 2000 73664
read 92 73756
read 2000 75756
read 2000 77756
read 92 77848
read 2000 79848
read 2000 81848
read 100 81948
read 2000 83948
read 2000 85948
read 100 86048
read 2000 88048
read 2000 90048
read 92 90140
read 2000 92140
read 2000 94140
read 96 94236
read 2000 96236
read 2000 98236
read 96 98332
read 2000 100332
read 2000 102332
read 96 102428
read 2000 104428
read 2000 106428
read 96 106524
read 2000 108524
read 2000 110524
read 96 110620
read 2000 112620
read 2000 114620
read 88 114708
read 2000 116708
read 2000 118708
read 114 118822
read 2000 120822
read 2000 122822
read 84 122906
read 2000 124906
read 2000 126906
read 98 127004
read 2000 129004
read 2000 131004
read 68 131072
read 28 131100
read 2000 133100
read 2000 135100
read 96 135196
read 2000 137196
read 2000 139196
read 92 139288
read 2000 141288
read 2000 143288
read 98 143386
read 2000 145386
read 2000 147386
read 100 147486
read 2000 149486
read 2000 151486
read 94 151580
read 2000 153580
read 2000 155580
read 106 155686
read 2000 157686
read 2000 159686
read 94 159780
read 2000 161780
read 2000 163780
read 88 163868
read 2000 165868
read 2000 167868
read 96 167964
read 2000 169964
read 2000 171964
read 92 172056
read 2000 174056
read 2000 176056
read 102 176158
read 2000 178158
read 2000 180158
read 98 180256
read 2000 182256
read 2000 184256
read 92 184348
read 2000 186348
read 2000 188348
read 96 188444
read 2000 190444
read 2000 192444
read 94 192538
read 2000 194538
read 2000 196538
read 70 196608
read 28 196636
read 2000 198636
read 1364 200000
I: testing cmd_write_fast_1chan...
not applicable
I: testing cmd_logic_bug...
rev 1
command_test returned 1, good
I: testing cmd_fifo_depth_check...
64, 1
128, 1
256, 1
512, 1
1024, 1
2048, 1
4096, 2
8192, 3
16384, 8
32768, 16
I: testing cmd_start_inttrig...
Segmentation fault
% Unable to handle kernel paging request at virtual address fee9ce1c
% printing eip:
% 16a71dbe
% *pde = 00000000
% Oops: 0000 [#1]
% Modules linked in: sch_ingress cls_u32 cls_fw sch_sfq sch_htb
% ppp_deflate zlib_deflate ppp_async ip_conntrack_ftp ipt_length
% ipt_mark ipt_MARK iptable_mangle ipt_REDIRECT ipt_MASQUERADE
% iptable_nat ipt_TCPMSS ipt_owner ni_pcimio comedi_fc mite 8255 comedi
% ipt_state ip_conntrack ipt_REJECT ipt_LOG ipt_limit iptable_filter
% ip_tables ppp_generic slhc snd_mixer_oss binfmt_misc snd_seq_midi
% snd_seq_midi_event snd_seq snd_ens1370 snd_ak4531_codec snd_ymfpci
% snd_ac97_codec snd_pcm snd_opl3_lib snd_timer snd_hwdep
% snd_page_alloc gameport snd_mpu401_uart snd_rawmidi snd_seq_device
% snd soundcore nfsd exportfs lockd ipv6 parport_pc lp parport ds
% yenta_socket pcmcia_core sunrpc autofs4 ne2k_pci 8390 3c59x microcode
% ext3 jbd dm_mod uhci_hcd
% CPU: 0
% EIP: 0060:[<16a71dbe>] Not tainted
% EFLAGS: 00010202 (2.6.6-1.435.2.3)
% EIP is at parse_insn+0x12e/0x2e0 [comedi]
% eax: fee9ce1c ebx: 083adf64 ecx: 1014f000 edx: 10d8e024
% esi: 10d8e024 edi: 0da33000 ebp: 16a86c80 esp: 083adf34
% ds: 007b es: 007b ss: 0068
% Process comedi_test (pid: 2994, threadinfo=083ad000 task=0ddcb9b0)
% Stack:
%00000004 fee9ce1c 1014f000 0fd12ba0 02140096 fffffff2 1014f000 fee9ce20
%0fd12ba0 16a71ff6 0fd12ba0 0da33000 0a000006 00000001 fee9ce1c 00000000
%00000000 00000000 00000000 00000000 16a770c0 8020640c 0fd12ba0 ffffffe7
% Call Trace:
% [<02140096>] get_user_size+0x2e/0x55
% [<16a71ff6>] do_insn_ioctl+0x86/0xd0 [comedi]
% [<0214f7f6>] sys_ioctl+0x1f2/0x224
% [<02142236>] sys_write+0x2c/0x42
%
% Code: 8b 08 89 f8 ff d5 85 c0 89 c5 0f 88 17 ff ff ff bd 01 00 00
%
Any idea?
Eran
Received on 2004-07-15Z05:21:54