Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 2932 - PCMCIA-CS hotswap failure - /var/run/stab issues
Summary: PCMCIA-CS hotswap failure - /var/run/stab issues
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Doug Goldstein (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-05-22 16:05 UTC by Bill Childers
Modified: 2003-02-04 19:42 UTC (History)
3 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Bill Childers 2002-05-22 16:05:38 UTC
Copied from email to chadh:
-----------------------------
I'm running kernel 2.4.18 and pcmcia-cs 3.1.33, and I'm *not* using the
kernel PCMCIA stuff, I am using the standalone pcmcia-cs drivers.  Modules
pcmcia_core, i82365, and ds are in my modules.autoload file.  The file
/etc/pcmcia/network.opts is set for DHCP, as is /etc/conf.d/net.

Basically, upon boot, everything's great, and PCMCIA services start and
everything works.  I can insert my Orinoco wireless card (which works,
correct config in /etc/pcmcia/wireless.opts) and the modules for the card
(orinoco_cs and orinoco) auto-load and dhcpcd gets an IP address and the
interface comes up.

The problem occurs when I try and eject the card.  If I issue a "cardctl
eject" to try a "friendly" PCMCIA swap, I get:
ioctl(): Device or resource busy

In /var/log/messages at the time of issuing the command, I get:
May 22 11:58:27 crusoe cardmgr[5807]: executing: './network check eth0'
May 22 11:58:27 crusoe cardmgr[5807]: + ./network: /var/run/stab: No such
file or directory
May 22 11:58:27 crusoe cardmgr[5807]: + usage: ./network [action] [device
name]
May 22 11:58:27 crusoe cardmgr[5807]: +   actions: start check stop
suspend resume
May 22 11:58:27 crusoe cardmgr[5807]: check cmd exited with status 1
May 22 11:58:27 crusoe cardmgr[5807]: exiting

If I manually ifdown the interface, rmmod the modules, and remove the card
I can insert the same card or another (say, my 3c575) and pcmcia-cs
correctly autoloads the right modules, but it doesn't get an IP address
again.  I have to run dhcpcd for this to occur.

From the above excerpt of the /var/log/messages file, it seems that the
/etc/pcmcia/network script can't access the /var/run/stab file.  If I
insert a card and manually check for this file, it's not there, although
the pcmcia start scripts seem to feed the correct argument when loading
cardmgr.

------------------------------
chadh requested this in his reply email:
------------------------------
Try to do a /etc/init.d/net.eth0 stop before the cardctl eject and see if 
that works.  I believe that since /var/run/stab is not there, the network 
script is not getting called correctly, which leaves your network up.  That 
is why you have to manually bring it down (cardctl cannot rm the modules 
b/c dhcpcd is still using them).

--------------------------------------
Results of request:
--------------------------------------

Same response.  Identical entries in /var/log/messages about /var/run/stab not
being accessable, and /etc/pcmcia/network check stops with error 1 status.
Comment 1 Tristan Henderson 2002-06-13 08:30:23 UTC
I resolved this problem by commenting out the line:

CARDMGR_OPTS="-f"

from /etc/conf.d/pcmcia

Don't know if this will introduce any other problems, though...
Comment 2 Yann Rouillard 2002-07-11 07:34:52 UTC
This is a bug from cardmgr which has already been reported (check 
https://sourceforge.net/tracker/index.php?
func=detail&aid=552720&group_id=2405&atid=102405 )

This has been fixed in the last beta version (however this version gave me a 
Segmentation Fault).

Comment 3 Doug Goldstein (RETIRED) gentoo-dev 2002-07-13 23:45:53 UTC
I'm gonna close out this bug cause it is a known bug when using the "-f" flag 
with cardmgr and has been fixed in pcmcia-cs 3.1.34 and I released pcmcia-cs-
3.1.34-r8 to Portage which will fix this problem and any other problem 
associated with it.