2 * Copyright (C) 2002 Jeff Dike (jdike@karaya.com)
3 * Licensed under the GPL
6 #ifndef __UM_NET_KERN_H
7 #define __UM_NET_KERN_H
9 #include "linux/netdevice.h"
10 #include "linux/skbuff.h"
11 #include "linux/socket.h"
12 #include "linux/list.h"
15 struct list_head list
;
16 struct net_device
*dev
;
17 struct platform_device pdev
;
19 unsigned char mac
[ETH_ALEN
];
23 struct uml_net_private
{
24 struct list_head list
;
26 struct net_device
*dev
;
28 struct net_device_stats stats
;
30 unsigned char mac
[ETH_ALEN
];
32 unsigned short (*protocol
)(struct sk_buff
*);
34 void (*close
)(int, void *);
35 void (*remove
)(void *);
36 int (*read
)(int, struct sk_buff
**skb
, struct uml_net_private
*);
37 int (*write
)(int, struct sk_buff
**skb
, struct uml_net_private
*);
39 void (*add_address
)(unsigned char *, unsigned char *, void *);
40 void (*delete_address
)(unsigned char *, unsigned char *, void *);
41 int (*set_mtu
)(int mtu
, void *);
45 struct net_kern_info
{
46 void (*init
)(struct net_device
*, void *);
47 unsigned short (*protocol
)(struct sk_buff
*);
48 int (*read
)(int, struct sk_buff
**skb
, struct uml_net_private
*);
49 int (*write
)(int, struct sk_buff
**skb
, struct uml_net_private
*);
53 struct list_head list
;
55 int (*setup
)(char *, char **, void *);
56 struct net_user_info
*user
;
57 struct net_kern_info
*kern
;
62 extern struct net_device
*ether_init(int);
63 extern unsigned short ether_protocol(struct sk_buff
*);
64 extern int setup_etheraddr(char *str
, unsigned char *addr
);
65 extern struct sk_buff
*ether_adjust_skb(struct sk_buff
*skb
, int extra
);
66 extern int tap_setup_common(char *str
, char *type
, char **dev_name
,
67 char **mac_out
, char **gate_addr
);
68 extern void register_transport(struct transport
*new);
69 extern unsigned short eth_protocol(struct sk_buff
*skb
);
74 * Overrides for Emacs so that we follow Linus's tabbing style.
75 * Emacs will notice this stuff at the end of the file and automatically
76 * adjust the settings for this buffer only. This must remain at the end
78 * ---------------------------------------------------------------------------
80 * c-file-style: "linux"
This page took 0.040785 seconds and 5 git commands to generate.