diff options
| author | Arnaldo Carvalho de Melo <acme@conectiva.com.br> | 2003-05-15 12:42:15 -0300 |
|---|---|---|
| committer | Arnaldo Carvalho de Melo <acme@conectiva.com.br> | 2003-05-15 12:42:15 -0300 |
| commit | 41d0ff2ee195e5bce56d51efa50a82c6f491eace (patch) | |
| tree | 9a7ad13e346e2b1a6605c8eccd59751782581219 /include | |
| parent | 7a2d9c1020e3aa7e0f4a64211ea578af2f3c10cd (diff) | |
o wanrouter: kill netdevice_t, do as all the rest of the tree, use struct net_device
Diffstat (limited to 'include')
| -rw-r--r-- | include/linux/if_wanpipe.h | 6 | ||||
| -rw-r--r-- | include/linux/if_wanpipe_common.h | 9 | ||||
| -rw-r--r-- | include/linux/wanpipe.h | 26 | ||||
| -rw-r--r-- | include/linux/wanrouter.h | 16 |
4 files changed, 24 insertions, 33 deletions
diff --git a/include/linux/if_wanpipe.h b/include/linux/if_wanpipe.h index 1279d330e4a8..166e0e62c8e2 100644 --- a/include/linux/if_wanpipe.h +++ b/include/linux/if_wanpipe.h @@ -101,16 +101,12 @@ typedef struct #ifdef __KERNEL__ -#ifndef netdevice_t -#define netdevice_t struct net_device -#endif - /* Private wanpipe socket structures. */ struct wanpipe_opt { void *mbox; /* Mail box */ void *card; /* Card bouded to */ - netdevice_t *dev; /* Bounded device */ + struct net_device *dev; /* Bounded device */ unsigned short lcn; /* Binded LCN */ unsigned char svc; /* 0=pvc, 1=svc */ unsigned char timer; /* flag for delayed transmit*/ diff --git a/include/linux/if_wanpipe_common.h b/include/linux/if_wanpipe_common.h index 7fbbb9cc92c1..f25fec8ee2ca 100644 --- a/include/linux/if_wanpipe_common.h +++ b/include/linux/if_wanpipe_common.h @@ -19,11 +19,8 @@ #include <linux/version.h> -#define netdevice_t struct net_device - - typedef struct { - netdevice_t *slave; + struct net_device *slave; atomic_t packet_sent; atomic_t receive_block; atomic_t command; @@ -32,8 +29,8 @@ typedef struct { long common_critical; struct timer_list *tx_timer; struct sock *sk; /* Wanpipe Sock bind's here */ - int (*func) (struct sk_buff *, netdevice_t *, - struct sock *); + int (*func)(struct sk_buff *skb, struct net_device *dev, + struct sock *sk); struct work_struct wanpipe_work; /* deferred keventd work */ unsigned char rw_bind; /* Sock bind state */ diff --git a/include/linux/wanpipe.h b/include/linux/wanpipe.h index 74f4a42c2517..167d956c492b 100644 --- a/include/linux/wanpipe.h +++ b/include/linux/wanpipe.h @@ -39,8 +39,6 @@ #ifndef _WANPIPE_H #define _WANPIPE_H -#define netdevice_t struct net_device - #include <linux/wanrouter.h> /* Defines */ @@ -335,22 +333,22 @@ typedef struct sdla u32 hi_pvc; u32 lo_svc; u32 hi_svc; - netdevice_t *svc_to_dev_map[MAX_X25_LCN]; - netdevice_t *pvc_to_dev_map[MAX_X25_LCN]; - netdevice_t *tx_dev; - netdevice_t *cmd_dev; + struct net_device *svc_to_dev_map[MAX_X25_LCN]; + struct net_device *pvc_to_dev_map[MAX_X25_LCN]; + struct net_device *tx_dev; + struct net_device *cmd_dev; u32 no_dev; volatile u8 *hdlc_buf_status; u32 tx_interrupts_pending; u16 timer_int_enabled; - netdevice_t *poll_device; + struct net_device *poll_device; atomic_t command_busy; u16 udp_pkt_lgth; u32 udp_type; u8 udp_pkt_src; u32 udp_lcn; - netdevice_t * udp_dev; + struct net_device *udp_dev; s8 udp_pkt_data[MAX_LGTH_UDP_MGNT_PKT]; u8 LAPB_hdlc; /* Option to turn off X25 and run only LAPB */ @@ -369,7 +367,7 @@ typedef struct sdla unsigned rx_top; /* S508 receive buffer end */ unsigned short node_dlci[100]; unsigned short dlci_num; - netdevice_t *dlci_to_dev_map[991 + 1]; + struct net_device *dlci_to_dev_map[991 + 1]; unsigned tx_interrupts_pending; unsigned short timer_int_enabled; unsigned short udp_pkt_lgth; @@ -382,7 +380,7 @@ typedef struct sdla void *curr_trc_el; /* current trace element */ unsigned short trc_bfr_space; /* trace buffer space */ unsigned char update_comms_stats; - netdevice_t *arp_dev; + struct net_device *arp_dev; spinlock_t if_send_lock; } f; struct /****** PPP-specific data ***********/ @@ -483,10 +481,10 @@ extern sdla_t * wanpipe_find_card_num (int); extern void wanpipe_queue_work (struct work_struct *); extern void wanpipe_mark_bh (void); -extern void wakeup_sk_bh (netdevice_t *); -extern int change_dev_flags (netdevice_t *, unsigned); -extern unsigned long get_ip_address (netdevice_t *dev, int option); -extern void add_gateway(sdla_t *, netdevice_t *); +extern void wakeup_sk_bh(struct net_device *dev); +extern int change_dev_flags(struct net_device *dev, unsigned flags); +extern unsigned long get_ip_address(struct net_device *dev, int option); +extern void add_gateway(sdla_t *card, struct net_device *dev); #endif /* __KERNEL__ */ diff --git a/include/linux/wanrouter.h b/include/linux/wanrouter.h index e5b088722aca..2b59fc664d19 100644 --- a/include/linux/wanrouter.h +++ b/include/linux/wanrouter.h @@ -44,8 +44,6 @@ * Jan 02, 1997 Gene Kozin Initial version (based on wanpipe.h). *****************************************************************************/ -#define netdevice_t struct net_device - #include <linux/spinlock.h> /* Support for SMP Locking */ #ifndef _ROUTER_H @@ -505,12 +503,12 @@ struct wan_device { int (*update) (struct wan_device *wandev); int (*ioctl) (struct wan_device *wandev, unsigned cmd, unsigned long arg); - int (*new_if) (struct wan_device *wandev, netdevice_t *dev, - wanif_conf_t *conf); - int (*del_if) (struct wan_device *wandev, netdevice_t *dev); + int (*new_if)(struct wan_device *wandev, struct net_device *dev, + wanif_conf_t *conf); + int (*del_if)(struct wan_device *wandev, struct net_device *dev); /****** maintained by the router ****/ struct wan_device* next; /* -> next device */ - netdevice_t* dev; /* list of network interfaces */ + struct net_device* dev; /* list of network interfaces */ unsigned ndev; /* number of interfaces */ struct proc_dir_entry *dent; /* proc filesystem entry */ }; @@ -518,8 +516,10 @@ struct wan_device { /* Public functions available for device drivers */ extern int register_wan_device(struct wan_device *wandev); extern int unregister_wan_device(char *name); -unsigned short wanrouter_type_trans(struct sk_buff *skb, netdevice_t *dev); -int wanrouter_encapsulate(struct sk_buff *skb, netdevice_t *dev,unsigned short type); +unsigned short wanrouter_type_trans(struct sk_buff *skb, + struct net_device *dev); +int wanrouter_encapsulate(struct sk_buff *skb, struct net_device *dev, + unsigned short type); /* Proc interface functions. These must not be called by the drivers! */ extern int wanrouter_proc_init(void); |
