Re: [RFC/PATCH 7/13] d80211: remove adm_status

2006-03-08 Thread Jean Tourrilhes
On Tue, Mar 07, 2006 at 07:11:27PM -0800, Simon Barber wrote:
 Overloading configuration parameters with extra meanings like this makes
 it harder to configure the system - I think it's useful to keep an
 on/off function separate from the power setting.
 
 Simon 

The main issue I have with adding another separate setting is
that I'm trying to fight the sprawling wireless API. Every time we add
a new command in the API, we have to implement it in a dozen driver
and support it more or less forever (deprecating things is hard).
Many people already complain that Wireless Extension is too
bloated (while simultaneously complaining that their pet feature is
not available).

I'm personally pragmatic, not dogmatic. So, I'm asking myself
these two questions :

1) Why is this setting useful to the user ?
If a user want to disable/power-off its network interface, the
official and supported way to do that is 'ifconfig ethX down'. Most
driver do support that, and it leaves the network stack in a
consistent state (interface is down, routing will use an alternate
interface).
Moreover, Linux power management and ACPI will probably define
ways to suspend the device, if not done already.
So, why do we need yet another way to acheive the same thing ?

2) in practical terms, for the average user, what is the
difference between shutting down the Tx power and shutting down the
whole MAC ? If you shut down Tx power, you can't remain associated,
you can't scan, and can't do anything useful in general, so there is
little point in keeping the rest of the MAC active.

Also, I disagree that it make things harder for the user. By
default, this parameter has the right value (on), so the user doesn't
have to touch it, and it's only if he touches it that he may run into
troubles. There are plenty of driver setting available (standard or
private) that the user will never touch.

To me, it's clear that we don't need to waste our collective
time supporting this feature.
And if a driver author insist on exporting such feature, he
can use 'txpower on'. It's not perfect, but a pretty good match. If
the author doesn't like that, there is plenty of driver specific APIs
available (iwpriv, /proc, sysfs...).

Have fun...

Jean
-
To unsubscribe from this list: send the line unsubscribe netdev in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


RE: [RFC/PATCH 7/13] d80211: remove adm_status

2006-03-07 Thread Simon Barber
Overloading configuration parameters with extra meanings like this makes
it harder to configure the system - I think it's useful to keep an
on/off function separate from the power setting.

Simon 

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
On Behalf Of Jouni Malinen
Sent: Monday, March 06, 2006 4:23 PM
To: Jean Tourrilhes
Cc: netdev@vger.kernel.org; Jiri Benc
Subject: Re: [RFC/PATCH 7/13] d80211: remove adm_status

On Mon, Mar 06, 2006 at 02:25:52PM -0800, Jean Tourrilhes wrote:
 Jouni Malinen wrote :
  This is used to implement radio on/off without having to change 
  other parts of the configuration (e.g., set interfaces down).

   The airo driver use 'txpower' for that. txpower has a 'off'
 option, and with the airo driver this disable the whole MAC, leaving 
 the interface up (and 'on' revert back).

This is somewhat confusing parameter for disabling both transmit and
receive (or the whole MAC for that matter). Other than that, I don't
really have anything against using this for what the adm_status was used
as long as the 'on' option returns the previously used TX level without
user space program having to set it again. I haven't looked at what the
current drivers are doing in this case.

-- 
Jouni MalinenPGP id EFC895FA
-
To unsubscribe from this list: send the line unsubscribe netdev in the
body of a message to [EMAIL PROTECTED] More majordomo info at
http://vger.kernel.org/majordomo-info.html
-
To unsubscribe from this list: send the line unsubscribe netdev in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [RFC/PATCH 7/13] d80211: remove adm_status

2006-03-06 Thread Jean Tourrilhes
Jouni Malinen wrote :
 
 On Mon, Mar 06, 2006 at 04:44:27PM +0100, Jiri Benc wrote:
 
  PRISM2_PARAM_ADM_STATUS is not used anywhere in kernel nor in userspace.
  It just passes a value to the driver, so it's safe to remove it.
 
 This is used to implement radio on/off without having to change other
 parts of the configuration (e.g., set interfaces down). I would rather
 not remove it unless there is an alternative way of doing this.

The airo driver use 'txpower' for that. txpower has a 'off'
option, and with the airo driver this disable the whole MAC, leaving
the interface up (and 'on' revert back).
Also note that at your request I defined 'relative' txpower,
i.e. txpower which are not in mW or dBm, because you needed that for
the Prism2 devices.

Have fun...

Jean

-
To unsubscribe from this list: send the line unsubscribe netdev in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [RFC/PATCH 7/13] d80211: remove adm_status

2006-03-06 Thread Jouni Malinen
On Mon, Mar 06, 2006 at 02:25:52PM -0800, Jean Tourrilhes wrote:
 Jouni Malinen wrote :
  This is used to implement radio on/off without having to change other
  parts of the configuration (e.g., set interfaces down).

   The airo driver use 'txpower' for that. txpower has a 'off'
 option, and with the airo driver this disable the whole MAC, leaving
 the interface up (and 'on' revert back).

This is somewhat confusing parameter for disabling both transmit and
receive (or the whole MAC for that matter). Other than that, I don't
really have anything against using this for what the adm_status was
used as long as the 'on' option returns the previously used TX level
without user space program having to set it again. I haven't looked at
what the current drivers are doing in this case.

-- 
Jouni MalinenPGP id EFC895FA
-
To unsubscribe from this list: send the line unsubscribe netdev in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [RFC/PATCH 7/13] d80211: remove adm_status

2006-03-06 Thread Jean Tourrilhes
On Mon, Mar 06, 2006 at 03:23:04PM -0800, Jouni Malinen wrote:
 On Mon, Mar 06, 2006 at 02:25:52PM -0800, Jean Tourrilhes wrote:
  Jouni Malinen wrote :
   This is used to implement radio on/off without having to change other
   parts of the configuration (e.g., set interfaces down).
 
  The airo driver use 'txpower' for that. txpower has a 'off'
  option, and with the airo driver this disable the whole MAC, leaving
  the interface up (and 'on' revert back).
 
 This is somewhat confusing parameter for disabling both transmit and
 receive (or the whole MAC for that matter).

Yes, I fully agree. I did not say I was fully confortable with
that and that you should do it, it was just another data point.
On the other hand, the difference between disabling Tx and
disabling the whole MAC would never be noticed by users except in
monitor mode. Also, such functionality is not very useful to the vast
majority of people, no harm if it's a bit buried in the API.

 Other than that, I don't
 really have anything against using this for what the adm_status was
 used as long as the 'on' option returns the previously used TX level
 without user space program having to set it again.

This is what 'on' does in WE : it read the current value, flip
the 'disabled' flag and rewrite it. So, as long as you fill the
correct stuff in the GET, it should be transparent in the GET.

 I haven't looked at
 what the current drivers are doing in this case.

I'm not 100% sure, but it seems that the HostAP driver use
txpower only to switch on and off the radio. Maybe you want to have
two words with HostAP maintainer ;-)

 Jouni MalinenPGP id EFC895FA

Have fun...

Jean
-
To unsubscribe from this list: send the line unsubscribe netdev in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html