linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] airo : Print of firmware version
@ 2010-02-28 14:42 matthieu castet
  2010-03-03 20:14 ` John W. Linville
  0 siblings, 1 reply; 6+ messages in thread
From: matthieu castet @ 2010-02-28 14:42 UTC (permalink / raw)
  To: linux-wireless; +Cc: Dan Williams, Jose Alonso

[-- Attachment #1: Type: text/plain, Size: 222 bytes --]

For the firmware version 5.30.17 the log file shows:
Firmware version 5.30.11

The variable softSubVer is binary.


Signed-off-by: Matthieu CASTET <castet.matthieu@free.fr>
Signed-off-by: Jose Alonso <joalonsof@gmail.com>

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: airo_firmware.diff --]
[-- Type: text/x-diff; name="airo_firmware.diff", Size: 628 bytes --]

Index: airo.c
===================================================================
--- 1/drivers/net/wireless/airo.c	(révision 47)
+++ 2/drivers/net/wireless/airo.c	(révision 48)
@@ -2993,7 +2993,7 @@
 	ai->wep_capable = (cap_rid.softCap & cpu_to_le16(0x02)) ? 1 : 0;
 	ai->max_wep_idx = (cap_rid.softCap & cpu_to_le16(0x80)) ? 3 : 0;
 
-	airo_print_info(dev->name, "Firmware version %x.%x.%02x",
+	airo_print_info(dev->name, "Firmware version %x.%x.%02d",
 	                ((le16_to_cpu(cap_rid.softVer) >> 8) & 0xF),
 	                (le16_to_cpu(cap_rid.softVer) & 0xFF),
 	                le16_to_cpu(cap_rid.softSubVer));

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] airo : Print of firmware version
  2010-02-28 14:42 [PATCH] airo : Print of firmware version matthieu castet
@ 2010-03-03 20:14 ` John W. Linville
  2010-03-03 23:12   ` Jose Alonso
  0 siblings, 1 reply; 6+ messages in thread
From: John W. Linville @ 2010-03-03 20:14 UTC (permalink / raw)
  To: matthieu castet; +Cc: linux-wireless, Dan Williams, Jose Alonso

On Sun, Feb 28, 2010 at 03:42:54PM +0100, matthieu castet wrote:
> For the firmware version 5.30.17 the log file shows:
> Firmware version 5.30.11
>
> The variable softSubVer is binary.
>
>
> Signed-off-by: Matthieu CASTET <castet.matthieu@free.fr>
> Signed-off-by: Jose Alonso <joalonsof@gmail.com>

> Index: airo.c
> ===================================================================
> --- 1/drivers/net/wireless/airo.c	(r?vision 47)
> +++ 2/drivers/net/wireless/airo.c	(r?vision 48)
> @@ -2993,7 +2993,7 @@
>  	ai->wep_capable = (cap_rid.softCap & cpu_to_le16(0x02)) ? 1 : 0;
>  	ai->max_wep_idx = (cap_rid.softCap & cpu_to_le16(0x80)) ? 3 : 0;
>  
> -	airo_print_info(dev->name, "Firmware version %x.%x.%02x",
> +	airo_print_info(dev->name, "Firmware version %x.%x.%02d",
>  	                ((le16_to_cpu(cap_rid.softVer) >> 8) & 0xF),
>  	                (le16_to_cpu(cap_rid.softVer) & 0xFF),
>  	                le16_to_cpu(cap_rid.softSubVer));

Why should the last segment be in decimal form if the other two
segments of the version number are in hexadecimal form?

John
-- 
John W. Linville		Someday the world will need a hero, and you
linville@tuxdriver.com			might be all we have.  Be ready.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] airo : Print of firmware version
  2010-03-03 20:14 ` John W. Linville
@ 2010-03-03 23:12   ` Jose Alonso
  2010-03-04  2:20     ` John W. Linville
  0 siblings, 1 reply; 6+ messages in thread
