2a6d27cc5dd23ed75036609c354edc08fb0446ad
[openwrt/svn-archive/archive.git] / package / madwifi / patches / 438-poweroffset_sysctl.patch
1 --- a/ath/if_ath.c
2 +++ b/ath/if_ath.c
3 @@ -11029,6 +11029,7 @@ enum {
4 ATH_DEBUG,
5 ATH_TXANTENNA,
6 ATH_RXANTENNA,
7 + ATH_POWEROFFSET,
8 ATH_DIVERSITY,
9 ATH_TXINTRPERIOD,
10 ATH_FFTXQMIN,
11 @@ -11309,6 +11310,9 @@ ATH_SYSCTL_DECL(ath_sysctl_halparam, ctl
12 ath_debug_global = (val & ATH_DEBUG_GLOBAL);
13 #endif
14 break;
15 + case ATH_POWEROFFSET:
16 + sc->sc_poweroffset = val;
17 + break;
18 case ATH_TXANTENNA:
19 /*
20 * antenna can be:
21 @@ -11476,6 +11480,9 @@ ATH_SYSCTL_DECL(ath_sysctl_halparam, ctl
22 case ATH_DEBUG:
23 val = sc->sc_debug | ath_debug_global;
24 break;
25 + case ATH_POWEROFFSET:
26 + val = sc->sc_poweroffset;
27 + break;
28 case ATH_TXANTENNA:
29 val = sc->sc_txantenna;
30 break;
31 @@ -11617,6 +11624,12 @@ static const ctl_table ath_sysctl_templa
32 },
33 #endif
34 { .ctl_name = CTL_AUTO,
35 + .procname = "poweroffset",
36 + .mode = 0644,
37 + .proc_handler = ath_sysctl_halparam,
38 + .extra2 = (void *)ATH_POWEROFFSET,
39 + },
40 + { .ctl_name = CTL_AUTO,
41 .procname = "txantenna",
42 .mode = 0644,
43 .proc_handler = ath_sysctl_halparam,