Commit 8c27eba5 authored by Linus Torvalds's avatar Linus Torvalds

Merge git://git.kernel.org/pub/scm/linux/kernel/git/herbert/net-2.6

* git://git.kernel.org/pub/scm/linux/kernel/git/herbert/net-2.6: (41 commits)
  [XFRM]: Fix leak of expired xfrm_states
  [ATM]: [he] initialize lock and tasklet earlier
  [IPV4]: Remove bogus ifdef mess in arp_process
  [SKBUFF]: Free old skb properly in skb_morph
  [IPV4]: Fix memory leak in inet_hashtables.h when NUMA is on
  [IPSEC]: Temporarily remove locks around copying of non-atomic fields
  [TCP] MTUprobe: Cleanup send queue check (no need to loop)
  [TCP]: MTUprobe: receiver window & data available checks fixed
  [MAINTAINERS]: tlan list is subscribers-only
  [SUNRPC]: Remove SPIN_LOCK_UNLOCKED
  [SUNRPC]: Make xprtsock.c:xs_setup_{udp,tcp}() static
  [PFKEY]: Sending an SADB_GET responds with an SADB_GET
  [IRDA]: Compilation for CONFIG_INET=n case
  [IPVS]: Fix compiler warning about unused register_ip_vs_protocol
  [ARP]: Fix arp reply when sender ip 0
  [IPV6] TCPMD5: Fix deleting key operation.
  [IPV6] TCPMD5: Check return value of tcp_alloc_md5sig_pool().
  [IPV4] TCPMD5: Use memmove() instead of memcpy() because we have overlaps.
  [IPV4] TCPMD5: Omit redundant NULL check for kfree() argument.
  ieee80211: Stop net_ratelimit/IEEE80211_DEBUG_DROP log pollution
  ...
