]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/blame - src/patches/backports-4.2.6-1-ath9k_add_missing_mask_init.patch
squid 3.5.28: latest patches (01-02)
[people/pmueller/ipfire-2.x.git] / src / patches / backports-4.2.6-1-ath9k_add_missing_mask_init.patch
CommitLineData
875bd87b
AF
1by moving common code to ar5008_hw_cmn_spur_mitigate i forgot to move
2mask_m & mask_p initialisation. This coused a performance regression
3on ar9281.
4
5
6Fixes: f911085ffa88 ("ath9k: split ar5008_hw_spur_mitigate and reuse common
7code in ar9002_hw_spur_mitigate.")
8Reported-by: Gustav Frederiksen <lkml2...@openmailbox.org>
9Tested-by: Gustav Frederiksen <lkml2...@openmailbox.org>
10Signed-off-by: Oleksij Rempel <li...@rempel-privat.de>
11diff -Naur backports-4.2.6-1.org/drivers/net/wireless/ath/ath9k/ar5008_phy.c backports-4.2.6-1/drivers/net/wireless/ath/ath9k/ar5008_phy.c
12--- backports-4.2.6-1.org/drivers/net/wireless/ath/ath9k/ar5008_phy.c 2015-11-15 22:19:39.000000000 +0100
13+++ backports-4.2.6-1/drivers/net/wireless/ath/ath9k/ar5008_phy.c 2016-04-25 09:37:58.765112541 +0200
14@@ -274,6 +274,9 @@
15 };
16 static const int inc[4] = { 0, 100, 0, 0 };
17
18+ memset(&mask_m, 0, sizeof(int8_t) * 123);
19+ memset(&mask_p, 0, sizeof(int8_t) * 123);
20+
21 cur_bin = -6000;
22 upper = bin + 100;
23 lower = bin - 100;
24@@ -424,14 +427,9 @@
25 int tmp, new;
26 int i;
27
28- int8_t mask_m[123];
29- int8_t mask_p[123];
30 int cur_bb_spur;
31 bool is2GHz = IS_CHAN_2GHZ(chan);
32
33- memset(&mask_m, 0, sizeof(int8_t) * 123);
34- memset(&mask_p, 0, sizeof(int8_t) * 123);
35-
36 for (i = 0; i < AR_EEPROM_MODAL_SPURS; i++) {
37 cur_bb_spur = ah->eep_ops->get_spur_channel(ah, i, is2GHz);
38 if (AR_NO_SPUR == cur_bb_spur)
39diff -Naur backports-4.2.6-1.org/drivers/net/wireless/ath/ath9k/ar9002_phy.c backports-4.2.6-1/drivers/net/wireless/ath/ath9k/ar9002_phy.c
40--- backports-4.2.6-1.org/drivers/net/wireless/ath/ath9k/ar9002_phy.c 2015-11-15 22:19:39.000000000 +0100
41+++ backports-4.2.6-1/drivers/net/wireless/ath/ath9k/ar9002_phy.c 2016-04-25 09:38:57.729109148 +0200
42@@ -178,14 +178,9 @@
43 int i;
44 struct chan_centers centers;
45
46- int8_t mask_m[123];
47- int8_t mask_p[123];
48 int cur_bb_spur;
49 bool is2GHz = IS_CHAN_2GHZ(chan);
50
51- memset(&mask_m, 0, sizeof(int8_t) * 123);
52- memset(&mask_p, 0, sizeof(int8_t) * 123);
53-
54 ath9k_hw_get_channel_centers(ah, chan, &centers);
55 freq = centers.synth_center;
56