[LEDE-DEV] [PATCH v3 1/4] base-files: generate /etc/config/wireless, if it doesn't exist
Christian Lamparter
chunkeey at googlemail.com
Tue Oct 18 05:22:43 PDT 2016
On Tuesday, October 18, 2016 12:05:43 PM CEST Bastian Bittorf wrote:
> * Christian Lamparter <chunkeey at googlemail.com> [18.10.2016 08:41]:
> > wifi_detect() {
> > + [ ! -f /etc/config/wireless ] && touch /etc/config/wireless
> > +
> > for driver in $DRIVERS; do (
> > if eval "type detect_$driver" 2>/dev/null >/dev/null; then
> > eval "detect_$driver" || echo "$driver: Detect failed" >&2
>
> maybe move it down, otherwise also on
> boards without wifi we touch '/etc/config/wireless':
>
> if eval "detect_$driver" 2>/dev/null >/dev/null; then
> [ -f /etc/config/wireless ] || touch /etc/config/wireless
> ...
> else
> ...
> fi
Ah there's a reason behind this exact location.
Patch 3/4 makes it so that wifi config is run as part of the
ieee80211/net(broadcom-wl) hotplug handler. So boards without
wifi will never run /sbin/wifi config and hence don't create
/etc/config/wireless. This also means that they always will
spend 1 Second sleeping in /etc/init.d/boot... But this is what
we currently do anyway.
Regards,
Christian
More information about the Lede-dev
mailing list