Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
L
lede-mikrotik
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
External wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Johannes Rudolph
lede-mikrotik
Commits
8643ea58
Commit
8643ea58
authored
13 years ago
by
Felix Fietkau
Browse files
Options
Downloads
Patches
Plain Diff
ath9k: minor fixes for the antenna control patch
SVN-Revision: 28109
parent
dcb00e06
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
package/mac80211/patches/582-ath9k_antdiv_comb_cb.patch
+0
-50
0 additions, 50 deletions
package/mac80211/patches/582-ath9k_antdiv_comb_cb.patch
package/mac80211/patches/582-ath9k_antenna_control.patch
+5
-6
5 additions, 6 deletions
package/mac80211/patches/582-ath9k_antenna_control.patch
with
5 additions
and
56 deletions
package/mac80211/patches/582-ath9k_antdiv_comb_cb.patch
deleted
100644 → 0
+
0
−
50
View file @
dcb00e06
--- a/drivers/net/wireless/ath/ath9k/hw-ops.h
+++ b/drivers/net/wireless/ath/ath9k/hw-ops.h
@@ -121,13 +121,15 @@
static inline void ath9k_hw_set_clrdmask
static inline void ath9k_hw_antdiv_comb_conf_get(struct ath_hw *ah,
struct ath_hw_antcomb_conf *antconf)
{
- ath9k_hw_ops(ah)->antdiv_comb_conf_get(ah, antconf);
+ if (ath9k_hw_ops(ah)->antdiv_comb_conf_get)
+ ath9k_hw_ops(ah)->antdiv_comb_conf_get(ah, antconf);
}
static inline void ath9k_hw_antdiv_comb_conf_set(struct ath_hw *ah,
struct ath_hw_antcomb_conf *antconf)
{
- ath9k_hw_ops(ah)->antdiv_comb_conf_set(ah, antconf);
+ if (ath9k_hw_ops(ah)->antdiv_comb_conf_set)
+ ath9k_hw_ops(ah)->antdiv_comb_conf_set(ah, antconf);
}
/* Private hardware call ops */
--- a/drivers/net/wireless/ath/ath9k/ar9002_phy.c
+++ b/drivers/net/wireless/ath/ath9k/ar9002_phy.c
@@ -570,8 +570,10 @@
void ar9002_hw_attach_phy_ops(struct ath
priv_ops->compute_pll_control = ar9002_hw_compute_pll_control;
priv_ops->do_getnf = ar9002_hw_do_getnf;
- ops->antdiv_comb_conf_get = ar9002_hw_antdiv_comb_conf_get;
- ops->antdiv_comb_conf_set = ar9002_hw_antdiv_comb_conf_set;
+ if (AR_SREV_9285(ah)) {
+ ops->antdiv_comb_conf_get = ar9002_hw_antdiv_comb_conf_get;
+ ops->antdiv_comb_conf_set = ar9002_hw_antdiv_comb_conf_set;
+ }
ar9002_hw_set_nf_limits(ah);
}
--- a/drivers/net/wireless/ath/ath9k/ar9003_phy.c
+++ b/drivers/net/wireless/ath/ath9k/ar9003_phy.c
@@ -1283,8 +1283,10 @@
void ar9003_hw_attach_phy_ops(struct ath
priv_ops->ani_cache_ini_regs = ar9003_hw_ani_cache_ini_regs;
priv_ops->set_radar_params = ar9003_hw_set_radar_params;
- ops->antdiv_comb_conf_get = ar9003_hw_antdiv_comb_conf_get;
- ops->antdiv_comb_conf_set = ar9003_hw_antdiv_comb_conf_set;
+ if (AR_SREV_9330(ah) || AR_SREV_9485(ah)) {
+ ops->antdiv_comb_conf_get = ar9003_hw_antdiv_comb_conf_get;
+ ops->antdiv_comb_conf_set = ar9003_hw_antdiv_comb_conf_set;
+ }
ar9003_hw_set_nf_limits(ah);
ar9003_hw_set_radar_conf(ah);
This diff is collapsed.
Click to expand it.
package/mac80211/patches/58
3
-ath9k_antenna_control.patch
→
package/mac80211/patches/58
2
-ath9k_antenna_control.patch
+
5
−
6
View file @
8643ea58
...
...
@@ -24,7 +24,7 @@
hw->flags = IEEE80211_HW_RX_INCLUDES_FCS |
IEEE80211_HW_HOST_BROADCAST_PS_BUFFERING |
@@ -692,6 +705,1
7
@@
void ath9k_set_hw_capab(struct ath_softc
@@ -692,6 +705,1
6
@@
void ath9k_set_hw_capab(struct ath_softc
hw->sta_data_size = sizeof(struct ath_node);
hw->vif_data_size = sizeof(struct ath_vif);
...
...
@@ -32,9 +32,8 @@
+ hw->wiphy->available_antennas_tx = BIT(ah->caps.max_txchains) - 1;
+
+ /* single chain devices with rx diversity */
+ if (ah->caps.max_rxchains == 1 &&
+ ath9k_hw_ops(ah)->antdiv_comb_conf_get)
+ hw->wiphy->available_antennas_rx = 3;
+ if (ah->caps.hw_caps & ATH9K_HW_CAP_ANT_DIV_COMB)
+ hw->wiphy->available_antennas_rx = BIT(0) | BIT(1);
+
+ sc->ant_rx = hw->wiphy->available_antennas_rx;
+ sc->ant_tx = hw->wiphy->available_antennas_tx;
...
...
@@ -42,7 +41,7 @@
#ifdef CONFIG_ATH9K_RATE_CONTROL
hw->rate_control_algorithm = "ath9k_rate_control";
#endif
@@ -703,12 +72
7
,7 @@
void ath9k_set_hw_capab(struct ath_softc
@@ -703,12 +72
6
,7 @@
void ath9k_set_hw_capab(struct ath_softc
hw->wiphy->bands[IEEE80211_BAND_5GHZ] =
&sc->sbands[IEEE80211_BAND_5GHZ];
...
...
@@ -62,7 +61,7 @@
struct ath_descdma txsdma;
struct ath_ant_comb ant_comb;
+ u
32
ant_tx, ant_rx;
+ u
8
ant_tx, ant_rx;
};
void ath9k_tasklet(unsigned long data);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment