Linux 2.6.22.11
Subsystems (20)
We (the -stable team) are announcing the release of the 2.6.22.11 kernel. It fixes a number of reported bugs, and any user of the 2.6.22 series is encouraged to upgrade.
I'll also be replying to this message with a copy of the patch between 2.6.22.10 and 2.6.22.11
Based on the responses of the last patch review cycle, we've received a number of other patches that should be added to the 2.6.22.y tree, so there will be one more release in this series.
The updated 2.6.22.y git tree can be found at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-2.6.22.y.git
and can be browsed at the normal kernel.org git web browser:
http://git.kernel.org/?p=linux/kernel/git/stable/linux-2.6.22.y.git;a=summarythanks,
greg k-h
--------
Makefile | 2 arch/powerpc/math-emu/math.c | 13 +++-- arch/sparc64/kernel/sys_sparc.c | 15 +----- drivers/acpi/processor_core.c | 2 drivers/acpi/processor_idle.c | 19 +++++++ drivers/char/drm/i915_irq.c | 2 drivers/char/random.c | 10 ++-- drivers/firewire/fw-card.c | 6 +- drivers/hwmon/lm87.c | 4 - drivers/hwmon/w83627hf.c | 78 ++++++++++++++++++-------------- drivers/media/video/ivtv/ivtv-fileops.c | 2 drivers/net/natsemi.c | 2 drivers/net/usb/dm9601.c | 2 drivers/net/wireless/libertas/11d.c | 2 drivers/net/wireless/libertas/cmd.c | 6 -- drivers/net/wireless/libertas/wext.c | 8 +-- drivers/scsi/esp_scsi.c | 3 - include/acpi/processor.h | 2 include/net/rose.h | 2 include/net/tcp.h | 6 -- kernel/lockdep.c | 2 net/ieee80211/ieee80211_rx.c | 6 ++ net/ipv4/tcp_input.c | 3 + net/ipv4/tcp_ipv4.c | 19 +++---- net/ipv6/addrconf.c | 13 ++++- net/ipv6/ndisc.c | 9 ++- net/ipv6/tcp_ipv6.c | 18 +++---- net/mac80211/ieee80211.c | 8 ++- net/rose/rose_loopback.c | 4 - net/rose/rose_route.c | 15 ++++-- net/sched/cls_u32.c | 2 net/socket.c | 3 - 32 files changed, 170 insertions(+), 118 deletions(-)
Summary of changes from v2.6.22.10 to v2.6.22.11
================================================
Al Viro (2):
libertas: fix endianness breakage
libertas: more endianness breakage
Alexey Dobriyan (1):
Fix ROSE module unload oops.
Andy Green (1):
Add get_unaligned to ieee80211_get_radiotap_len
Brian Haley (1):
Fix ipv6 redirect processing, leads to TAHI failures.
Dave Airlie (1):
i915: fix vbl swap allocation size.
David Miller (2):
Fix ESP host instance numbering.
Fix TCP MD5 on big-endian.
David S. Miller (2):
Fix zero length socket write() semantics.
Fix sys_ipc() SEMCTL on sparc64.
Eric Dumazet (1):
Fix TCP initial sequence number selection.
Greg Kroah-Hartman (1):
Linux 2.6.22.11
Gregory Haskins (1):
lockdep: fix mismatched lockdep_depth/curr_chain_hash
Ian Armstrong (1):
V4L: ivtv: fix udma yuv bug
Ilpo Järvinen (1):
Fix TCP's ->fastpath_cnt_hit handling.
Jean Delvare (4):
hwmon/lm87: Fix a division by zero
hwmon/lm87: Disable VID when it should be hwmon/w83627hf: Fix setting fan min right after driver load hwmon/w83627hf: Don't assume bank 0
Jeff Garzik (1):
netdrvr: natsemi: Fix device removal bug
John W. Linville (2):
Fix ieee80211 handling of bogus hdrlength field
mac80211: filter locally-originated multicast frames
Kumar Gala (1):
POWERPC: Fix handling of stfiwx math emulation
Mitsuru Chinen (1):
Fix some cases of missed IPV6 DAD
Peter Korsgaard (1):
dm9601: Fix receive MTU
Stefan Richter (1):
firewire: fix unloading of fw-ohci while devices are attached
Stephen Hemminger (1):
Fix cls_u32 error return handling.
Thomas Gleixner (1):
ACPI: disable lower idle C-states across suspend/resume
Makefile +1 -1
@@ -1,7 +1,7 @@ VERSION = 2 PATCHLEVEL = 6 SUBLEVEL = 22 -EXTRAVERSION = .10 +EXTRAVERSION = .11 NAME = Holy Dancing Manatees, Batman! # *DOCUMENTATION*
arch/powerpc/math-emu/math.c +9 -4
@@ -407,11 +407,16 @@ do_mathemu(struct pt_regs *regs)case XE : idx = (insn >>16 ) &0x1f ; -if (!idx) - goto illegal; - op0 = (void *)¤t->thread.fpr[(insn >>21 ) &0x1f ]; - op1 = (void *)(regs->gpr[idx] + regs->gpr[(insn >>11 ) &0x1f ]); +if (!idx) { +if (((insn >>1 ) &0x3ff ) ==STFIWX ) + op1 = (void *)(regs->gpr[(insn >>11 ) &0x1f ]); +else + goto illegal; + }else { + op1 = (void *)(regs->gpr[idx] + regs->gpr[(insn >>11 ) &0x1f ]); + } +break ;case XEU :
arch/sparc64/kernel/sys_sparc.c +4 -11
@@ -436,7 +436,7 @@ out:asmlinkage long sys_ipc (unsigned int call,int first,unsigned long second,unsigned long third,void __user *ptr,long fifth) { -int err; +long err;/* No need for backward compatibility. We can start fresh... */ if (call <=SEMCTL ) {
@@ -453,16 +453,9 @@ asmlinkage long sys_ipc(unsigned int call, int first, unsigned long second, err =sys_semget (first, (int )second, (int )third); goto out;case SEMCTL : { -union semun fourth; - err = -EINVAL ; -if (!ptr) - goto out; - err = -EFAULT ; -if (get_user (fourth.__pad, - (void __user *__user *) ptr)) - goto out; - err =sys_semctl (first, (int )second |IPC_64 , - (int )third, fourth); + err =sys_semctl (first, third, + (int )second |IPC_64 , + (union semun ) ptr); goto out; }default :
drivers/acpi/processor_core.c +2 -0
@@ -93,6 +93,8 @@ static struct acpi_driver acpi_processor_driver = { .add = acpi_processor_add, .remove = acpi_processor_remove, .start = acpi_processor_start, + .suspend = acpi_processor_suspend, + .resume = acpi_processor_resume, }, };
drivers/acpi/processor_idle.c +18 -1
@@ -324,6 +324,23 @@ static void acpi_state_timer_broadcast(struct acpi_processor *pr,#endif +/* +* Suspend / resume control +*/ +static int acpi_idle_suspend; + +int acpi_processor_suspend (struct acpi_device * device,pm_message_t state) +{ + acpi_idle_suspend =1 ; +return 0 ; +} + +int acpi_processor_resume (struct acpi_device * device) +{ + acpi_idle_suspend =0 ; +return 0 ; +} +static void acpi_processor_idle (void ) {struct acpi_processor *pr =NULL ;
@@ -354,7 +371,7 @@ static void acpi_processor_idle(void) } cx = pr->power.state; -if (!cx) { +if (!cx || acpi_idle_suspend) {if (pm_idle_save)pm_idle_save ();else
drivers/char/drm/i915_irq.c +1 -1
@@ -541,7 +541,7 @@ int i915_vblank_swap(DRM_IOCTL_ARGS)return DRM_ERR (EBUSY ); } - vbl_swap =drm_calloc (1 ,sizeof (vbl_swap),DRM_MEM_DRIVER ); + vbl_swap =drm_calloc (1 ,sizeof (*vbl_swap),DRM_MEM_DRIVER );if (!vbl_swap) {DRM_ERROR ("Failed to allocate memory to queue swap\n" );
drivers/char/random.c +6 -4
@@ -1550,11 +1550,13 @@ __u32 secure_tcp_sequence_number(__be32 saddr, __be32 daddr,* As close as possible to RFC 793, which * suggests using a 250 kHz clock. * Further reading shows this assumes 2 Mb/s networks. -* For 10 Gb/s Ethernet, a 1 GHz clock is appropriate. -* That's funny, Linux has one built in! Use it! -* (Networks are faster now - should this be increased?) +* For 10 Mb/s Ethernet, a 1 MHz clock is appropriate. +* For 10 Gb/s Ethernet, a 1 GHz clock should be ok, but +* we also need to limit the resolution so that the u32 seq +* overlaps less than one time per MSL (2 minutes). +* Choosing a clock of 64 ns period is OK. (period of 274 s) */ - seq +=ktime_get_real ().tv64; + seq +=ktime_get_real ().tv64 >>6 ;#if 0 printk ("init_seq(%lx, %lx, %d, %d) = %d\n" , saddr, daddr, sport, dport, seq);
drivers/firewire/fw-card.c +4 -2
@@ -507,9 +507,11 @@ fw_core_remove_card(struct fw_card *card)/* Set up the dummy driver. */ card->driver = &dummy_driver; -fw_flush_transactions (card); -fw_destroy_nodes (card); +flush_scheduled_work (); + +fw_flush_transactions (card); +del_timer_sync (&card->flush_timer);fw_card_put (card); }
drivers/hwmon/lm87.c +2 -2
@@ -129,7 +129,7 @@ static u8 LM87_REG_TEMP_LOW[3] = { 0x3A, 0x38, 0x2C }; (((val) < 0 ? (val)-500 : (val)+500) / 1000))#define FAN_FROM_REG (reg,div) ((reg) == 255 || (reg) == 0 ? 0 : \ - 1350000 + (reg)*(div) / 2) / ((reg)*(div)) + (1350000 + (reg)*(div) / 2) / ((reg)*(div)))#define FAN_TO_REG (val,div) ((val)*(div) * 255 <= 1350000 ? 255 : \ (1350000 + (val)*(div) / 2) / ((val)*(div)))
@@ -145,7 +145,7 @@ static u8 LM87_REG_TEMP_LOW[3] = { 0x3A, 0x38, 0x2C };#define CHAN_NO_FAN (nr) (1 << (nr))#define CHAN_TEMP3 (1 << 2)#define CHAN_VCC_5V (1 << 3) -#define CHAN_NO_VID (1 << 8) +#define CHAN_NO_VID (1 << 7)/* * Functions declaration
drivers/hwmon/w83627hf.c +44 -34
132 lines not on this page · raw message
drivers/media/video/ivtv/ivtv-fileops.c +2 -0
@@ -753,6 +753,8 @@ static void ivtv_stop_decoding(struct ivtv_open_id *id, int flags, u64 pts) }if (s->type ==IVTV_DEC_STREAM_TYPE_YUV && itv->output_mode ==OUT_YUV ) itv->output_mode =OUT_NONE ; +else if (s->type ==IVTV_DEC_STREAM_TYPE_YUV && itv->output_mode ==OUT_UDMA_YUV ) + itv->output_mode =OUT_NONE ;else if (s->type ==IVTV_DEC_STREAM_TYPE_MPG && itv->output_mode ==OUT_MPG ) itv->output_mode =OUT_NONE ;
drivers/net/natsemi.c +1 -1
@@ -671,7 +671,7 @@ static ssize_t natsemi_show_##_name(struct device *dev, \#define NATSEMI_CREATE_FILE (_dev, _name) \ device_create_file(&_dev->dev, &dev_attr_##_name)#define NATSEMI_REMOVE_FILE (_dev, _name) \ - device_create_file(&_dev->dev, &dev_attr_##_name) + device_remove_file(&_dev->dev, &dev_attr_##_name)NATSEMI_ATTR (dspcfg_workaround);
drivers/net/usb/dm9601.c +1 -1
@@ -405,7 +405,7 @@ static int dm9601_bind(struct usbnet *dev, struct usb_interface *intf) dev->net->ethtool_ops = &dm9601_ethtool_ops; dev->net->hard_header_len +=DM_TX_OVERHEAD ; dev->hard_mtu = dev->net->mtu + dev->net->hard_header_len; - dev->rx_urb_size = dev->net->mtu +DM_RX_OVERHEAD ; + dev->rx_urb_size = dev->net->mtu +ETH_HLEN +DM_RX_OVERHEAD ; dev->mii.dev = dev->net; dev->mii.mdio_read = dm9601_mdio_read;
drivers/net/wireless/libertas/11d.c +1 -1
@@ -562,7 +562,7 @@ int libertas_cmd_802_11d_domain_info(wlan_private * priv, nr_subband * sizeof(struct ieeetypes_subbandset)); cmd->size =cpu_to_le16 (sizeof (pdomaininfo->action) + - domain->header.len + +le16_to_cpu (domain->header.len) +sizeof (struct mrvlietypesheader ) +S_DS_GEN ); }else {
drivers/net/wireless/libertas/cmd.c +2 -4
@@ -185,14 +185,12 @@ static int wlan_cmd_802_11_set_wep(wlan_private * priv,switch (pkey->len) {case KEY_LEN_WEP_40 : - wep->keytype[i] = -cpu_to_le16 (cmd_type_wep_40_bit); + wep->keytype[i] = cmd_type_wep_40_bit;memmove (&wep->keymaterial[i], pkey->key, pkey->len);break ;case KEY_LEN_WEP_104 : - wep->keytype[i] = -cpu_to_le16 (cmd_type_wep_104_bit); + wep->keytype[i] = cmd_type_wep_104_bit;memmove (&wep->keymaterial[i], pkey->key, pkey->len);break ;
drivers/net/wireless/libertas/wext.c +4 -4
@@ -973,7 +973,7 @@ static struct iw_statistics *wlan_get_wireless_stats(struct net_device *dev)/* Quality by TX errors */ priv->wstats.discard.retries = priv->stats.tx_errors; - tx_retries =le16_to_cpu (adapter->logmsg.retry); + tx_retries =le32_to_cpu (adapter->logmsg.retry);if (tx_retries >75 ) tx_qual = (90 - tx_retries) *POOR /15 ;
@@ -989,10 +989,10 @@ static struct iw_statistics *wlan_get_wireless_stats(struct net_device *dev) (PERFECT -VERY_GOOD ) /50 +VERY_GOOD ; quality =min (quality, tx_qual); - priv->wstats.discard.code =le16_to_cpu (adapter->logmsg.wepundecryptable); - priv->wstats.discard.fragment =le16_to_cpu (adapter->logmsg.rxfrag); + priv->wstats.discard.code =le32_to_cpu (adapter->logmsg.wepundecryptable); + priv->wstats.discard.fragment =le32_to_cpu (adapter->logmsg.rxfrag); priv->wstats.discard.retries = tx_retries; - priv->wstats.discard.misc =le16_to_cpu (adapter->logmsg.ackfailure); + priv->wstats.discard.misc =le32_to_cpu (adapter->logmsg.ackfailure);/* Calculate quality */ priv->wstats.qual.qual =max (quality, (u32 )100 );
drivers/scsi/esp_scsi.c +2 -1
@@ -2318,6 +2318,7 @@ int __devinit scsi_esp_register(struct esp *esp, struct device *dev) esp->host->transportt = esp_transport_template; esp->host->max_lun =ESP_MAX_LUN ; esp->host->cmd_per_lun =2 ; + esp->host->unique_id = instance;esp_set_clock_params (esp);
@@ -2341,7 +2342,7 @@ int __devinit scsi_esp_register(struct esp *esp, struct device *dev)if (err)return err; - esp->host->unique_id = instance++; + instance++;scsi_scan_host (esp->host);
include/acpi/processor.h +2 -0
@@ -279,6 +279,8 @@ int acpi_processor_power_init(struct acpi_processor *pr,int acpi_processor_cst_has_changed (struct acpi_processor *pr);int acpi_processor_power_exit (struct acpi_processor *pr,struct acpi_device *device); +int acpi_processor_suspend (struct acpi_device * device,pm_message_t state); +int acpi_processor_resume (struct acpi_device * device);/* in processor_thermal.c */ int acpi_processor_get_limit_info (struct acpi_processor *pr);
include/net/rose.h +1 -1
@@ -188,7 +188,7 @@ extern void rose_kick(struct sock *);extern void rose_enquiry_response (struct sock *);/* rose_route.c */ -extern struct rose_neigh rose_loopback_neigh; +extern struct rose_neigh *rose_loopback_neigh;extern const struct file_operations rose_neigh_fops;extern const struct file_operations rose_nodes_fops;extern const struct file_operations rose_routes_fops;
include/net/tcp.h +2 -4
@@ -1061,14 +1061,12 @@ struct tcp_md5sig_key { };struct tcp4_md5sig_key { -u8 *key; -u16 keylen; +struct tcp_md5sig_key base;__be32 addr; };struct tcp6_md5sig_key { -u8 *key; -u16 keylen; +struct tcp_md5sig_key base;#if 0 u32 scope_id;/* XXX */ #endif
kernel/lockdep.c +1 -1
@@ -2166,7 +2166,6 @@ out_calc_hash: }#endif chain_key =iterate_chain_key (chain_key, id); - curr->curr_chain_key = chain_key;/* * Trylock needs to maintain the stack of held locks, but it
@@ -2215,6 +2214,7 @@ out_calc_hash:if (unlikely (!debug_locks))return 0 ; + curr->curr_chain_key = chain_key; curr->lockdep_depth++;check_chain_key (curr);#ifdef CONFIG_DEBUG_LOCKDEP
net/ieee80211/ieee80211_rx.c +6 -0
@@ -366,6 +366,12 @@ int ieee80211_rx(struct ieee80211_device *ieee, struct sk_buff *skb, frag =WLAN_GET_SEQ_FRAG (sc); hdrlen =ieee80211_get_hdrlen (fc); +if (skb->len < hdrlen) { +printk (KERN_INFO "%s: invalid SKB length %d\n" , + dev->name, skb->len); + goto rx_dropped; + } +/* Put this code here so that we avoid duplicating it in all * Rx paths. - Jean II */ #ifdef CONFIG_WIRELESS_EXT
net/ipv4/tcp_input.c +3 -0
@@ -2403,6 +2403,9 @@ static int tcp_tso_acked(struct sock *sk, struct sk_buff *skb,__u32 dval =min (tp->fackets_out, packets_acked); tp->fackets_out -= dval; } +/* hint's skb might be NULL but we don't need to care */ + tp->fastpath_cnt_hint -=min_t (u32, packets_acked, + tp->fastpath_cnt_hint); tp->packets_out -= packets_acked;BUG_ON (tcp_skb_pcount (skb) ==0 );
net/ipv4/tcp_ipv4.c +9 -10
@@ -833,8 +833,7 @@ static struct tcp_md5sig_key *return NULL ;for (i =0 ; i < tp->md5sig_info->entries4; i++) {if (tp->md5sig_info->keys4[i].addr == addr) -return (struct tcp_md5sig_key *) - &tp->md5sig_info->keys4[i]; +return &tp->md5sig_info->keys4[i].base; }return NULL ; }
@@ -865,9 +864,9 @@ int tcp_v4_md5_do_add(struct sock *sk, __be32 addr, key = (struct tcp4_md5sig_key *)tcp_v4_md5_do_lookup (sk, addr);if (key) {/* Pre-existing entry - just update that one. */ -kfree (key->key); - key->key = newkey; - key->keylen = newkeylen; +kfree (key->base.key); + key->base.key = newkey; + key->base.keylen = newkeylen; }else {struct tcp_md5sig_info *md5sig;
@@ -906,9 +905,9 @@ int tcp_v4_md5_do_add(struct sock *sk, __be32 addr, md5sig->alloced4++; } md5sig->entries4++; - md5sig->keys4[md5sig->entries4 -1 ].addr = addr; - md5sig->keys4[md5sig->entries4 -1 ].key = newkey; - md5sig->keys4[md5sig->entries4 -1 ].keylen = newkeylen; + md5sig->keys4[md5sig->entries4 -1 ].addr = addr; + md5sig->keys4[md5sig->entries4 -1 ].base.key = newkey; + md5sig->keys4[md5sig->entries4 -1 ].base.keylen = newkeylen; }return 0 ; }
@@ -930,7 +929,7 @@ int tcp_v4_md5_do_del(struct sock *sk, __be32 addr)for (i =0 ; i < tp->md5sig_info->entries4; i++) {if (tp->md5sig_info->keys4[i].addr == addr) {/* Free the key */ -kfree (tp->md5sig_info->keys4[i].key); +kfree (tp->md5sig_info->keys4[i].base.key); tp->md5sig_info->entries4--;if (tp->md5sig_info->entries4 ==0 ) {
@@ -964,7 +963,7 @@ static void tcp_v4_clear_md5_list(struct sock *sk)if (tp->md5sig_info->entries4) {int i;for (i =0 ; i < tp->md5sig_info->entries4; i++) -kfree (tp->md5sig_info->keys4[i].key); +kfree (tp->md5sig_info->keys4[i].base.key); tp->md5sig_info->entries4 =0 ;tcp_free_md5sig_pool (); }
net/ipv6/addrconf.c +10 -3
@@ -73,6 +73,7 @@#include <net/tcp.h> #include <net/ip.h> #include <net/netlink.h> +#include <net/pkt_sched.h> #include <linux/if_tunnel.h> #include <linux/rtnetlink.h>
@@ -212,6 +213,12 @@ static struct ipv6_devconf ipv6_devconf_dflt __read_mostly = {const struct in6_addr in6addr_any =IN6ADDR_ANY_INIT ;const struct in6_addr in6addr_loopback =IN6ADDR_LOOPBACK_INIT ; +/* Check if a valid qdisc is available */ +static inline int addrconf_qdisc_ok (struct net_device *dev) +{ +return (dev->qdisc != &noop_qdisc); +} +static void addrconf_del_timer (struct inet6_ifaddr *ifp) {if (del_timer (&ifp->timer))
@@ -376,7 +383,7 @@ static struct inet6_dev * ipv6_add_dev(struct net_device *dev) }#endif -if (netif_running (dev) &&netif_carrier_ok (dev)) +if (netif_running (dev) &&addrconf_qdisc_ok (dev)) ndev->if_flags |=IF_READY ;ipv6_mc_init_dev (ndev);
@@ -2269,7 +2276,7 @@ static int addrconf_notify(struct notifier_block *this, unsigned long event,case NETDEV_UP :case NETDEV_CHANGE :if (event ==NETDEV_UP ) { -if (!netif_carrier_ok (dev)) { +if (!addrconf_qdisc_ok (dev)) {/* device is not ready yet. */ printk (KERN_INFO "ADDRCONF(NETDEV_UP): %s: "
@@ -2281,7 +2288,7 @@ static int addrconf_notify(struct notifier_block *this, unsigned long event,if (idev) idev->if_flags |=IF_READY ; }else { -if (!netif_carrier_ok (dev)) { +if (!addrconf_qdisc_ok (dev)) {/* device is still not ready. */ break ; }
net/ipv6/ndisc.c +5 -4
@@ -1268,9 +1268,10 @@ static void ndisc_redirect_rcv(struct sk_buff *skb)if (ipv6_addr_equal (dest, target)) { on_link =1 ; - }else if (!(ipv6_addr_type (target) &IPV6_ADDR_LINKLOCAL )) { + }else if (ipv6_addr_type (target) != + (IPV6_ADDR_UNICAST |IPV6_ADDR_LINKLOCAL )) {ND_PRINTK2 (KERN_WARNING -"ICMPv6 Redirect: target address is not link-local.\n" ); +"ICMPv6 Redirect: target address is not link-local unicast.\n" );return ; }
@@ -1344,9 +1345,9 @@ void ndisc_send_redirect(struct sk_buff *skb, struct neighbour *neigh, }if (!ipv6_addr_equal (&ipv6_hdr (skb)->daddr, target) && - !(ipv6_addr_type (target) &IPV6_ADDR_LINKLOCAL )) { +ipv6_addr_type (target) != (IPV6_ADDR_UNICAST |IPV6_ADDR_LINKLOCAL )) {ND_PRINTK2 (KERN_WARNING -"ICMPv6 Redirect: target address is not link-local.\n" ); +"ICMPv6 Redirect: target address is not link-local unicast.\n" );return ; }
net/ipv6/tcp_ipv6.c +9 -9
@@ -551,7 +551,7 @@ static struct tcp_md5sig_key *tcp_v6_md5_do_lookup(struct sock *sk,for (i =0 ; i < tp->md5sig_info->entries6; i++) {if (ipv6_addr_cmp (&tp->md5sig_info->keys6[i].addr, addr) ==0 ) -return (struct tcp_md5sig_key *)&tp->md5sig_info->keys6[i]; +return &tp->md5sig_info->keys6[i].base; }return NULL ; }
@@ -579,9 +579,9 @@ static int tcp_v6_md5_do_add(struct sock *sk, struct in6_addr *peer, key = (struct tcp6_md5sig_key *)tcp_v6_md5_do_lookup (sk, peer);if (key) {/* modify existing entry - just update that one */ -kfree (key->key); - key->key = newkey; - key->keylen = newkeylen; +kfree (key->base.key); + key->base.key = newkey; + key->base.keylen = newkeylen; }else {/* reallocate new list if current one is full. */ if (!tp->md5sig_info) {
@@ -615,8 +615,8 @@ static int tcp_v6_md5_do_add(struct sock *sk, struct in6_addr *peer,ipv6_addr_copy (&tp->md5sig_info->keys6[tp->md5sig_info->entries6].addr, peer); - tp->md5sig_info->keys6[tp->md5sig_info->entries6].key = newkey; - tp->md5sig_info->keys6[tp->md5sig_info->entries6].keylen = newkeylen; + tp->md5sig_info->keys6[tp->md5sig_info->entries6].base.key = newkey; + tp->md5sig_info->keys6[tp->md5sig_info->entries6].base.keylen = newkeylen; tp->md5sig_info->entries6++; }
@@ -638,7 +638,7 @@ static int tcp_v6_md5_do_del(struct sock *sk, struct in6_addr *peer)for (i =0 ; i < tp->md5sig_info->entries6; i++) {if (ipv6_addr_cmp (&tp->md5sig_info->keys6[i].addr, peer) ==0 ) {/* Free the key */ -kfree (tp->md5sig_info->keys6[i].key); +kfree (tp->md5sig_info->keys6[i].base.key); tp->md5sig_info->entries6--;if (tp->md5sig_info->entries6 ==0 ) {
@@ -669,7 +669,7 @@ static void tcp_v6_clear_md5_list (struct sock *sk)if (tp->md5sig_info->entries6) {for (i =0 ; i < tp->md5sig_info->entries6; i++) -kfree (tp->md5sig_info->keys6[i].key); +kfree (tp->md5sig_info->keys6[i].base.key); tp->md5sig_info->entries6 =0 ;tcp_free_md5sig_pool (); }
@@ -680,7 +680,7 @@ static void tcp_v6_clear_md5_list (struct sock *sk)if (tp->md5sig_info->entries4) {for (i =0 ; i < tp->md5sig_info->entries4; i++) -kfree (tp->md5sig_info->keys4[i].key); +kfree (tp->md5sig_info->keys4[i].base.key); tp->md5sig_info->entries4 =0 ;tcp_free_md5sig_pool (); }
net/mac80211/ieee80211.c +5 -3
@@ -24,6 +24,7 @@#include <linux/compiler.h> #include <linux/bitmap.h> #include <net/cfg80211.h> +#include <asm/unaligned.h> #include "ieee80211_common.h" #include "ieee80211_i.h"
@@ -338,7 +339,7 @@ static int ieee80211_get_radiotap_len(struct sk_buff *skb)struct ieee80211_radiotap_header *hdr = (struct ieee80211_radiotap_header *) skb->data; -return le16_to_cpu (hdr->it_len); +return le16_to_cpu (get_unaligned (&hdr->it_len)); }#ifdef CONFIG_MAC80211_LOWTX_FRAME_DUMP
@@ -2615,9 +2616,10 @@ ieee80211_rx_h_data(struct ieee80211_txrx_data *rx)memcpy (dst, hdr->addr1,ETH_ALEN );memcpy (src, hdr->addr3,ETH_ALEN ); -if (sdata->type !=IEEE80211_IF_TYPE_STA ) { +if (sdata->type !=IEEE80211_IF_TYPE_STA || + (is_multicast_ether_addr (dst) && + !compare_ether_addr (src, dev->dev_addr)))return TXRX_DROP ; - }break ;case 0 :/* DA SA BSSID */
net/rose/rose_loopback.c +2 -2
@@ -79,7 +79,7 @@ static void rose_loopback_timer(unsigned long param)skb_reset_transport_header (skb); - sk =rose_find_socket (lci_o, &rose_loopback_neigh); + sk =rose_find_socket (lci_o, rose_loopback_neigh);if (sk) {if (rose_process_rx_frame (sk, skb) ==0 )kfree_skb (skb);
@@ -88,7 +88,7 @@ static void rose_loopback_timer(unsigned long param)if (frametype ==ROSE_CALL_REQUEST ) {if ((dev =rose_dev_get (dest)) !=NULL ) { -if (rose_rx_call_request (skb, dev, &rose_loopback_neigh, lci_o) ==0 ) +if (rose_rx_call_request (skb, dev, rose_loopback_neigh, lci_o) ==0 )kfree_skb (skb); }else {kfree_skb (skb);
net/rose/rose_route.c +10 -5
@@ -45,7 +45,7 @@ static DEFINE_SPINLOCK(rose_neigh_list_lock);static struct rose_route *rose_route_list;static DEFINE_SPINLOCK (rose_route_list_lock); -struct rose_neigh rose_loopback_neigh; +struct rose_neigh *rose_loopback_neigh;/* * Add a new route to a node, and in the process add the node and the
@@ -362,7 +362,12 @@ out:*/ void rose_add_loopback_neigh (void ) { -struct rose_neigh *sn = &rose_loopback_neigh; +struct rose_neigh *sn; + + rose_loopback_neigh =kmalloc (sizeof (struct rose_neigh ),GFP_KERNEL ); +if (!rose_loopback_neigh) +return ; + sn = rose_loopback_neigh; sn->callsign = null_ax25_address; sn->digipeat =NULL ;
@@ -417,13 +422,13 @@ int rose_add_loopback_node(rose_address *address) rose_node->mask =10 ; rose_node->count =1 ; rose_node->loopback =1 ; - rose_node->neighbour[0 ] = &rose_loopback_neigh; + rose_node->neighbour[0 ] = rose_loopback_neigh;/* Insert at the head of list. Address is always mask=10 */ rose_node->next = rose_node_list; rose_node_list = rose_node; - rose_loopback_neigh.count++; + rose_loopback_neigh->count++; out:spin_unlock_bh (&rose_node_list_lock);
@@ -454,7 +459,7 @@ void rose_del_loopback_node(rose_address *address)rose_remove_node (rose_node); - rose_loopback_neigh.count--; + rose_loopback_neigh->count--; out:spin_unlock_bh (&rose_node_list_lock);
net/sched/cls_u32.c +1 -1
@@ -518,7 +518,7 @@ static int u32_set_parms(struct tcf_proto *tp, unsigned long base,#ifdef CONFIG_NET_CLS_IND if (tb[TCA_U32_INDEV -1 ]) { -int err =tcf_change_indev (tp, n->indev, tb[TCA_U32_INDEV -1 ]); + err =tcf_change_indev (tp, n->indev, tb[TCA_U32_INDEV -1 ]);if (err <0 ) goto errout; }
net/socket.c +0 -3
@@ -778,9 +778,6 @@ static ssize_t sock_aio_write(struct kiocb *iocb, const struct iovec *iov,if (pos !=0 )return -ESPIPE ; -if (iocb->ki_left ==0 )/* Match SYS5 behaviour */ -return 0 ; - x =alloc_sock_iocb (iocb, &siocb);if (!x)return -ENOMEM ;