mirror of
git://projects.qi-hardware.com/openwrt-xburst.git
synced 2024-12-27 09:03:20 +02:00
2562cde3ef
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@17687 3c298f89-4303-0410-b956-a3cf2f4a3e73
82 lines
3.1 KiB
Diff
82 lines
3.1 KiB
Diff
--- a/ath/if_ath.c
|
|
+++ b/ath/if_ath.c
|
|
@@ -395,7 +395,7 @@ static int bstuck_thresh = BSTUCK_THRESH
|
|
static char *autocreate = NULL;
|
|
static char *ratectl = DEF_RATE_CTL;
|
|
static int rfkill = 0;
|
|
-static int tpc = 0;
|
|
+static int tpc = 1;
|
|
static int countrycode = -1;
|
|
static int maxvaps = -1;
|
|
static int outdoor = -1;
|
|
@@ -4932,6 +4932,7 @@ ath_beacon_setup(struct ath_softc *sc, s
|
|
(((_ic)->ic_flags & (IEEE80211_F_SHPREAMBLE | IEEE80211_F_USEBARKER))\
|
|
== IEEE80211_F_SHPREAMBLE)
|
|
struct ieee80211com *ic = bf->bf_node->ni_ic;
|
|
+ struct ieee80211vap *vap = bf->bf_node->ni_vap;
|
|
struct sk_buff *skb = bf->bf_skb;
|
|
struct ath_hal *ah = sc->sc_ah;
|
|
struct ath_desc *ds;
|
|
@@ -4999,7 +5000,7 @@ ath_beacon_setup(struct ath_softc *sc, s
|
|
skb->len + IEEE80211_CRC_LEN, /* frame length */
|
|
sizeof(struct ieee80211_frame), /* header length */
|
|
HAL_PKT_TYPE_BEACON, /* Atheros packet type */
|
|
- bf->bf_node->ni_txpower, /* txpower XXX */
|
|
+ (vap->iv_beacon_txpow ? vap->iv_beacon_txpow : 63),
|
|
rate, 1, /* series 0 rate/tries */
|
|
HAL_TXKEYIX_INVALID, /* no encryption */
|
|
antenna, /* antenna mode */
|
|
--- a/net80211/ieee80211_ioctl.h
|
|
+++ b/net80211/ieee80211_ioctl.h
|
|
@@ -652,6 +652,7 @@ enum {
|
|
IEEE80211_PARAM_WDS_SEP = 82, /* move wds stations into separate interfaces */
|
|
IEEE80211_PARAM_MAXASSOC = 83, /* maximum associated stations */
|
|
IEEE80211_PARAM_PROBEREQ = 84, /* enable handling of probe requests */
|
|
+ IEEE80211_PARAM_BEACON_TXP = 85, /* set beacon tx power */
|
|
};
|
|
|
|
#define SIOCG80211STATS (SIOCDEVPRIVATE+2)
|
|
--- a/net80211/ieee80211_var.h
|
|
+++ b/net80211/ieee80211_var.h
|
|
@@ -254,6 +254,7 @@ struct ieee80211vap {
|
|
u_int8_t iv_dtim_period; /* DTIM period */
|
|
u_int8_t iv_dtim_count; /* DTIM count from last bcn */
|
|
/* set/unset aid pwrsav state */
|
|
+ u_int8_t iv_beacon_txpow; /* beacon tx power */
|
|
void (*iv_set_tim)(struct ieee80211_node *, int);
|
|
u_int8_t iv_uapsdinfo; /* sta mode QoS Info flags */
|
|
struct ieee80211_node *iv_bss; /* information for this node */
|
|
--- a/net80211/ieee80211_wireless.c
|
|
+++ b/net80211/ieee80211_wireless.c
|
|
@@ -2871,6 +2871,9 @@ ieee80211_ioctl_setparam(struct net_devi
|
|
case IEEE80211_PARAM_PROBEREQ:
|
|
vap->iv_no_probereq = !value;
|
|
break;
|
|
+ case IEEE80211_PARAM_BEACON_TXP:
|
|
+ vap->iv_beacon_txpow = value;
|
|
+ break;
|
|
#ifdef ATH_REVERSE_ENGINEERING
|
|
case IEEE80211_PARAM_DUMPREGS:
|
|
ieee80211_dump_registers(dev, info, w, extra);
|
|
@@ -3236,6 +3239,9 @@ ieee80211_ioctl_getparam(struct net_devi
|
|
case IEEE80211_PARAM_PROBEREQ:
|
|
param[0] = !vap->iv_no_probereq;
|
|
break;
|
|
+ case IEEE80211_PARAM_BEACON_TXP:
|
|
+ param[0] = vap->iv_beacon_txpow;
|
|
+ break;
|
|
default:
|
|
return -EOPNOTSUPP;
|
|
}
|
|
@@ -5810,6 +5816,10 @@ static const struct iw_priv_args ieee802
|
|
IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, 0, "probereq"},
|
|
{ IEEE80211_PARAM_PROBEREQ,
|
|
0, IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, "get_probereq"},
|
|
+ { IEEE80211_PARAM_BEACON_TXP,
|
|
+ IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, 0, "beacon_pwr"},
|
|
+ { IEEE80211_PARAM_BEACON_TXP,
|
|
+ 0, IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, "get_beacon_pwr"},
|
|
|
|
#ifdef ATH_REVERSE_ENGINEERING
|
|
/*
|