Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 17 Jun 2001 16:15:59 -0700 (PDT)
From:      David Wolfskill <david@catwhisker.org>
To:        freebsd-mobile@FreeBSD.ORG, michelle@eugene.net
Subject:   Re: PCMCIA startup question
Message-ID:  <200106172315.f5HNFxb06050@bunrab.catwhisker.org>
In-Reply-To: <a0500194ab752e49dfedf@[192.168.1.1]>

next in thread | previous in thread | raw e-mail | index | archive | help
>Date: Sun, 17 Jun 2001 15:51:07 -0700
>From: Michelle Brownsworth <michelle@eugene.net>

>I've installed 4.3 on my Toshiba Portege 3025CT, using a 3Com 3C589C 
>NIC, which was zp0 under 3.2, but is now ep0.  The 3C589C works fine, 
>but I'm troubled about the boot sequence. 

OK; different hardware all around over here, but similar principles
appear to be involved.

>It seems that the PCMCIA cards (NIC and 56K modem are not located and 
>started until the final stage.  I've seen others question this in the 
>list archives but haven't seen an answer.

It's my (current) understanding that -- at least, the way I have things
set up for my laptop -- pccardd is responsible for dealing with
recognizing when a card is present or not; since it isn't started until
rather late in the sequence, the behavior you notice would appear to be
reasonable under the circumstances.

>...
>Jun 16 18:35:42 3jane pccard[91]: pccardd started

>After the cards are started the routes are added and reachable:

As expected, yes.

>BTW, I don't have an /etc/pccard.conf; I'm still using the default 
>/etc/defaults/pccard.conf.

Likewise.  :-)

>Bottom line, everything seems to be working, but I'm troubled by the 
>bootup sequence.  Is there a change I can make in the configuration 
>to start the cards earlier in the process?

Well, pccardd appears to get started out of /etc/rc.pccard, which gets
sourced from /etc/rc (line 284, as of today's -STABLE).  It would
certainly be technically possible to start it (somewhat, at least)
earlier, though I'm not convinced that's an approach to recommend.

>The network's being unreachable at an earlier point would foil 
>Apache's or sendmail's startup if they were running on this machine 
>(and they just might be).

Understood; since I maintain my copy of the CVS repository on my laptop,
I also run Apache (for local cvsweb access).  So what I do is this:

* In /etc/rc.conf, I define the hostname as "localhost".
* In the same file, I specify 'pccard_ifconfig="DHCP"' (&
  'pccard_enable="YES"')
* Created /etc/dhclient_exit_hooks, which I cobbled up so it gets
  control after dhclient has done what it normally would do, but just
  before it claims completion of its tasks.  The code I cobbled checks to
  see if the current hostname is NULL or "localhost", and if so, and if an
  IP address was assigned, it does a "reverse lookup" of the IP address to
  determine what the hostname should be, and then sets it (the hostname).
  (I thought I had a copy of that script on the Web page I threw
  together about what I've been doing with the laptop, but I don't see it
  there.  I'll try putting it up there shortly.)

This basically works, though changing the hostname out from underneath X11
(which can happen if one wanders from one network to another --
especially easy if the NIC is wireless, as in my case) is pretty unfriendly.

>Oddly, under 3.2 there were no such boot messages.  The card seemed 
>to be treated almost like a non-PCMCIA NIC during bootup when it was 
>zp0.  I didn't see any card startup messages at all.

I confess I didn't really try using FreeBSD on a laptop until 4.x, so I
don't have the background for that.

Cheers,
david
-- 
David H. Wolfskill				david@catwhisker.org
As a computing professional, I believe it would be unethical for me to
advise, recommend, or support the use (save possibly for personal
amusement) of any product that is or depends on any Microsoft product.

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-mobile" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200106172315.f5HNFxb06050>