Search Linux Wireless

Re: [PATCH] iw: scan: Improved handling of Country String environment values

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

Couple of comments:

On Fri, 2024-08-09 at 22:20 +0300, Taavi Eomäe wrote:
> The third octet in Country String (dot11CountryString) can be a reference
> to one of the tables defined in IEEE 802.11 Annex E. The hexadecimal value
> directly corresponds to a table with the same number.
> 
> Also added handling for non-country entity and hexadecimal printout of all
> values for enhanced clarity.

First off, the subject and commit message should be written in
imperative voice, "improve handling", "add handling", etc.



> 
> Signed-off-by: Taavi Eomäe <taaviw@xxxxxxxxx>
> 
> ---
>   scan.c | 18 ++++++++++++++++--
>   1 file changed, 16 insertions(+), 2 deletions(-)
> 
> diff --git a/scan.c b/scan.c
> index faf406d..85798b8 100644
> --- a/scan.c
> +++ b/scan.c
> @@ -661,10 +661,24 @@ static const char *country_env_str(char environment)
>           return "Indoor only";
>       case 'O':
>           return "Outdoor only";
> +    case 'X':
> +        return "Non-country";

Please follow existing coding style with tabs. Or maybe your email
client just mangled it?

> 
> @@ -673,7 +687,7 @@ static void print_country(const uint8_t type, 
> uint8_t len, const uint8_t *data,
>   {
>       printf(" %.*s", 2, data);
> 
> -    printf("\tEnvironment: %s\n", country_env_str(data[2]));
> +    printf("\tEnvironment: %s (%#.2x)\n", country_env_str(data[2]), 
> data[2]);
> 

This also got line-broken so I can't apply it.

johannes





[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux