4
* This program is free software and may be modified and
5
* distributed under the terms of the GNU Public License.
9
#include <linux/kernel.h>
10
#include <linux/version.h>
11
#include <linux/netdevice.h>
15
static int lapd_change_mtu(struct net_device *dev, int mtu)
20
static int lapd_mac_addr(struct net_device *dev, void *addr)
25
void setup_lapd(struct net_device *netdev)
28
netdev->change_mtu = lapd_change_mtu;
29
netdev->set_mac_address = lapd_mac_addr;
30
#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,24)
31
netdev->hard_header = NULL;
32
netdev->rebuild_header = NULL;
33
netdev->hard_header_cache = NULL;
34
netdev->header_cache_update= NULL;
37
netdev->type = ARPHRD_LAPD;
38
netdev->hard_header_len = 0;
41
netdev->tx_queue_len = 10;
43
memset(netdev->broadcast, 0x00, sizeof(netdev->broadcast));
45
netdev->flags = IFF_NOARP;