Skip to content

Commit

Permalink
cfg80211.h/mac80211.h: Remove extern from function prototypes
Browse files Browse the repository at this point in the history
There are a mix of function prototypes with and without extern
in the kernel sources.  Standardize on not using extern for
function prototypes.

Function prototypes don't need to be written with extern.
extern is assumed by the compiler.  Its use is as unnecessary as
using auto to declare automatic/local variables in a block.

Reflow modified prototypes to 80 columns.

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Joe Perches authored and David S. Miller committed Aug 1, 2013
1 parent c1d8f80 commit 10dd9b7
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 25 deletions.
34 changes: 17 additions & 17 deletions include/net/cfg80211.h
Original file line number Diff line number Diff line change
Expand Up @@ -2841,7 +2841,7 @@ struct wiphy *wiphy_new(const struct cfg80211_ops *ops, int sizeof_priv);
*
* Return: A non-negative wiphy index or a negative error code.
*/
extern int wiphy_register(struct wiphy *wiphy);
int wiphy_register(struct wiphy *wiphy);

/**
* wiphy_unregister - deregister a wiphy from cfg80211
Expand All @@ -2852,14 +2852,14 @@ extern int wiphy_register(struct wiphy *wiphy);
* pointer, but the call may sleep to wait for an outstanding
* request that is being handled.
*/
extern void wiphy_unregister(struct wiphy *wiphy);
void wiphy_unregister(struct wiphy *wiphy);

/**
* wiphy_free - free wiphy
*
* @wiphy: The wiphy to free
*/
extern void wiphy_free(struct wiphy *wiphy);
void wiphy_free(struct wiphy *wiphy);

/* internal structs */
struct cfg80211_conn;
Expand Down Expand Up @@ -3014,14 +3014,14 @@ static inline void *wdev_priv(struct wireless_dev *wdev)
* @band: band, necessary due to channel number overlap
* Return: The corresponding frequency (in MHz), or 0 if the conversion failed.
*/
extern int ieee80211_channel_to_frequency(int chan, enum ieee80211_band band);
int ieee80211_channel_to_frequency(int chan, enum ieee80211_band band);

/**
* ieee80211_frequency_to_channel - convert frequency to channel number
* @freq: center frequency
* Return: The corresponding channel, or 0 if the conversion failed.
*/
extern int ieee80211_frequency_to_channel(int freq);
int ieee80211_frequency_to_channel(int freq);

/*
* Name indirection necessary because the ieee80211 code also has
Expand All @@ -3030,8 +3030,8 @@ extern int ieee80211_frequency_to_channel(int freq);
* to include both header files you'll (rightfully!) get a symbol
* clash.
*/
extern struct ieee80211_channel *__ieee80211_get_channel(struct wiphy *wiphy,
int freq);
struct ieee80211_channel *__ieee80211_get_channel(struct wiphy *wiphy,
int freq);
/**
* ieee80211_get_channel - get channel struct from wiphy for specified frequency
* @wiphy: the struct wiphy to get the channel for
Expand Down Expand Up @@ -3141,13 +3141,14 @@ struct ieee80211_radiotap_iterator {
int _reset_on_ext;
};

extern int ieee80211_radiotap_iterator_init(
struct ieee80211_radiotap_iterator *iterator,
struct ieee80211_radiotap_header *radiotap_header,
int max_length, const struct ieee80211_radiotap_vendor_namespaces *vns);
int
ieee80211_radiotap_iterator_init(struct ieee80211_radiotap_iterator *iterator,
struct ieee80211_radiotap_header *radiotap_header,
int max_length,
const struct ieee80211_radiotap_vendor_namespaces *vns);

extern int ieee80211_radiotap_iterator_next(
struct ieee80211_radiotap_iterator *iterator);
int
ieee80211_radiotap_iterator_next(struct ieee80211_radiotap_iterator *iterator);


extern const unsigned char rfc1042_header[6];
Expand Down Expand Up @@ -3307,7 +3308,7 @@ const u8 *cfg80211_find_vendor_ie(unsigned int oui, u8 oui_type,
*
* Return: 0 on success. -ENOMEM.
*/
extern int regulatory_hint(struct wiphy *wiphy, const char *alpha2);
int regulatory_hint(struct wiphy *wiphy, const char *alpha2);

/**
* wiphy_apply_custom_regulatory - apply a custom driver regulatory domain
Expand All @@ -3321,9 +3322,8 @@ extern int regulatory_hint(struct wiphy *wiphy, const char *alpha2);
* default channel settings will be disregarded. If no rule is found for a
* channel on the regulatory domain the channel will be disabled.
*/
extern void wiphy_apply_custom_regulatory(
struct wiphy *wiphy,
const struct ieee80211_regdomain *regd);
void wiphy_apply_custom_regulatory(struct wiphy *wiphy,
const struct ieee80211_regdomain *regd);

/**
* freq_reg_info - get regulatory information for the given frequency
Expand Down
16 changes: 8 additions & 8 deletions include/net/mac80211.h
Original file line number Diff line number Diff line change
Expand Up @@ -2877,14 +2877,14 @@ enum ieee80211_tpt_led_trigger_flags {
};

#ifdef CONFIG_MAC80211_LEDS
extern char *__ieee80211_get_tx_led_name(struct ieee80211_hw *hw);
extern char *__ieee80211_get_rx_led_name(struct ieee80211_hw *hw);
extern char *__ieee80211_get_assoc_led_name(struct ieee80211_hw *hw);
extern char *__ieee80211_get_radio_led_name(struct ieee80211_hw *hw);
extern char *__ieee80211_create_tpt_led_trigger(
struct ieee80211_hw *hw, unsigned int flags,
const struct ieee80211_tpt_blink *blink_table,
unsigned int blink_table_len);
char *__ieee80211_get_tx_led_name(struct ieee80211_hw *hw);
char *__ieee80211_get_rx_led_name(struct ieee80211_hw *hw);
char *__ieee80211_get_assoc_led_name(struct ieee80211_hw *hw);
char *__ieee80211_get_radio_led_name(struct ieee80211_hw *hw);
char *__ieee80211_create_tpt_led_trigger(struct ieee80211_hw *hw,
unsigned int flags,
const struct ieee80211_tpt_blink *blink_table,
unsigned int blink_table_len);
#endif
/**
* ieee80211_get_tx_led_name - get name of TX LED
Expand Down

0 comments on commit 10dd9b7

Please sign in to comment.