parents 8912858b 5dba4797
...@@ -3725,7 +3725,7 @@ S: Maintained ...@@ -3725,7 +3725,7 @@ S: Maintained
TLAN NETWORK DRIVER TLAN NETWORK DRIVER
P: Samuel Chessman P: Samuel Chessman
M: chessman@tux.org M: chessman@tux.org
L: tlan-devel@lists.sourceforge.net L: tlan-devel@lists.sourceforge.net (subscribers-only)
W: http://sourceforge.net/projects/tlan/ W: http://sourceforge.net/projects/tlan/
S: Maintained S: Maintained
......
...@@ -394,6 +394,11 @@ he_init_one(struct pci_dev *pci_dev, const struct pci_device_id *pci_ent) ...@@ -394,6 +394,11 @@ he_init_one(struct pci_dev *pci_dev, const struct pci_device_id *pci_ent)
he_dev->atm_dev->dev_data = he_dev; he_dev->atm_dev->dev_data = he_dev;
atm_dev->dev_data = he_dev; atm_dev->dev_data = he_dev;
he_dev->number = atm_dev->number; he_dev->number = atm_dev->number;
#ifdef USE_TASKLET
tasklet_init(&he_dev->tasklet, he_tasklet, (unsigned long) he_dev);
#endif
spin_lock_init(&he_dev->global_lock);
if (he_start(atm_dev)) { if (he_start(atm_dev)) {
he_stop(he_dev); he_stop(he_dev);
err = -ENODEV; err = -ENODEV;
...@@ -1173,11 +1178,6 @@ he_start(struct atm_dev *dev) ...@@ -1173,11 +1178,6 @@ he_start(struct atm_dev *dev)
if ((err = he_init_irq(he_dev)) != 0) if ((err = he_init_irq(he_dev)) != 0)
return err; return err;
#ifdef USE_TASKLET
tasklet_init(&he_dev->tasklet, he_tasklet, (unsigned long) he_dev);
#endif
spin_lock_init(&he_dev->global_lock);
/* 4.11 enable pci bus controller state machines */ /* 4.11 enable pci bus controller state machines */
host_cntl |= (OUTFF_ENB | CMDFF_ENB | host_cntl |= (OUTFF_ENB | CMDFF_ENB |
QUICK_RD_RETRY | QUICK_WR_RETRY | PERR_INT_ENB); QUICK_RD_RETRY | QUICK_WR_RETRY | PERR_INT_ENB);
......
...@@ -1032,7 +1032,7 @@ static void rt2500usb_write_tx_desc(struct rt2x00_dev *rt2x00dev, ...@@ -1032,7 +1032,7 @@ static void rt2500usb_write_tx_desc(struct rt2x00_dev *rt2x00dev,
} }
static int rt2500usb_get_tx_data_len(struct rt2x00_dev *rt2x00dev, static int rt2500usb_get_tx_data_len(struct rt2x00_dev *rt2x00dev,
int maxpacket, struct sk_buff *skb) struct sk_buff *skb)
{ {
int length; int length;
...@@ -1041,7 +1041,7 @@ static int rt2500usb_get_tx_data_len(struct rt2x00_dev *rt2x00dev, ...@@ -1041,7 +1041,7 @@ static int rt2500usb_get_tx_data_len(struct rt2x00_dev *rt2x00dev,
* but it must _not_ be a multiple of the USB packet size. * but it must _not_ be a multiple of the USB packet size.
*/ */
length = roundup(skb->len, 2); length = roundup(skb->len, 2);
length += (2 * !(length % maxpacket)); length += (2 * !(length % rt2x00dev->usb_maxpacket));
return length; return length;
} }
...@@ -1643,7 +1643,6 @@ static int rt2500usb_beacon_update(struct ieee80211_hw *hw, ...@@ -1643,7 +1643,6 @@ static int rt2500usb_beacon_update(struct ieee80211_hw *hw,
struct data_entry *beacon; struct data_entry *beacon;
struct data_entry *guardian; struct data_entry *guardian;
int pipe = usb_sndbulkpipe(usb_dev, 1); int pipe = usb_sndbulkpipe(usb_dev, 1);
int max_packet = usb_maxpacket(usb_dev, pipe, 1);
int length; int length;
/* /*
...@@ -1672,7 +1671,7 @@ static int rt2500usb_beacon_update(struct ieee80211_hw *hw, ...@@ -1672,7 +1671,7 @@ static int rt2500usb_beacon_update(struct ieee80211_hw *hw,
ring->desc_size), ring->desc_size),
skb->len - ring->desc_size, control); skb->len - ring->desc_size, control);
length = rt2500usb_get_tx_data_len(rt2x00dev, max_packet, skb); length = rt2500usb_get_tx_data_len(rt2x00dev, skb);
usb_fill_bulk_urb(beacon->priv, usb_dev, pipe, usb_fill_bulk_urb(beacon->priv, usb_dev, pipe,
skb->data, length, rt2500usb_beacondone, beacon); skb->data, length, rt2500usb_beacondone, beacon);
......
...@@ -418,7 +418,7 @@ struct rt2x00lib_ops { ...@@ -418,7 +418,7 @@ struct rt2x00lib_ops {
int (*write_tx_data) (struct rt2x00_dev *rt2x00dev, int (*write_tx_data) (struct rt2x00_dev *rt2x00dev,
struct data_ring *ring, struct sk_buff *skb, struct data_ring *ring, struct sk_buff *skb,
struct ieee80211_tx_control *control); struct ieee80211_tx_control *control);
int (*get_tx_data_len) (struct rt2x00_dev *rt2x00dev, int maxpacket, int (*get_tx_data_len) (struct rt2x00_dev *rt2x00dev,
struct sk_buff *skb); struct sk_buff *skb);
void (*kick_tx_queue) (struct rt2x00_dev *rt2x00dev, void (*kick_tx_queue) (struct rt2x00_dev *rt2x00dev,
unsigned int queue); unsigned int queue);
...@@ -598,6 +598,11 @@ struct rt2x00_dev { ...@@ -598,6 +598,11 @@ struct rt2x00_dev {
*/ */
u32 *rf; u32 *rf;
/*
* USB Max frame size (for rt2500usb & rt73usb).
*/
u16 usb_maxpacket;
/* /*
* Current TX power value. * Current TX power value.
*/ */
......
...@@ -159,7 +159,6 @@ int rt2x00usb_write_tx_data(struct rt2x00_dev *rt2x00dev, ...@@ -159,7 +159,6 @@ int rt2x00usb_write_tx_data(struct rt2x00_dev *rt2x00dev,
interface_to_usbdev(rt2x00dev_usb(rt2x00dev)); interface_to_usbdev(rt2x00dev_usb(rt2x00dev));
struct data_entry *entry = rt2x00_get_data_entry(ring); struct data_entry *entry = rt2x00_get_data_entry(ring);
int pipe = usb_sndbulkpipe(usb_dev, 1); int pipe = usb_sndbulkpipe(usb_dev, 1);
int max_packet = usb_maxpacket(usb_dev, pipe, 1);
u32 length; u32 length;
if (rt2x00_ring_full(ring)) { if (rt2x00_ring_full(ring)) {
...@@ -194,8 +193,7 @@ int rt2x00usb_write_tx_data(struct rt2x00_dev *rt2x00dev, ...@@ -194,8 +193,7 @@ int rt2x00usb_write_tx_data(struct rt2x00_dev *rt2x00dev,
* length of the data to usb_fill_bulk_urb. Pass the skb * length of the data to usb_fill_bulk_urb. Pass the skb
* to the driver to determine what the length should be. * to the driver to determine what the length should be.
*/ */
length = rt2x00dev->ops->lib->get_tx_data_len(rt2x00dev, length = rt2x00dev->ops->lib->get_tx_data_len(rt2x00dev, skb);
max_packet, skb);
/* /*
* Initialize URB and send the frame to the device. * Initialize URB and send the frame to the device.
...@@ -490,6 +488,11 @@ int rt2x00usb_probe(struct usb_interface *usb_intf, ...@@ -490,6 +488,11 @@ int rt2x00usb_probe(struct usb_interface *usb_intf,
rt2x00dev->ops = ops; rt2x00dev->ops = ops;
rt2x00dev->hw = hw; rt2x00dev->hw = hw;
rt2x00dev->usb_maxpacket =
usb_maxpacket(usb_dev, usb_sndbulkpipe(usb_dev, 1), 1);
if (!rt2x00dev->usb_maxpacket)
rt2x00dev->usb_maxpacket = 1;
retval = rt2x00usb_alloc_reg(rt2x00dev); retval = rt2x00usb_alloc_reg(rt2x00dev);
if (retval) if (retval)
goto exit_free_device; goto exit_free_device;
......
...@@ -1251,7 +1251,7 @@ static void rt73usb_write_tx_desc(struct rt2x00_dev *rt2x00dev, ...@@ -1251,7 +1251,7 @@ static void rt73usb_write_tx_desc(struct rt2x00_dev *rt2x00dev,
} }
static int rt73usb_get_tx_data_len(struct rt2x00_dev *rt2x00dev, static int rt73usb_get_tx_data_len(struct rt2x00_dev *rt2x00dev,
int maxpacket, struct sk_buff *skb) struct sk_buff *skb)
{ {
int length; int length;
...@@ -1260,7 +1260,7 @@ static int rt73usb_get_tx_data_len(struct rt2x00_dev *rt2x00dev, ...@@ -1260,7 +1260,7 @@ static int rt73usb_get_tx_data_len(struct rt2x00_dev *rt2x00dev,
* but it must _not_ be a multiple of the USB packet size. * but it must _not_ be a multiple of the USB packet size.
*/ */
length = roundup(skb->len, 4); length = roundup(skb->len, 4);
length += (4 * !(length % maxpacket)); length += (4 * !(length % rt2x00dev->usb_maxpacket));
return length; return length;
} }
......
...@@ -356,7 +356,6 @@ static inline struct sk_buff *alloc_skb_fclone(unsigned int size, ...@@ -356,7 +356,6 @@ static inline struct sk_buff *alloc_skb_fclone(unsigned int size,
return __alloc_skb(size, priority, 1, -1); return __alloc_skb(size, priority, 1, -1);
} }
extern void kfree_skbmem(struct sk_buff *skb);
extern struct sk_buff *skb_morph(struct sk_buff *dst, struct sk_buff *src); extern struct sk_buff *skb_morph(struct sk_buff *dst, struct sk_buff *src);
extern struct sk_buff *skb_clone(struct sk_buff *skb, extern struct sk_buff *skb_clone(struct sk_buff *skb,
gfp_t priority); gfp_t priority);
......
...@@ -115,8 +115,16 @@ extern u32 ieee80211_debug_level; ...@@ -115,8 +115,16 @@ extern u32 ieee80211_debug_level;
do { if (ieee80211_debug_level & (level)) \ do { if (ieee80211_debug_level & (level)) \
printk(KERN_DEBUG "ieee80211: %c %s " fmt, \ printk(KERN_DEBUG "ieee80211: %c %s " fmt, \
in_interrupt() ? 'I' : 'U', __FUNCTION__ , ## args); } while (0) in_interrupt() ? 'I' : 'U', __FUNCTION__ , ## args); } while (0)
static inline bool ieee80211_ratelimit_debug(u32 level)
{
return (ieee80211_debug_level & level) && net_ratelimit();
}
#else #else
#define IEEE80211_DEBUG(level, fmt, args...) do {} while (0) #define IEEE80211_DEBUG(level, fmt, args...) do {} while (0)
static inline bool ieee80211_ratelimit_debug(u32 level)
{
return false;
}
#endif /* CONFIG_IEEE80211_DEBUG */ #endif /* CONFIG_IEEE80211_DEBUG */
/* escape_essid() is intended to be used in debug (and possibly error) /* escape_essid() is intended to be used in debug (and possibly error)
......
...@@ -186,9 +186,8 @@ static inline void inet_ehash_locks_free(struct inet_hashinfo *hashinfo) ...@@ -186,9 +186,8 @@ static inline void inet_ehash_locks_free(struct inet_hashinfo *hashinfo)
if (size > PAGE_SIZE) if (size > PAGE_SIZE)
vfree(hashinfo->ehash_locks); vfree(hashinfo->ehash_locks);
else else
#else
kfree(hashinfo->ehash_locks);
#endif #endif
kfree(hashinfo->ehash_locks);
hashinfo->ehash_locks = NULL; hashinfo->ehash_locks = NULL;
} }
} }
......
...@@ -327,40 +327,6 @@ extern int ip_vs_get_debug_level(void); ...@@ -327,40 +327,6 @@ extern int ip_vs_get_debug_level(void);
#define FTPPORT __constant_htons(21) #define FTPPORT __constant_htons(21)
#define FTPDATA __constant_htons(20) #define FTPDATA __constant_htons(20)
/*
* IPVS sysctl variables under the /proc/sys/net/ipv4/vs/
*/
#define NET_IPV4_VS 21
enum {
NET_IPV4_VS_DEBUG_LEVEL=1,
NET_IPV4_VS_AMEMTHRESH=2,
NET_IPV4_VS_AMDROPRATE=3,
NET_IPV4_VS_DROP_ENTRY=4,
NET_IPV4_VS_DROP_PACKET=5,
NET_IPV4_VS_SECURE_TCP=6,
NET_IPV4_VS_TO_ES=7,
NET_IPV4_VS_TO_SS=8,
NET_IPV4_VS_TO_SR=9,
NET_IPV4_VS_TO_FW=10,
NET_IPV4_VS_TO_TW=11,
NET_IPV4_VS_TO_CL=12,
NET_IPV4_VS_TO_CW=13,
NET_IPV4_VS_TO_LA=14,
NET_IPV4_VS_TO_LI=15,
NET_IPV4_VS_TO_SA=16,
NET_IPV4_VS_TO_UDP=17,
NET_IPV4_VS_TO_ICMP=18,
NET_IPV4_VS_LBLC_EXPIRE=19,
NET_IPV4_VS_LBLCR_EXPIRE=20,
NET_IPV4_VS_CACHE_BYPASS=22,
NET_IPV4_VS_EXPIRE_NODEST_CONN=23,
NET_IPV4_VS_SYNC_THRESHOLD=24,
NET_IPV4_VS_NAT_ICMP_SEND=25,
NET_IPV4_VS_EXPIRE_QUIESCENT_TEMPLATE=26,
NET_IPV4_VS_LAST
};
/* /*
* TCP State Values * TCP State Values
*/ */
......
...@@ -1236,6 +1236,9 @@ static inline struct sk_buff *sk_stream_alloc_pskb(struct sock *sk, ...@@ -1236,6 +1236,9 @@ static inline struct sk_buff *sk_stream_alloc_pskb(struct sock *sk,
{ {
struct sk_buff *skb; struct sk_buff *skb;
/* The TCP header must be at least 32-bit aligned. */
size = ALIGN(size, 4);
skb = alloc_skb_fclone(size + sk->sk_prot->max_header, gfp); skb = alloc_skb_fclone(size + sk->sk_prot->max_header, gfp);
if (skb) { if (skb) {
skb->truesize += mem; skb->truesize += mem;
......
...@@ -1288,6 +1288,9 @@ static inline void tcp_insert_write_queue_before(struct sk_buff *new, ...@@ -1288,6 +1288,9 @@ static inline void tcp_insert_write_queue_before(struct sk_buff *new,
struct sock *sk) struct sock *sk)
{ {
__skb_insert(new, skb->prev, skb, &sk->sk_write_queue); __skb_insert(new, skb->prev, skb, &sk->sk_write_queue);
if (sk->sk_send_head == skb)
sk->sk_send_head = new;
} }
static inline void tcp_unlink_write_queue(struct sk_buff *skb, struct sock *sk) static inline void tcp_unlink_write_queue(struct sk_buff *skb, struct sock *sk)
......
...@@ -234,36 +234,6 @@ static struct trans_ctl_table trans_net_ipv4_conf_table[] = { ...@@ -234,36 +234,6 @@ static struct trans_ctl_table trans_net_ipv4_conf_table[] = {
{} {}
}; };
static struct trans_ctl_table trans_net_ipv4_vs_table[] = {
{ NET_IPV4_VS_AMEMTHRESH, "amemthresh" },
{ NET_IPV4_VS_DEBUG_LEVEL, "debug_level" },
{ NET_IPV4_VS_AMDROPRATE, "am_droprate" },
{ NET_IPV4_VS_DROP_ENTRY, "drop_entry" },
{ NET_IPV4_VS_DROP_PACKET, "drop_packet" },
{ NET_IPV4_VS_SECURE_TCP, "secure_tcp" },
{ NET_IPV4_VS_TO_ES, "timeout_established" },
{ NET_IPV4_VS_TO_SS, "timeout_synsent" },
{ NET_IPV4_VS_TO_SR, "timeout_synrecv" },
{ NET_IPV4_VS_TO_FW, "timeout_finwait" },
{ NET_IPV4_VS_TO_TW, "timeout_timewait" },
{ NET_IPV4_VS_TO_CL, "timeout_close" },
{ NET_IPV4_VS_TO_CW, "timeout_closewait" },
{ NET_IPV4_VS_TO_LA, "timeout_lastack" },
{ NET_IPV4_VS_TO_LI, "timeout_listen" },
{ NET_IPV4_VS_TO_SA, "timeout_synack" },
{ NET_IPV4_VS_TO_UDP, "timeout_udp" },
{ NET_IPV4_VS_TO_ICMP, "timeout_icmp" },
{ NET_IPV4_VS_CACHE_BYPASS, "cache_bypass" },
{ NET_IPV4_VS_EXPIRE_NODEST_CONN, "expire_nodest_conn" },
{ NET_IPV4_VS_EXPIRE_QUIESCENT_TEMPLATE, "expire_quiescent_template" },
{ NET_IPV4_VS_SYNC_THRESHOLD, "sync_threshold" },
{ NET_IPV4_VS_NAT_ICMP_SEND, "nat_icmp_send" },
{ NET_IPV4_VS_LBLC_EXPIRE, "lblc_expiration" },
{ NET_IPV4_VS_LBLCR_EXPIRE, "lblcr_expiration" },
{}
};
static struct trans_ctl_table trans_net_neigh_vars_table[] = { static struct trans_ctl_table trans_net_neigh_vars_table[] = {
{ NET_NEIGH_MCAST_SOLICIT, "mcast_solicit" }, { NET_NEIGH_MCAST_SOLICIT, "mcast_solicit" },
{ NET_NEIGH_UCAST_SOLICIT, "ucast_solicit" }, { NET_NEIGH_UCAST_SOLICIT, "ucast_solicit" },
...@@ -338,7 +308,6 @@ static struct trans_ctl_table trans_net_ipv4_table[] = { ...@@ -338,7 +308,6 @@ static struct trans_ctl_table trans_net_ipv4_table[] = {
{ NET_IPV4_ROUTE, "route", trans_net_ipv4_route_table }, { NET_IPV4_ROUTE, "route", trans_net_ipv4_route_table },
/* NET_IPV4_FIB_HASH unused */ /* NET_IPV4_FIB_HASH unused */
{ NET_IPV4_NETFILTER, "netfilter", trans_net_ipv4_netfilter_table }, { NET_IPV4_NETFILTER, "netfilter", trans_net_ipv4_netfilter_table },
{ NET_IPV4_VS, "vs", trans_net_ipv4_vs_table },
{ NET_IPV4_TCP_TIMESTAMPS, "tcp_timestamps" }, { NET_IPV4_TCP_TIMESTAMPS, "tcp_timestamps" },
{ NET_IPV4_TCP_WINDOW_SCALING, "tcp_window_scaling" }, { NET_IPV4_TCP_WINDOW_SCALING, "tcp_window_scaling" },
......
...@@ -187,7 +187,7 @@ static int ebt_among_check(const char *tablename, unsigned int hookmask, ...@@ -187,7 +187,7 @@ static int ebt_among_check(const char *tablename, unsigned int hookmask,
if (datalen != EBT_ALIGN(expected_length)) { if (datalen != EBT_ALIGN(expected_length)) {
printk(KERN_WARNING printk(KERN_WARNING
"ebtables: among: wrong size: %d" "ebtables: among: wrong size: %d "
"against expected %d, rounded to %Zd\n", "against expected %d, rounded to %Zd\n",
datalen, expected_length, datalen, expected_length,
EBT_ALIGN(expected_length)); EBT_ALIGN(expected_length));
......
...@@ -2463,8 +2463,6 @@ static int pktgen_output_ipsec(struct sk_buff *skb, struct pktgen_dev *pkt_dev) ...@@ -2463,8 +2463,6 @@ static int pktgen_output_ipsec(struct sk_buff *skb, struct pktgen_dev *pkt_dev)
x->curlft.bytes +=skb->len; x->curlft.bytes +=skb->len;
x->curlft.packets++; x->curlft.packets++;
spin_unlock(&x->lock);
error: error:
spin_unlock(&x->lock); spin_unlock(&x->lock);
return err; return err;
......
...@@ -275,12 +275,11 @@ static void skb_release_data(struct sk_buff *skb) ...@@ -275,12 +275,11 @@ static void skb_release_data(struct sk_buff *skb)
/* /*
* Free an skbuff by memory without cleaning the state. * Free an skbuff by memory without cleaning the state.
*/ */
void kfree_skbmem(struct sk_buff *skb) static void kfree_skbmem(struct sk_buff *skb)
{ {
struct sk_buff *other; struct sk_buff *other;
atomic_t *fclone_ref; atomic_t *fclone_ref;
skb_release_data(skb);
switch (skb->fclone) { switch (skb->fclone) {
case SKB_FCLONE_UNAVAILABLE: case SKB_FCLONE_UNAVAILABLE:
kmem_cache_free(skbuff_head_cache, skb); kmem_cache_free(skbuff_head_cache, skb);
...@@ -307,16 +306,8 @@ void kfree_skbmem(struct sk_buff *skb) ...@@ -307,16 +306,8 @@ void kfree_skbmem(struct sk_buff *skb)
} }
} }
/** /* Free everything but the sk_buff shell. */
* __kfree_skb - private function static void skb_release_all(struct sk_buff *skb)
* @skb: buffer
*
* Free an sk_buff. Release anything attached to the buffer.
* Clean the state. This is an internal helper function. Users should
* always call kfree_skb
*/
void __kfree_skb(struct sk_buff *skb)
{ {
dst_release(skb->dst); dst_release(skb->dst);
#ifdef CONFIG_XFRM #ifdef CONFIG_XFRM
...@@ -340,7 +331,21 @@ void __kfree_skb(struct sk_buff *skb) ...@@ -340,7 +331,21 @@ void __kfree_skb(struct sk_buff *skb)
skb->tc_verd = 0; skb->tc_verd = 0;
#endif #endif
#endif #endif
skb_release_data(skb);
}
/**
* __kfree_skb - private function
* @skb: buffer
*
* Free an sk_buff. Release anything attached to the buffer.
* Clean the state. This is an internal helper function. Users should
* always call kfree_skb
*/
void __kfree_skb(struct sk_buff *skb)
{
skb_release_all(skb);
kfree_skbmem(skb); kfree_skbmem(skb);
} }
...@@ -441,7 +446,7 @@ static struct sk_buff *__skb_clone(struct sk_buff *n, struct sk_buff *skb) ...@@ -441,7 +446,7 @@ static struct sk_buff *__skb_clone(struct sk_buff *n, struct sk_buff *skb)
*/ */
struct sk_buff *skb_morph(struct sk_buff *dst, struct sk_buff *src) struct sk_buff *skb_morph(struct sk_buff *dst, struct sk_buff *src)
{ {
skb_release_data(dst); skb_release_all(dst);
return __skb_clone(dst, src); return __skb_clone(dst, src);
} }
EXPORT_SYMBOL_GPL(skb_morph); EXPORT_SYMBOL_GPL(skb_morph);
......
...@@ -166,7 +166,7 @@ static u32 dccp_li_calc_first_li(struct sock *sk, ...@@ -166,7 +166,7 @@ static u32 dccp_li_calc_first_li(struct sock *sk,
} }
if (unlikely(interval == 0)) { if (unlikely(interval == 0)) {
DCCP_WARN("%s(%p), Could not find a win_count interval > 0." DCCP_WARN("%s(%p), Could not find a win_count interval > 0. "
"Defaulting to 1\n", dccp_role(sk), sk); "Defaulting to 1\n", dccp_role(sk), sk);
interval = 1; interval = 1;
} }
......
...@@ -338,7 +338,7 @@ static int ieee80211_ccmp_decrypt(struct sk_buff *skb, int hdr_len, void *priv) ...@@ -338,7 +338,7 @@ static int ieee80211_ccmp_decrypt(struct sk_buff *skb, int hdr_len, void *priv)
pos += 8; pos += 8;
if (ccmp_replay_check(pn, key->rx_pn)) { if (ccmp_replay_check(pn, key->rx_pn)) {
if (net_ratelimit()) { if (ieee80211_ratelimit_debug(IEEE80211_DL_DROP)) {
IEEE80211_DEBUG_DROP("CCMP: replay detected: STA=%s " IEEE80211_DEBUG_DROP("CCMP: replay detected: STA=%s "
"previous PN %02x%02x%02x%02x%02x%02x " "previous PN %02x%02x%02x%02x%02x%02x "
"received PN %02x%02x%02x%02x%02x%02x\n", "received PN %02x%02x%02x%02x%02x%02x\n",
......
...@@ -464,7 +464,7 @@ static int ieee80211_tkip_decrypt(struct sk_buff *skb, int hdr_len, void *priv) ...@@ -464,7 +464,7 @@ static int ieee80211_tkip_decrypt(struct sk_buff *skb, int hdr_len, void *priv)
pos += 8; pos += 8;
if (tkip_replay_check(iv32, iv16, tkey->rx_iv32, tkey->rx_iv16)) { if (tkip_replay_check(iv32, iv16, tkey->rx_iv32, tkey->rx_iv16)) {
if (net_ratelimit()) { if (ieee80211_ratelimit_debug(IEEE80211_DL_DROP)) {
IEEE80211_DEBUG_DROP("TKIP: replay detected: STA=%s" IEEE80211_DEBUG_DROP("TKIP: replay detected: STA=%s"
" previous TSC %08x%04x received TSC " " previous TSC %08x%04x received TSC "
"%08x%04x\n", print_mac(mac, hdr->addr2), "%08x%04x\n", print_mac(mac, hdr->addr2),
...@@ -504,7 +504,7 @@ static int ieee80211_tkip_decrypt(struct sk_buff *skb, int hdr_len, void *priv) ...@@ -504,7 +504,7 @@ static int ieee80211_tkip_decrypt(struct sk_buff *skb, int hdr_len, void *priv)
* it needs to be recalculated for the next packet. */ * it needs to be recalculated for the next packet. */
tkey->rx_phase1_done = 0; tkey->rx_phase1_done = 0;
} }
if (net_ratelimit()) { if (ieee80211_ratelimit_debug(IEEE80211_DL_DROP)) {
IEEE80211_DEBUG_DROP("TKIP: ICV error detected: STA=" IEEE80211_DEBUG_DROP("TKIP: ICV error detected: STA="
"%s\n", print_mac(mac, hdr->addr2)); "%s\n", print_mac(mac, hdr->addr2));
} }
......
...@@ -111,12 +111,8 @@ ...@@ -111,12 +111,8 @@
#include <net/tcp.h> #include <net/tcp.h>
#include <net/sock.h> #include <net/sock.h>
#include <net/arp.h> #include <net/arp.h>
#if defined(CONFIG_AX25) || defined(CONFIG_AX25_MODULE)
#include <net/ax25.h> #include <net/ax25.h>
#if defined(CONFIG_NETROM) || defined(CONFIG_NETROM_MODULE)
#include <net/netrom.h> #include <net/netrom.h>
#endif
#endif
#if defined(CONFIG_ATM_CLIP) || defined(CONFIG_ATM_CLIP_MODULE) #if defined(CONFIG_ATM_CLIP) || defined(CONFIG_ATM_CLIP_MODULE)
#include <net/atmclip.h> #include <net/atmclip.h>
struct neigh_table *clip_tbl_hook; struct neigh_table *clip_tbl_hook;
...@@ -731,20 +727,10 @@ static int arp_process(struct sk_buff *skb) ...@@ -731,20 +727,10 @@ static int arp_process(struct sk_buff *skb)
htons(dev_type) != arp->ar_hrd) htons(dev_type) != arp->ar_hrd)
goto out; goto out;
break; break;
#ifdef CONFIG_NET_ETHERNET
case ARPHRD_ETHER: case ARPHRD_ETHER:
#endif
#ifdef CONFIG_TR
case ARPHRD_IEEE802_TR: case ARPHRD_IEEE802_TR:
#endif
#ifdef CONFIG_FDDI
case ARPHRD_FDDI: case ARPHRD_FDDI:
#endif
#ifdef CONFIG_NET_FC