From: Jose Alonso @ 2010-03-03 23:12 UTC (permalink / raw)
  To: John W. Linville; +Cc: matthieu castet, linux-wireless, Dan Williams

On Wed, 2010-03-03 at 15:14 -0500, John W. Linville wrote:
> On Sun, Feb 28, 2010 at 03:42:54PM +0100, matthieu castet wrote:
> > For the firmware version 5.30.17 the log file shows:
> > Firmware version 5.30.11
> >
> > The variable softSubVer is binary.
> >
> >
> > Signed-off-by: Matthieu CASTET <castet.matthieu@free.fr>
> > Signed-off-by: Jose Alonso <joalonsof@gmail.com>
> 
> > Index: airo.c
> > ===================================================================
> > --- 1/drivers/net/wireless/airo.c	(r?vision 47)
> > +++ 2/drivers/net/wireless/airo.c	(r?vision 48)
> > @@ -2993,7 +2993,7 @@
> >  	ai->wep_capable = (cap_rid.softCap & cpu_to_le16(0x02)) ? 1 : 0;
> >  	ai->max_wep_idx = (cap_rid.softCap & cpu_to_le16(0x80)) ? 3 : 0;
> >  
> > -	airo_print_info(dev->name, "Firmware version %x.%x.%02x",
> > +	airo_print_info(dev->name, "Firmware version %x.%x.%02d",
> >  	                ((le16_to_cpu(cap_rid.softVer) >> 8) & 0xF),
> >  	                (le16_to_cpu(cap_rid.softVer) & 0xFF),
> >  	                le16_to_cpu(cap_rid.softSubVer));
> 
> Why should the last segment be in decimal form if the other two
> segments of the version number are in hexadecimal form?

The airo.c shows the usage of hexadecimal and binary form:

        /* Test for WPA support */
        /* Only firmware versions 5.30.17 or better can do WPA */
        if (le16_to_cpu(cap_rid.softVer) > 0x530
         || (le16_to_cpu(cap_rid.softVer) == 0x530
              && le16_to_cpu(cap_rid.softSubVer) >= 17)) {
                airo_print_info(ai->dev->name, "WPA supported.");



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] airo : Print of firmware version
  2010-03-03 23:12   ` Jose Alonso
@ 2010-03-04  2:20     ` John W. Linville
  2010-03-04 16:06       ` Dan Williams
  0 siblings, 1 reply; 6+ messages in thread
From: John W. Linville @ 2010-03-04  2:20 UTC (permalink / raw)
  To: Jose Alonso; +Cc: matthieu castet, linux-wireless, Dan Williams

On Wed, Mar 03, 2010 at 08:12:53PM -0300, Jose Alonso wrote:
> On Wed, 2010-03-03 at 15:14 -0500, John W. Linville wrote:
> > On Sun, Feb 28, 2010 at 03:42:54PM +0100, matthieu castet wrote:
> > > For the firmware version 5.30.17 the log file shows:
> > > Firmware version 5.30.11
> > >
> > > The variable softSubVer is binary.
> > >
> > >
> > > Signed-off-by: Matthieu CASTET <castet.matthieu@free.fr>
> > > Signed-off-by: Jose Alonso <joalonsof@gmail.com>
> > 
> > > Index: airo.c
> > > ===================================================================
> > > --- 1/drivers/net/wireless/airo.c	(r?vision 47)
> > > +++ 2/drivers/net/wireless/airo.c	(r?vision 48)
> > > @@ -2993,7 +2993,7 @@
> > >  	ai->wep_capable = (cap_rid.softCap & cpu_to_le16(0x02)) ? 1 : 0;
> > >  	ai->max_wep_idx = (cap_rid.softCap & cpu_to_le16(0x80)) ? 3 : 0;
> > >  
> > > -	airo_print_info(dev->name, "Firmware version %x.%x.%02x",
> > > +	airo_print_info(dev->name, "Firmware version %x.%x.%02d",
> > >  	                ((le16_to_cpu(cap_rid.softVer) >> 8) & 0xF),
> > >  	                (le16_to_cpu(cap_rid.softVer) & 0xFF),
> > >  	                le16_to_cpu(cap_rid.softSubVer));
> > 
> > Why should the last segment be in decimal form if the other two
> > segments of the version number are in hexadecimal form?
> 
> The airo.c shows the usage of hexadecimal and binary form:
> 
>         /* Test for WPA support */
>         /* Only firmware versions 5.30.17 or better can do WPA */
>         if (le16_to_cpu(cap_rid.softVer) > 0x530
>          || (le16_to_cpu(cap_rid.softVer) == 0x530
>               && le16_to_cpu(cap_rid.softSubVer) >= 17)) {
>                 airo_print_info(ai->dev->name, "WPA supported.");

Alright, but that could be an argument for changing the comment.
Probably too much to ask, but is there some authoritative source for
this busted numbering scheme?

John
-- 
John W. Linville                Someday the world will need a hero, and you
linville@tuxdriver.com                  might be all we have.  Be ready.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] airo : Print of firmware version
  2010-03-04  2:20     ` John W. Linville
@ 2010-03-04 16:06       ` Dan Williams
  2010-03-04 16:10         ` Dan Williams
  0 siblings, 1 reply; 6+ messages in thread
From: Dan Williams @ 2010-03-04 16:06 UTC (permalink / raw)
  To: John W. Linville; +Cc: Jose Alonso, matthieu castet, linux-wireless

On Wed, 2010-03-03 at 21:20 -0500, John W. Linville wrote:
> On Wed, Mar 03, 2010 at 08:12:53PM -0300, Jose Alonso wrote:
> > On Wed, 2010-03-03 at 15:14 -0500, John W. Linville wrote:
> > > On Sun, Feb 28, 2010 at 03:42:54PM +0100, matthieu castet wrote:
> > > > For the firmware version 5.30.17 the log file shows:
> > > > Firmware version 5.30.11
> > > >
> > > > The variable softSubVer is binary.
> > > >
> > > >
> > > > Signed-off-by: Matthieu CASTET <castet.matthieu@free.fr>
> > > > Signed-off-by: Jose Alonso <joalonsof@gmail.com>
> > > 
> > > > Index: airo.c
> > > > ===================================================================
> > > > --- 1/drivers/net/wireless/airo.c	(r?vision 47)
> > > > +++ 2/drivers/net/wireless/airo.c	(r?vision 48)
> > > > @@ -2993,7 +2993,7 @@
> > > >  	ai->wep_capable = (cap_rid.softCap & cpu_to_le16(0x02)) ? 1 : 0;
> > > >  	ai->max_wep_idx = (cap_rid.softCap & cpu_to_le16(0x80)) ? 3 : 0;
> > > >  
> > > > -	airo_print_info(dev->name, "Firmware version %x.%x.%02x",
> > > > +	airo_print_info(dev->name, "Firmware version %x.%x.%02d",
> > > >  	                ((le16_to_cpu(cap_rid.softVer) >> 8) & 0xF),
> > > >  	                (le16_to_cpu(cap_rid.softVer) & 0xFF),
> > > >  	                le16_to_cpu(cap_rid.softSubVer));
> > > 
> > > Why should the last segment be in decimal form if the other two
> > > segments of the version number are in hexadecimal form?
> > 
> > The airo.c shows the usage of hexadecimal and binary form:
> > 
> >         /* Test for WPA support */
> >         /* Only firmware versions 5.30.17 or better can do WPA */
> >         if (le16_to_cpu(cap_rid.softVer) > 0x530
> >          || (le16_to_cpu(cap_rid.softVer) == 0x530
> >               && le16_to_cpu(cap_rid.softSubVer) >= 17)) {
> >                 airo_print_info(ai->dev->name, "WPA supported.");
> 
> Alright, but that could be an argument for changing the comment.
> Probably too much to ask, but is there some authoritative source for
> this busted numbering scheme?

Not really, you flash a certain known version of firmware onto the
device in Windows, then see what Linux supports.  I'll see if I can
check my card out and see what I come up with.

Dan



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] airo : Print of firmware version
  2010-03-04 16:06       ` Dan Williams
@ 2010-03-04 16:10         ` Dan Williams
  0 siblings, 0 replies; 6+ messages in thread
From: Dan Williams @ 2010-03-04 16:10 UTC (permalink / raw)
  To: John W. Linville; +Cc: Jose Alonso, matthieu castet, linux-wireless

On Thu, 2010-03-04 at 08:06 -0800, Dan Williams wrote:
> On Wed, 2010-03-03 at 21:20 -0500, John W. Linville wrote:
> > On Wed, Mar 03, 2010 at 08:12:53PM -0300, Jose Alonso wrote:
> > > On Wed, 2010-03-03 at 15:14 -0500, John W. Linville wrote:
> > > > On Sun, Feb 28, 2010 at 03:42:54PM +0100, matthieu castet wrote:
> > > > > For the firmware version 5.30.17 the log file shows:
> > > > > Firmware version 5.30.11
> > > > >
> > > > > The variable softSubVer is binary.
> > > > >
> > > > >
> > > > > Signed-off-by: Matthieu CASTET <castet.matthieu@free.fr>
> > > > > Signed-off-by: Jose Alonso <joalonsof@gmail.com>
> > > > 
> > > > > Index: airo.c
> > > > > ===================================================================
> > > > > --- 1/drivers/net/wireless/airo.c	(r?vision 47)
> > > > > +++ 2/drivers/net/wireless/airo.c	(r?vision 48)
> > > > > @@ -2993,7 +2993,7 @@
> > > > >  	ai->wep_capable = (cap_rid.softCap & cpu_to_le16(0x02)) ? 1 : 0;
> > > > >  	ai->max_wep_idx = (cap_rid.softCap & cpu_to_le16(0x80)) ? 3 : 0;
> > > > >  
> > > > > -	airo_print_info(dev->name, "Firmware version %x.%x.%02x",
> > > > > +	airo_print_info(dev->name, "Firmware version %x.%x.%02d",
> > > > >  	                ((le16_to_cpu(cap_rid.softVer) >> 8) & 0xF),
> > > > >  	                (le16_to_cpu(cap_rid.softVer) & 0xFF),
> > > > >  	                le16_to_cpu(cap_rid.softSubVer));
> > > > 
> > > > Why should the last segment be in decimal form if the other two
> > > > segments of the version number are in hexadecimal form?
> > > 
> > > The airo.c shows the usage of hexadecimal and binary form:
> > > 
> > >         /* Test for WPA support */
> > >         /* Only firmware versions 5.30.17 or better can do WPA */
> > >         if (le16_to_cpu(cap_rid.softVer) > 0x530
> > >          || (le16_to_cpu(cap_rid.softVer) == 0x530
> > >               && le16_to_cpu(cap_rid.softSubVer) >= 17)) {
> > >                 airo_print_info(ai->dev->name, "WPA supported.");
> > 
> > Alright, but that could be an argument for changing the comment.
> > Probably too much to ask, but is there some authoritative source for
> > this busted numbering scheme?
> 
> Not really, you flash a certain known version of firmware onto the
> device in Windows, then see what Linux supports.  I'll see if I can
> check my card out and see what I come up with.

s/supports/reports.

Dan



^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2010-03-04 16:10 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-02-28 14:42 [PATCH] airo : Print of firmware version matthieu castet
2010-03-03 20:14 ` John W. Linville
2010-03-03 23:12   ` Jose Alonso
2010-03-04  2:20     ` John W. Linville
2010-03-04 16:06       ` Dan Williams
2010-03-04 16:10         ` Dan Williams

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).