summaryrefslogtreecommitdiff
path: root/e1000-xioh/kcompat.h
blob: 133481608ebba77314e61a34b060f476a1ccca15 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#ifndef _KCOMPAT_H_
#define  _KCOMPAT_H_

#define netdev_uc_count(dev) ((dev)->uc.count)
#define netdev_uc_empty(dev) ((dev)->uc.count == 0)
#define netdev_for_each_uc_addr(ha, dev) \
	        list_for_each_entry(ha, &dev->uc.list, list)

#define netdev_mc_count(dev) ((dev)->mc_count)
#define netdev_mc_empty(dev) (netdev_mc_count(dev) == 0)

#define netdev_for_each_mc_addr(mclist, dev) \
	        for (mclist = dev->mc_list; mclist; mclist = mclist->next)

#if 0
static inline struct sk_buff *netdev_alloc_skb_ip_align(struct net_device *dev,
                unsigned int length)
{
        struct sk_buff *skb = netdev_alloc_skb(dev, length + NET_IP_ALIGN);

        if (NET_IP_ALIGN && skb)
                skb_reserve(skb, NET_IP_ALIGN);
        return skb;
}
#endif

#endif