net: move procfs code to net/core/net-procfs.c
Similar to net/core/net-sysfs.c, group procfs code to a single unit. Cc: "David S. Miller" <davem@davemloft.net> Signed-off-by: Cong Wang <xiyou.wangcong@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
45d213f5f8
commit
900ff8c632
@@ -2692,9 +2692,9 @@ extern void net_enable_timestamp(void);
|
||||
extern void net_disable_timestamp(void);
|
||||
|
||||
#ifdef CONFIG_PROC_FS
|
||||
extern void *dev_seq_start(struct seq_file *seq, loff_t *pos);
|
||||
extern void *dev_seq_next(struct seq_file *seq, void *v, loff_t *pos);
|
||||
extern void dev_seq_stop(struct seq_file *seq, void *v);
|
||||
extern int __init dev_proc_init(void);
|
||||
#else
|
||||
#define dev_proc_init() 0
|
||||
#endif
|
||||
|
||||
extern int netdev_class_create_file(struct class_attribute *class_attr);
|
||||
@@ -2896,4 +2896,34 @@ do { \
|
||||
})
|
||||
#endif
|
||||
|
||||
/*
|
||||
* The list of packet types we will receive (as opposed to discard)
|
||||
* and the routines to invoke.
|
||||
*
|
||||
* Why 16. Because with 16 the only overlap we get on a hash of the
|
||||
* low nibble of the protocol value is RARP/SNAP/X.25.
|
||||
*
|
||||
* NOTE: That is no longer true with the addition of VLAN tags. Not
|
||||
* sure which should go first, but I bet it won't make much
|
||||
* difference if we are running VLANs. The good news is that
|
||||
* this protocol won't be in the list unless compiled in, so
|
||||
* the average user (w/out VLANs) will not be adversely affected.
|
||||
* --BLG
|
||||
*
|
||||
* 0800 IP
|
||||
* 8100 802.1Q VLAN
|
||||
* 0001 802.3
|
||||
* 0002 AX.25
|
||||
* 0004 802.2
|
||||
* 8035 RARP
|
||||
* 0005 SNAP
|
||||
* 0805 X.25
|
||||
* 0806 ARP
|
||||
* 8137 IPX
|
||||
* 0009 Localtalk
|
||||
* 86DD IPv6
|
||||
*/
|
||||
#define PTYPE_HASH_SIZE (16)
|
||||
#define PTYPE_HASH_MASK (PTYPE_HASH_SIZE - 1)
|
||||
|
||||
#endif /* _LINUX_NETDEVICE_H */
|
||||
|
Reference in New Issue
Block a user