Commit f04c3a0a authored by Paul Gortmaker's avatar Paul Gortmaker Committed by Jeff Garzik

s/extern inline/static inline/ for net drivers:

aironet4500, arlan, e2100, baycom, soundmodem
parent d25992e0
......@@ -450,7 +450,7 @@ struct awc_fid_queue {
};
extern __inline__ void
static __inline__ void
awc_fid_queue_init(struct awc_fid_queue * queue){
unsigned long flags;
......@@ -463,7 +463,7 @@ awc_fid_queue_init(struct awc_fid_queue * queue){
spin_unlock_irqrestore(&queue->spinlock,flags);
};
extern inline void
static inline void
awc_fid_queue_push_tail( struct awc_fid_queue * queue,
struct awc_fid * fid){
......@@ -488,7 +488,7 @@ awc_fid_queue_push_tail( struct awc_fid_queue * queue,
};
extern inline void
static inline void
awc_fid_queue_push_head( struct awc_fid_queue * queue,
struct awc_fid * fid){
......@@ -513,7 +513,7 @@ awc_fid_queue_push_head( struct awc_fid_queue * queue,
extern inline void
static inline void
awc_fid_queue_rm( struct awc_fid_queue * queue,
struct awc_fid * fid){
......@@ -541,7 +541,7 @@ awc_fid_queue_rm( struct awc_fid_queue * queue,
}
};
extern inline void
static inline void
awc_fid_queue_remove( struct awc_fid_queue * queue,
struct awc_fid * fid){
unsigned long flags;
......@@ -555,7 +555,7 @@ awc_fid_queue_remove( struct awc_fid_queue * queue,
extern inline struct awc_fid *
static inline struct awc_fid *
awc_fid_queue_pop_head( struct awc_fid_queue * queue){
unsigned long flags;
......@@ -575,7 +575,7 @@ awc_fid_queue_pop_head( struct awc_fid_queue * queue){
extern inline struct awc_fid *
static inline struct awc_fid *
awc_fid_queue_pop_tail( struct awc_fid_queue * queue){
unsigned long flags;
......
......@@ -128,7 +128,7 @@ int arlan_command(struct net_device * dev, int command);
EXPORT_SYMBOL(arlan_command);
extern inline long long arlan_time(void)
static inline long long arlan_time(void)
{
struct timeval timev;
do_gettimeofday(&timev);
......@@ -186,7 +186,7 @@ extern inline long long arlan_time(void)
extern inline int arlan_drop_tx(struct net_device *dev)
static inline int arlan_drop_tx(struct net_device *dev)
{
struct arlan_private *priv = ((struct arlan_private *) dev->priv);
......@@ -554,7 +554,7 @@ int arlan_command(struct net_device *dev, int command_p)
};
extern inline void arlan_command_process(struct net_device *dev)
static inline void arlan_command_process(struct net_device *dev)
{
struct arlan_private *priv = ((struct arlan_private *) dev->priv);
......@@ -575,7 +575,7 @@ extern inline void arlan_command_process(struct net_device *dev)
}
extern inline void arlan_retransmit_now(struct net_device *dev)
static inline void arlan_retransmit_now(struct net_device *dev)
{
struct arlan_private *priv = ((struct arlan_private *) dev->priv);
......@@ -1405,7 +1405,7 @@ static int arlan_tx(struct sk_buff *skb, struct net_device *dev)
}
extern inline int DoNotReTransmitCrap(struct net_device *dev)
static inline int DoNotReTransmitCrap(struct net_device *dev)
{
struct arlan_private *priv = ((struct arlan_private *) dev->priv);
......@@ -1415,7 +1415,7 @@ extern inline int DoNotReTransmitCrap(struct net_device *dev)
}
extern inline int DoNotWaitReTransmitCrap(struct net_device *dev)
static inline int DoNotWaitReTransmitCrap(struct net_device *dev)
{
struct arlan_private *priv = ((struct arlan_private *) dev->priv);
......@@ -1424,7 +1424,7 @@ extern inline int DoNotWaitReTransmitCrap(struct net_device *dev)
return 0;
}
extern inline void arlan_queue_retransmit(struct net_device *dev)
static inline void arlan_queue_retransmit(struct net_device *dev)
{
struct arlan_private *priv = ((struct arlan_private *) dev->priv);
......
......@@ -72,7 +72,7 @@ static int e21_probe_list[] = {0x300, 0x280, 0x380, 0x220, 0};
#define E21_SAPROM 0x10 /* Offset to station address data. */
#define E21_IO_EXTENT 0x20
extern inline void mem_on(short port, volatile char *mem_base,
static inline void mem_on(short port, volatile char *mem_base,
unsigned char start_page )
{
/* This is a little weird: set the shared memory window by doing a
......@@ -82,7 +82,7 @@ extern inline void mem_on(short port, volatile char *mem_base,
outb(E21_MEM_ON, port + E21_MEM_ENABLE + E21_MEM_ON);
}
extern inline void mem_off(short port)
static inline void mem_off(short port)
{
inb(port + E21_MEM_ENABLE);
outb(0x00, port + E21_MEM_ENABLE);
......
......@@ -302,7 +302,7 @@ static const unsigned short crc_ccitt_table[] = {
/*---------------------------------------------------------------------------*/
#if 0
extern inline void append_crc_ccitt(unsigned char *buffer, int len)
static inline void append_crc_ccitt(unsigned char *buffer, int len)
{
unsigned int crc = 0xffff;
......@@ -316,7 +316,7 @@ extern inline void append_crc_ccitt(unsigned char *buffer, int len)
/*---------------------------------------------------------------------------*/
extern inline int check_crc_ccitt(const unsigned char *buf, int cnt)
static inline int check_crc_ccitt(const unsigned char *buf, int cnt)
{
unsigned int crc = 0xffff;
......@@ -327,7 +327,7 @@ extern inline int check_crc_ccitt(const unsigned char *buf, int cnt)
/*---------------------------------------------------------------------------*/
extern inline int calc_crc_ccitt(const unsigned char *buf, int cnt)
static inline int calc_crc_ccitt(const unsigned char *buf, int cnt)
{
unsigned int crc = 0xffff;
......
......@@ -201,12 +201,12 @@ static inline void ser12_set_divisor(struct net_device *dev,
/* --------------------------------------------------------------------- */
#if 0
extern inline unsigned int hweight16(unsigned int w)
static inline unsigned int hweight16(unsigned int w)
__attribute__ ((unused));
extern inline unsigned int hweight8(unsigned int w)
static inline unsigned int hweight8(unsigned int w)
__attribute__ ((unused));
extern inline unsigned int hweight16(unsigned int w)
static inline unsigned int hweight16(unsigned int w)
{
unsigned short res = (w & 0x5555) + ((w >> 1) & 0x5555);
res = (res & 0x3333) + ((res >> 2) & 0x3333);
......@@ -214,7 +214,7 @@ extern inline unsigned int hweight16(unsigned int w)
return (res & 0x00FF) + ((res >> 8) & 0x00FF);
}
extern inline unsigned int hweight8(unsigned int w)
static inline unsigned int hweight8(unsigned int w)
{
unsigned short res = (w & 0x55) + ((w >> 1) & 0x55);
res = (res & 0x33) + ((res >> 2) & 0x33);
......
......@@ -158,7 +158,7 @@ extern const char sm_drvinfo[];
* ===================== diagnostics stuff ===============================
*/
extern inline void diag_trigger(struct sm_state *sm)
static inline void diag_trigger(struct sm_state *sm)
{
if (sm->diag.ptr < 0)
if (!(sm->diag.flags & SM_DIAGFLAG_DCDGATE) || sm->hdrv.hdlcrx.dcd)
......@@ -170,7 +170,7 @@ extern inline void diag_trigger(struct sm_state *sm)
#define SHRT_MAX ((short)(((unsigned short)(~0U))>>1))
#define SHRT_MIN (-SHRT_MAX-1)
extern inline void diag_add(struct sm_state *sm, int valinp, int valdemod)
static inline void diag_add(struct sm_state *sm, int valinp, int valdemod)
{
int val;
......@@ -189,7 +189,7 @@ extern inline void diag_add(struct sm_state *sm, int valinp, int valdemod)
/* --------------------------------------------------------------------- */
extern inline void diag_add_one(struct sm_state *sm, int val)
static inline void diag_add_one(struct sm_state *sm, int val)
{
if ((sm->diag.mode != SM_DIAGMODE_INPUT &&
sm->diag.mode != SM_DIAGMODE_DEMOD) ||
......@@ -229,14 +229,14 @@ static inline void diag_add_constellation(struct sm_state *sm, int vali, int val
*/
#if 0
extern inline unsigned int hweight32(unsigned int w)
static inline unsigned int hweight32(unsigned int w)
__attribute__ ((unused));
extern inline unsigned int hweight16(unsigned short w)
static inline unsigned int hweight16(unsigned short w)
__attribute__ ((unused));
extern inline unsigned int hweight8(unsigned char w)
static inline unsigned int hweight8(unsigned char w)
__attribute__ ((unused));
extern inline unsigned int hweight32(unsigned int w)
static inline unsigned int hweight32(unsigned int w)
{
unsigned int res = (w & 0x55555555) + ((w >> 1) & 0x55555555);
res = (res & 0x33333333) + ((res >> 2) & 0x33333333);
......@@ -245,7 +245,7 @@ extern inline unsigned int hweight32(unsigned int w)
return (res & 0x0000FFFF) + ((res >> 16) & 0x0000FFFF);
}
extern inline unsigned int hweight16(unsigned short w)
static inline unsigned int hweight16(unsigned short w)
{
unsigned short res = (w & 0x5555) + ((w >> 1) & 0x5555);
res = (res & 0x3333) + ((res >> 2) & 0x3333);
......@@ -253,7 +253,7 @@ extern inline unsigned int hweight16(unsigned short w)
return (res & 0x00FF) + ((res >> 8) & 0x00FF);
}
extern inline unsigned int hweight8(unsigned char w)
static inline unsigned int hweight8(unsigned char w)
{
unsigned short res = (w & 0x55) + ((w >> 1) & 0x55);
res = (res & 0x33) + ((res >> 2) & 0x33);
......@@ -262,12 +262,12 @@ extern inline unsigned int hweight8(unsigned char w)
#endif
extern inline unsigned int gcd(unsigned int x, unsigned int y)
static inline unsigned int gcd(unsigned int x, unsigned int y)
__attribute__ ((unused));
extern inline unsigned int lcm(unsigned int x, unsigned int y)
static inline unsigned int lcm(unsigned int x, unsigned int y)
__attribute__ ((unused));
extern inline unsigned int gcd(unsigned int x, unsigned int y)
static inline unsigned int gcd(unsigned int x, unsigned int y)
{
for (;;) {
if (!x)
......@@ -281,7 +281,7 @@ extern inline unsigned int gcd(unsigned int x, unsigned int y)
}
}
extern inline unsigned int lcm(unsigned int x, unsigned int y)
static inline unsigned int lcm(unsigned int x, unsigned int y)
{
return x * y / gcd(x, y);
}
......
......@@ -94,7 +94,7 @@ static void modulator_1200_s16(struct sm_state *sm, short *buf, unsigned int buf
/* --------------------------------------------------------------------- */
extern __inline__ int convolution8_u8(const unsigned char *st, const int *coeff, int csum)
static __inline__ int convolution8_u8(const unsigned char *st, const int *coeff, int csum)
{
int sum = -0x80 * csum;
......@@ -111,7 +111,7 @@ extern __inline__ int convolution8_u8(const unsigned char *st, const int *coeff,
return sum * sum;
}
extern __inline__ int convolution8_s16(const short *st, const int *coeff, int csum)
static __inline__ int convolution8_s16(const short *st, const int *coeff, int csum)
{
int sum = 0;
......@@ -128,7 +128,7 @@ extern __inline__ int convolution8_s16(const short *st, const int *coeff, int cs
return sum * sum;
}
extern __inline__ int do_filter_1200_u8(const unsigned char *buf)
static __inline__ int do_filter_1200_u8(const unsigned char *buf)
{
int sum = convolution8_u8(buf, afsk12_tx_lo_i, SUM_AFSK12_TX_LO_I);
sum += convolution8_u8(buf, afsk12_tx_lo_q, SUM_AFSK12_TX_LO_Q);
......@@ -137,7 +137,7 @@ extern __inline__ int do_filter_1200_u8(const unsigned char *buf)
return sum;
}
extern __inline__ int do_filter_1200_s16(const short *buf)
static __inline__ int do_filter_1200_s16(const short *buf)
{
int sum = convolution8_s16(buf, afsk12_tx_lo_i, SUM_AFSK12_TX_LO_I);
sum += convolution8_s16(buf, afsk12_tx_lo_q, SUM_AFSK12_TX_LO_Q);
......
......@@ -104,7 +104,7 @@ static void modulator_2400_s16(struct sm_state *sm, short *buf, unsigned int buf
/* --------------------------------------------------------------------- */
extern __inline__ int convolution14_u8(const unsigned char *st, const int *coeff, int csum)
static __inline__ int convolution14_u8(const unsigned char *st, const int *coeff, int csum)
{
int sum = -0x80 * csum;
......@@ -127,7 +127,7 @@ extern __inline__ int convolution14_u8(const unsigned char *st, const int *coeff
return sum * sum;
}
extern __inline__ int convolution14_s16(const short *st, const int *coeff, int csum)
static __inline__ int convolution14_s16(const short *st, const int *coeff, int csum)
{
int sum = 0;
......@@ -150,7 +150,7 @@ extern __inline__ int convolution14_s16(const short *st, const int *coeff, int c
return sum * sum;
}
extern __inline__ int do_filter_2400_u8(const unsigned char *buf)
static __inline__ int do_filter_2400_u8(const unsigned char *buf)
{
int sum = convolution14_u8(buf, afsk24_tx_lo_i, SUM_AFSK24_TX_LO_I);
sum += convolution14_u8(buf, afsk24_tx_lo_q, SUM_AFSK24_TX_LO_Q);
......@@ -159,7 +159,7 @@ extern __inline__ int do_filter_2400_u8(const unsigned char *buf)
return sum;
}
extern __inline__ int do_filter_2400_s16(const short *buf)
static __inline__ int do_filter_2400_s16(const short *buf)
{
int sum = convolution14_s16(buf, afsk24_tx_lo_i, SUM_AFSK24_TX_LO_I);
sum += convolution14_s16(buf, afsk24_tx_lo_q, SUM_AFSK24_TX_LO_Q);
......
......@@ -104,7 +104,7 @@ static void modulator_2400_s16(struct sm_state *sm, short *buf, unsigned int buf
/* --------------------------------------------------------------------- */
extern __inline__ int convolution14_u8(const unsigned char *st, const int *coeff, int csum)
static __inline__ int convolution14_u8(const unsigned char *st, const int *coeff, int csum)
{
int sum = -0x80 * csum;
......@@ -127,7 +127,7 @@ extern __inline__ int convolution14_u8(const unsigned char *st, const int *coeff
return sum * sum;
}
extern __inline__ int convolution14_s16(const short *st, const int *coeff, int csum)
static __inline__ int convolution14_s16(const short *st, const int *coeff, int csum)
{
int sum = 0;
......@@ -150,7 +150,7 @@ extern __inline__ int convolution14_s16(const short *st, const int *coeff, int c
return sum * sum;
}
extern __inline__ int do_filter_2400_u8(const unsigned char *buf)
static __inline__ int do_filter_2400_u8(const unsigned char *buf)
{
int sum = convolution14_u8(buf, afsk24_tx_lo_i, SUM_AFSK24_TX_LO_I);
sum += convolution14_u8(buf, afsk24_tx_lo_q, SUM_AFSK24_TX_LO_Q);
......@@ -159,7 +159,7 @@ extern __inline__ int do_filter_2400_u8(const unsigned char *buf)
return sum;
}
extern __inline__ int do_filter_2400_s16(const short *buf)
static __inline__ int do_filter_2400_s16(const short *buf)
{
int sum = convolution14_s16(buf, afsk24_tx_lo_i, SUM_AFSK24_TX_LO_I);
sum += convolution14_s16(buf, afsk24_tx_lo_q, SUM_AFSK24_TX_LO_Q);
......
......@@ -114,7 +114,7 @@ static void modulator_2666_s16(struct sm_state *sm, short *buf, unsigned int buf
/* --------------------------------------------------------------------- */
extern __inline__ int convolution12_u8(const unsigned char *st, const int *coeff, int csum)
static __inline__ int convolution12_u8(const unsigned char *st, const int *coeff, int csum)
{
int sum = -0x80 * csum;
......@@ -134,7 +134,7 @@ extern __inline__ int convolution12_u8(const unsigned char *st, const int *coeff
return sum;
}
extern __inline__ int convolution12_s16(const short *st, const int *coeff, int csum)
static __inline__ int convolution12_s16(const short *st, const int *coeff, int csum)
{
int sum = 0;
......
......@@ -59,7 +59,7 @@
#define put_user(x,ptr) ({ __put_user((unsigned long)(x),(ptr),sizeof(*(ptr))); 0; })
#define get_user(x,ptr) ({ x = ((__typeof__(*(ptr)))__get_user((ptr),sizeof(*(ptr)))); 0; })
extern inline int copy_from_user(void *to, const void *from, unsigned long n)
static inline int copy_from_user(void *to, const void *from, unsigned long n)
{
int i = verify_area(VERIFY_READ, from, n);
if (i)
......@@ -68,7 +68,7 @@ extern inline int copy_from_user(void *to, const void *from, unsigned long n)
return 0;
}
extern inline int copy_to_user(void *to, const void *from, unsigned long n)
static inline int copy_to_user(void *to, const void *from, unsigned long n)
{
int i = verify_area(VERIFY_WRITE, to, n);
if (i)
......
......@@ -58,7 +58,7 @@
#define put_user(x,ptr) ({ __put_user((unsigned long)(x),(ptr),sizeof(*(ptr))); 0; })
#define get_user(x,ptr) ({ x = ((__typeof__(*(ptr)))__get_user((ptr),sizeof(*(ptr)))); 0; })
extern inline int copy_from_user(void *to, const void *from, unsigned long n)
static inline int copy_from_user(void *to, const void *from, unsigned long n)
{
int i = verify_area(VERIFY_READ, from, n);
if (i)
......@@ -67,7 +67,7 @@ extern inline int copy_from_user(void *to, const void *from, unsigned long n)
return 0;
}
extern inline int copy_to_user(void *to, const void *from, unsigned long n)
static inline int copy_to_user(void *to, const void *from, unsigned long n)
{
int i = verify_area(VERIFY_WRITE, to, n);
if (i)
......
......@@ -52,7 +52,7 @@
/*
* returns the number of samples per fragment
*/
extern __inline__ unsigned int dma_setup(struct sm_state *sm, int send, unsigned int dmanr)
static __inline__ unsigned int dma_setup(struct sm_state *sm, int send, unsigned int dmanr)
{
if (send) {
disable_dma(dmanr);
......@@ -79,7 +79,7 @@ extern __inline__ unsigned int dma_setup(struct sm_state *sm, int send, unsigned
/* --------------------------------------------------------------------- */
extern __inline__ unsigned int dma_ptr(struct sm_state *sm, int send, unsigned int dmanr,
static __inline__ unsigned int dma_ptr(struct sm_state *sm, int send, unsigned int dmanr,
unsigned int *curfrag)
{
unsigned int dmaptr, sz, frg, offs;
......@@ -120,7 +120,7 @@ extern __inline__ unsigned int dma_ptr(struct sm_state *sm, int send, unsigned i
/* --------------------------------------------------------------------- */
extern __inline__ int dma_end_transmit(struct sm_state *sm, unsigned int curfrag)
static __inline__ int dma_end_transmit(struct sm_state *sm, unsigned int curfrag)
{
unsigned int diff = (NUM_FRAGMENTS + curfrag - sm->dma.ofragptr) % NUM_FRAGMENTS;
......@@ -137,7 +137,7 @@ extern __inline__ int dma_end_transmit(struct sm_state *sm, unsigned int curfrag
return 0;
}
extern __inline__ void dma_transmit(struct sm_state *sm)
static __inline__ void dma_transmit(struct sm_state *sm)
{
void *p;
......@@ -155,13 +155,13 @@ extern __inline__ void dma_transmit(struct sm_state *sm)
}
}
extern __inline__ void dma_init_transmit(struct sm_state *sm)
static __inline__ void dma_init_transmit(struct sm_state *sm)
{
sm->dma.ofragptr = 0;
sm->dma.ptt_cnt = 0;
}
extern __inline__ void dma_start_transmit(struct sm_state *sm)
static __inline__ void dma_start_transmit(struct sm_state *sm)
{
sm->dma.ofragptr = 0;
if (sm->dma.o16bit) {
......@@ -174,7 +174,7 @@ extern __inline__ void dma_start_transmit(struct sm_state *sm)
sm->dma.ptt_cnt = 1;
}
extern __inline__ void dma_clear_transmit(struct sm_state *sm)
static __inline__ void dma_clear_transmit(struct sm_state *sm)
{
sm->dma.ptt_cnt = 0;
memset(sm->dma.obuf, (sm->dma.o16bit) ? 0 : 0x80, sm->dma.ofragsz * NUM_FRAGMENTS);
......@@ -182,7 +182,7 @@ extern __inline__ void dma_clear_transmit(struct sm_state *sm)
/* --------------------------------------------------------------------- */
extern __inline__ void dma_receive(struct sm_state *sm, unsigned int curfrag)
static __inline__ void dma_receive(struct sm_state *sm, unsigned int curfrag)
{
void *p;
......@@ -205,7 +205,7 @@ extern __inline__ void dma_receive(struct sm_state *sm, unsigned int curfrag)
}
}
extern __inline__ void dma_init_receive(struct sm_state *sm)
static __inline__ void dma_init_receive(struct sm_state *sm)
{
sm->dma.ifragptr = 0;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment