Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 235642
b: refs/heads/master
c: 20de47a
h: refs/heads/master
v: v3
  • Loading branch information
Arend van Spriel authored and Greg Kroah-Hartman committed Jan 21, 2011
1 parent 02dfefe commit 8398e82
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 78 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: f3237e56b995367448f717a0dddcd76e0743bfdb
refs/heads/master: 20de47a5c2d6516a4eebf874cc35ee5432955f8d
67 changes: 0 additions & 67 deletions trunk/drivers/staging/brcm80211/brcmsmac/wlc_channel.c
Original file line number Diff line number Diff line change
Expand Up @@ -658,46 +658,11 @@ void wlc_channel_mgr_detach(wlc_cm_info_t *wlc_cm)
kfree(wlc_cm);
}

const char *wlc_channel_country_abbrev(wlc_cm_info_t *wlc_cm)
{
return wlc_cm->country_abbrev;
}

u8 wlc_channel_locale_flags(wlc_cm_info_t *wlc_cm)
{
struct wlc_info *wlc = wlc_cm->wlc;

return wlc_cm->bandstate[wlc->band->bandunit].locale_flags;
}

u8 wlc_channel_locale_flags_in_band(wlc_cm_info_t *wlc_cm, uint bandunit)
{
return wlc_cm->bandstate[bandunit].locale_flags;
}

/* return chanvec for a given country code and band */
bool
wlc_channel_get_chanvec(struct wlc_info *wlc, const char *country_abbrev,
int bandtype, chanvec_t *channels)
{
const country_info_t *country;
const locale_info_t *locale = NULL;

country = wlc_country_lookup(wlc, country_abbrev);
if (country == NULL)
return false;

if (bandtype == WLC_BAND_2G)
locale = wlc_get_locale_2g(country->locale_2G);
else if (bandtype == WLC_BAND_5G)
locale = wlc_get_locale_5g(country->locale_5G);
if (locale == NULL)
return false;

wlc_locale_get_channels(locale, channels);
return true;
}

/* set the driver's current country and regulatory information using a country code
* as the source. Lookup built in country information found with the country code.
*/
Expand Down Expand Up @@ -1071,16 +1036,6 @@ bool wlc_valid_channel20(wlc_cm_info_t *wlc_cm, uint val)
val));
}

/* Is the 40 MHz allowed for the current locale and specified band? */
bool wlc_valid_40chanspec_in_band(wlc_cm_info_t *wlc_cm, uint bandunit)
{
struct wlc_info *wlc = wlc_cm->wlc;

return (((wlc_cm->bandstate[bandunit].
locale_flags & (WLC_NO_MIMO | WLC_NO_40MHZ)) == 0)
&& wlc->bandstate[bandunit]->mimo_cap_40);
}

static void
wlc_channel_min_txpower_limits_with_local_constraint(wlc_cm_info_t *wlc_cm,
struct txpwr_limits *txpwr,
Expand Down Expand Up @@ -1185,23 +1140,6 @@ wlc_channel_set_chanspec(wlc_cm_info_t *wlc_cm, chanspec_t chanspec,
&txpwr);
}

int
wlc_channel_set_txpower_limit(wlc_cm_info_t *wlc_cm,
u8 local_constraint_qdbm)
{
struct wlc_info *wlc = wlc_cm->wlc;
struct txpwr_limits txpwr;

wlc_channel_reg_limits(wlc_cm, wlc->chanspec, &txpwr);

wlc_channel_min_txpower_limits_with_local_constraint(wlc_cm, &txpwr,
local_constraint_qdbm);

wlc_phy_txpower_limit_set(wlc->band->pi, &txpwr, wlc->chanspec);

return 0;
}

#ifdef POWER_DBG
static void wlc_phy_txpower_limits_dump(txpwr_limits_t *txpwr)
{
Expand Down Expand Up @@ -1598,11 +1536,6 @@ wlc_valid_chanspec_ext(wlc_cm_info_t *wlc_cm, chanspec_t chspec, bool dualband)
return false;
}

bool wlc_valid_chanspec(wlc_cm_info_t *wlc_cm, chanspec_t chspec)
{
return wlc_valid_chanspec_ext(wlc_cm, chspec, false);
}

bool wlc_valid_chanspec_db(wlc_cm_info_t *wlc_cm, chanspec_t chspec)
{
return wlc_valid_chanspec_ext(wlc_cm, chspec, true);
Expand Down
10 changes: 0 additions & 10 deletions trunk/drivers/staging/brcm80211/brcmsmac/wlc_channel.h
Original file line number Diff line number Diff line change
Expand Up @@ -112,8 +112,6 @@ extern int wlc_set_countrycode_rev(wlc_cm_info_t *wlc_cm,
const char *country_abbrev,
const char *ccode, int regrev);

extern const char *wlc_channel_country_abbrev(wlc_cm_info_t *wlc_cm);
extern u8 wlc_channel_locale_flags(wlc_cm_info_t *wlc_cm);
extern u8 wlc_channel_locale_flags_in_band(wlc_cm_info_t *wlc_cm,
uint bandunit);

Expand All @@ -124,24 +122,19 @@ extern bool wlc_quiet_chanspec(wlc_cm_info_t *wlc_cm, chanspec_t chspec);
#define VALID_CHANNEL20_IN_BAND(wlc, bandunit, val) \
wlc_valid_channel20_in_band((wlc)->cmi, bandunit, val)
#define VALID_CHANNEL20(wlc, val) wlc_valid_channel20((wlc)->cmi, val)
#define VALID_40CHANSPEC_IN_BAND(wlc, bandunit) wlc_valid_40chanspec_in_band((wlc)->cmi, bandunit)

extern bool wlc_valid_chanspec(wlc_cm_info_t *wlc_cm, chanspec_t chspec);
extern bool wlc_valid_chanspec_db(wlc_cm_info_t *wlc_cm, chanspec_t chspec);
extern bool wlc_valid_channel20_db(wlc_cm_info_t *wlc_cm, uint val);
extern bool wlc_valid_channel20_in_band(wlc_cm_info_t *wlc_cm, uint bandunit,
uint val);
extern bool wlc_valid_channel20(wlc_cm_info_t *wlc_cm, uint val);
extern bool wlc_valid_40chanspec_in_band(wlc_cm_info_t *wlc_cm, uint bandunit);

extern void wlc_channel_reg_limits(wlc_cm_info_t *wlc_cm,
chanspec_t chanspec,
struct txpwr_limits *txpwr);
extern void wlc_channel_set_chanspec(wlc_cm_info_t *wlc_cm,
chanspec_t chanspec,
u8 local_constraint_qdbm);
extern int wlc_channel_set_txpower_limit(wlc_cm_info_t *wlc_cm,
u8 local_constraint_qdbm);

extern const country_info_t *wlc_country_lookup(struct wlc_info *wlc,
const char *ccode);
Expand All @@ -152,8 +145,5 @@ extern const locale_info_t *wlc_get_locale_5g(u8 locale_idx);
extern bool wlc_japan(struct wlc_info *wlc);

extern u8 wlc_get_regclass(wlc_cm_info_t *wlc_cm, chanspec_t chanspec);
extern bool wlc_channel_get_chanvec(struct wlc_info *wlc,
const char *country_abbrev, int bandtype,
chanvec_t *channels);

#endif /* _WLC_CHANNEL_H */

0 comments on commit 8398e82

Please sign in to comment.