wireless-{,iwl-,ipw-}power modules do not discard non-wireless interfaces

Bug #662981 reported by Faustus on 2010-10-18
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
laptop-mode-tools (Ubuntu)
Undecided
Unassigned

Bug Description

Binary package hint: laptop-mode-tools

In all the three modules:
    $IWCONFIG $IFNAME >/dev/null 2>&1;
    ret=$?;
    if [ "$ret" = "0" ]; then
        # Yes, it is a wireless device.
    ....

However, iwconfig gleefully returns status code 0 for any network device. This results in ugly error messages afterwards.

Moreover, in wireless-power:
    if ( ! iwconfig $IF power $WIRELESS_AC_POWER_SAVING_ONOFF ) ; then
    if ( ! iwconfig $IF power $WIRELESS_BATT_POWER_SAVING_ONOFF ) ; then

Not using the $IWCONFIG variable defined earlier.

Moreover, wireless-power supports WIRELESS_POWER_SAVING_EXCLUDE_DRIVERS, whereas wireless-{iwl,ipw}-power do not.

Moreover,
    # LP: #369113
    # Kernel's 2.6.29 and above have been reported to be missing
    # the $DEVICE/wireless folder.
See the OCNFIG_WIRELESS_EXT_SYSFS kernel variable for that.

On Tuesday 19 Oct 2010 03:28:28 Faustus wrote:
> In all the three modules:
> $IWCONFIG $IFNAME >/dev/null 2>&1;
> ret=$?;
> if [ "$ret" = "0" ]; then
> # Yes, it is a wireless device.

We already fixed this upstream. If not already, it should be part of the next
release.

--
Ritesh Raj Sarraf
RESEARCHUT - http://www.researchut.com
"Necessity is the mother of invention."

Faustus (orlovm) wrote :

That's great. Did you also fix the use of iwconfig instead of $IWCONFIG, and inconsistent support for WIRELESS_POWER_SAVING_EXCLUDE_DRIVERS?

On Wednesday 20 Oct 2010 16:31:11 Faustus wrote:
> That's great. Did you also fix the use of iwconfig instead of $IWCONFIG,
> and inconsistent support for WIRELESS_POWER_SAVING_EXCLUDE_DRIVERS?

Yes, just finished that now. Thanks again.

--
Ritesh Raj Sarraf
RESEARCHUT - http://www.researchut.com
"Necessity is the mother of invention."

Ritesh Raj Sarraf (rrs) wrote :

On Wednesday 20 Oct 2010 16:31:11 Faustus wrote:
> Moreover, wireless-power supports WIRELESS_POWER_SAVING_EXCLUDE_DRIVERS,
> whereas wireless-{iwl,ipw}-power do not.

Oops!! No. this was wrong. drivers are excluded because they already have
separate modules for them.

Reverted.

--
Ritesh Raj Sarraf
RESEARCHUT - http://www.researchut.com
"Necessity is the mother of invention."

Faustus (orlovm) wrote :

Ah, it was a misunderstanding on my part about the purpose of this variable. I thought it was a generic one, just undocumented.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers