Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 29 Jun 2005 22:07:58 -0700
From:      Brooks Davis <brooks@one-eyed-alien.net>
To:        Brooks Davis <brooks@one-eyed-alien.net>
Cc:        Darren Pilgrim <dmp@bitfreak.org>, current@freebsd.org
Subject:   Re: dhclient/wpa_supplicant patch
Message-ID:  <20050630050758.GA13861@odin.ac.hmc.edu>
In-Reply-To: <20050629072338.GB24309@odin.ac.hmc.edu>
References:  <20050629053335.GA18808@odin.ac.hmc.edu> <001201c57c6e$fcb87140$0b2a15ac@SMILEY> <20050629072338.GB24309@odin.ac.hmc.edu>

next in thread | previous in thread | raw e-mail | index | archive | help

--cNdxnHkX5QqsyA0e
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Wed, Jun 29, 2005 at 12:23:38AM -0700, Brooks Davis wrote:
> On Tue, Jun 28, 2005 at 10:54:15PM -0700, Darren Pilgrim wrote:
> > From: Brooks Davis
> > >=20
> > > --- rc.d/wpa_supplicant	Tue Jun 28 22:24:18 2005
> > > +++ rc.d/wpa_supplicant	Tue Jun 28 18:51:32 2005
> > <...>
> > > +if ! wpaif $ifn; then
> > > +	return 1
> > > +fi
> >=20
> > I think it would be better if the dhcpif/wpaif test is contained within
> > netif.  It has to exist in netif because its job is to determine how to
> > configure the interface.  The dhclient and wpa_supplicant scripts should
> > be "dumb" single-task scripts to start/stop their respective clients.
> >=20
> > By putting the dhcpif/wpaif test in the dhclient/wpa_supplicant scripts,
> > not only is it redundant, it makes it impossible to use the scripts
> > manually with an interface that isn't configured in /etc/rc.conf with
> > the DHCP or WPA magic words.  Such manual operations are useful in
> > testing, temporary interfaces and custom profile-based configurations
> > where it's not possible/practical to have a configuration line in
> > /etc/rc.conf beforehand.
>=20
> Good point.  The test is already in ifconfig_up/down so it's not needed
> in wpa_supplicant or dhclient.

Upon further reflection, the wpa_supplicant case was removed before
commit, but I've kept the dhclient case because the code to start a new
dhclient via devd when link is detected relies on rc.d/dhclient only
working on appropriate interfaces.  An option to skip this test when
called with forcestart/forcestart seems like a reasionable compromise in
keeping with rc.subr's design.  I don't have time to work that out at
the moment, but would be happy to look at patches.

-- Brooks

--=20
Any statement of the form "X is the one, true Y" is FALSE.
PGP fingerprint 655D 519C 26A7 82E7 2529  9BF0 5D8E 8BE9 F238 1AD4

--cNdxnHkX5QqsyA0e
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1 (GNU/Linux)

iD8DBQFCw34tXY6L6fI4GtQRAg+3AJsEL/D++FAmwPPEPfcDCavruocZMACgrnmb
JDpoeBztpW6AFz+Ons91UEk=
=qy/E
-----END PGP SIGNATURE-----

--cNdxnHkX5QqsyA0e--



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