Re: ipw srcipts for hal
- From: yelo_3 <yelo_3 yahoo it>
- To: yelo_3 <yelo_3 yahoo it>, Dan Williams <dcbw redhat com>, dragoran <drago01 gmail com>
- Cc: network manager <networkmanager-list gnome org>
- Subject: Re: ipw srcipts for hal
- Date: Mon, 25 Jun 2007 13:13:51 +0000 (GMT)
> ok, but this does not solve the problem of multiple killswitches (will
> show up with multiple cards) because both will have
> /org/freedesktop/Hal/devices/ipw_wlan_switch as uid.
Yes the previous shell script didn't solve the problem... sorry. This might mean that the UDI should contain the interface name as you were saying
The C code misses the setrfkill section, and a !=null check when you fopen the file.
again corrected another error in hal-system-killswitch, reattaching
a question:how to invoke in hal getrfkill and setrfkill from the shell? to check if they return correct values!
another question: should we add laptop-leds stuff in this hal-system-killswitch, since it is really related to it, or do we really need a new hal entry?
___________________________________
L'email della prossima generazione? Puoi averla con la nuova Yahoo! Mail:
http://it.docs.yahoo.com/nowyoucan.html
--- hal-system-killswitch-get-power-linux.ORIG 2007-06-22 22:33:24.000000000 -0400
+++ hal-system-killswitch-get-power-linux 2007-06-22 23:13:39.000000000 -0400
@@ -47,6 +47,17 @@
echo "org.freedesktop.Hal.Device.KillSwitch.NotSupported" >&2
echo "dellWirelessCtl returned $value" >&2
fi
+ elif [ "$HAL_PROP_KILLSWITCH_ACCESS_METHOD" = "ipw" ] && [ -x /usr/bin/ipwWirelessCtl ]; then
+ /usr/bin/ipwWirelessCtl getrfkill
+ value=$?
+ if [ "$value" = "0" ]; then
+ exit 1
+ elif [ "$value" = "1" ]; then
+ exit 0
+ else
+ echo "org.freedesktop.Hal.Device.KillSwitch.NotSupported" >&2
+ echo "ipwWirelessCtl returned $value" >&2
+ fi
else
echo "org.freedesktop.Hal.Device.KillSwitch.NotSupported" >&2
echo "Access type not supported" >&2
--- hal-system-killswitch-set-power-linux.ORIG 2007-06-22 22:33:24.000000000 -0400
+++ hal-system-killswitch-set-power-linux 2007-06-22 23:13:39.000000000 -0400
@@ -47,6 +47,17 @@
echo "org.freedesktop.Hal.Device.KillSwitch.NotSupported" >&2
echo "dellWirelessCtl returned $value" >&2
fi
+ elif [ "$HAL_PROP_KILLSWITCH_ACCESS_METHOD" = "ipw" ] && [ -x /usr/bin/ipwWirelessCtl ]; then
+ if [ "$value" = "true" ]; then
+ rf_value=0
+ elif [ "$value" = "false" ]; then
+ rf_value=1
+ fi
+
+ /usr/bin/ipwWirelessCtl setrfkill $rf_value
+ ret=$?
+ if [ "$ret" != "0" ]; then
+ echo "org.freedesktop.Hal.Device.KillSwitch.NotSupported" >&2
+ echo "ipwWirelessCtl returned $value" >&2
+ fi
else
echo "org.freedesktop.Hal.Device.KillSwitch.NotSupported" >&2
echo "Access type not supported" >&2
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]