master firmware version bumped to 1.4; 1.3 branched

Eugene Krasnikov k.eugene.e at gmail.com
Mon Apr 8 06:35:48 EDT 2013


Ok let's start with something like this and change when feature bitmap
is implemented:

>From 6420a7bc940fb0d5f8c0cb3d22df5062c9cf69c9 Mon Sep 17 00:00:00 2001
From: Eugene Krasnikov <k.eugene.e at gmail.com>
Date: Thu, 4 Apr 2013 18:49:16 +0200
Subject: [PATCH] Add support opensource firmware

Opensource firmware was branched out and now driver
must support both new opensource and old proprietary
firmwares.

Signed-off-by: Eugene Krasnikov <k.eugene.e at gmail.com>
---
 drivers/net/wireless/ath/ath9k/htc_drv_init.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/wireless/ath/ath9k/htc_drv_init.c
b/drivers/net/wireless/ath/ath9k/htc_drv_init.c
index 716058b..502a1b2 100644
--- a/drivers/net/wireless/ath/ath9k/htc_drv_init.c
+++ b/drivers/net/wireless/ath/ath9k/htc_drv_init.c
@@ -795,8 +795,8 @@ static int ath9k_init_firmware_version(struct
ath9k_htc_priv *priv)
      * Check if the available FW matches the driver's
      * required version.
      */
-    if (priv->fw_version_major != MAJOR_VERSION_REQ ||
-        priv->fw_version_minor != MINOR_VERSION_REQ) {
+    if (!(priv->fw_version_major == MAJOR_VERSION_REQ &&
+        priv->fw_version_minor >= MINOR_VERSION_REQ)) {
         dev_err(priv->dev, "ath9k_htc: Please upgrade to FW version %d.%d\n",
             MAJOR_VERSION_REQ, MINOR_VERSION_REQ);
         return -EINVAL;
--
1.7.9.5



2013/4/5 Adrian Chadd <adrian at freebsd.org>:
> On 5 April 2013 09:50, Eugene Krasnikov <k.eugene.e at gmail.com> wrote:
>> Adrian,
>>
>> By the way do you know if 1.1 and 1.3 are compatible?
>> If they not then more tricky logic is required. E.g. starting from 2.0
>> compare only major version but before 2.0 use old logic to compare if
>> driver and fw compatible.
>
> No, I think 1.1 and 1.3 are incompatible. And we don't really support
> 1.1; I'd have to go find the code in the internal github repo in order
> to even be able to build a 1.1 era firmware.
>
> I'd rather we bite the bullet and leave people needing to run >= 1.3.
>
> And yes, once we migrate to a "2.0" firmware, it'll be a major jump.
> ath9k_htc just won't be backwards compatible at that point with 1.x.
> So that check will go away.
>
> So it's enough for now to say if (major == 1 && minor >= 3).
>
> Thanks,
>
>
> Adrian



-- 
Best regards,
Eugene



More information about the Ath9k_htc_fw mailing list