diff mbox

[03/11] rt2800: move RFCSR29_RSSI_GAIN to 3290 specific rfcsr init

Message ID 1365519930-3230-4-git-send-email-stf_xl@wp.pl (mailing list archive)
State Not Applicable, archived
Headers show

Commit Message

Stanislaw Gruszka April 9, 2013, 3:05 p.m. UTC
From: Stanislaw Gruszka <stf_xl@wp.pl>

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
---
 drivers/net/wireless/rt2x00/rt2800lib.c |   12 ++++++------
 1 files changed, 6 insertions(+), 6 deletions(-)

Comments

Gertjan van Wingerde April 14, 2013, 8:15 p.m. UTC | #1
(Resending as the message didn't seem to end up on the mailing list)


> Hi Stanislaw,
> 
> Looks good to me. When you repost the series with all comments fixed, you can add my acked-by.
> 
> Sent from my iPad
> 
> On 9 apr. 2013, at 17:05, stf_xl@wp.pl wrote:
> 
>> From: Stanislaw Gruszka <stf_xl@wp.pl>
>> 
>> Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
>> ---
>> drivers/net/wireless/rt2x00/rt2800lib.c |   12 ++++++------
>> 1 files changed, 6 insertions(+), 6 deletions(-)
>> 
>> diff --git a/drivers/net/wireless/rt2x00/rt2800lib.c b/drivers/net/wireless/rt2x00/rt2800lib.c
>> index 334973a..085b60c 100644
>> --- a/drivers/net/wireless/rt2x00/rt2800lib.c
>> +++ b/drivers/net/wireless/rt2x00/rt2800lib.c
>> @@ -4511,6 +4511,8 @@ static void rt2800_init_rfcsr_30xx(struct rt2x00_dev *rt2x00dev)
>> 
>> static void rt2800_init_rfcsr_3290(struct rt2x00_dev *rt2x00dev)
>> {
>> +    u8 rfcsr;
>> +
>>   rt2800_rf_init_calibration_53xx(rt2x00dev);
>> 
>>   rt2800_rfcsr_write(rt2x00dev, 1, 0x0f);
>> @@ -4559,6 +4561,10 @@ static void rt2800_init_rfcsr_3290(struct rt2x00_dev *rt2x00dev)
>>   rt2800_rfcsr_write(rt2x00dev, 59, 0x09);
>>   rt2800_rfcsr_write(rt2x00dev, 60, 0x45);
>>   rt2800_rfcsr_write(rt2x00dev, 61, 0xc1);
>> +
>> +    rt2800_rfcsr_read(rt2x00dev, 29, &rfcsr);
>> +    rt2x00_set_field8(&rfcsr, RFCSR29_RSSI_GAIN, 3);
>> +    rt2800_rfcsr_write(rt2x00dev, 29, rfcsr);
>> }
>> 
>> static void rt2800_init_rfcsr_3352(struct rt2x00_dev *rt2x00dev)
>> @@ -5103,12 +5109,6 @@ static int rt2800_init_rfcsr(struct rt2x00_dev *rt2x00dev)
>>       rt2800_rfcsr_write(rt2x00dev, 27, rfcsr);
>>   }
>> 
>> -    if (rt2x00_rt(rt2x00dev, RT3290)) {
>> -        rt2800_rfcsr_read(rt2x00dev, 29, &rfcsr);
>> -        rt2x00_set_field8(&rfcsr, RFCSR29_RSSI_GAIN, 3);
>> -        rt2800_rfcsr_write(rt2x00dev, 29, rfcsr);
>> -    }
>> -
>>   return 0;
>> }
>> 
>> -- 
>> 1.7.4.4
>> 
>> --
>> To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
>> the body of a message to majordomo@vger.kernel.org
>> More majordomo info at  http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/drivers/net/wireless/rt2x00/rt2800lib.c b/drivers/net/wireless/rt2x00/rt2800lib.c
index 334973a..085b60c 100644
--- a/drivers/net/wireless/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/rt2x00/rt2800lib.c
@@ -4511,6 +4511,8 @@  static void rt2800_init_rfcsr_30xx(struct rt2x00_dev *rt2x00dev)
 
 static void rt2800_init_rfcsr_3290(struct rt2x00_dev *rt2x00dev)
 {
+	u8 rfcsr;
+
 	rt2800_rf_init_calibration_53xx(rt2x00dev);
 
 	rt2800_rfcsr_write(rt2x00dev, 1, 0x0f);
@@ -4559,6 +4561,10 @@  static void rt2800_init_rfcsr_3290(struct rt2x00_dev *rt2x00dev)
 	rt2800_rfcsr_write(rt2x00dev, 59, 0x09);
 	rt2800_rfcsr_write(rt2x00dev, 60, 0x45);
 	rt2800_rfcsr_write(rt2x00dev, 61, 0xc1);
+
+	rt2800_rfcsr_read(rt2x00dev, 29, &rfcsr);
+	rt2x00_set_field8(&rfcsr, RFCSR29_RSSI_GAIN, 3);
+	rt2800_rfcsr_write(rt2x00dev, 29, rfcsr);
 }
 
 static void rt2800_init_rfcsr_3352(struct rt2x00_dev *rt2x00dev)
@@ -5103,12 +5109,6 @@  static int rt2800_init_rfcsr(struct rt2x00_dev *rt2x00dev)
 		rt2800_rfcsr_write(rt2x00dev, 27, rfcsr);
 	}
 
-	if (rt2x00_rt(rt2x00dev, RT3290)) {
-		rt2800_rfcsr_read(rt2x00dev, 29, &rfcsr);
-		rt2x00_set_field8(&rfcsr, RFCSR29_RSSI_GAIN, 3);
-		rt2800_rfcsr_write(rt2x00dev, 29, rfcsr);
-	}
-
 	return 0;
 }