Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6: (67 commits)
cxgb4vf: recover from failure in cxgb4vf_open()
netfilter: ebtables: make broute table work again
netfilter: fix race in conntrack between dump_table and destroy
ah: reload pointers to skb data after calling skb_cow_data()
ah: update maximum truncated ICV length
xfrm: check trunc_len in XFRMA_ALG_AUTH_TRUNC
ehea: Increase the skb array usage
net/fec: remove config FEC2 as it's used nowhere
pcnet_cs: add new_id
tcp: disallow bind() to reuse addr/port
net/r8169: Update the function of parsing firmware
net: ppp: use {get,put}_unaligned_be{16,32}
CAIF: Fix IPv6 support in receive path for GPRS/3G
arp: allow to invalidate specific ARP entries
net_sched: factorize qdisc stats handling
mlx4: Call alloc_etherdev to allocate RX and TX queues
net: Add alloc_netdev_mqs function
caif: don't set connection request param size before copying data
cxgb4vf: fix mailbox data/control coherency domain race
qlcnic: change module parameter permissions
...
This commit is contained in:
@@ -24,6 +24,7 @@ struct bfin_mii_bus_platform_data {
|
||||
const unsigned short *mac_peripherals;
|
||||
int phy_mode;
|
||||
unsigned int phy_mask;
|
||||
unsigned short vlan1_mask, vlan2_mask;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
@@ -48,8 +48,10 @@ extern int eth_validate_addr(struct net_device *dev);
|
||||
|
||||
|
||||
|
||||
extern struct net_device *alloc_etherdev_mq(int sizeof_priv, unsigned int queue_count);
|
||||
extern struct net_device *alloc_etherdev_mqs(int sizeof_priv, unsigned int txqs,
|
||||
unsigned int rxqs);
|
||||
#define alloc_etherdev(sizeof_priv) alloc_etherdev_mq(sizeof_priv, 1)
|
||||
#define alloc_etherdev_mq(sizeof_priv, count) alloc_etherdev_mqs(sizeof_priv, count, count)
|
||||
|
||||
/**
|
||||
* is_zero_ether_addr - Determine if give Ethernet address is all zeros.
|
||||
|
||||
@@ -3,6 +3,8 @@
|
||||
* Copyright (c) 2009 Orex Computed Radiography
|
||||
* Baruch Siach <baruch@tkos.co.il>
|
||||
*
|
||||
* Copyright (C) 2010 Freescale Semiconductor, Inc.
|
||||
*
|
||||
* Header file for the FEC platform data
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@@ -16,6 +18,7 @@
|
||||
|
||||
struct fec_platform_data {
|
||||
phy_interface_t phy;
|
||||
unsigned char mac[ETH_ALEN];
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
@@ -103,7 +103,7 @@ struct __fdb_entry {
|
||||
|
||||
extern void brioctl_set(int (*ioctl_hook)(struct net *, unsigned int, void __user *));
|
||||
|
||||
typedef int (*br_should_route_hook_t)(struct sk_buff *skb);
|
||||
typedef int br_should_route_hook_t(struct sk_buff *skb);
|
||||
extern br_should_route_hook_t __rcu *br_should_route_hook;
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2191,11 +2191,15 @@ static inline void netif_addr_unlock_bh(struct net_device *dev)
|
||||
extern void ether_setup(struct net_device *dev);
|
||||
|
||||
/* Support for loadable net-drivers */
|
||||
extern struct net_device *alloc_netdev_mq(int sizeof_priv, const char *name,
|
||||
extern struct net_device *alloc_netdev_mqs(int sizeof_priv, const char *name,
|
||||
void (*setup)(struct net_device *),
|
||||
unsigned int queue_count);
|
||||
unsigned int txqs, unsigned int rxqs);
|
||||
#define alloc_netdev(sizeof_priv, name, setup) \
|
||||
alloc_netdev_mq(sizeof_priv, name, setup, 1)
|
||||
alloc_netdev_mqs(sizeof_priv, name, setup, 1, 1)
|
||||
|
||||
#define alloc_netdev_mq(sizeof_priv, name, setup, count) \
|
||||
alloc_netdev_mqs(sizeof_priv, name, setup, count, count)
|
||||
|
||||
extern int register_netdev(struct net_device *dev);
|
||||
extern void unregister_netdev(struct net_device *dev);
|
||||
|
||||
@@ -2303,7 +2307,7 @@ unsigned long netdev_fix_features(unsigned long features, const char *name);
|
||||
void netif_stacked_transfer_operstate(const struct net_device *rootdev,
|
||||
struct net_device *dev);
|
||||
|
||||
int netif_get_vlan_features(struct sk_buff *skb, struct net_device *dev);
|
||||
int netif_skb_features(struct sk_buff *skb);
|
||||
|
||||
static inline int net_gso_ok(int features, int gso_type)
|
||||
{
|
||||
@@ -2317,16 +2321,10 @@ static inline int skb_gso_ok(struct sk_buff *skb, int features)
|
||||
(!skb_has_frag_list(skb) || (features & NETIF_F_FRAGLIST));
|
||||
}
|
||||
|
||||
static inline int netif_needs_gso(struct net_device *dev, struct sk_buff *skb)
|
||||
static inline int netif_needs_gso(struct sk_buff *skb, int features)
|
||||
{
|
||||
if (skb_is_gso(skb)) {
|
||||
int features = netif_get_vlan_features(skb, dev);
|
||||
|
||||
return (!skb_gso_ok(skb, features) ||
|
||||
unlikely(skb->ip_summed != CHECKSUM_PARTIAL));
|
||||
}
|
||||
|
||||
return 0;
|
||||
return skb_is_gso(skb) && (!skb_gso_ok(skb, features) ||
|
||||
unlikely(skb->ip_summed != CHECKSUM_PARTIAL));
|
||||
}
|
||||
|
||||
static inline void netif_set_gso_max_size(struct net_device *dev,
|
||||
|
||||
@@ -472,7 +472,7 @@ extern void xt_free_table_info(struct xt_table_info *info);
|
||||
* necessary for reading the counters.
|
||||
*/
|
||||
struct xt_info_lock {
|
||||
spinlock_t lock;
|
||||
seqlock_t lock;
|
||||
unsigned char readers;
|
||||
};
|
||||
DECLARE_PER_CPU(struct xt_info_lock, xt_info_locks);
|
||||
@@ -497,7 +497,7 @@ static inline void xt_info_rdlock_bh(void)
|
||||
local_bh_disable();
|
||||
lock = &__get_cpu_var(xt_info_locks);
|
||||
if (likely(!lock->readers++))
|
||||
spin_lock(&lock->lock);
|
||||
write_seqlock(&lock->lock);
|
||||
}
|
||||
|
||||
static inline void xt_info_rdunlock_bh(void)
|
||||
@@ -505,7 +505,7 @@ static inline void xt_info_rdunlock_bh(void)
|
||||
struct xt_info_lock *lock = &__get_cpu_var(xt_info_locks);
|
||||
|
||||
if (likely(!--lock->readers))
|
||||
spin_unlock(&lock->lock);
|
||||
write_sequnlock(&lock->lock);
|
||||
local_bh_enable();
|
||||
}
|
||||
|
||||
@@ -516,12 +516,12 @@ static inline void xt_info_rdunlock_bh(void)
|
||||
*/
|
||||
static inline void xt_info_wrlock(unsigned int cpu)
|
||||
{
|
||||
spin_lock(&per_cpu(xt_info_locks, cpu).lock);
|
||||
write_seqlock(&per_cpu(xt_info_locks, cpu).lock);
|
||||
}
|
||||
|
||||
static inline void xt_info_wrunlock(unsigned int cpu)
|
||||
{
|
||||
spin_unlock(&per_cpu(xt_info_locks, cpu).lock);
|
||||
write_sequnlock(&per_cpu(xt_info_locks, cpu).lock);
|
||||
}
|
||||
|
||||
/*
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
#include <linux/skbuff.h>
|
||||
|
||||
/* This is the maximum truncated ICV length that we know of. */
|
||||
#define MAX_AH_AUTH_LEN 12
|
||||
#define MAX_AH_AUTH_LEN 16
|
||||
|
||||
struct crypto_ahash;
|
||||
|
||||
|
||||
@@ -25,5 +25,6 @@ extern struct sk_buff *arp_create(int type, int ptype, __be32 dest_ip,
|
||||
const unsigned char *src_hw,
|
||||
const unsigned char *target_hw);
|
||||
extern void arp_xmit(struct sk_buff *skb);
|
||||
int arp_invalidate(struct net_device *dev, __be32 ip);
|
||||
|
||||
#endif /* _ARP_H */
|
||||
|
||||
@@ -107,8 +107,8 @@ struct phonet_protocol {
|
||||
int sock_type;
|
||||
};
|
||||
|
||||
int phonet_proto_register(int protocol, struct phonet_protocol *pp);
|
||||
void phonet_proto_unregister(int protocol, struct phonet_protocol *pp);
|
||||
int phonet_proto_register(unsigned int protocol, struct phonet_protocol *pp);
|
||||
void phonet_proto_unregister(unsigned int protocol, struct phonet_protocol *pp);
|
||||
|
||||
int phonet_sysctl_init(void);
|
||||
void phonet_sysctl_exit(void);
|
||||
|
||||
@@ -207,7 +207,7 @@ static inline int qdisc_qlen(struct Qdisc *q)
|
||||
return q->q.qlen;
|
||||
}
|
||||
|
||||
static inline struct qdisc_skb_cb *qdisc_skb_cb(struct sk_buff *skb)
|
||||
static inline struct qdisc_skb_cb *qdisc_skb_cb(const struct sk_buff *skb)
|
||||
{
|
||||
return (struct qdisc_skb_cb *)skb->cb;
|
||||
}
|
||||
@@ -394,7 +394,7 @@ static inline bool qdisc_tx_is_noop(const struct net_device *dev)
|
||||
return true;
|
||||
}
|
||||
|
||||
static inline unsigned int qdisc_pkt_len(struct sk_buff *skb)
|
||||
static inline unsigned int qdisc_pkt_len(const struct sk_buff *skb)
|
||||
{
|
||||
return qdisc_skb_cb(skb)->pkt_len;
|
||||
}
|
||||
@@ -426,10 +426,18 @@ static inline int qdisc_enqueue_root(struct sk_buff *skb, struct Qdisc *sch)
|
||||
return qdisc_enqueue(skb, sch) & NET_XMIT_MASK;
|
||||
}
|
||||
|
||||
static inline void __qdisc_update_bstats(struct Qdisc *sch, unsigned int len)
|
||||
|
||||
static inline void bstats_update(struct gnet_stats_basic_packed *bstats,
|
||||
const struct sk_buff *skb)
|
||||
{
|
||||
sch->bstats.bytes += len;
|
||||
sch->bstats.packets++;
|
||||
bstats->bytes += qdisc_pkt_len(skb);
|
||||
bstats->packets += skb_is_gso(skb) ? skb_shinfo(skb)->gso_segs : 1;
|
||||
}
|
||||
|
||||
static inline void qdisc_bstats_update(struct Qdisc *sch,
|
||||
const struct sk_buff *skb)
|
||||
{
|
||||
bstats_update(&sch->bstats, skb);
|
||||
}
|
||||
|
||||
static inline int __qdisc_enqueue_tail(struct sk_buff *skb, struct Qdisc *sch,
|
||||
@@ -437,7 +445,7 @@ static inline int __qdisc_enqueue_tail(struct sk_buff *skb, struct Qdisc *sch,
|
||||
{
|
||||
__skb_queue_tail(list, skb);
|
||||
sch->qstats.backlog += qdisc_pkt_len(skb);
|
||||
__qdisc_update_bstats(sch, qdisc_pkt_len(skb));
|
||||
qdisc_bstats_update(sch, skb);
|
||||
|
||||
return NET_XMIT_SUCCESS;
|
||||
}
|
||||
|
||||
@@ -152,14 +152,18 @@ struct sock_common {
|
||||
* fields between dontcopy_begin/dontcopy_end
|
||||
* are not copied in sock_copy()
|
||||
*/
|
||||
/* private: */
|
||||
int skc_dontcopy_begin[0];
|
||||
/* public: */
|
||||
union {
|
||||
struct hlist_node skc_node;
|
||||
struct hlist_nulls_node skc_nulls_node;
|
||||
};
|
||||
int skc_tx_queue_mapping;
|
||||
atomic_t skc_refcnt;
|
||||
/* private: */
|
||||
int skc_dontcopy_end[0];
|
||||
/* public: */
|
||||
};
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user