linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Mohammed Shafi Shajakhan <mohammed@qca.qualcomm.com>
To: Mohammed Shafi Shajakhan <mohammed@qca.qualcomm.com>
Cc: "John W. Linville" <linville@tuxdriver.com>,
	<linux-wireless@vger.kernel.org>,
	Rodriguez Luis <rodrigue@qca.qualcomm.com>,
	<ath9k-devel@lists.ath9k.org>,
	"nbd@openwrt.org" <nbd@openwrt.org>
Subject: Re: [RFC] ath9k_hw: Fix chip revision checks
Date: Mon, 12 Mar 2012 15:14:42 +0530	[thread overview]
Message-ID: <4F5DC58A.10808@qca.qualcomm.com> (raw)
In-Reply-To: <1331531853-5043-1-git-send-email-mohammed@qca.qualcomm.com>

On Monday 12 March 2012 11:27 AM, Mohammed Shafi Shajakhan wrote:
> From: Mohammed Shafi Shajakhan<mohammed@qca.qualcomm.com>
>
> not sure if these checks are previously avoided may be those revision of
> chipsets are obselete ?
>
> Signed-off-by: Mohammed Shafi Shajakhan<mohammed@qca.qualcomm.com>
> ---
>   drivers/net/wireless/ath/ath9k/reg.h |   20 +++++++++++++++-----
>   1 files changed, 15 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/net/wireless/ath/ath9k/reg.h b/drivers/net/wireless/ath/ath9k/reg.h
> index 80b1856..55e3513 100644
> --- a/drivers/net/wireless/ath/ath9k/reg.h
> +++ b/drivers/net/wireless/ath/ath9k/reg.h
> @@ -821,20 +821,28 @@
>   	 ((_ah)->hw_version.macRev == AR_SREV_REVISION_9160_11))
>   #define AR_SREV_9280(_ah) \
>   	(((_ah)->hw_version.macVersion == AR_SREV_VERSION_9280))
> -#define AR_SREV_9280_20_OR_LATER(_ah) \
> -	(((_ah)->hw_version.macVersion>= AR_SREV_VERSION_9280))
>   #define AR_SREV_9280_20(_ah) \
>   	(((_ah)->hw_version.macVersion == AR_SREV_VERSION_9280))
> +#define AR_SREV_9280_10_OR_LATER(_ah) \
> +	(((_ah)->hw_version.macVersion>= AR_SREV_VERSION_9280))
> +#define AR_SREV_9280_20_OR_LATER(_ah) \
> +	(((_ah)->hw_version.macVersion>  AR_SREV_VERSION_9280) || \
> +	 (((_ah)->hw_version.macVersion == AR_SREV_VERSION_9280)&&  \
> +	  ((_ah)->hw_version.macRev>= AR_SREV_REVISION_9280_20)))
>
>   #define AR_SREV_9285(_ah) \
>   	(((_ah)->hw_version.macVersion == AR_SREV_VERSION_9285))
>   #define AR_SREV_9285_12_OR_LATER(_ah) \
> -	(((_ah)->hw_version.macVersion>= AR_SREV_VERSION_9285))
> +	(((_ah)->hw_version.macVersion>  AR_SREV_VERSION_9285) || \
> +	 (((_ah)->hw_version.macVersion == AR_SREV_VERSION_9285)&&  \
> +	  ((_ah)->hw_version.macRev>= AR_SREV_REVISION_9285_12)))
>
>   #define AR_SREV_9287(_ah) \
>   	(((_ah)->hw_version.macVersion == AR_SREV_VERSION_9287))
>   #define AR_SREV_9287_11_OR_LATER(_ah) \
> -	(((_ah)->hw_version.macVersion>= AR_SREV_VERSION_9287))
> +	(((_ah)->hw_version.macVersion>  AR_SREV_VERSION_9287) || \
> +	 (((_ah)->hw_version.macVersion == AR_SREV_VERSION_9287)&&  \
> +	  ((_ah)->hw_version.macRev>= AR_SREV_REVISION_9285_11)))

oops, also i made a mistake here, it should be AR_SREV_REVISION_9287_11


>   #define AR_SREV_9287_11(_ah) \
>   	(((_ah)->hw_version.macVersion == AR_SREV_VERSION_9287)&&  \
>   	 ((_ah)->hw_version.macRev == AR_SREV_REVISION_9287_11))
> @@ -862,7 +870,9 @@
>   #define AR_SREV_9300(_ah) \
>   	(((_ah)->hw_version.macVersion == AR_SREV_VERSION_9300))
>   #define AR_SREV_9300_20_OR_LATER(_ah) \
> -	((_ah)->hw_version.macVersion>= AR_SREV_VERSION_9300)
> +	(((_ah)->hw_version.macVersion>  AR_SREV_VERSION_9300) || \
> +	 (((_ah)->hw_version.macVersion == AR_SREV_VERSION_9300)&&  \
> +	  ((_ah)->hw_version.macRev>= AR_SREV_REVISION_9300_20)))
>
>   #define AR_SREV_9330(_ah) \
>   	(((_ah)->hw_version.macVersion == AR_SREV_VERSION_9330))


-- 
thanks,
shafi

      parent reply	other threads:[~2012-03-12  9:44 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-03-12  5:57 [RFC] ath9k_hw: Fix chip revision checks Mohammed Shafi Shajakhan
2012-03-12  9:02 ` [ath9k-devel] " Felix Fietkau
2012-03-12  9:16   ` Mohammed Shafi Shajakhan
2012-03-12  9:41     ` Mohammed Shafi Shajakhan
2012-03-12 20:16     ` Luis R. Rodriguez
2012-03-13  4:36       ` Mohammed Shafi Shajakhan
2012-03-12  9:44 ` Mohammed Shafi Shajakhan [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4F5DC58A.10808@qca.qualcomm.com \
    --to=mohammed@qca.qualcomm.com \
    --cc=ath9k-devel@lists.ath9k.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=linville@tuxdriver.com \
    --cc=nbd@openwrt.org \
    --cc=rodrigue@qca.qualcomm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).