In addition, change "inline static" to the preferred "static inline" form.
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
-----------------------------------------------------------------*/
/* Find a tag in pppoe frame and return the pointer */
-static __inline__ unsigned char *__nat25_find_pppoe_tag(struct pppoe_hdr *ph, unsigned short type)
+static inline unsigned char *__nat25_find_pppoe_tag(struct pppoe_hdr *ph, unsigned short type)
{
unsigned char *cur_ptr, *start_ptr;
unsigned short tagLen, tagType;
return 0;
}
-static __inline__ int __nat25_add_pppoe_tag(struct sk_buff *skb, struct pppoe_tag *tag)
+static inline int __nat25_add_pppoe_tag(struct sk_buff *skb, struct pppoe_tag *tag)
{
struct pppoe_hdr *ph = (struct pppoe_hdr *)(skb->data + ETH_HLEN);
int data_len;
return 0;
}
-static __inline__ unsigned long __nat25_timeout(_adapter *priv)
+static inline unsigned long __nat25_timeout(_adapter *priv)
{
unsigned long timeout;
return timeout;
}
-static __inline__ int __nat25_has_expired(_adapter *priv,
+static inline int __nat25_has_expired(_adapter *priv,
struct nat25_network_db_entry *fdb)
{
if(time_before_eq(fdb->ageing_timer, __nat25_timeout(priv)))
return 0;
}
-static __inline__ void __nat25_generate_ipv4_network_addr(unsigned char *networkAddr,
+static inline void __nat25_generate_ipv4_network_addr(unsigned char *networkAddr,
unsigned int *ipAddr)
{
memset(networkAddr, 0, MAX_NETWORK_ADDR_LEN);
memcpy(networkAddr+7, (unsigned char *)ipAddr, 4);
}
-static __inline__ void __nat25_generate_ipx_network_addr_with_node(unsigned char *networkAddr,
+static inline void __nat25_generate_ipx_network_addr_with_node(unsigned char *networkAddr,
unsigned int *ipxNetAddr, unsigned char *ipxNodeAddr)
{
memset(networkAddr, 0, MAX_NETWORK_ADDR_LEN);
memcpy(networkAddr+5, ipxNodeAddr, 6);
}
-static __inline__ void __nat25_generate_ipx_network_addr_with_socket(unsigned char *networkAddr,
+static inline void __nat25_generate_ipx_network_addr_with_socket(unsigned char *networkAddr,
unsigned int *ipxNetAddr, unsigned short *ipxSocketAddr)
{
memset(networkAddr, 0, MAX_NETWORK_ADDR_LEN);
memcpy(networkAddr+5, (unsigned char *)ipxSocketAddr, 2);
}
-static __inline__ void __nat25_generate_apple_network_addr(unsigned char *networkAddr,
+static inline void __nat25_generate_apple_network_addr(unsigned char *networkAddr,
unsigned short *network, unsigned char *node)
{
memset(networkAddr, 0, MAX_NETWORK_ADDR_LEN);
networkAddr[3] = *node;
}
-static __inline__ void __nat25_generate_pppoe_network_addr(unsigned char *networkAddr,
+static inline void __nat25_generate_pppoe_network_addr(unsigned char *networkAddr,
unsigned char *ac_mac, unsigned short *sid)
{
memset(networkAddr, 0, MAX_NETWORK_ADDR_LEN);
}
#endif /* CL_IPV6_PASS */
-static __inline__ int __nat25_network_hash(unsigned char *networkAddr)
+static inline int __nat25_network_hash(unsigned char *networkAddr)
{
if(networkAddr[0] == NAT25_IPV4)
{
}
}
-static __inline__ void __network_hash_link(_adapter *priv,
+static inline void __network_hash_link(_adapter *priv,
struct nat25_network_db_entry *ent, int hash)
{
/* Caller must _enter_critical_bh already! */
/* spin_unlock_bh(&priv->br_ext_lock); */
}
-static __inline__ void __network_hash_unlink(struct nat25_network_db_entry *ent)
+static inline void __network_hash_unlink(struct nat25_network_db_entry *ent)
{
/* Caller must _enter_critical_bh already! */
/* _irqL irqL; */
}
#endif /* CONFIG_LPS_RPWM_TIMER */
-__inline static void register_task_alive(struct pwrctrl_priv *pwrctrl, u32 tag)
+static inline void register_task_alive(struct pwrctrl_priv *pwrctrl, u32 tag)
{
pwrctrl->alives |= tag;
}
-__inline static void unregister_task_alive(struct pwrctrl_priv *pwrctrl, u32 tag)
+static inline void unregister_task_alive(struct pwrctrl_priv *pwrctrl, u32 tag)
{
pwrctrl->alives &= ~tag;
}
}
}
-__inline u8 *get_my_bssid(WLAN_BSSID_EX *pnetwork)
+inline u8 *get_my_bssid(WLAN_BSSID_EX *pnetwork)
{
return (pnetwork->MacAddress);
}
return ptxservq;
}
#else
-__inline static struct tx_servq *rtw_get_sta_pending
+static inline struct tx_servq *rtw_get_sta_pending
(_adapter *padapter, _queue **ppstapending, struct sta_info *psta, int up)
{
struct tx_servq *ptxservq;
int rtw_handle_dualmac(_adapter *adapter, bool init);
-__inline static u8 *myid(struct eeprom_priv *peepriv)
+static inline u8 *myid(struct eeprom_priv *peepriv)
{
return (peepriv->mac_addr);
}
#define MAC_FMT "%02x:%02x:%02x:%02x:%02x:%02x"
#define MAC_ARG(x) ((u8*)(x))[0],((u8*)(x))[1],((u8*)(x))[2],((u8*)(x))[3],((u8*)(x))[4],((u8*)(x))[5]
-extern __inline int is_multicast_mac_addr(const u8 *addr)
+extern inline int is_multicast_mac_addr(const u8 *addr)
{
return ((addr[0] != 0xff) && (0x01 & addr[0]));
}
typedef void timer_hdl_return;
typedef void* timer_hdl_context;
-__inline static struct list_head *get_list_head(_queue *queue)
+static inline struct list_head *get_list_head(_queue *queue)
{
return (&(queue->queue));
}
-__inline static void _init_timer(_timer *ptimer,_nic_hdl nic_hdl,void *pfunc,void* cntx)
+static inline void _init_timer(_timer *ptimer,_nic_hdl nic_hdl,void *pfunc,void* cntx)
{
//setup_timer(ptimer, pfunc,(u32)cntx);
ptimer->function = pfunc;
init_timer(ptimer);
}
-__inline static void _set_timer(_timer *ptimer,u32 delay_time)
+static inline void _set_timer(_timer *ptimer,u32 delay_time)
{
mod_timer(ptimer , (jiffies+(delay_time*HZ/1000)));
}
-__inline static void _cancel_timer(_timer *ptimer,u8 *bcancelled)
+static inline void _cancel_timer(_timer *ptimer,u8 *bcancelled)
{
del_timer_sync(ptimer);
*bcancelled= _TRUE;//TRUE ==1; FALSE==0
extern void rtw_yield_os(void);
-__inline static unsigned char _cancel_timer_ex(_timer *ptimer)
+static inline unsigned char _cancel_timer_ex(_timer *ptimer)
{
return del_timer_sync(ptimer);
}
-static __inline void thread_enter(char *name)
+static inline void thread_enter(char *name)
{
#ifdef daemonize
daemonize("%s", name);
allow_signal(SIGTERM);
}
-__inline static void flush_signals_thread(void)
+static inline void flush_signals_thread(void)
{
if (signal_pending (current))
flush_signals(current);
#define _RND(sz, r) ((((sz)+((r)-1))/(r))*(r))
#define RND4(x) (((x >> 2) + (((x & 3) == 0) ? 0: 1)) << 2)
-__inline static u32 _RND4(u32 sz)
+static inline u32 _RND4(u32 sz)
{
u32 val;
}
-__inline static u32 _RND8(u32 sz)
+static inline u32 _RND8(u32 sz)
{
u32 val;
}
-__inline static u32 _RND128(u32 sz)
+static inline u32 _RND128(u32 sz)
{
u32 val;
}
-__inline static u32 _RND256(u32 sz)
+static inline u32 _RND256(u32 sz)
{
u32 val;
}
-__inline static u32 _RND512(u32 sz)
+static inline u32 _RND512(u32 sz)
{
u32 val;
}
-__inline static u32 bitshift(u32 bitmask)
+static inline u32 bitshift(u32 bitmask)
{
u32 i;
extern int rtw_set_key(_adapter *adapter,struct security_priv *psecuritypriv,int keyid, u8 set_tx);
extern int rtw_set_auth(_adapter *adapter,struct security_priv *psecuritypriv);
-__inline static u8 *get_bssid(struct mlme_priv *pmlmepriv)
+static inline u8 *get_bssid(struct mlme_priv *pmlmepriv)
{ //if sta_mode:pmlmepriv->cur_network.network.MacAddress=> bssid
// if adhoc_mode:pmlmepriv->cur_network.network.MacAddress=> ibss mac address
return pmlmepriv->cur_network.network.MacAddress;
}
-__inline static int check_fwstate(struct mlme_priv *pmlmepriv, int state)
+static inline int check_fwstate(struct mlme_priv *pmlmepriv, int state)
{
if (pmlmepriv->fw_state & state)
return _TRUE;
return _FALSE;
}
-__inline static int get_fwstate(struct mlme_priv *pmlmepriv)
+static inline int get_fwstate(struct mlme_priv *pmlmepriv)
{
return pmlmepriv->fw_state;
}
* ### NOTE:#### (!!!!)
* MUST TAKE CARE THAT BEFORE CALLING THIS FUNC, YOU SHOULD HAVE LOCKED pmlmepriv->lock
*/
-__inline static void set_fwstate(struct mlme_priv *pmlmepriv, int state)
+static inline void set_fwstate(struct mlme_priv *pmlmepriv, int state)
{
pmlmepriv->fw_state |= state;
//FOR HW integration
}
}
-__inline static void _clr_fwstate_(struct mlme_priv *pmlmepriv, int state)
+static inline void _clr_fwstate_(struct mlme_priv *pmlmepriv, int state)
{
pmlmepriv->fw_state &= ~state;
//FOR HW integration
* No Limit on the calling context,
* therefore set it to be the critical section...
*/
-__inline static void clr_fwstate(struct mlme_priv *pmlmepriv, int state)
+static inline void clr_fwstate(struct mlme_priv *pmlmepriv, int state)
{
spin_lock_bh(&pmlmepriv->lock);
if (check_fwstate(pmlmepriv, state) == _TRUE)
spin_unlock_bh(&pmlmepriv->lock);
}
-__inline static void clr_fwstate_ex(struct mlme_priv *pmlmepriv, int state)
+static inline void clr_fwstate_ex(struct mlme_priv *pmlmepriv, int state)
{
spin_lock_bh(&pmlmepriv->lock);
_clr_fwstate_(pmlmepriv, state);
spin_unlock_bh(&pmlmepriv->lock);
}
-__inline static void up_scanned_network(struct mlme_priv *pmlmepriv)
+static inline void up_scanned_network(struct mlme_priv *pmlmepriv)
{
spin_lock_bh(&pmlmepriv->lock);
pmlmepriv->num_of_scanned++;
int check_buddy_fwstate(_adapter *padapter, int state);
#endif //CONFIG_CONCURRENT_MODE
-__inline static void down_scanned_network(struct mlme_priv *pmlmepriv)
+static inline void down_scanned_network(struct mlme_priv *pmlmepriv)
{
spin_lock_bh(&pmlmepriv->lock);
pmlmepriv->num_of_scanned--;
spin_unlock_bh(&pmlmepriv->lock);
}
-__inline static void set_scanned_network_val(struct mlme_priv *pmlmepriv, int val)
+static inline void set_scanned_network_val(struct mlme_priv *pmlmepriv, int val)
{
spin_lock_bh(&pmlmepriv->lock);
pmlmepriv->num_of_scanned = val;
void rtw_reordering_ctrl_timeout_handler(void *pcontext);
-__inline static u8 *get_rxmem(union recv_frame *precvframe)
+static inline u8 *get_rxmem(union recv_frame *precvframe)
{
//always return rx_head...
if(precvframe==NULL)
return precvframe->u.hdr.rx_head;
}
-__inline static u8 *get_rx_status(union recv_frame *precvframe)
+static inline u8 *get_rx_status(union recv_frame *precvframe)
{
return get_rxmem(precvframe);
}
-__inline static u8 *get_recvframe_data(union recv_frame *precvframe)
+static inline u8 *get_recvframe_data(union recv_frame *precvframe)
{
//alwasy return rx_data
}
-__inline static u8 *recvframe_push(union recv_frame *precvframe, int sz)
+static inline u8 *recvframe_push(union recv_frame *precvframe, int sz)
{
// append data before rx_data
}
-__inline static u8 *recvframe_pull(union recv_frame *precvframe, int sz)
+static inline u8 *recvframe_pull(union recv_frame *precvframe, int sz)
{
// rx_data += sz; move rx_data sz bytes hereafter
}
-__inline static u8 *recvframe_put(union recv_frame *precvframe, int sz)
+static inline u8 *recvframe_put(union recv_frame *precvframe, int sz)
{
// rx_tai += sz; move rx_tail sz bytes hereafter
-__inline static u8 *recvframe_pull_tail(union recv_frame *precvframe, int sz)
+static inline u8 *recvframe_pull_tail(union recv_frame *precvframe, int sz)
{
// rmv data from rx_tail (by yitsen)
-__inline static _buffer * get_rxbuf_desc(union recv_frame *precvframe)
+static inline _buffer * get_rxbuf_desc(union recv_frame *precvframe)
{
_buffer * buf_desc;
}
-__inline static union recv_frame *rxmem_to_recvframe(u8 *rxmem)
+static inline union recv_frame *rxmem_to_recvframe(u8 *rxmem)
{
//due to the design of 2048 bytes alignment of recv_frame, we can reference the union recv_frame
//from any given member of recv_frame.
}
-__inline static union recv_frame *pkt_to_recvframe(_pkt *pkt)
+static inline union recv_frame *pkt_to_recvframe(_pkt *pkt)
{
u8 * buf_star;
return precv_frame;
}
-__inline static u8 *pkt_to_recvmem(_pkt *pkt)
+static inline u8 *pkt_to_recvmem(_pkt *pkt)
{
// return the rx_head
}
-__inline static u8 *pkt_to_recvdata(_pkt *pkt)
+static inline u8 *pkt_to_recvdata(_pkt *pkt)
{
// return the rx_data
}
-__inline static int get_recvframe_len(union recv_frame *precvframe)
+static inline int get_recvframe_len(union recv_frame *precvframe)
{
return precvframe->u.hdr.len;
}
-__inline static s32 translate_percentage_to_dbm(u32 SignalStrengthIndex)
+static inline s32 translate_percentage_to_dbm(u32 SignalStrengthIndex)
{
s32 SignalPower; // in dBm.
};
-__inline static u32 wifi_mac_hash(u8 *mac)
+static inline u32 wifi_mac_hash(u8 *mac)
{
u32 x;
#define GetAddr4Ptr(pbuf) ((unsigned char *)((unsigned long)(pbuf) + 24))
-__inline static unsigned char * get_da(unsigned char *pframe)
+static inline unsigned char * get_da(unsigned char *pframe)
{
unsigned char *da;
unsigned int to_fr_ds = (GetToDs(pframe) << 1) | GetFrDs(pframe);
}
-__inline static unsigned char * get_sa(unsigned char *pframe)
+static inline unsigned char * get_sa(unsigned char *pframe)
{
unsigned char *sa;
unsigned int to_fr_ds = (GetToDs(pframe) << 1) | GetFrDs(pframe);
return sa;
}
-__inline static unsigned char * get_hdr_bssid(unsigned char *pframe)
+static inline unsigned char * get_hdr_bssid(unsigned char *pframe)
{
unsigned char *sa;
unsigned int to_fr_ds = (GetToDs(pframe) << 1) | GetFrDs(pframe);
}
-__inline static int IsFrameTypeCtrl(unsigned char *pframe)
+static inline int IsFrameTypeCtrl(unsigned char *pframe)
{
if(WIFI_CTRL_TYPE == GetFrameType(pframe))
return _TRUE;
}__attribute__((packed))
WLAN_BSSID_EX, *PWLAN_BSSID_EX;
-__inline static uint get_WLAN_BSSID_EX_sz(WLAN_BSSID_EX *bss)
+inline static uint get_WLAN_BSSID_EX_sz(WLAN_BSSID_EX *bss)
{
#if 0
uint t_len;