linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/4] rt2800: radio 3xxx: reprogram only lower bits of RF_R3
@ 2012-01-30 15:17 Stanislaw Gruszka
  2012-01-30 15:17 ` [PATCH 2/4] rt2800: radio 3xxx: program RF_R1 during channel switch Stanislaw Gruszka
                   ` (3 more replies)
  0 siblings, 4 replies; 14+ messages in thread
From: Stanislaw Gruszka @ 2012-01-30 15:17 UTC (permalink / raw)
  To: John W. Linville; +Cc: linux-wireless, users, Stanislaw Gruszka

Synchronize code with Ralink driver:
2011_0719_RT3070_RT3370_RT5370_RT5372_Linux_STA_V2.5.0.3_DPO
(functions: RT33xx_ChipSwitchChannel() and RT30xx_ChipSwitchChannel())

Acked-by: Gertjan van Wingerde <gwingerde@gmail.com>
Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>
---
 drivers/net/wireless/rt2x00/rt2800.h    |    5 +++++
 drivers/net/wireless/rt2x00/rt2800lib.c |    5 ++++-
 2 files changed, 9 insertions(+), 1 deletions(-)

diff --git a/drivers/net/wireless/rt2x00/rt2800.h b/drivers/net/wireless/rt2x00/rt2800.h
index 2571a2f..abf2ae5 100644
--- a/drivers/net/wireless/rt2x00/rt2800.h
+++ b/drivers/net/wireless/rt2x00/rt2800.h
@@ -1796,6 +1796,11 @@ struct mac_iveiv_entry {
 #define RFCSR2_RESCAL_EN		FIELD8(0x80)
 
 /*
+ * RFCSR 3:
+ */
+#define RFCSR3_K			FIELD8(0x0f)
+
+/*
  * FRCSR 5:
  */
 #define RFCSR5_R1			FIELD8(0x0c)
diff --git a/drivers/net/wireless/rt2x00/rt2800lib.c b/drivers/net/wireless/rt2x00/rt2800lib.c
index 22a1a8f..6edf566 100644
--- a/drivers/net/wireless/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/rt2x00/rt2800lib.c
@@ -1649,7 +1649,10 @@ static void rt2800_config_channel_rf3xxx(struct rt2x00_dev *rt2x00dev,
 	u8 rfcsr;
 
 	rt2800_rfcsr_write(rt2x00dev, 2, rf->rf1);
-	rt2800_rfcsr_write(rt2x00dev, 3, rf->rf3);
+
+	rt2800_rfcsr_read(rt2x00dev, 3, &rfcsr);
+	rt2x00_set_field8(&rfcsr, RFCSR3_K, rf->rf3);
+	rt2800_rfcsr_write(rt2x00dev, 3, rfcsr);
 
 	rt2800_rfcsr_read(rt2x00dev, 6, &rfcsr);
 	rt2x00_set_field8(&rfcsr, RFCSR6_R1, rf->rf2);
-- 
1.7.1


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

end of thread, other threads:[~2012-02-01 19:12 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-01-30 15:17 [PATCH 1/4] rt2800: radio 3xxx: reprogram only lower bits of RF_R3 Stanislaw Gruszka
2012-01-30 15:17 ` [PATCH 2/4] rt2800: radio 3xxx: program RF_R1 during channel switch Stanislaw Gruszka
2012-01-30 22:06   ` [rt2x00-users] " Gertjan van Wingerde
2012-01-31  8:14     ` Stanislaw Gruszka
2012-01-31 17:00       ` Gertjan van Wingerde
2012-02-01 15:21         ` Stanislaw Gruszka
2012-01-30 15:17 ` [PATCH 3/4] rt2800: radio 3xxx: add channel switch calibration routines Stanislaw Gruszka
2012-02-01 10:30   ` Helmut Schaa
2012-01-30 15:17 ` [PATCH 4/4] rt2800: radio 3xxxx: channel switch RX/TX calibration fixes Stanislaw Gruszka
2012-01-30 22:12   ` [rt2x00-users] " Gertjan van Wingerde
2012-02-01 15:17   ` [PATCH 5/4] rt2800: document RF_R03 register bits [7:4] Stanislaw Gruszka
2012-02-01 17:00     ` Helmut Schaa
2012-02-01 19:11     ` [rt2x00-users] " Gertjan van Wingerde
2012-02-01 10:27 ` [PATCH 1/4] rt2800: radio 3xxx: reprogram only lower bits of RF_R3 Helmut Schaa

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).