Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 74073 - slmodem 2.9.10-r1 causes kernel usb_endpoint_halted warning and prevents slusb module to load and slmodemd to start
Summary: slmodem 2.9.10-r1 causes kernel usb_endpoint_halted warning and prevents slus...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: x86 Linux
: High major (vote)
Assignee: Gentoo Dialup Developers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-12-11 01:09 UTC by Kilburn Abrahams
Modified: 2006-03-20 01:05 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
slmodem-fix-usb_endpoint_halted-symbol.patch (slmodem-fix-usb_endpoint_halted-symbol.patch,830 bytes, patch)
2004-12-11 01:15 UTC, Stefan Schweizer (RETIRED)
Details | Diff
slusb (slusb,432 bytes, text/plain)
2004-12-12 01:20 UTC, Stefan Schweizer (RETIRED)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Kilburn Abrahams 2004-12-11 01:09:24 UTC
I am using 2.6.9r9.  After I USE="usb" emerge slmodem, I edit /etc/conf.d/slmodem , recompile kernel with USB modem, then I get WARNING:
/lib/modules/2.6.9-gentoo-r9/extra/slusb.ko needs unknown symbol usb_endpoint_halted

I load slusb in auto load modules and I get this usb_endpoint_halted error and the module wont load, causing slmodem not to start.

frog slmodem-2.9.10-r1 # fgrep -r usb_endpoint_halted .
./work/slmodem-2.9.10/drivers/st7554.c:     if (usb_endpoint_halted(s->usbdev, usb_pipeendpoint(pipe), usb_pipeout(pipe))) {   \
./work/slmodem-2.9.10/drivers/old_st7554.c:     if (usb_endpoint_halted(s->usbdev, usb_pipeendpoint(pipe), usb_pipeout(pipe))) {   \
Binary file ./work/slmodem-2.9.10/drivers/slusb.o matches
Binary file ./work/slmodem-2.9.10/drivers/st7554.o matches
Binary file ./work/slmodem-2.9.10/drivers/slusb.ko matches
Binary file ./image/lib/modules/2.6.9-gentoo-r9/extra/slusb.ko matches
frog slmodem-2.9.10-r1 # nm ./work/slmodem-2.9.10/drivers/slusb.ko |fgrep  usb_endpoint_halted
         U usb_endpoint_halted
frog slmodem-2.9.10-r1 # nm ./work/slmodem-2.9.10/drivers/st7554.o |fgrep  usb_endpoint_halted
         U usb_endpoint_halted
frog slmodem-2.9.10-r1 # fgrep -r usb_endpoint_halted  /usr/src/linux-2.6.9-gentoo-r9/
frog slmodem-2.9.10-r1 # fgrep -r usb_endpoint_halted  /usr/src/
.keep                    linux-2.4.26-gentoo-r11  linux-2.6.8-gentoo-r3    linux-2.6.9              linux-2.6.9-gentoo-r6
config-2004.0-2.6.1      linux-2.4.26-gentoo-r9   linux-2.6.8-gentoo-r7    linux-2.6.9-gentoo-r1    linux-2.6.9-gentoo-r9
linux                    linux-2.6.8-gentoo-r10   linux-2.6.8.1            linux-2.6.9-gentoo-r4

fgrep -r usb_endpoint_halted  /usr/src/
/usr/src/linux-2.4.26-gentoo-r9/include/linux/usb.h:#define usb_endpoint_halted(dev, ep, out) ((dev)->halted[out] & (1 << (ep)))
/usr/src/linux-2.6.8-gentoo-r7/include/linux/usb.h:#define usb_endpoint_halted(dev, ep, out) ((dev)->halted[out] & (1 << (ep)))
/usr/src/linux-2.6.8-gentoo-r3/include/linux/usb.h:#define usb_endpoint_halted(dev, ep, out) ((dev)->halted[out] & (1 << (ep)))
/usr/src/linux-2.6.8.1/include/linux/usb.h:#define usb_endpoint_halted(dev, ep, out) ((dev)->halted[out] & (1 << (ep)))
/usr/src/linux-2.6.8-gentoo-r10/include/linux/usb.h:#define usb_endpoint_halted(dev, ep, out) ((dev)->halted[out] & (1 << (ep)))
/usr/src/linux-2.4.26-gentoo-r11/include/linux/usb.h:#define usb_endpoint_halted(dev, ep, out) ((dev)->halted[out] & (1 << (ep)))

PS: usb_endpoint_halted no longer exists in 2.6.9 kernels.
Comment 1 Stefan Schweizer (RETIRED) gentoo-dev 2004-12-11 01:15:33 UTC
Created attachment 45723 [details, diff]
slmodem-fix-usb_endpoint_halted-symbol.patch

Can you please test this patch:

emerge -va slmodem
ctrl+z after source unpacked

cd /var/tmp/slmodem-2.6.10-r1/portage/work/slmodem-2.6.10
patch -p1 < /home/usr/slmodem-fix-usb_endpoint_halted-symbol.patch
fg




Then let it compile and tell me if the error is still there, please.
If you have some more interest in this driver, you could also help us to
make/test a hotplug script, which is missing currently because I have only a
pci modem :)
Comment 2 Kilburn Abrahams 2004-12-11 14:50:36 UTC
patched st7554.c file with patch, compiled and it still get the kernel warning.
Comment 3 Stefan Schweizer (RETIRED) gentoo-dev 2004-12-11 15:12:22 UTC
Strange, I am pretty sure that this patch fixes it for me. 
Do you have the same kernel in /usr/src/linux that you are running? 
Did you patch early enough? 
Can someone else please check this? 
Can you please provide your emerge info?
Comment 4 Kilburn Abrahams 2004-12-11 19:17:43 UTC
Sorry, or my previous post. The patch works fine on kernel 2.6.9r9 and slmodem 2.9.10.
Comment 5 Stefan Schweizer (RETIRED) gentoo-dev 2004-12-12 00:39:02 UTC
Can you please provide the lsusb output, when your modem is plugged in?
Comment 6 Stefan Schweizer (RETIRED) gentoo-dev 2004-12-12 01:16:05 UTC
---hotplug script start---
RC_NOCOLOR="yes"
source /sbin/functions.sh
source /etc/conf.d/slmodem
if [ -z "${USBMOD}" ]
then MODULE="slusb"
else MODULE=${USBMOD}
fi

source "${svclib}/sh/rc-services.sh"
start && source "${svclib}/sh/rc-services.sh"
---end---
save this in /etc/hotplug/usb/slusb


---/etc/hotplug/usb/slusb.usermap
slusb 0x0003 0x(first ID) 0x(second ID) 0x0000 0x0000 0x00 0x00 0x00 0x00 0x00 0x00 0x00000000
---end---


This should start the init script with the right parameters without the need to configure anything. Please note that you should not have started slmodem when you plug in your modem.
Comment 7 Stefan Schweizer (RETIRED) gentoo-dev 2004-12-12 01:20:56 UTC
Created attachment 45808 [details]
slusb

I better attach a working one here :). Please place in /etc/hotplug/usb and
make executable. You still need the usermap with your detected values.
Comment 8 Alin Năstac (RETIRED) gentoo-dev 2004-12-14 10:22:30 UTC
merged in 2.9.10-r2