File 0027-ifup-wireless-do-not-fail-on-unsupported-power-optio.patch of Package sysconfig.openSUSE_12.1_Update
From ea0c57bee1760e2c2f9c460da40dd9b7e6bc5c9b Mon Sep 17 00:00:00 2001
From: Marius Tomaschewski <mt@suse.com>
Date: Thu, 25 Oct 2012 16:30:51 +0200
References: bnc#716652
Subject: [PATCH 09/11] ifup-wireless: do not fail on unsupported power
options
The power management support differs from driver to driver;
complain, but do not forward errors (cause ifup failures)
when the specified power operation is not supported ...
---
scripts/ifup-wireless | 14 ++++++++------
1 Datei geändert, 8 Zeilen hinzugefügt(+), 6 Zeilen entfernt(-)
diff --git a/scripts/ifup-wireless b/scripts/ifup-wireless
index a75e8f2..502aeaa 100755
--- a/scripts/ifup-wireless
+++ b/scripts/ifup-wireless
@@ -785,20 +785,22 @@ case $ACTION in
""|none) ;;
yes) run_iw_tool config power period 2
if [ $RETVAL -eq 250 ]; then
- # The power operation is invalid or unsupported.
+ # The power operations may be not supported by the
+ # driver and not all driver support all modes ...
iwconfig $INTERFACE power off 2> /dev/null
- # If the power operation is unsupported, ignore the error.
- [ $? -eq 250 ] && RETVAL=$R_SUCCESS
+ # Error were logged/displayed ... don't fail here.
+ RETVAL=$R_SUCCESS
fi ;;
no|off) run_iw_tool config power off
# If the power operation is unsupported, ignore the error.
[ $RETVAL -eq 250 ] && RETVAL=$R_SUCCESS ;;
*) run_iw_tool config power $WIRELESS_POWER
if [ $RETVAL -eq 250 ]; then
- # The power operation is invalid or unsupported.
+ # The power operations may be not supported by the
+ # driver and not all driver support all modes ...
iwconfig $INTERFACE power off 2> /dev/null
- # If the power operation is unsupported, ignore the error.
- [ $? -eq 250 ] && RETVAL=$R_SUCCESS
+ # Error were logged/displayed ... don't fail here.
+ RETVAL=$R_SUCCESS
fi ;;
esac
--
1.7.10.4