Re: devd *NOT* called on wi0 insert?

From: David Gilbert <dgilbert_at_dclg.ca>
Date: Sun, 7 Sep 2003 14:20:39 -0400
>>>>> "M" == M Warner Losh <imp_at_bsdimp.com> writes:

M> In message: <18850000.1062771730_at_lerlaptop.iadfw.net> Larry
M> Rosenman <ler_at_lerctr.org> writes: : I have a (within the week)
M> -CURRENT system.  If I boot with my Linksys : WPC11 V.3 card
M> inserted : I get the dhcp actions and all is fine.  If I remove the
M> card, we don't : kill off dhclient.  : : If I boot without the

Actually, I think devd needs to be significantly smarter.  Consider
the average laptop: one or more permanent interfaces and one or more
transient interfaces.

Currently, if bge0 (my permanent interface) has link at boot, it gets
dhclient.  Similarly to the origional poster, if wi0 is inserted at
boot, it gets dhclient.

devd doesn't seem to do much else.

There is a caveat, of course.  You can't run multiple copies of
dhclient (say one for each interface).  This is broken.  You must, in
fact, run one copy of dhclient listing all the interfaces to
configure.  This is contrary (say) to moused ... which works well with
multiple mice.

Ideally, you would start dhclient on an interface when it had link and
stop it when it lost link.  You might want to put a 10 or 15 second
timeout on that (as it could be annoying with a flakey controller),
but this makes sense.  In this case, devd would not only have to watch
changes to the device tree, but device state transitions.

Less ideally, dhclient should run on all capable interfaces whenever
they're present.  In the current scheme, this requires some external
smarts as you must kill off the current dhclient and restart it with a
new list of interfaces.

Dave.

-- 
============================================================================
|David Gilbert, Independent Contractor.       | Two things can only be     |
|Mail:       dave_at_daveg.ca                    |  equal if and only if they |
|http://daveg.ca                              |   are precisely opposite.  |
=========================================================GLO================
Received on Sun Sep 07 2003 - 09:20:45 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:37:21 UTC