Add support for rf3070 devices from Stanislaw Gruszka (rhbz 974072)

This commit is contained in:
Josh Boyer 2013-09-30 09:39:49 -04:00
parent 6393d282ca
commit 7f68f83dae
2 changed files with 87 additions and 0 deletions

View File

@ -777,6 +777,9 @@ Patch25115: elevator-acquire-q-sysfs_lock-in-elevator_change.patch
#rhbz 1011719
Patch25116: hwmon-applesmc-Check-key-count-before-proceeding.patch
#rhbz 974072
Patch25117: rt2800-add-support-for-rf3070.patch
# END OF PATCH DEFINITIONS
%endif
@ -1502,6 +1505,9 @@ ApplyPatch elevator-acquire-q-sysfs_lock-in-elevator_change.patch
#rhbz 1011719
ApplyPatch hwmon-applesmc-Check-key-count-before-proceeding.patch
#rhbz 974072
ApplyPatch rt2800-add-support-for-rf3070.patch
# END OF PATCH APPLICATIONS
%endif
@ -2315,6 +2321,7 @@ fi
%changelog
* Mon Sep 30 2013 Josh Boyer <jwboyer@fedoraproject.org>
- Add support for rf3070 devices from Stanislaw Gruszka (rhbz 974072)
- Drop VC_MUTE patch (rhbz 859485)
* Fri Sep 27 2013 Justin M. Forbes <jforbes@fedoraproject.org> - 3.11.2-201

View File

@ -0,0 +1,80 @@
diff --git a/drivers/net/wireless/rt2x00/rt2800.h b/drivers/net/wireless/rt2x00/rt2800.h
index d78c495..2132830 100644
--- a/drivers/net/wireless/rt2x00/rt2800.h
+++ b/drivers/net/wireless/rt2x00/rt2800.h
@@ -65,6 +65,7 @@
#define RF3021 0x0007
#define RF3022 0x0008
#define RF3052 0x0009
+#define RF3070 0x3070
#define RF2853 0x000a
#define RF3320 0x000b
#define RF3322 0x000c
diff --git a/drivers/net/wireless/rt2x00/rt2800lib.c b/drivers/net/wireless/rt2x00/rt2800lib.c
index 1b41c8e..2958265 100644
--- a/drivers/net/wireless/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/rt2x00/rt2800lib.c
@@ -2597,6 +2597,7 @@ static void rt2800_config_channel(struct rt2x00_dev *rt2x00dev,
case RF3322:
rt2800_config_channel_rf3322(rt2x00dev, conf, rf, info);
break;
+ case RF3070:
case RF5360:
case RF5370:
case RF5372:
@@ -2611,7 +2612,8 @@ static void rt2800_config_channel(struct rt2x00_dev *rt2x00dev,
rt2800_config_channel_rf2xxx(rt2x00dev, conf, rf, info);
}
- if (rt2x00_rf(rt2x00dev, RF3290) ||
+ if (rt2x00_rf(rt2x00dev, RF3070) ||
+ rt2x00_rf(rt2x00dev, RF3290) ||
rt2x00_rf(rt2x00dev, RF3322) ||
rt2x00_rf(rt2x00dev, RF5360) ||
rt2x00_rf(rt2x00dev, RF5370) ||
@@ -3219,6 +3221,7 @@ void rt2800_vco_calibration(struct rt2x00_dev *rt2x00dev)
rt2x00_set_field8(&rfcsr, RFCSR7_RF_TUNING, 1);
rt2800_rfcsr_write(rt2x00dev, 7, rfcsr);
break;
+ case RF3070:
case RF3290:
case RF5360:
case RF5370:
@@ -5731,6 +5734,7 @@ static int rt2800_init_eeprom(struct rt2x00_dev *rt2x00dev)
case RF3021:
case RF3022:
case RF3052:
+ case RF3070:
case RF3290:
case RF3320:
case RF3322:
@@ -6186,6 +6190,7 @@ static int rt2800_probe_hw_mode(struct rt2x00_dev *rt2x00dev)
rt2x00_rf(rt2x00dev, RF2020) ||
rt2x00_rf(rt2x00dev, RF3021) ||
rt2x00_rf(rt2x00dev, RF3022) ||
+ rt2x00_rf(rt2x00dev, RF3070) ||
rt2x00_rf(rt2x00dev, RF3290) ||
rt2x00_rf(rt2x00dev, RF3320) ||
rt2x00_rf(rt2x00dev, RF3322) ||
@@ -6219,10 +6224,11 @@ static int rt2800_probe_hw_mode(struct rt2x00_dev *rt2x00dev)
/*
* Initialize HT information.
*/
- if (!rt2x00_rf(rt2x00dev, RF2020))
+ if (!rt2x00_rf(rt2x00dev, RF2020)) {
spec->ht.ht_supported = true;
- else
+ } else {
spec->ht.ht_supported = false;
+ }
spec->ht.cap =
IEEE80211_HT_CAP_SUP_WIDTH_20_40 |
@@ -6290,6 +6296,7 @@ static int rt2800_probe_hw_mode(struct rt2x00_dev *rt2x00dev)
case RF3022:
case RF3320:
case RF3052:
+ case RF3070:
case RF3290:
case RF5360:
case RF5370: