Arch Linux

Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#3714 - lirc 0.7.2-6 causes kernel oops

Attached to Project: Arch Linux
Opened by Todd Musall (twm) - Friday, 06 January 2006, 01:54 GMT
Last edited by Tobias Powalowski (tpowa) - Friday, 06 January 2006, 08:16 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To Paul Mattal (paul)
Architecture not specified
Severity High
Priority Normal
Reported Version 0.7 Wombat
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Upgraded packages kernel26 2.6.15-2 and lirc 0.7.2-6 don't play well together. I'm getting the following kernel oops:

Unable to handle kernel NULL pointer dereference at virtual address 00000000
printing eip:
c023bcc0
*pde = 00000000
Oops: 0000 [#1]
PREEMPT SMP
Modules linked in: lirc_gpio lirc_dev usbhid tuner bttv video_buf i2c_algo_bit v4l2_common btcx_risc tveeprom i2c_core videodev raw1394 ohci1394 ieee1394 rtc visor snd_pcm_oss snd_mixer_oss snd_emu10k1 snd_rawmidi snd_seq_device snd_ac97_codec snd_pcm snd_timer snd_ac97_bus snd_page_alloc snd_util_mem snd_hwdep snd soundcore sr_mod usb_storage usbserial via_agp agpgart ehci_hcd uhci_hcd 8139too e100 mii usbcore ide_cd cdrom reiserfs ide_floppy ide_disk via82cxxx pdc202xx_new generic ide_core
CPU: 0
EIP: 0060:[<c023bcc0>] Not tainted VLI
EFLAGS: 00010216 (2.6.15-ARCH)
EIP is at vsnprintf+0x30/0x640
eax: df2250ef ebx: df225080 ecx: 00000000 edx: 00000014
esi: df2250f0 edi: df225103 ebp: e0d95248 esp: de6d5e74
ds: 007b es: 007b ss: 0068
Process modprobe (pid: 2191, threadinfo=de6d4000 task=de53f070)
Stack: de6d5ee4 de6d5e78 de6d5e78 00000202 00000033 c1575540 00000000 00000286
00000000 00000000 00000084 fffffff4 c014f4ff df225080 00000014 df225180
e0d95248 c02a65e5 df2250f0 00000014 00000000 de6d5ef4 de6d5ef4 e0d960a0
Call Trace:
[<c014f4ff>] kzalloc+0x1f/0x50
[<c02a65e5>] class_device_create+0x95/0xd0
[<e0d9356c>] lirc_register_plugin+0x24c/0x560 [lirc_dev]
[<e0d985b1>] gpio_remote_init+0xb1/0x1b0 [lirc_gpio]
[<e0d986f5>] init_module+0x45/0x300 [lirc_gpio]
[<c0140e1c>] sys_init_module+0xdc/0x240
[<c01031f7>] sysenter_past_esp+0x54/0x75
Code: ec 34 8b 44 24 4c 85 c0 0f 88 d8 05 00 00 8b 44 24 48 8b 54 24 4c 8d 7c 10 ff 48 39 c7 0f 82 6d 01 00 00 8b 4c 24 50 8b 74 24 48 <0f> b6 01 84 c0 0f 84 45 01 00 00 90 8d 74 26 00 31 d2 3c 25 89

I tried rebuilding lirc but the patches don't apply cleanly.
This task depends upon

Closed by  Paul Mattal (paul)
Saturday, 14 January 2006, 18:30 GMT
Reason for closing:  Fixed
Comment by Tobias Powalowski (tpowa) - Friday, 06 January 2006, 08:16 GMT
paul i added some pathces from lirc cvs seems they don'T work, pehraps you find a way how to integrate the gpio patches right.
greetings
tpowa
Comment by Paul Mattal (paul) - Friday, 06 January 2006, 13:22 GMT
I've been thinking about switching onto the lirc CVS tree altogether, hoping that a full stable CVS build might be a better alternative in general. I realize this is a tricky business. I am away at the moment, but may have a large chunk of time tomorrow I could spend looking at this. As soon as I am able to cook something up, I'll drop it into testing and we can work from there.
Comment by Dale Blount (dale) - Friday, 06 January 2006, 13:24 GMT
0.8.0pre3 might be easier to switch to before you try CVS... only change IIRC is --with-driver=any needs to be --with-driver=all.


Comment by Todd Musall (twm) - Saturday, 07 January 2006, 21:35 GMT
I tried compiling 0.8.0pre3 and it fails. I got the following errors when compiling lirc_gpio.ko:

make -f scripts/Makefile.build obj=/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio
gcc -m32 -Wp,-MD,/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/.lirc_gpio.o.d -nostdinc -isystem /usr/lib/gcc/i686-pc-linux-gnu/4.0.3/include -D__KERNEL__ -Iinclude -include include/linux/autoconf.h -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -ffreestanding -O2 -fomit-frame-pointer -pipe -msoft-float -mpreferred-stack-boundary=2 -fno-unit-at-a-time -march=i686 -Iinclude/asm-i386/mach-default -Wdeclaration-after-statement -Wno-pointer-sign -DIRCTL_DEV_MAJOR=61 -DEXPORT_SYMTAB -DHAVE_CONFIG_H -I. -I. -I../.. -I/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/../.. -I/lib/modules/2.6.15-ARCH/build//include/ -DMODULE -DKBUILD_BASENAME=lirc_gpio -DKBUILD_MODNAME=lirc_gpio -c -o /home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.o /home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:71: error: 'BTTV_UNKNOWN' undeclared here (not in a function)
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:79:1: warning: "dprintk" redefined
In file included from /home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:53:
include/../drivers/media/video/bttvp.h:227:1: warning: this is the location of the previous definition
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:98: error: 'BTTV_PXELVWPLTVPAK' undeclared here (not in a function)
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:99: error: 'BTTV_PXELVWPLTVPRO' undeclared here (not in a function)
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:100: error: 'BTTV_PV_BT878P_9B' undeclared here (not in a function)
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:101: error: 'BTTV_PV_BT878P_PLUS' undeclared here (not in a function)
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:102: error: 'BTTV_AVERMEDIA' undeclared here (not in a function)
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:103: error: 'BTTV_AVPHONE98' undeclared here (not in a function)
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:104: error: 'BTTV_AVERMEDIA98' undeclared here (not in a function)
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:112: error: 'BTTV_CHRONOS_VS2' undeclared here (not in a function)
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:115: error: 'BTTV_MIRO' undeclared here (not in a function)
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:116: error: 'BTTV_DYNALINK' undeclared here (not in a function)
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:117: error: 'BTTV_WINVIEW_601' undeclared here (not in a function)
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:122: error: 'BTTV_MAGICTVIEW061' undeclared here (not in a function)
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:123: error: 'BTTV_MAGICTVIEW063' undeclared here (not in a function)
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:124: error: 'BTTV_PHOEBE_TVMAS' undeclared here (not in a function)
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:130: error: 'BTTV_FLYVIDEO' undeclared here (not in a function)
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:131: error: 'BTTV_FLYVIDEO_98' undeclared here (not in a function)
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:132: error: 'BTTV_TYPHOON_TVIEW' undeclared here (not in a function)
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:142: error: 'BTTV_WINFAST2000' undeclared here (not in a function)
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c: In function 'build_key':
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:230: error: duplicate case value
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:224: error: previously used here
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:241: error: duplicate case value
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:224: error: previously used here
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:243: error: duplicate case value
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:224: error: previously used here
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:244: error: duplicate case value
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:224: error: previously used here
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:245: error: duplicate case value
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:224: error: previously used here
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:257: error: duplicate case value
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:224: error: previously used here
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:258: error: duplicate case value
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:224: error: previously used here
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:259: error: duplicate case value
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:224: error: previously used here
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:266: error: duplicate case value
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:224: error: previously used here
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:267: error: duplicate case value
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:224: error: previously used here
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:268: error: duplicate case value
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:224: error: previously used here
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:269: error: duplicate case value
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:224: error: previously used here
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:270: error: duplicate case value
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:224: error: previously used here
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:271: error: duplicate case value
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:224: error: previously used here
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:295: error: duplicate case value
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:224: error: previously used here
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:298: error: duplicate case value
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:224: error: previously used here
/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.c:190: confused by earlier errors, bailing out
make[6]: *** [/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio/lirc_gpio.o] Error 1
make[5]: *** [_module_/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio] Error 2
make[5]: Leaving directory `/usr/src/linux-2.6.15-ARCH'
make[4]: *** [lirc_gpio.o] Error 2
make[4]: Leaving directory `/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio'
make[3]: *** [all] Error 2
make[3]: Leaving directory `/home/tmusall/src/lirc-0.8.0pre3/drivers/lirc_gpio'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/tmusall/src/lirc-0.8.0pre3/drivers'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/tmusall/src/lirc-0.8.0pre3'
make: *** [all] Error 2


On the other hand, CVS compiles cleanly and lirc_gpio.ko functions properly. No kernel oops.
Comment by Tobias Powalowski (tpowa) - Monday, 09 January 2006, 17:29 GMT
my patches were taken from cvs, seems i just stripped them too much or i forgot to add other stuff.
Comment by Paul Mattal (paul) - Wednesday, 11 January 2006, 14:17 GMT
cvs is not compiling cleanly for me; something is going on with the disabling of the non-SMP drivers; todd, can you send me your PKGBUILD that worked cleanly? perhaps I'm missing something.
Comment by Todd Musall (twm) - Thursday, 12 January 2006, 01:57 GMT
Paul, I actually just built cvs. I never tried making it in a package.

cvs -d:pserver:anonymous@cvs.sourceforge.net:/cvsroot/lirc login
cvs -z8 -d:pserver:anonymous@cvs.sourceforge.net:/cvsroot/lirc co lirc
cd lirc
./autogen.sh
./configure --enable-sandboxed --prefix=/usr --with-driver=pixelview_pro
make

I only built it for pixelview_pro (lirc_dev, lirc_gpio).

BTW when I try to build all drivers the following lirc_parallel comes up:

gcc -m32 -Wp,-MD,/home/tmusall/arch/abs/lirc/lirc/drivers/lirc_parallel/.lirc_parallel.o.d -nostdinc -isystem /usr/lib/gcc/i686-pc-linux-gnu/4.0.3/include -D__KERNEL__ -Iinclude -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -ffreestanding -O2 -fomit-frame-pointer -pipe -msoft-float -mpreferred-stack-boundary=2 -fno-unit-at-a-time -march=i686 -Iinclude/asm-i386/mach-default -Wdeclaration-after-statement -Wno-pointer-sign -DIRCTL_DEV_MAJOR=61 -DEXPORT_SYMTAB -DHAVE_CONFIG_H -I. -I. -I../.. -I/home/tmusall/arch/abs/lirc/lirc/drivers/lirc_parallel/../.. -I/lib/modules/2.6.14-ARCH/build//include/ -DMODULE -DKBUILD_BASENAME=lirc_parallel -DKBUILD_MODNAME=lirc_parallel -c -o /home/tmusall/arch/abs/lirc/lirc/drivers/lirc_parallel/lirc_parallel.o /home/tmusall/arch/abs/lirc/lirc/drivers/lirc_parallel/lirc_parallel.c
/home/tmusall/arch/abs/lirc/lirc/drivers/lirc_parallel/lirc_parallel.c:46:2: error: #error "--- Sorry, this driver is not SMP safe. ---"
/home/tmusall/arch/abs/lirc/lirc/drivers/lirc_parallel/lirc_parallel.c:618:5: warning: "WE_DONT_USE_LOCAL_OPEN_CLOSE" is not defined
/home/tmusall/arch/abs/lirc/lirc/drivers/lirc_parallel/lirc_parallel.c:626:5: warning: "WE_DONT_USE_LOCAL_OPEN_CLOSE" is not defined
make[5]: *** [/home/tmusall/arch/abs/lirc/lirc/drivers/lirc_parallel/lirc_parallel.o] Error 1
make[4]: *** [_module_/home/tmusall/arch/abs/lirc/lirc/drivers/lirc_parallel] Error 2
make[4]: Leaving directory `/usr/src/linux-2.6.14-ARCH'
make[3]: *** [lirc_parallel.o] Error 2
make[3]: Leaving directory `/home/tmusall/arch/abs/lirc/lirc/drivers/lirc_parallel'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/tmusall/arch/abs/lirc/lirc/drivers'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/tmusall/arch/abs/lirc/lirc'
make: *** [all] Error 2

If after configure I do the sed command in the PKGBuild then all driver compile cleanly:

sed -i -e "s:lirc_parallel::" -e "s:lirc_bt829::" drivers/Makefile

[drivers]$ find . -name '*.ko'
./lirc_dev/lirc_dev.ko
./lirc_i2c/lirc_i2c.ko
./lirc_sir/lirc_sir.ko
./lirc_serial/lirc_serial.ko
./lirc_bt829/lirc_bt829.ko
./lirc_cmdir/lirc_cmdir.ko
./lirc_sasem/lirc_sasem.ko
./lirc_igorplugusb/lirc_igorplugusb.ko
./lirc_gpio/lirc_gpio.ko
./lirc_imon/lirc_imon.ko
./lirc_it87/lirc_it87.ko
./lirc_streamzap/lirc_streamzap.ko
./lirc_mceusb2/lirc_mceusb2.ko
./lirc_atiusb/lirc_atiusb.ko
./lirc_mceusb/lirc_mceusb.ko

Hope that helps.
Comment by Paul Mattal (paul) - Thursday, 12 January 2006, 06:48 GMT
Are you sure all compiles cleanly for you then? If the sed line is working how come there's still a lirc_bt829 driver in your output?

For me, it doesn't seem to work, even after applying the sed line. I'm not sure why, but it still tries to compile the parallel driver.

I'll get past this eventually, but it's a bear of a problem. I really wish they'd just give you a way to enable all and then disable *particular* drivers with an override flag to configure.

- P
Comment by Todd Musall (twm) - Thursday, 12 January 2006, 23:47 GMT
I tried it again and it does build cleanly. lirc_bt829 must have been a left over from a previous build. Here's what gets built:

find drivers/ -name '*.ko'
drivers/lirc_dev/lirc_dev.ko
drivers/lirc_i2c/lirc_i2c.ko
drivers/lirc_sir/lirc_sir.ko
drivers/lirc_serial/lirc_serial.ko
drivers/lirc_cmdir/lirc_cmdir.ko
drivers/lirc_sasem/lirc_sasem.ko
drivers/lirc_igorplugusb/lirc_igorplugusb.ko
drivers/lirc_gpio/lirc_gpio.ko
drivers/lirc_imon/lirc_imon.ko
drivers/lirc_it87/lirc_it87.ko
drivers/lirc_streamzap/lirc_streamzap.ko
drivers/lirc_mceusb2/lirc_mceusb2.ko
drivers/lirc_atiusb/lirc_atiusb.ko
drivers/lirc_mceusb/lirc_mceusb.ko
Comment by Paul Mattal (paul) - Saturday, 14 January 2006, 05:24 GMT
I cleaned up things immensely; builds much cleaner now, and we're on CVS; can you test for me to make sure this eliminates your oops?

Thanks for your help debugging; I managed to simplify my build file immensely which was causing the confusion I was having.
Comment by Todd Musall (twm) - Saturday, 14 January 2006, 18:21 GMT
I've tested you new CVS lirc package and it works fine (no kernel oops and the remote functions normally). Also the cleanups in PKGBUILD are nice to see. I never did understand the extra steps to build and install the kernel modules. 'Make install' takes care of that for you. I'd consider this bug closed :)

Loading...