Linux 3.14.14
Greg KH
maintainerI'm announcing the release of the 3.14.14 kernel.
All users of the 3.14 kernel series must upgrade.
The updated 3.14.y git tree can be found at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-3.14.y
and can be browsed at the normal kernel.org git web browser:
http://git.kernel.org/?p=linux/kernel/git/stable/linux-stable.git;a=summary
thanks,
greg k-h
------------
Makefile | 2 arch/arc/include/uapi/asm/ptrace.h | 1 arch/arc/kernel/ptrace.c | 4 arch/arm/Kconfig | 1 arch/arm/boot/dts/imx25.dtsi | 1 arch/arm/boot/dts/imx27.dtsi | 1 arch/arm/boot/dts/imx51.dtsi | 1 arch/arm/boot/dts/imx53.dtsi | 1 arch/arm64/Kconfig | 1 arch/powerpc/Kconfig | 1 arch/sparc/Kconfig | 1 arch/x86/Kconfig | 1 arch/x86/kernel/cpu/perf_event_intel.c | 9 + arch/x86/kernel/tsc.c | 4 drivers/bluetooth/hci_h5.c | 1 drivers/gpu/drm/qxl/qxl_irq.c | 3 drivers/gpu/drm/radeon/atombios_encoders.c | 10 + drivers/gpu/drm/radeon/radeon_display.c | 5 drivers/hv/hv_kvp.c | 14 ++ drivers/hv/hv_util.c | 2 drivers/hwmon/adt7470.c | 6 - drivers/hwmon/da9052-hwmon.c | 2 drivers/hwmon/da9055-hwmon.c | 2 drivers/iio/industrialio-event.c | 3 drivers/irqchip/irq-gic.c | 7 + drivers/md/dm-cache-metadata.c | 9 + drivers/md/dm-thin-metadata.c | 9 + drivers/media/usb/gspca/pac7302.c | 1 drivers/mtd/devices/elm.c | 2 drivers/net/bonding/bond_main.c | 2 drivers/net/can/slcan.c | 41 +++++--- drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c | 3 drivers/net/ethernet/emulex/benet/be_main.c | 2 drivers/net/ethernet/intel/e1000e/ich8lan.c | 2 drivers/net/ethernet/intel/e1000e/ich8lan.h | 2 drivers/net/ethernet/intel/igb/e1000_82575.c | 7 + drivers/net/ethernet/intel/igb/e1000_defines.h | 18 +-- drivers/net/ethernet/intel/igb/e1000_hw.h | 3 drivers/net/ethernet/intel/igb/e1000_i210.c | 66 ++++++++++++ drivers/net/ethernet/intel/igb/e1000_i210.h | 12 ++ drivers/net/ethernet/intel/igb/e1000_regs.h | 1 drivers/net/ethernet/intel/igb/igb_main.c | 16 +++ drivers/net/ethernet/marvell/mvneta.c | 4 drivers/net/ethernet/sun/sunvnet.c | 20 +++ drivers/net/ppp/pppoe.c | 2 drivers/net/slip/slip.c | 36 +++++-- drivers/net/slip/slip.h | 1 drivers/net/usb/huawei_cdc_ncm.c | 10 + drivers/net/usb/qmi_wwan.c | 3 drivers/net/wireless/iwlwifi/dvm/rxon.c | 12 -- drivers/net/wireless/iwlwifi/mvm/mac-ctxt.c | 8 - drivers/net/wireless/iwlwifi/pcie/drv.c | 3 drivers/net/wireless/mwifiex/main.c | 1 drivers/usb/chipidea/udc.c | 4 drivers/usb/core/hub.c | 19 +++ drivers/xen/balloon.c | 12 -- fs/aio.c | 7 + fs/fuse/dir.c | 7 - fs/fuse/inode.c | 20 +++ fs/quota/dquot.c | 2 include/net/sock.h | 16 +-- kernel/Kconfig.locks | 5 kernel/events/core.c | 2 kernel/power/process.c | 1 kernel/sched/debug.c | 2 kernel/time/alarmtimer.c | 20 +++ kernel/trace/ftrace.c | 4 kernel/trace/ring_buffer.c | 4 kernel/trace/trace.c | 18 +++ kernel/trace/trace_events.c | 1 mm/shmem.c | 104 ++++++++++++++++++-- mm/vmscan.c | 11 -- net/8021q/vlan_core.c | 5 net/8021q/vlan_dev.c | 13 +- net/appletalk/ddp.c | 3 net/core/dev.c | 11 +- net/core/dst.c | 16 ++- net/core/skbuff.c | 3 net/dns_resolver/dns_query.c | 4 net/ipv4/af_inet.c | 3 net/ipv4/gre_offload.c | 3 net/ipv4/icmp.c | 2 net/ipv4/igmp.c | 10 + net/ipv4/ip_options.c | 4 net/ipv4/ip_tunnel.c | 26 ++--- net/ipv4/route.c | 15 +- net/ipv4/tcp.c | 3 net/ipv4/tcp_input.c | 10 - net/ipv4/tcp_offload.c | 2 net/ipv4/tcp_output.c | 6 - net/ipv6/tcpv6_offload.c | 2 net/netlink/af_netlink.c | 4 net/sctp/sysctl.c | 46 ++++----- net/sctp/ulpevent.c | 122 ++---------------------- net/tipc/bcast.c | 1 sound/pci/hda/hda_intel.c | 10 - sound/pci/hda/patch_hdmi.c | 1 97 files changed, 646 insertions(+), 318 deletions(-)
Abbas Raza (1):
usb: chipidea: udc: Disable auto ZLP generation on ep0
Alex Deucher (2):
drm/radeon: set default bl level to something reasonable drm/radeon: avoid leaking edid data
Amitkumar Karwar (1):
mwifiex: fix Tx timeout issue
Anand Avati (1):
fuse: ignore entry-timeout on LOOKUP_REVAL
Andrey Utkin (1):
appletalk: Fix socket referencing in skb
Anton Kolesov (1):
ARC: Implement ptrace(PTRACE_GET_THREAD_AREA)
Axel Lin (2):
hwmon: (da9055) Don't use dash in the name attribute
hwmon: (da9052) Don't use dash in the name attribute
Ben Hutchings (1):
dns_resolver: Null-terminate the right string
Ben Pfaff (1):
netlink: Fix handling of error from netlink_dump().
Benjamin LaHaise (1):
aio: protect reqs_available updates from changes in interrupt handlers
Bernd Wachter (1):
net: qmi_wwan: Add ID for Telewell TW-LTE 4G v2
Bjørn Mork (3):
net: huawei_cdc_ncm: increase command buffer size
net: qmi_wwan: add two Sierra Wireless/Netgear devices
net: huawei_cdc_ncm: add "subclass 3" devices
Christoph Paasch (1):
tcp: Fix divide by zero when pushing during tcp-repair
Christoph Schulz (1):
net: pppoe: use correct channel MTU when using Multilink PPP
Daniel Borkmann (3):
net: sctp: propagate sysctl errors from proc_do* properly
net: sctp: check proc_dointvec result in proc_sctp_do_auth
net: sctp: fix information leaks in ulpevent layer
David Ertman (1):
e1000e: Fix SHRA register access for 82579
David Vrabel (1):
xen/balloon: set ballooned out pages as invalid in p2m
Dmitry Popov (1):
ip_tunnel: fix ip_tunnel_lookup
Edward Allcutt (1):
ipv4: icmp: Fix pMTU handling for rare case
Emmanuel Grumbach (2):
iwlwifi: dvm: don't enable CTS to self
iwlwifi: mvm: disable CTS to Self
Eric Dumazet (6):
ipv4: fix dst race in sk_dst_get()
ipv4: irq safe sk_dst_[re]set() and ipv4_sk_update_pmtu() fix
net: fix sparse warning in sk_dst_set()
vlan: free percpu stats in device destructor
bnx2x: fix possible panic under memory stress
ipv4: fix buffer overflow in ip_options_compile()
Gavin Guo (1):
usb: Check if port status is equal to RxDetect
Greg Kroah-Hartman (1):
Linux 3.14.14
Guenter Roeck (1):
hwmon: (adt7470) Fix writes to temperature limit registers
HATAYAMA Daisuke (1):
perf/x86/intel: ignore CondChgd bit to avoid false NMI handling
Hans de Goede (1):
media: gspca_pac7302: Add new usb-id for Genius i-Look 317
Hugh Dickins (3):
shmem: fix faulting into a hole while it's punched
shmem: fix faulting into a hole, not taking i_mutex
shmem: fix splicing from a hole while it's punched
Jason Wang (1):
drm/qxl: return IRQ_NONE if it was not our irq
Jerry Chu (1):
net-gre-gro: Fix a bug that breaks the forwarding path
Jiri Olsa (1):
perf: Do not allow optimized switch for non-cloned events
John Stultz (1):
alarmtimer: Fix bug where relative alarm timers were treated as absolute
Jon Paul Maloy (1):
tipc: clear 'next'-pointer of message fragments before reassembly
K. Y. Srinivasan (1):
Drivers: hv: util: Fix a bug in the KVP code
Li RongQing (1):
8021q: fix a potential memory leak
Linus Torvalds (1):
Don't trigger congestion wait on dirty-but-not-writeout pages
Loic Poulain (1):
Bluetooth: Ignore H5 non-link packets in non-active state
Loic Prylli (1):
net: Fix NETDEV_CHANGE notifier usage causing spurious arp flush
Manuel Schölling (1):
dns_resolver: assure that dns_query() result is null-terminated
Marek Vasut (1):
ARM: dts: imx: Add alias for ethernet controller
Martin Lau (1):
ring-buffer: Fix polling on trace_pipe
Mateusz Guzik (1):
sched: Fix possible divide by zero in avg_atom() calculation
Matthias Brugger (1):
irqchip: gic: Add support for cortex a7 compatible string
Mengdong Lin (1):
ALSA: hda - initialize audio InfoFrame to be all zero
Mike Snitzer (2):
dm thin metadata: do not allow the data block size to change dm cache metadata: do not allow the data block size to change
Miklos Szeredi (2):
fuse: timeout comparison fix
fuse: handle large user and group ID
Neal Cardwell (1):
tcp: fix tcp_match_skb_to_sack() for unaligned SACK at end of an skb
Nikolay Aleksandrov (1):
bonding: fix ad_select module param check
Niu Yawei (1):
quota: missing lock in dqcache_shrink_scan()
Oleg Nesterov (1):
tracing: instance_rmdir() leaks ftrace_event_file->filter
Oren Givon (1):
iwlwifi: update the 7265 series HW IDs
Peter Zijlstra (2):
x86, tsc: Fix cpufreq lockup
locking/mutex: Disable optimistic spinning on some architectures
Sowmini Varadhan (1):
sunvnet: clean up objects created in vnet_new() on vnet_exit()
Srinivas Pandruvada (1):
iio:core: Handle error when mask type is not separate
Stefan Assmann (1):
igb: do a reset on SR-IOV re-init if device is down
Steven Rostedt (Red Hat) (1):
tracing: Fix graph tracer with stack tracer on other archs
Suravee Suthikulpanit (1):
irqchip: gic: Add binding probe for ARM GIC400
Suresh Reddy (1):
be2net: set EQ DB clear-intr bit in be_open()
Takashi Iwai (2):
ALSA: hda - Fix broken PM due to incomplete i915 initialization PM / sleep: Fix request_firmware() error at resume
Ted Juan (1):
mtd: devices: elm: fix elm_context_save() and elm_context_restore() functions
Thomas Fitzsimmons (1):
net: mvneta: Fix big endian issue in mvneta_txq_desc_csum()
Thomas Petazzoni (1):
net: mvneta: fix operation in 10 Mbit/s mode
Todd Fujinaka (1):
igb: Workaround for i210 Errata 25: Slow System Clock
Tomasz Figa (1):
irqchip: gic: Fix core ID calculation when topology is read from DT
Tyler Hall (2):
slip: Fix deadlock in write_wakeup
slcan: Port write_wakeup deadlock fix from slip
Wei-Chun Chao (1):
net: fix UDP tunnel GSO of frag_list GRO packets
Yuchung Cheng (1):
tcp: fix false undo corner cases
dingtianhong (1):
igmp: fix the problem when mc leave group
zhangwei(Jovi) (2):
tracing: Add ftrace_trace_stack into __trace_puts/__trace_bputs
tracing: Add TRACE_ITER_PRINTK flag check in __trace_puts/__trace_bputs
Greg KH
maintainerMakefile +1 -1
@@ -1,6 +1,6 @@ VERSION = 3 PATCHLEVEL = 14 -SUBLEVEL = 13 +SUBLEVEL = 14 EXTRAVERSION = NAME = Remembering Coco
arch/arc/include/uapi/asm/ptrace.h +1 -0
@@ -11,6 +11,7 @@#ifndef _UAPI__ASM_ARC_PTRACE_H#define _UAPI__ASM_ARC_PTRACE_H +#define PTRACE_GET_THREAD_AREA 25#ifndef __ASSEMBLY__/*
arch/arc/kernel/ptrace.c +4 -0
@@ -146,6 +146,10 @@ long arch_ptrace(struct task_struct *child, long request,pr_debug ("REQ=%ld: ADDR =0x%lx, DATA=0x%lx)\n" , request, addr, data);switch (request) { +case PTRACE_GET_THREAD_AREA : + ret =put_user (task_thread_info (child)->thr_ptr, + (unsigned long __user *)data); +break ;default : ret =ptrace_request (child, request, addr, data);break ;
arch/arm/Kconfig +1 -0
@@ -6,6 +6,7 @@ config ARM select ARCH_HAS_TICK_BROADCAST if GENERIC_CLOCKEVENTS_BROADCAST select ARCH_HAVE_CUSTOM_GPIO_H select ARCH_MIGHT_HAVE_PC_PARPORT + select ARCH_SUPPORTS_ATOMIC_RMW select ARCH_USE_BUILTIN_BSWAP select ARCH_USE_CMPXCHG_LOCKREF select ARCH_WANT_IPC_PARSE_VERSION
arch/arm/boot/dts/imx25.dtsi +1 -0
@@ -30,6 +30,7 @@ spi2 = &spi3; usb0 = &usbotg; usb1 = &usbhost1; + ethernet0 = &fec; }; cpus {
arch/arm/boot/dts/imx27.dtsi +1 -0
@@ -30,6 +30,7 @@ spi0 = &cspi1; spi1 = &cspi2; spi2 = &cspi3; + ethernet0 = &fec; }; aitc: aitc-interrupt-controller@e0000000 {
arch/arm/boot/dts/imx51.dtsi +1 -0
@@ -27,6 +27,7 @@ spi0 = &ecspi1; spi1 = &ecspi2; spi2 = &cspi; + ethernet0 = &fec; }; tzic: tz-interrupt-controller@e0000000 {
arch/arm/boot/dts/imx53.dtsi +1 -0
@@ -33,6 +33,7 @@ spi0 = &ecspi1; spi1 = &ecspi2; spi2 = &cspi; + ethernet0 = &fec; }; cpus {
arch/arm64/Kconfig +1 -0
@@ -2,6 +2,7 @@ config ARM64 def_bool y select ARCH_HAS_ATOMIC64_DEC_IF_POSITIVE select ARCH_USE_CMPXCHG_LOCKREF + select ARCH_SUPPORTS_ATOMIC_RMW select ARCH_HAS_TICK_BROADCAST if GENERIC_CLOCKEVENTS_BROADCAST select ARCH_WANT_OPTIONAL_GPIOLIB select ARCH_WANT_COMPAT_IPC_PARSE_VERSION
arch/powerpc/Kconfig +1 -0
@@ -141,6 +141,7 @@ config PPC select HAVE_DEBUG_STACKOVERFLOW select HAVE_IRQ_EXIT_ON_IRQ_STACK select ARCH_USE_CMPXCHG_LOCKREF if PPC64 + select ARCH_SUPPORTS_ATOMIC_RMW config GENERIC_CSUM def_bool CPU_LITTLE_ENDIAN
arch/sparc/Kconfig +1 -0
@@ -77,6 +77,7 @@ config SPARC64 select ARCH_HAVE_NMI_SAFE_CMPXCHG select HAVE_C_RECORDMCOUNT select NO_BOOTMEM + select ARCH_SUPPORTS_ATOMIC_RMW config ARCH_DEFCONFIG string
arch/x86/Kconfig +1 -0
@@ -127,6 +127,7 @@ config X86 select HAVE_DEBUG_STACKOVERFLOW select HAVE_IRQ_EXIT_ON_IRQ_STACK if X86_64 select HAVE_CC_STACKPROTECTOR + select ARCH_SUPPORTS_ATOMIC_RMW config INSTRUCTION_DECODER def_bool y
arch/x86/kernel/cpu/perf_event_intel.c +9 -0
@@ -1383,6 +1383,15 @@ again:intel_pmu_lbr_read ();/* +* CondChgd bit 63 doesn't mean any overflow status. Ignore +* and clear the bit. +*/ +if (__test_and_clear_bit (63 , (unsigned long *)&status)) { +if (!status) + goto done; + } + +/* * PEBS overflow sets bit 62 in the global status register */ if (__test_and_clear_bit (62 , (unsigned long *)&status)) {
arch/x86/kernel/tsc.c +2 -2
@@ -921,9 +921,9 @@ static int time_cpufreq_notifier(struct notifier_block *nb, unsigned long val, tsc_khz =cpufreq_scale (tsc_khz_ref, ref_freq, freq->new);if (!(freq->flags &CPUFREQ_CONST_LOOPS ))mark_tsc_unstable ("cpufreq changes" ); - } -set_cyc2ns_scale (tsc_khz, freq->cpu); +set_cyc2ns_scale (tsc_khz, freq->cpu); + }return 0 ; }
drivers/bluetooth/hci_h5.c +1 -0
@@ -406,6 +406,7 @@ static int h5_rx_3wire_hdr(struct hci_uart *hu, unsigned char c) H5_HDR_PKT_TYPE(hdr) != HCI_3WIRE_LINK_PKT) {BT_ERR ("Non-link packet received in non-active state" );h5_reset_rx (h5); +return 0 ; } h5->rx_func = h5_rx_payload;
drivers/gpu/drm/qxl/qxl_irq.c +3 -0
@@ -33,6 +33,9 @@ irqreturn_t qxl_irq_handler(int irq, void *arg) pending =xchg (&qdev->ram_header->int_pending,0 ); +if (!pending) +return IRQ_NONE ; +atomic_inc (&qdev->irq_received);if (pending &QXL_INTERRUPT_DISPLAY ) {
drivers/gpu/drm/radeon/atombios_encoders.c +7 -3
@@ -183,7 +183,6 @@ void radeon_atom_backlight_init(struct radeon_encoder *radeon_encoder,struct backlight_properties props;struct radeon_backlight_privdata *pdata;struct radeon_encoder_atom_dig *dig; -u8 backlight_level;char bl_name[16 ];/* Mac laptops with multiple GPUs use the gmux driver for backlight
@@ -222,12 +221,17 @@ void radeon_atom_backlight_init(struct radeon_encoder *radeon_encoder, pdata->encoder = radeon_encoder; - backlight_level =radeon_atom_get_backlight_level_from_reg (rdev); - dig = radeon_encoder->enc_priv; dig->bl_dev = bd; bd->props.brightness =radeon_atom_backlight_get_brightness (bd); +/* Set a reasonable default here if the level is 0 otherwise +* fbdev will attempt to turn the backlight on after console +* unblanking and it will try and restore 0 which turns the backlight +* off again. +*/ +if (bd->props.brightness ==0 ) + bd->props.brightness =RADEON_MAX_BL_LEVEL ; bd->props.power =FB_BLANK_UNBLANK ;backlight_update_status (bd);
drivers/gpu/drm/radeon/radeon_display.c +5 -0
@@ -755,6 +755,10 @@ int radeon_ddc_get_modes(struct radeon_connector *radeon_connector)struct radeon_device *rdev = dev->dev_private;int ret =0 ; +/* don't leak the edid if we already fetched it in detect() */ +if (radeon_connector->edid) + goto got_edid; +/* on hw with routers, select right port */ if (radeon_connector->router.ddc_valid)radeon_router_select_ddc_port (radeon_connector);
@@ -794,6 +798,7 @@ int radeon_ddc_get_modes(struct radeon_connector *radeon_connector) radeon_connector->edid =radeon_bios_get_hardcoded_edid (rdev); }if (radeon_connector->edid) { +got_edid:drm_mode_connector_update_edid_property (&radeon_connector->base, radeon_connector->edid); ret =drm_add_edid_modes (&radeon_connector->base, radeon_connector->edid);drm_edid_to_eld (&radeon_connector->base, radeon_connector->edid);
drivers/hv/hv_kvp.c +12 -2
@@ -127,6 +127,15 @@ kvp_work_func(struct work_struct *dummy)kvp_respond_to_host (NULL ,HV_E_FAIL ); } +static void poll_channel (struct vmbus_channel *channel) +{ +unsigned long flags; + +spin_lock_irqsave (&channel->inbound_lock, flags); +hv_kvp_onchannelcallback (channel); +spin_unlock_irqrestore (&channel->inbound_lock, flags); +} +static int kvp_handle_handshake (struct hv_kvp_msg *msg) {int ret =1 ;
@@ -155,7 +164,7 @@ static int kvp_handle_handshake(struct hv_kvp_msg *msg)kvp_register (dm_reg_value); kvp_transaction.active = false;if (kvp_transaction.kvp_context) -hv_kvp_onchannelcallback (kvp_transaction.kvp_context); +poll_channel (kvp_transaction.kvp_context); }return ret; }
@@ -568,6 +577,7 @@ response_done:vmbus_sendpacket (channel, recv_buffer, buf_len, req_id,VM_PKT_DATA_INBAND ,0 ); +poll_channel (channel); }
@@ -603,7 +613,7 @@ void hv_kvp_onchannelcallback(void *context)return ; } -vmbus_recvpacket (channel, recv_buffer,PAGE_SIZE *2 , &recvlen, +vmbus_recvpacket (channel, recv_buffer,PAGE_SIZE *4 , &recvlen, &requestid);if (recvlen >0 ) {
drivers/hv/hv_util.c +1 -1
@@ -312,7 +312,7 @@ static int util_probe(struct hv_device *dev, (struct hv_util_service *)dev_id->driver_data;int ret; - srv->recv_buffer =kmalloc (PAGE_SIZE *2 ,GFP_KERNEL ); + srv->recv_buffer =kmalloc (PAGE_SIZE *4 ,GFP_KERNEL );if (!srv->recv_buffer)return -ENOMEM ;if (srv->util_init) {
drivers/hwmon/adt7470.c +3 -3
@@ -515,7 +515,7 @@ static ssize_t set_temp_min(struct device *dev,return -EINVAL ; temp =DIV_ROUND_CLOSEST (temp,1000 ); - temp =clamp_val (temp,0 ,255 ); + temp =clamp_val (temp,-128 ,127 );mutex_lock (&data->lock); data->temp_min[attr->index] = temp;
@@ -549,7 +549,7 @@ static ssize_t set_temp_max(struct device *dev,return -EINVAL ; temp =DIV_ROUND_CLOSEST (temp,1000 ); - temp =clamp_val (temp,0 ,255 ); + temp =clamp_val (temp,-128 ,127 );mutex_lock (&data->lock); data->temp_max[attr->index] = temp;
@@ -826,7 +826,7 @@ static ssize_t set_pwm_tmin(struct device *dev,return -EINVAL ; temp =DIV_ROUND_CLOSEST (temp,1000 ); - temp =clamp_val (temp,0 ,255 ); + temp =clamp_val (temp,-128 ,127 );mutex_lock (&data->lock); data->pwm_tmin[attr->index] = temp;
drivers/hwmon/da9052-hwmon.c +1 -1
@@ -194,7 +194,7 @@ static ssize_t da9052_hwmon_show_name(struct device *dev,struct device_attribute *devattr, char *buf) { - return sprintf(buf, "da9052-hwmon\n"); + return sprintf(buf, "da9052\n"); } static ssize_t show_label(struct device *dev,
drivers/hwmon/da9055-hwmon.c +1 -1
@@ -204,7 +204,7 @@ static ssize_t da9055_hwmon_show_name(struct device *dev,struct device_attribute *devattr, char *buf) { - return sprintf(buf, "da9055-hwmon\n"); + return sprintf(buf, "da9055\n"); } static ssize_t show_label(struct device *dev,
drivers/iio/industrialio-event.c +3 -0
@@ -343,6 +343,9 @@ static int iio_device_add_event(struct iio_dev *indio_dev, &indio_dev->event_interface->dev_attr_list);kfree (postfix); +if ((ret == -EBUSY ) && (shared_by !=IIO_SEPARATE )) +continue ; +if (ret)return ret;
drivers/irqchip/irq-gic.c +6 -1
@@ -42,6 +42,7 @@#include <linux/irqchip/chained_irq.h> #include <linux/irqchip/arm-gic.h> +#include <asm/cputype.h> #include <asm/irq.h> #include <asm/exception.h> #include <asm/smp_plat.h>
@@ -903,7 +904,9 @@ void __init gic_init_bases(unsigned int gic_nr, int irq_start, }for_each_possible_cpu (cpu) { -unsigned long offset = percpu_offset *cpu_logical_map (cpu); +u32 mpidr =cpu_logical_map (cpu); +u32 core_id =MPIDR_AFFINITY_LEVEL (mpidr,0 ); +unsigned long offset = percpu_offset * core_id; *per_cpu_ptr (gic->dist_base.percpu_base, cpu) = dist_base + offset; *per_cpu_ptr (gic->cpu_base.percpu_base, cpu) = cpu_base + offset; }
@@ -1008,8 +1011,10 @@ int __init gic_of_init(struct device_node *node, struct device_node *parent) gic_cnt++;return 0 ; } +IRQCHIP_DECLARE (gic_400,"arm,gic-400" , gic_of_init);IRQCHIP_DECLARE (cortex_a15_gic,"arm,cortex-a15-gic" , gic_of_init);IRQCHIP_DECLARE (cortex_a9_gic,"arm,cortex-a9-gic" , gic_of_init); +IRQCHIP_DECLARE (cortex_a7_gic,"arm,cortex-a7-gic" , gic_of_init);IRQCHIP_DECLARE (msm_8660_qgic,"qcom,msm-8660-qgic" , gic_of_init);IRQCHIP_DECLARE (msm_qgic2,"qcom,msm-qgic2" , gic_of_init);
drivers/md/dm-cache-metadata.c +9 -0
@@ -425,6 +425,15 @@ static int __open_metadata(struct dm_cache_metadata *cmd) disk_super =dm_block_data (sblock); +/* Verify the data block size hasn't changed */ +if (le32_to_cpu (disk_super->data_block_size) != cmd->data_block_size) { +DMERR ("changing the data block size (from %u to %llu) is not supported" , +le32_to_cpu (disk_super->data_block_size), + (unsigned long long )cmd->data_block_size); + r = -EINVAL ; + goto bad; + } + r =__check_incompat_features (disk_super, cmd);if (r <0 ) goto bad;
drivers/md/dm-thin-metadata.c +9 -0
@@ -613,6 +613,15 @@ static int __open_metadata(struct dm_pool_metadata *pmd) disk_super =dm_block_data (sblock); +/* Verify the data block size hasn't changed */ +if (le32_to_cpu (disk_super->data_block_size) != pmd->data_block_size) { +DMERR ("changing the data block size (from %u to %llu) is not supported" , +le32_to_cpu (disk_super->data_block_size), + (unsigned long long )pmd->data_block_size); + r = -EINVAL ; + goto bad_unlock_sblock; + } + r =__check_incompat_features (disk_super, pmd);if (r <0 ) goto bad_unlock_sblock;
drivers/media/usb/gspca/pac7302.c +1 -0
@@ -928,6 +928,7 @@ static const struct usb_device_id device_table[] = { {USB_DEVICE(0x093a, 0x2620)}, {USB_DEVICE(0x093a, 0x2621)}, {USB_DEVICE(0x093a, 0x2622), .driver_info = FL_VFLIP}, + {USB_DEVICE(0x093a, 0x2623), .driver_info = FL_VFLIP}, {USB_DEVICE(0x093a, 0x2624), .driver_info = FL_VFLIP}, {USB_DEVICE(0x093a, 0x2625)}, {USB_DEVICE(0x093a, 0x2626)},
drivers/mtd/devices/elm.c +2 -0
@@ -428,6 +428,7 @@ static int elm_context_save(struct elm_info *info) ELM_SYNDROME_FRAGMENT_1 + offset); regs->elm_syndrome_fragment_0[i] =elm_read_reg (info,ELM_SYNDROME_FRAGMENT_0 + offset); +break ;default :return -EINVAL ; }
@@ -466,6 +467,7 @@ static int elm_context_restore(struct elm_info *info) regs->elm_syndrome_fragment_1[i]);elm_write_reg (info,ELM_SYNDROME_FRAGMENT_0 + offset, regs->elm_syndrome_fragment_0[i]); +break ;default :return -EINVAL ; }
drivers/net/bonding/bond_main.c +1 -1
@@ -4068,7 +4068,7 @@ static int bond_check_params(struct bond_params *params) }if (ad_select) { -bond_opt_initstr (&newval, lacp_rate); +bond_opt_initstr (&newval, ad_select); valptr =bond_opt_parse (bond_opt_get (BOND_OPT_AD_SELECT ), &newval);if (!valptr) {
drivers/net/can/slcan.c +29 -12
89 lines not on this page · raw message
drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c +2 -1
@@ -793,7 +793,8 @@ static void bnx2x_tpa_stop(struct bnx2x *bp, struct bnx2x_fastpath *fp,return ; } -bnx2x_frag_free (fp, new_data); +if (new_data) +bnx2x_frag_free (fp, new_data); drop:/* drop the packet and keep the buffer in the bin */ DP(NETIF_MSG_RX_STATUS,
drivers/net/ethernet/emulex/benet/be_main.c +1 -1
@@ -2797,7 +2797,7 @@ static int be_open(struct net_device *netdev) for_all_evt_queues(adapter, eqo, i) {napi_enable (&eqo->napi);be_enable_busy_poll (eqo); -be_eq_notify (adapter, eqo->q.id, true, false,0 ); +be_eq_notify (adapter, eqo->q.id, true, true,0 ); } adapter->flags |=BE_FLAGS_NAPI_ENABLED ;
drivers/net/ethernet/intel/e1000e/ich8lan.c +1 -1
@@ -1374,7 +1374,7 @@ static void e1000_rar_set_pch2lan(struct e1000_hw *hw, u8 *addr, u32 index)/* RAR[1-6] are owned by manageability. Skip those and program the * next address into the SHRA register array. */ -if (index < (u32)(hw->mac.rar_entry_count -6 )) { +if (index < (u32)(hw->mac.rar_entry_count)) {s32 ret_val; ret_val =e1000_acquire_swflag_ich8lan (hw);
drivers/net/ethernet/intel/e1000e/ich8lan.h +1 -1
@@ -98,7 +98,7 @@#define PCIE_ICH8_SNOOP_ALL PCIE_NO_SNOOP_ALL#define E1000_ICH_RAR_ENTRIES 7 -#define E1000_PCH2_RAR_ENTRIES 11/* RAR[0-6], SHRA[0-3] */ +#define E1000_PCH2_RAR_ENTRIES 5/* RAR[0], SHRA[0-3] */ #define E1000_PCH_LPT_RAR_ENTRIES 12/* RAR[0], SHRA[0-10] */ #define PHY_PAGE_SHIFT 5
drivers/net/ethernet/intel/igb/e1000_82575.c +7 -0
@@ -1492,6 +1492,13 @@ static s32 igb_init_hw_82575(struct e1000_hw *hw)s32 ret_val;u16 i, rar_count = mac->rar_entry_count; +if ((hw->mac.type >= e1000_i210) && + !(igb_get_flash_presence_i210 (hw))) { + ret_val =igb_pll_workaround_i210 (hw); +if (ret_val) +return ret_val; + } +/* Initialize identification LED */ ret_val =igb_id_led_init (hw);if (ret_val) {
drivers/net/ethernet/intel/igb/e1000_defines.h +10 -8
@@ -46,14 +46,15 @@/* Extended Device Control */ #define E1000_CTRL_EXT_SDP3_DATA 0x00000080/* Value of SW Defineable Pin 3 */ /* Physical Func Reset Done Indication */ -#define E1000_CTRL_EXT_PFRSTD 0x00004000 -#define E1000_CTRL_EXT_LINK_MODE_MASK 0x00C00000 -#define E1000_CTRL_EXT_LINK_MODE_PCIE_SERDES 0x00C00000 -#define E1000_CTRL_EXT_LINK_MODE_1000BASE_KX 0x00400000 -#define E1000_CTRL_EXT_LINK_MODE_SGMII 0x00800000 -#define E1000_CTRL_EXT_LINK_MODE_GMII 0x00000000 -#define E1000_CTRL_EXT_EIAME 0x01000000 -#define E1000_CTRL_EXT_IRCA 0x00000001 +#define E1000_CTRL_EXT_PFRSTD 0x00004000 +#define E1000_CTRL_EXT_SDLPE 0X00040000/* SerDes Low Power Enable */ +#define E1000_CTRL_EXT_LINK_MODE_MASK 0x00C00000 +#define E1000_CTRL_EXT_LINK_MODE_PCIE_SERDES 0x00C00000 +#define E1000_CTRL_EXT_LINK_MODE_1000BASE_KX 0x00400000 +#define E1000_CTRL_EXT_LINK_MODE_SGMII 0x00800000 +#define E1000_CTRL_EXT_LINK_MODE_GMII 0x00000000 +#define E1000_CTRL_EXT_EIAME 0x01000000 +#define E1000_CTRL_EXT_IRCA 0x00000001/* Interrupt delay cancellation */ /* Driver loaded bit for FW */ #define E1000_CTRL_EXT_DRV_LOAD 0x10000000
@@ -62,6 +63,7 @@/* packet buffer parity error detection enabled */ /* descriptor FIFO parity error detection enable */ #define E1000_CTRL_EXT_PBA_CLR 0x80000000/* PBA Clear */ +#define E1000_CTRL_EXT_PHYPDEN 0x00100000#define E1000_I2CCMD_REG_ADDR_SHIFT 16#define E1000_I2CCMD_PHY_ADDR_SHIFT 24#define E1000_I2CCMD_OPCODE_READ 0x08000000
drivers/net/ethernet/intel/igb/e1000_hw.h +3 -0
@@ -572,4 +572,7 @@ struct net_device *igb_get_hw_dev(struct e1000_hw *hw);/* These functions must be implemented by drivers */ s32 igb_read_pcie_cap_reg (struct e1000_hw *hw,u32 reg,u16 *value);s32 igb_write_pcie_cap_reg (struct e1000_hw *hw,u32 reg,u16 *value); + +void igb_read_pci_cfg (struct e1000_hw *hw,u32 reg,u16 *value); +void igb_write_pci_cfg (struct e1000_hw *hw,u32 reg,u16 *value);#endif /* _E1000_HW_H_ */
drivers/net/ethernet/intel/igb/e1000_i210.c +66 -0
69 lines not on this page · raw message
drivers/net/ethernet/intel/igb/e1000_i210.h +12 -0
@@ -46,6 +46,7 @@ s32 igb_read_xmdio_reg(struct e1000_hw *hw, u16 addr, u8 dev_addr, u16 *data);s32 igb_write_xmdio_reg (struct e1000_hw *hw,u16 addr,u8 dev_addr,u16 data);s32 igb_init_nvm_params_i210 (struct e1000_hw *hw);bool igb_get_flash_presence_i210 (struct e1000_hw *hw); +s32 igb_pll_workaround_i210 (struct e1000_hw *hw);#define E1000_STM_OPCODE 0xDB00#define E1000_EEPROM_FLASH_SIZE_WORD 0x11
@@ -91,4 +92,15 @@ enum E1000_INVM_STRUCTURE_TYPE {#define NVM_LED_1_CFG_DEFAULT_I211 0x0184#define NVM_LED_0_2_CFG_DEFAULT_I211 0x200C +/* PLL Defines */ +#define E1000_PCI_PMCSR 0x44 +#define E1000_PCI_PMCSR_D3 0x03 +#define E1000_MAX_PLL_TRIES 5 +#define E1000_PHY_PLL_UNCONF 0xFF +#define E1000_PHY_PLL_FREQ_PAGE 0xFC0000 +#define E1000_PHY_PLL_FREQ_REG 0x000E +#define E1000_INVM_DEFAULT_AL 0x202F +#define E1000_INVM_AUTOLOAD 0x0A +#define E1000_INVM_PLL_WO_VAL 0x0010 +#endif
drivers/net/ethernet/intel/igb/e1000_regs.h +1 -0
@@ -69,6 +69,7 @@#define E1000_PBA 0x01000/* Packet Buffer Allocation - RW */ #define E1000_PBS 0x01008/* Packet Buffer Size */ #define E1000_EEMNGCTL 0x01010/* MNG EEprom Control */ +#define E1000_EEARBC_I210 0x12024/* EEPROM Auto Read Bus Control */ #define E1000_EEWR 0x0102C/* EEPROM Write Register - RW */ #define E1000_I2CCMD 0x01028/* SFPI2C Command Register - RW */ #define E1000_FRTIMER 0x01048/* Free Running Timer - RW */
drivers/net/ethernet/intel/igb/igb_main.c +16 -0
@@ -7128,6 +7128,20 @@ static int igb_ioctl(struct net_device *netdev, struct ifreq *ifr, int cmd) } } +void igb_read_pci_cfg (struct e1000_hw *hw,u32 reg,u16 *value) +{ +struct igb_adapter *adapter = hw->back; + +pci_read_config_word (adapter->pdev, reg, value); +} + +void igb_write_pci_cfg (struct e1000_hw *hw,u32 reg,u16 *value) +{ +struct igb_adapter *adapter = hw->back; + +pci_write_config_word (adapter->pdev, reg, *value); +} +s32 igb_read_pcie_cap_reg (struct e1000_hw *hw,u32 reg,u16 *value) {struct igb_adapter *adapter = hw->back;
@@ -7491,6 +7505,8 @@ static int igb_sriov_reinit(struct pci_dev *dev)if (netif_running (netdev))igb_close (netdev); +else +igb_reset (adapter);igb_clear_interrupt_scheme (adapter);
drivers/net/ethernet/marvell/mvneta.c +2 -2
@@ -1217,7 +1217,7 @@ static u32 mvneta_txq_desc_csum(int l3_offs, int l3_proto, command = l3_offs <<MVNETA_TX_L3_OFF_SHIFT ; command |= ip_hdr_len <<MVNETA_TX_IP_HLEN_SHIFT ; -if (l3_proto ==swab16 (ETH_P_IP )) +if (l3_proto ==htons (ETH_P_IP )) command |=MVNETA_TXD_IP_CSUM ;else command |=MVNETA_TX_L3_IP6 ;
@@ -2393,7 +2393,7 @@ static void mvneta_adjust_link(struct net_device *ndev)if (phydev->speed ==SPEED_1000 ) val |=MVNETA_GMAC_CONFIG_GMII_SPEED ; -else +else if (phydev->speed ==SPEED_100 ) val |=MVNETA_GMAC_CONFIG_MII_SPEED ;mvreg_write (pp,MVNETA_GMAC_AUTONEG_CONFIG , val);
drivers/net/ethernet/sun/sunvnet.c +19 -1
@@ -1083,6 +1083,24 @@ static struct vnet *vnet_find_or_create(const u64 *local_mac)return vp; } +static void vnet_cleanup (void ) +{ +struct vnet *vp; +struct net_device *dev; + +mutex_lock (&vnet_list_mutex); +while (!list_empty (&vnet_list)) { + vp = list_first_entry(&vnet_list, struct vnet, list); +list_del (&vp->list); + dev = vp->dev; +/* vio_unregister_driver() should have cleaned up port_list */ +BUG_ON (!list_empty (&vp->port_list)); +unregister_netdev (dev); +free_netdev (dev); + } +mutex_unlock (&vnet_list_mutex); +} +static const char *local_mac_prop ="local-mac-address" ; static struct vnet *vnet_find_parent(struct mdesc_handle *hp,
@@ -1240,7 +1258,6 @@ static int vnet_port_remove(struct vio_dev *vdev)kfree (port); -unregister_netdev (vp->dev); }return 0 ; }
@@ -1268,6 +1285,7 @@ static int __init vnet_init(void) static void __exit vnet_exit(void) {vio_unregister_driver (&vnet_port_driver); +vnet_cleanup (); }module_init (vnet_init);
drivers/net/ppp/pppoe.c +1 -1
@@ -675,7 +675,7 @@ static int pppoe_connect(struct socket *sock, struct sockaddr *uservaddr, po->chan.hdrlen = (sizeof (struct pppoe_hdr ) + dev->hard_header_len); - po->chan.mtu = dev->mtu -sizeof (struct pppoe_hdr ); + po->chan.mtu = dev->mtu -sizeof (struct pppoe_hdr ) -2 ; po->chan.private = sk; po->chan.ops = &pppoe_chan_ops;
drivers/net/slip/slip.c +26 -10
@@ -83,6 +83,7 @@#include <linux/delay.h> #include <linux/init.h> #include <linux/slab.h> +#include <linux/workqueue.h> #include "slip.h" #ifdef CONFIG_INET #include <linux/ip.h>
@@ -416,36 +417,46 @@ static void sl_encaps(struct slip *sl, unsigned char *icp, int len)#endif } -/* -* Called by the driver when there's room for more data. If we have -* more packets to send, we send them here. -*/ -static void slip_write_wakeup (struct tty_struct *tty) +/* Write out any remaining transmit buffer. Scheduled when tty is writable */ +static void slip_transmit (struct work_struct *work) { + struct slip *sl = container_of(work, struct slip, tx_work);int actual; -struct slip *sl = tty->disc_data; +spin_lock_bh (&sl->lock);/* First make sure we're connected. */ -if (!sl || sl->magic !=SLIP_MAGIC || !netif_running (sl->dev)) +if (!sl->tty || sl->magic !=SLIP_MAGIC || !netif_running (sl->dev)) { +spin_unlock_bh (&sl->lock);return ; + } -spin_lock_bh (&sl->lock);if (sl->xleft <=0 ) {/* Now serial buffer is almost free & we can start * transmission of another packet */ sl->dev->stats.tx_packets++; -clear_bit (TTY_DO_WRITE_WAKEUP , &tty->flags); +clear_bit (TTY_DO_WRITE_WAKEUP , &sl->tty->flags);spin_unlock_bh (&sl->lock);sl_unlock (sl);return ; } - actual = tty->ops->write (tty, sl->xhead, sl->xleft); + actual = sl->tty->ops->write (sl->tty, sl->xhead, sl->xleft); sl->xleft -= actual; sl->xhead += actual;spin_unlock_bh (&sl->lock); } +/* +* Called by the driver when there's room for more data. +* Schedule the transmit. +*/ +static void slip_write_wakeup (struct tty_struct *tty) +{ +struct slip *sl = tty->disc_data; + +schedule_work (&sl->tx_work); +} +static void sl_tx_timeout (struct net_device *dev) {struct slip *sl =netdev_priv (dev);
@@ -749,6 +760,7 @@ static struct slip *sl_alloc(dev_t line) sl->magic =SLIP_MAGIC ; sl->dev = dev;spin_lock_init (&sl->lock); +INIT_WORK (&sl->tx_work, slip_transmit); sl->mode =SL_MODE_DEFAULT ;#ifdef CONFIG_SLIP_SMART /* initialize timer_list struct */
@@ -872,8 +884,12 @@ static void slip_close(struct tty_struct *tty)if (!sl || sl->magic !=SLIP_MAGIC || sl->tty != tty)return ; +spin_lock_bh (&sl->lock); tty->disc_data =NULL ; sl->tty =NULL ; +spin_unlock_bh (&sl->lock); + +flush_work (&sl->tx_work);/* VSV = very important to remove timers */ #ifdef CONFIG_SLIP_SMART
drivers/net/slip/slip.h +1 -0
@@ -53,6 +53,7 @@ struct slip {struct tty_struct *tty;/* ptr to TTY structure */ struct net_device *dev;/* easy for intr handling */ spinlock_t lock; +struct work_struct tx_work;/* Flushes transmit buffer */ #ifdef SL_INCLUDE_CSLIP struct slcompress *slcomp;/* for header compression */
drivers/net/usb/huawei_cdc_ncm.c +7 -3
@@ -84,12 +84,13 @@ static int huawei_cdc_ncm_bind(struct usbnet *usbnet_dev, ctx = drvstate->ctx;if (usbnet_dev->status) -/* CDC-WMC r1.1 requires wMaxCommand to be "at least 256 -* decimal (0x100)" +/* The wMaxCommand buffer must be big enough to hold +* any message from the modem. Experience has shown +* that some replies are more than 256 bytes long */ subdriver =usb_cdc_wdm_register (ctx->control, &usbnet_dev->status->desc, -256 ,/* wMaxCommand */ +1024 ,/* wMaxCommand */ huawei_cdc_ncm_wdm_manage_power);if (IS_ERR (subdriver)) { ret =PTR_ERR (subdriver);
@@ -206,6 +207,9 @@ static const struct usb_device_id huawei_cdc_ncm_devs[] = { { USB_VENDOR_AND_INTERFACE_INFO(0x12d1, 0xff, 0x02, 0x76), .driver_info = (unsigned long )&huawei_cdc_ncm_info, }, + { USB_VENDOR_AND_INTERFACE_INFO(0x12d1, 0xff, 0x03, 0x16), + .driver_info = (unsigned long)&huawei_cdc_ncm_info, + }, /* Terminating entry */ {
drivers/net/usb/qmi_wwan.c +3 -0
@@ -660,6 +660,7 @@ static const struct usb_device_id products[] = { {QMI_FIXED_INTF(0x05c6, 0x9084, 4)}, {QMI_FIXED_INTF(0x05c6, 0x920d, 0)}, {QMI_FIXED_INTF(0x05c6, 0x920d, 5)}, + {QMI_FIXED_INTF(0x0846, 0x68a2, 8)}, {QMI_FIXED_INTF(0x12d1, 0x140c, 1)}, /* Huawei E173 */ {QMI_FIXED_INTF(0x12d1, 0x14ac, 1)}, /* Huawei E1820 */ {QMI_FIXED_INTF(0x16d8, 0x6003, 0)}, /* CMOTech 6003 */
@@ -734,6 +735,7 @@ static const struct usb_device_id products[] = { {QMI_FIXED_INTF(0x19d2, 0x1424, 2)}, {QMI_FIXED_INTF(0x19d2, 0x1425, 2)}, {QMI_FIXED_INTF(0x19d2, 0x1426, 2)}, /* ZTE MF91 */ + {QMI_FIXED_INTF(0x19d2, 0x1428, 2)}, /* Telewell TW-LTE 4G v2 */ {QMI_FIXED_INTF(0x19d2, 0x2002, 4)}, /* ZTE (Vodafone) K3765-Z */ {QMI_FIXED_INTF(0x0f3d, 0x68a2, 8)}, /* Sierra Wireless MC7700 */ {QMI_FIXED_INTF(0x114f, 0x68a2, 8)}, /* Sierra Wireless MC7750 */
@@ -746,6 +748,7 @@ static const struct usb_device_id products[] = { {QMI_FIXED_INTF(0x1199, 0x901f, 8)}, /* Sierra Wireless EM7355 */ {QMI_FIXED_INTF(0x1199, 0x9041, 8)}, /* Sierra Wireless MC7305/MC7355 */ {QMI_FIXED_INTF(0x1199, 0x9051, 8)}, /* Netgear AirCard 340U */ + {QMI_FIXED_INTF(0x1199, 0x9057, 8)}, {QMI_FIXED_INTF(0x1bbb, 0x011e, 4)}, /* Telekom Speedstick LTE II (Alcatel One Touch L100V LTE) */ {QMI_FIXED_INTF(0x1bbb, 0x0203, 2)}, /* Alcatel L800MA */ {QMI_FIXED_INTF(0x2357, 0x0201, 4)}, /* TP-LINK HSUPA Modem MA180 */
drivers/net/wireless/iwlwifi/dvm/rxon.c +0 -12
@@ -1068,13 +1068,6 @@ int iwlagn_commit_rxon(struct iwl_priv *priv, struct iwl_rxon_context *ctx)/* recalculate basic rates */ iwl_calc_basic_rates (priv, ctx); -/* -* force CTS-to-self frames protection if RTS-CTS is not preferred -* one aggregation protection method -*/ -if (!priv->hw_params.use_rts_for_aggregation) - ctx->staging.flags |=RXON_FLG_SELF_CTS_EN ; -if ((ctx->vif && ctx->vif->bss_conf.use_short_slot) || !(ctx->staging.flags &RXON_FLG_BAND_24G_MSK )) ctx->staging.flags |=RXON_FLG_SHORT_SLOT_MSK ;
@@ -1480,11 +1473,6 @@ void iwlagn_bss_info_changed(struct ieee80211_hw *hw,else ctx->staging.flags &= ~RXON_FLG_TGG_PROTECT_MSK ; -if (bss_conf->use_cts_prot) - ctx->staging.flags |=RXON_FLG_SELF_CTS_EN ; -else - ctx->staging.flags &= ~RXON_FLG_SELF_CTS_EN ; -memcpy (ctx->staging.bssid_addr, bss_conf->bssid,ETH_ALEN ); if (vif->type == NL80211_IFTYPE_AP ||
drivers/net/wireless/iwlwifi/mvm/mac-ctxt.c +2 -6
@@ -651,13 +651,9 @@ static void iwl_mvm_mac_ctxt_cmd_common(struct iwl_mvm *mvm,if (vif->bss_conf.qos) cmd->qos_flags |=cpu_to_le32 (MAC_QOS_FLG_UPDATE_EDCA ); -/* Don't use cts to self as the fw doesn't support it currently. */ -if (vif->bss_conf.use_cts_prot) { +if (vif->bss_conf.use_cts_prot) cmd->protection_flags |=cpu_to_le32 (MAC_PROT_FLG_TGG_PROTECT ); -if (IWL_UCODE_API (mvm->fw->ucode_ver) >=8 ) - cmd->protection_flags |= -cpu_to_le32 (MAC_PROT_FLG_SELF_CTS_EN ); - } +IWL_DEBUG_RATE (mvm,"use_cts_prot %d, ht_operation_mode %d\n" , vif->bss_conf.use_cts_prot, vif->bss_conf.ht_operation_mode);
drivers/net/wireless/iwlwifi/pcie/drv.c +2 -1
@@ -366,6 +366,7 @@ static DEFINE_PCI_DEVICE_TABLE(iwl_hw_card_ids) = { {IWL_PCI_DEVICE(0x095A, 0x5012, iwl7265_2ac_cfg)}, {IWL_PCI_DEVICE(0x095A, 0x5412, iwl7265_2ac_cfg)}, {IWL_PCI_DEVICE(0x095A, 0x5410, iwl7265_2ac_cfg)}, + {IWL_PCI_DEVICE(0x095A, 0x5510, iwl7265_2ac_cfg)}, {IWL_PCI_DEVICE(0x095A, 0x5400, iwl7265_2ac_cfg)}, {IWL_PCI_DEVICE(0x095A, 0x1010, iwl7265_2ac_cfg)}, {IWL_PCI_DEVICE(0x095A, 0x5000, iwl7265_2n_cfg)},
@@ -379,7 +380,7 @@ static DEFINE_PCI_DEVICE_TABLE(iwl_hw_card_ids) = { {IWL_PCI_DEVICE(0x095A, 0x9110, iwl7265_2ac_cfg)}, {IWL_PCI_DEVICE(0x095A, 0x9112, iwl7265_2ac_cfg)}, {IWL_PCI_DEVICE(0x095A, 0x9210, iwl7265_2ac_cfg)}, - {IWL_PCI_DEVICE(0x095A, 0x9200, iwl7265_2ac_cfg)}, + {IWL_PCI_DEVICE(0x095B, 0x9200, iwl7265_2ac_cfg)}, {IWL_PCI_DEVICE(0x095A, 0x9510, iwl7265_2ac_cfg)}, {IWL_PCI_DEVICE(0x095A, 0x9310, iwl7265_2ac_cfg)}, {IWL_PCI_DEVICE(0x095A, 0x9410, iwl7265_2ac_cfg)},
drivers/net/wireless/mwifiex/main.c +1 -0
@@ -646,6 +646,7 @@ mwifiex_hard_start_xmit(struct sk_buff *skb, struct net_device *dev) } tx_info =MWIFIEX_SKB_TXCB (skb); +memset (tx_info,0 ,sizeof (*tx_info)); tx_info->bss_num = priv->bss_num; tx_info->bss_type = priv->bss_type; tx_info->pkt_len = skb->len;
drivers/usb/chipidea/udc.c +2 -2
@@ -1179,8 +1179,8 @@ static int ep_enable(struct usb_ep *ep,if (hwep->type ==USB_ENDPOINT_XFER_CONTROL ) cap |=QH_IOS ; -if (hwep->num) - cap |=QH_ZLT ; + + cap |=QH_ZLT ; cap |= (hwep->ep.maxpacket <<__ffs (QH_MAX_PKT )) &QH_MAX_PKT ;/* * For ISO-TX, we set mult at QH as the largest value, and use
drivers/usb/core/hub.c +19 -0
@@ -884,6 +884,25 @@ static int hub_usb3_port_disable(struct usb_hub *hub, int port1)if (!hub_is_superspeed (hub->hdev))return -EINVAL ; + ret =hub_port_status (hub, port1, &portstatus, &portchange); +if (ret <0 ) +return ret; + +/* +* USB controller Advanced Micro Devices, Inc. [AMD] FCH USB XHCI +* Controller [1022:7814] will have spurious result making the following +* usb 3.0 device hotplugging route to the 2.0 root hub and recognized +* as high-speed device if we set the usb 3.0 port link state to +* Disabled. Since it's already in USB_SS_PORT_LS_RX_DETECT state, we +* check the state here to avoid the bug. +*/ +if ((portstatus &USB_PORT_STAT_LINK_STATE ) == +USB_SS_PORT_LS_RX_DETECT ) { +dev_dbg (&hub->ports[port1 -1 ]->dev, +"Not disabling port; link state is RxDetect\n" ); +return ret; + } + ret =hub_set_port_link_state (hub, port1,USB_SS_PORT_LS_SS_DISABLED );if (ret)return ret;
drivers/xen/balloon.c +5 -7
@@ -426,20 +426,18 @@ static enum bp_state decrease_reservation(unsigned long nr_pages, gfp_t gfp)* p2m are consistent. */ if (!xen_feature (XENFEAT_auto_translated_physmap)) { -unsigned long p; -struct page *scratch_page =get_balloon_scratch_page (); -if (!PageHighMem (page)) { +struct page *scratch_page =get_balloon_scratch_page (); + ret =HYPERVISOR_update_va_mapping ( (unsigned long )__va (pfn <<PAGE_SHIFT ),pfn_pte (page_to_pfn (scratch_page),PAGE_KERNEL_RO ),0 );BUG_ON (ret); - } - p =page_to_pfn (scratch_page); -__set_phys_to_machine (pfn,pfn_to_mfn (p)); -put_balloon_scratch_page (); +put_balloon_scratch_page (); + } +__set_phys_to_machine (pfn,INVALID_P2M_ENTRY ); }#endif
fs/aio.c +7 -0
@@ -830,16 +830,20 @@ void exit_aio(struct mm_struct *mm)static void put_reqs_available (struct kioctx *ctx,unsigned nr) {struct kioctx_cpu *kcpu; +unsigned long flags;preempt_disable (); kcpu =this_cpu_ptr (ctx->cpu); +local_irq_save (flags); kcpu->reqs_available += nr; +while (kcpu->reqs_available >= ctx->req_batch *2 ) { kcpu->reqs_available -= ctx->req_batch;atomic_add (ctx->req_batch, &ctx->reqs_available); } +local_irq_restore (flags);preempt_enable (); }
@@ -847,10 +851,12 @@ static bool get_reqs_available(struct kioctx *ctx) {struct kioctx_cpu *kcpu;bool ret = false; +unsigned long flags;preempt_disable (); kcpu =this_cpu_ptr (ctx->cpu); +local_irq_save (flags);if (!kcpu->reqs_available) {int old, avail =atomic_read (&ctx->reqs_available);
@@ -869,6 +875,7 @@ static bool get_reqs_available(struct kioctx *ctx) ret = true; kcpu->reqs_available--; out: +local_irq_restore (flags);preempt_enable ();return ret; }
fs/fuse/dir.c +4 -3
@@ -198,7 +198,8 @@ static int fuse_dentry_revalidate(struct dentry *entry, unsigned int flags) inode =ACCESS_ONCE (entry->d_inode);if (inode &&is_bad_inode (inode)) goto invalid; -else if (fuse_dentry_time (entry) <get_jiffies_64 ()) { +else if (time_before64 (fuse_dentry_time (entry),get_jiffies_64 ()) || + (flags &LOOKUP_REVAL )) {int err;struct fuse_entry_out outarg;struct fuse_req *req;
@@ -925,7 +926,7 @@ int fuse_update_attributes(struct inode *inode, struct kstat *stat,int err;bool r; -if (fi->i_time <get_jiffies_64 ()) { +if (time_before64 (fi->i_time,get_jiffies_64 ())) { r = true; err =fuse_do_getattr (inode, stat, file); }else {
@@ -1111,7 +1112,7 @@ static int fuse_permission(struct inode *inode, int mask) ((mask & MAY_EXEC) && S_ISREG(inode->i_mode))) {struct fuse_inode *fi =get_fuse_inode (inode); -if (fi->i_time <get_jiffies_64 ()) { +if (time_before64 (fi->i_time,get_jiffies_64 ())) { refreshed = true; err =fuse_perm_getattr (inode, mask);
fs/fuse/inode.c +16 -4
@@ -461,6 +461,17 @@ static const match_table_t tokens = { {OPT_ERR, NULL} }; +static int fuse_match_uint (substring_t *s,unsigned int *res) +{ +int err = -ENOMEM ; +char *buf =match_strdup (s); +if (buf) { + err =kstrtouint (buf,10 , res); +kfree (buf); + } +return err; +} +static int parse_fuse_opt (char *opt,struct fuse_mount_data *d,int is_bdev) {char *p;
@@ -471,6 +482,7 @@ static int parse_fuse_opt(char *opt, struct fuse_mount_data *d, int is_bdev)while ((p =strsep (&opt,"," )) !=NULL ) {int token;int value; +unsigned uv;substring_t args[MAX_OPT_ARGS ];if (!*p)continue ;
@@ -494,18 +506,18 @@ static int parse_fuse_opt(char *opt, struct fuse_mount_data *d, int is_bdev)break ;case OPT_USER_ID : -if (match_int (&args[0 ], &value)) +if (fuse_match_uint (&args[0 ], &uv))return 0 ; - d->user_id =make_kuid (current_user_ns (), value); + d->user_id =make_kuid (current_user_ns (), uv);if (!uid_valid (d->user_id))return 0 ; d->user_id_present =1 ;break ;case OPT_GROUP_ID : -if (match_int (&args[0 ], &value)) +if (fuse_match_uint (&args[0 ], &uv))return 0 ; - d->group_id =make_kgid (current_user_ns (), value); + d->group_id =make_kgid (current_user_ns (), uv);if (!gid_valid (d->group_id))return 0 ; d->group_id_present =1 ;
fs/quota/dquot.c +2 -0
@@ -702,6 +702,7 @@ dqcache_shrink_scan(struct shrinker *shrink, struct shrink_control *sc)struct dquot *dquot;unsigned long freed =0 ; +spin_lock (&dq_list_lock); head = free_dquots.prev;while (head != &free_dquots && sc->nr_to_scan) { dquot = list_entry(head, struct dquot, dq_free);
@@ -713,6 +714,7 @@ dqcache_shrink_scan(struct shrinker *shrink, struct shrink_control *sc) freed++; head = free_dquots.prev; } +spin_unlock (&dq_list_lock);return freed; }
include/net/sock.h +8 -8
@@ -1755,8 +1755,8 @@ sk_dst_get(struct sock *sk)rcu_read_lock (); dst =rcu_dereference (sk->sk_dst_cache); -if (dst) -dst_hold (dst); +if (dst && !atomic_inc_not_zero (&dst->__refcnt)) + dst =NULL ;rcu_read_unlock ();return dst; }
@@ -1793,9 +1793,11 @@ __sk_dst_set(struct sock *sk, struct dst_entry *dst)static inline void sk_dst_set (struct sock *sk,struct dst_entry *dst) { -spin_lock (&sk->sk_dst_lock); -__sk_dst_set (sk, dst); -spin_unlock (&sk->sk_dst_lock); +struct dst_entry *old_dst; + +sk_tx_queue_clear (sk); + old_dst =xchg ((__force struct dst_entry **)&sk->sk_dst_cache, dst); +dst_release (old_dst); } static inline void
@@ -1807,9 +1809,7 @@ __sk_dst_reset(struct sock *sk)static inline void sk_dst_reset (struct sock *sk) { -spin_lock (&sk->sk_dst_lock); -__sk_dst_reset (sk); -spin_unlock (&sk->sk_dst_lock); +sk_dst_set (sk,NULL ); }struct dst_entry *__sk_dst_check (struct sock *sk,u32 cookie);
kernel/Kconfig.locks +4 -1
@@ -220,6 +220,9 @@ config INLINE_WRITE_UNLOCK_IRQRESTORE endif +config ARCH_SUPPORTS_ATOMIC_RMW + bool + config MUTEX_SPIN_ON_OWNER def_bool y - depends on SMP && !DEBUG_MUTEXES + depends on SMP && !DEBUG_MUTEXES && ARCH_SUPPORTS_ATOMIC_RMW
kernel/events/core.c +1 -1
@@ -2311,7 +2311,7 @@ static void perf_event_context_sched_out(struct task_struct *task, int ctxn, next_parent =rcu_dereference (next_ctx->parent_ctx);/* If neither context have a parent context; they cannot be clones. */ -if (!parent && !next_parent) +if (!parent || !next_parent) goto unlock;if (next_parent == ctx || next_ctx == parent || next_parent == parent) {
kernel/power/process.c +1 -0
@@ -184,6 +184,7 @@ void thaw_processes(void)printk ("Restarting tasks ... " ); +__usermodehelper_set_disable_depth (UMH_FREEZING );thaw_workqueues ();read_lock (&tasklist_lock);
kernel/sched/debug.c +1 -1
@@ -608,7 +608,7 @@ void proc_sched_show_task(struct task_struct *p, struct seq_file *m) avg_atom = p->se.sum_exec_runtime;if (nr_switches) -do_div (avg_atom, nr_switches); + avg_atom =div64_ul (avg_atom, nr_switches);else avg_atom =-1LL ;
kernel/time/alarmtimer.c +18 -2
@@ -585,9 +585,14 @@ static int alarm_timer_set(struct k_itimer *timr, int flags,struct itimerspec *new_setting, struct itimerspec *old_setting) { + ktime_t exp; +if (!rtcdev)return -ENOTSUPP ; +if (flags & ~TIMER_ABSTIME ) +return -EINVAL ; +if (old_setting)alarm_timer_get (timr, old_setting);
@@ -597,8 +602,16 @@ static int alarm_timer_set(struct k_itimer *timr, int flags,/* start the timer */ timr->it.alarm.interval =timespec_to_ktime (new_setting->it_interval); -alarm_start (&timr->it.alarm.alarmtimer, -timespec_to_ktime (new_setting->it_value)); + exp =timespec_to_ktime (new_setting->it_value); +/* Convert (if necessary) to absolute time */ +if (flags !=TIMER_ABSTIME ) { +ktime_t now; + + now = alarm_bases[timr->it.alarm.alarmtimer.type].gettime (); + exp =ktime_add (now, exp); + } + +alarm_start (&timr->it.alarm.alarmtimer, exp);return 0 ; }
@@ -730,6 +743,9 @@ static int alarm_timer_nsleep(const clockid_t which_clock, int flags,if (!alarmtimer_get_rtcdev ())return -ENOTSUPP ; +if (flags & ~TIMER_ABSTIME ) +return -EINVAL ; +if (!capable (CAP_WAKE_ALARM ))return -EPERM ;
kernel/trace/ftrace.c +2 -2
@@ -331,12 +331,12 @@ static void update_ftrace_function(void) func = ftrace_ops_list_func; } +update_function_graph_func (); +/* If there's no change, then do nothing more here */ if (ftrace_trace_function == func)return ; -update_function_graph_func (); -/* * If we are using the list function, it doesn't care * about the function_trace_ops.
kernel/trace/ring_buffer.c +0 -4
@@ -616,10 +616,6 @@ int ring_buffer_poll_wait(struct ring_buffer *buffer, int cpu,struct ring_buffer_per_cpu *cpu_buffer;struct rb_irq_work *work; -if ((cpu ==RING_BUFFER_ALL_CPUS && !ring_buffer_empty (buffer)) || - (cpu !=RING_BUFFER_ALL_CPUS && !ring_buffer_empty_cpu (buffer, cpu))) -return POLLIN |POLLRDNORM ; -if (cpu ==RING_BUFFER_ALL_CPUS ) work = &buffer->irq_work;else {
kernel/trace/trace.c +16 -2
@@ -454,6 +454,12 @@ int __trace_puts(unsigned long ip, const char *str, int size)struct print_entry *entry;unsigned long irq_flags;int alloc; +int pc; + +if (!(trace_flags &TRACE_ITER_PRINTK )) +return 0 ; + + pc =preempt_count ();if (unlikely (tracing_selftest_running || tracing_disabled))return 0 ;
@@ -463,7 +469,7 @@ int __trace_puts(unsigned long ip, const char *str, int size)local_save_flags (irq_flags); buffer = global_trace.trace_buffer.buffer; event =trace_buffer_lock_reserve (buffer,TRACE_PRINT , alloc, - irq_flags,preempt_count ()); + irq_flags, pc);if (!event)return 0 ;
@@ -480,6 +486,7 @@ int __trace_puts(unsigned long ip, const char *str, int size) entry->buf[size] ='\0' ;__buffer_unlock_commit (buffer, event); +ftrace_trace_stack (buffer, irq_flags,4 , pc);return size; }
@@ -497,6 +504,12 @@ int __trace_bputs(unsigned long ip, const char *str)struct bputs_entry *entry;unsigned long irq_flags;int size =sizeof (struct bputs_entry ); +int pc; + +if (!(trace_flags &TRACE_ITER_PRINTK )) +return 0 ; + + pc =preempt_count ();if (unlikely (tracing_selftest_running || tracing_disabled))return 0 ;
@@ -504,7 +517,7 @@ int __trace_bputs(unsigned long ip, const char *str)local_save_flags (irq_flags); buffer = global_trace.trace_buffer.buffer; event =trace_buffer_lock_reserve (buffer,TRACE_BPUTS , size, - irq_flags,preempt_count ()); + irq_flags, pc);if (!event)return 0 ;
@@ -513,6 +526,7 @@ int __trace_bputs(unsigned long ip, const char *str) entry->str = str;__buffer_unlock_commit (buffer, event); +ftrace_trace_stack (buffer, irq_flags,4 , pc);return 1 ; }
kernel/trace/trace_events.c +1 -0
@@ -439,6 +439,7 @@ static void remove_event_file_dir(struct ftrace_event_file *file)list_del (&file->list);remove_subsystem (file->system); +free_event_filter (file->filter);kmem_cache_free (file_cachep, file); }
mm/shmem.c +92 -12
169 lines not on this page · raw message
mm/vmscan.c +5 -6
@@ -1540,19 +1540,18 @@ shrink_inactive_list(unsigned long nr_to_scan, struct lruvec *lruvec,* If dirty pages are scanned that are not queued for IO, it * implies that flushers are not keeping up. In this case, flag * the zone ZONE_TAIL_LRU_DIRTY and kswapd will start writing -* pages from reclaim context. It will forcibly stall in the -* next check. +* pages from reclaim context. */ if (nr_unqueued_dirty == nr_taken)zone_set_flag (zone,ZONE_TAIL_LRU_DIRTY );/* -* In addition, if kswapd scans pages marked marked for -* immediate reclaim and under writeback (nr_immediate), it -* implies that pages are cycling through the LRU faster than +* If kswapd scans pages marked marked for immediate +* reclaim and under writeback (nr_immediate), it implies +* that pages are cycling through the LRU faster than * they are written so also forcibly stall. */ -if (nr_unqueued_dirty == nr_taken || nr_immediate) +if (nr_immediate)congestion_wait (BLK_RW_ASYNC ,HZ /10 ); }
net/8021q/vlan_core.c +4 -1
@@ -108,8 +108,11 @@ EXPORT_SYMBOL(vlan_dev_vlan_id);static struct sk_buff *vlan_reorder_header (struct sk_buff *skb) { -if (skb_cow (skb,skb_headroom (skb)) <0 ) +if (skb_cow (skb,skb_headroom (skb)) <0 ) { +kfree_skb (skb);return NULL ; + } +memmove (skb->data -ETH_HLEN , skb->data -VLAN_ETH_HLEN ,2 *ETH_ALEN ); skb->mac_header +=VLAN_HLEN ;return skb;
net/8021q/vlan_dev.c +10 -3
@@ -635,8 +635,6 @@ static void vlan_dev_uninit(struct net_device *dev)struct vlan_dev_priv *vlan =vlan_dev_priv (dev);int i; -free_percpu (vlan->vlan_pcpu_stats); - vlan->vlan_pcpu_stats =NULL ;for (i =0 ; i <ARRAY_SIZE (vlan->egress_priority_map); i++) {while ((pm = vlan->egress_priority_map[i]) !=NULL ) { vlan->egress_priority_map[i] = pm->next;
@@ -796,6 +794,15 @@ static const struct net_device_ops vlan_netdev_ops = { .ndo_get_lock_subclass = vlan_dev_get_lock_subclass, }; +static void vlan_dev_free (struct net_device *dev) +{ +struct vlan_dev_priv *vlan =vlan_dev_priv (dev); + +free_percpu (vlan->vlan_pcpu_stats); + vlan->vlan_pcpu_stats =NULL ; +free_netdev (dev); +} +void vlan_setup (struct net_device *dev) {ether_setup (dev);
@@ -805,7 +812,7 @@ void vlan_setup(struct net_device *dev) dev->tx_queue_len =0 ; dev->netdev_ops = &vlan_netdev_ops; - dev->destructor = free_netdev; + dev->destructor = vlan_dev_free; dev->ethtool_ops = &vlan_ethtool_ops;memset (dev->broadcast,0 ,ETH_ALEN );
net/appletalk/ddp.c +0 -3
@@ -1489,8 +1489,6 @@ static int atalk_rcv(struct sk_buff *skb, struct net_device *dev, goto drop;/* Queue packet (standard) */ - skb->sk = sock; -if (sock_queue_rcv_skb (sock, skb) <0 ) goto drop;
@@ -1644,7 +1642,6 @@ static int atalk_sendmsg(struct kiocb *iocb, struct socket *sock, struct msghdrif (!skb) goto out; - skb->sk = sk;skb_reserve (skb, ddp_dl->header_length);skb_reserve (skb, dev->hard_header_len); skb->dev = dev;
net/core/dev.c +10 -1
@@ -148,6 +148,9 @@ struct list_head ptype_all __read_mostly; /* Taps */static struct list_head offload_base__read_mostly ;static int netif_rx_internal (struct sk_buff *skb); +static int call_netdevice_notifiers_info (unsigned long val, +struct net_device *dev, +struct netdev_notifier_info *info);/* * The @dev_base_head list is protected by @dev_base_lock and the rtnl
@@ -1207,7 +1210,11 @@ EXPORT_SYMBOL(netdev_features_change);void netdev_state_change (struct net_device *dev) {if (dev->flags &IFF_UP ) { -call_netdevice_notifiers (NETDEV_CHANGE , dev); +struct netdev_notifier_change_info change_info; + + change_info.flags_changed =0 ; +call_netdevice_notifiers_info (NETDEV_CHANGE , dev, + &change_info.info);rtmsg_ifinfo (RTM_NEWLINK , dev,0 ,GFP_KERNEL ); } }
@@ -4051,6 +4058,8 @@ static void napi_reuse_skb(struct napi_struct *napi, struct sk_buff *skb) skb->vlan_tci =0 ; skb->dev = napi->dev; skb->skb_iif =0 ; + skb->encapsulation =0 ; +skb_shinfo (skb)->gso_type =0 ; skb->truesize =SKB_TRUESIZE (skb_end_offset (skb)); napi->skb = skb;
net/core/dst.c +11 -5
@@ -267,6 +267,15 @@ again: }EXPORT_SYMBOL (dst_destroy); +static void dst_destroy_rcu (struct rcu_head *head) +{ + struct dst_entry *dst = container_of(head, struct dst_entry, rcu_head); + + dst =dst_destroy (dst); +if (dst) +__dst_free (dst); +} +void dst_release (struct dst_entry *dst) {if (dst) {
@@ -274,11 +283,8 @@ void dst_release(struct dst_entry *dst) newrefcnt =atomic_dec_return (&dst->__refcnt);WARN_ON (newrefcnt <0 ); -if (unlikely (dst->flags &DST_NOCACHE ) && !newrefcnt) { - dst =dst_destroy (dst); -if (dst) -__dst_free (dst); - } +if (unlikely (dst->flags &DST_NOCACHE ) && !newrefcnt) +call_rcu (&dst->rcu_head, dst_destroy_rcu); } }EXPORT_SYMBOL (dst_release);
net/core/skbuff.c +2 -1
@@ -2881,12 +2881,13 @@ struct sk_buff *skb_segment(struct sk_buff *head_skb,int pos;int dummy; +__skb_push (head_skb, doffset); proto =skb_network_protocol (head_skb, &dummy);if (unlikely (!proto))return ERR_PTR (-EINVAL ); csum = !!can_checksum_protocol (features, proto); -__skb_push (head_skb, doffset); + headroom =skb_headroom (head_skb); pos =skb_headlen (head_skb);
net/dns_resolver/dns_query.c +3 -1
@@ -149,7 +149,9 @@ int dns_query(const char *type, const char *name, size_t namelen,if (!*_result) goto put; -memcpy (*_result, upayload->data, len +1 ); +memcpy (*_result, upayload->data, len); + (*_result)[len] ='\0' ; +if (_expiry) *_expiry = rkey->expiry;
net/ipv4/af_inet.c +3 -0
@@ -1434,6 +1434,9 @@ static int inet_gro_complete(struct sk_buff *skb, int nhoff)int proto = iph->protocol;int err = -ENOSYS ; +if (skb->encapsulation) +skb_set_inner_network_header (skb, nhoff); +csum_replace2 (&iph->check, iph->tot_len, newlen); iph->tot_len = newlen;
net/ipv4/gre_offload.c +3 -0
@@ -255,6 +255,9 @@ static int gre_gro_complete(struct sk_buff *skb, int nhoff)int err = -ENOENT ;__be16 type; + skb->encapsulation =1 ; +skb_shinfo (skb)->gso_type =SKB_GSO_GRE ; + type = greh->protocol;if (greh->flags &GRE_KEY ) grehlen +=GRE_HEADER_SECTION ;
net/ipv4/icmp.c +0 -2
@@ -732,8 +732,6 @@ static void icmp_unreach(struct sk_buff *skb)/* fall through */ case 0 : info =ntohs (icmph->un.frag.mtu); -if (!info) - goto out; }break ;case ICMP_SR_FAILED :
net/ipv4/igmp.c +6 -4
@@ -1952,6 +1952,10 @@ int ip_mc_leave_group(struct sock *sk, struct ip_mreqn *imr)rtnl_lock (); in_dev =ip_mc_find_dev (net, imr); +if (!in_dev) { + ret = -ENODEV ; + goto out; + } ifindex = imr->imr_ifindex; for (imlp = &inet->mc_list; (iml = rtnl_dereference(*imlp)) != NULL;
@@ -1969,16 +1973,14 @@ int ip_mc_leave_group(struct sock *sk, struct ip_mreqn *imr) *imlp = iml->next_rcu; -if (in_dev) -ip_mc_dec_group (in_dev, group); +ip_mc_dec_group (in_dev, group);rtnl_unlock ();/* decrease mem now to avoid the memleak warning */ atomic_sub (sizeof (*iml), &sk->sk_omem_alloc);kfree_rcu (iml, rcu);return 0 ; } -if (!in_dev) - ret = -ENODEV ; +out:rtnl_unlock ();return ret; }
net/ipv4/ip_options.c +4 -0
@@ -288,6 +288,10 @@ int ip_options_compile(struct net *net, optptr++;continue ; } +if (unlikely (l <2 )) { + pp_ptr = optptr; + goto error; + } optlen = optptr[1 ];if (optlen <2 || optlen > l) { pp_ptr = optptr;
net/ipv4/ip_tunnel.c +13 -13
@@ -73,12 +73,7 @@ static void __tunnel_dst_set(struct ip_tunnel_dst *idst, {struct dst_entry *old_dst; -if (dst) { -if (dst->flags &DST_NOCACHE ) - dst =NULL ; -else -dst_clone (dst); - } +dst_clone (dst); old_dst =xchg ((__force struct dst_entry **)&idst->dst, dst);dst_release (old_dst); }
@@ -108,13 +103,14 @@ static struct rtable *tunnel_rtable_get(struct ip_tunnel *t, u32 cookie)rcu_read_lock (); dst =rcu_dereference (this_cpu_ptr (t->dst_cache)->dst); +if (dst && !atomic_inc_not_zero (&dst->__refcnt)) + dst =NULL ;if (dst) {if (dst->obsolete && dst->ops->check (dst, cookie) ==NULL ) { -rcu_read_unlock ();tunnel_dst_reset (t); -return NULL ; +dst_release (dst); + dst =NULL ; } -dst_hold (dst); }rcu_read_unlock ();return (struct rtable *)dst;
@@ -173,6 +169,7 @@ struct ip_tunnel *ip_tunnel_lookup(struct ip_tunnel_net *itn,hlist_for_each_entry_rcu (t, head, hash_node) {if (remote != t->parms.iph.daddr || + t->parms.iph.saddr !=0 || !(t->dev->flags &IFF_UP ))continue ;
@@ -189,10 +186,11 @@ struct ip_tunnel *ip_tunnel_lookup(struct ip_tunnel_net *itn, head = &itn->tunnels[hash];hlist_for_each_entry_rcu (t, head, hash_node) { -if ((local != t->parms.iph.saddr && - (local != t->parms.iph.daddr || - !ipv4_is_multicast (local))) || - !(t->dev->flags &IFF_UP )) +if ((local != t->parms.iph.saddr || t->parms.iph.daddr !=0 ) && + (local != t->parms.iph.daddr || !ipv4_is_multicast (local))) +continue ; + +if (!(t->dev->flags &IFF_UP ))continue ;if (!ip_tunnel_key_match (&t->parms, flags, key))
@@ -209,6 +207,8 @@ struct ip_tunnel *ip_tunnel_lookup(struct ip_tunnel_net *itn,hlist_for_each_entry_rcu (t, head, hash_node) {if (t->parms.i_key != key || + t->parms.iph.saddr !=0 || + t->parms.iph.daddr !=0 || !(t->dev->flags &IFF_UP ))continue ;
net/ipv4/route.c +8 -7
@@ -1029,7 +1029,7 @@ void ipv4_sk_update_pmtu(struct sk_buff *skb, struct sock *sk, u32 mtu)const struct iphdr *iph = (const struct iphdr *) skb->data;struct flowi4 fl4;struct rtable *rt; -struct dst_entry *dst; +struct dst_entry *odst =NULL ;bool new = false;bh_lock_sock (sk);
@@ -1037,16 +1037,17 @@ void ipv4_sk_update_pmtu(struct sk_buff *skb, struct sock *sk, u32 mtu)if (!ip_sk_accept_pmtu (sk)) goto out; - rt = (struct rtable *)__sk_dst_get (sk); + odst =sk_dst_get (sk); -if (sock_owned_by_user (sk) || !rt) { +if (sock_owned_by_user (sk) || !odst) {__ipv4_sk_update_pmtu (skb, sk, mtu); goto out; }__build_flow_key (&fl4, sk, iph,0 ,0 ,0 ,0 ,0 ); -if (!__sk_dst_check (sk,0 )) { + rt = (struct rtable *)odst; +if (odst->obsolete && odst->ops->check (odst,0 ) ==NULL ) { rt =ip_route_output_flow (sock_net (sk), &fl4, sk);if (IS_ERR (rt)) goto out;
@@ -1056,8 +1057,7 @@ void ipv4_sk_update_pmtu(struct sk_buff *skb, struct sock *sk, u32 mtu)__ip_rt_update_pmtu ((struct rtable *) rt->dst.path, &fl4, mtu); - dst =dst_check (&rt->dst,0 ); -if (!dst) { +if (!dst_check (&rt->dst,0 )) {if (new)dst_release (&rt->dst);
@@ -1069,10 +1069,11 @@ void ipv4_sk_update_pmtu(struct sk_buff *skb, struct sock *sk, u32 mtu) }if (new) -__sk_dst_set (sk, &rt->dst); +sk_dst_set (sk, &rt->dst); out:bh_unlock_sock (sk); +dst_release (odst); }EXPORT_SYMBOL_GPL (ipv4_sk_update_pmtu);
net/ipv4/tcp.c +2 -1
@@ -1108,7 +1108,7 @@ int tcp_sendmsg(struct kiocb *iocb, struct sock *sk, struct msghdr *msg,if (unlikely (tp->repair)) {if (tp->repair_queue ==TCP_RECV_QUEUE ) { copied =tcp_send_rcvq (sk, msg, size); - goto out; + goto out_nopush; } err = -EINVAL ;
@@ -1282,6 +1282,7 @@ wait_for_memory: out:if (copied)tcp_push (sk, flags, mss_now, tp->nonagle, size_goal); +out_nopush:release_sock (sk);return copied + copied_syn;
net/ipv4/tcp_input.c +5 -5
@@ -1113,7 +1113,7 @@ static bool tcp_check_dsack(struct sock *sk, const struct sk_buff *ack_skb, }/* D-SACK for already forgotten data... Do dumb counting. */ -if (dup_sack && tp->undo_marker && tp->undo_retrans && +if (dup_sack && tp->undo_marker && tp->undo_retrans >0 && !after (end_seq_0, prior_snd_una) &&after (end_seq_0, tp->undo_marker)) tp->undo_retrans--;
@@ -1169,7 +1169,7 @@ static int tcp_match_skb_to_sack(struct sock *sk, struct sk_buff *skb,unsigned int new_len = (pkt_len / mss) * mss;if (!in_sack && new_len < pkt_len) { new_len += mss; -if (new_len > skb->len) +if (new_len >= skb->len)return 0 ; } pkt_len = new_len;
@@ -1193,7 +1193,7 @@ static u8 tcp_sacktag_one(struct sock *sk,/* Account D-SACK for retransmitted packet. */ if (dup_sack && (sacked &TCPCB_RETRANS )) { -if (tp->undo_marker && tp->undo_retrans && +if (tp->undo_marker && tp->undo_retrans >0 &&after (end_seq, tp->undo_marker)) tp->undo_retrans--;if (sacked &TCPCB_SACKED_ACKED )
@@ -1894,7 +1894,7 @@ static void tcp_clear_retrans_partial(struct tcp_sock *tp) tp->lost_out =0 ; tp->undo_marker =0 ; - tp->undo_retrans =0 ; + tp->undo_retrans =-1 ; }void tcp_clear_retrans (struct tcp_sock *tp)
@@ -2663,7 +2663,7 @@ static void tcp_enter_recovery(struct sock *sk, bool ece_ack) tp->prior_ssthresh =0 ; tp->undo_marker = tp->snd_una; - tp->undo_retrans = tp->retrans_out; + tp->undo_retrans = tp->retrans_out ? :-1 ;if (inet_csk (sk)->icsk_ca_state <TCP_CA_CWR ) {if (!ece_ack)
net/ipv4/tcp_offload.c +1 -1
@@ -310,7 +310,7 @@ static int tcp4_gro_complete(struct sk_buff *skb, int thoff) th->check = ~tcp_v4_check (skb->len - thoff, iph->saddr, iph->daddr,0 ); -skb_shinfo (skb)->gso_type =SKB_GSO_TCPV4 ; +skb_shinfo (skb)->gso_type |=SKB_GSO_TCPV4 ;return tcp_gro_complete (skb); }
net/ipv4/tcp_output.c +4 -2
@@ -2448,8 +2448,6 @@ int tcp_retransmit_skb(struct sock *sk, struct sk_buff *skb)if (!tp->retrans_stamp) tp->retrans_stamp =TCP_SKB_CB (skb)->when; - tp->undo_retrans +=tcp_skb_pcount (skb); -/* snd_nxt is stored to detect loss of retransmitted segment, * see tcp_input.c tcp_sacktag_write_queue(). */
@@ -2457,6 +2455,10 @@ int tcp_retransmit_skb(struct sock *sk, struct sk_buff *skb) }else {NET_INC_STATS_BH (sock_net (sk),LINUX_MIB_TCPRETRANSFAIL ); } + +if (tp->undo_retrans <0 ) + tp->undo_retrans =0 ; + tp->undo_retrans +=tcp_skb_pcount (skb);return err; }
net/ipv6/tcpv6_offload.c +1 -1
@@ -73,7 +73,7 @@ static int tcp6_gro_complete(struct sk_buff *skb, int thoff) th->check = ~tcp_v6_check (skb->len - thoff, &iph->saddr, &iph->daddr,0 ); -skb_shinfo (skb)->gso_type =SKB_GSO_TCPV6 ; +skb_shinfo (skb)->gso_type |=SKB_GSO_TCPV6 ;return tcp_gro_complete (skb); }
net/netlink/af_netlink.c +2 -2
@@ -636,7 +636,7 @@ static unsigned int netlink_poll(struct file *file, struct socket *sock,while (nlk->cb_running &&netlink_dump_space (nlk)) { err =netlink_dump (sk);if (err <0 ) { - sk->sk_err = err; + sk->sk_err = -err; sk->sk_error_report (sk);break ; }
@@ -2448,7 +2448,7 @@ static int netlink_recvmsg(struct kiocb *kiocb, struct socket *sock, atomic_read(&sk->sk_rmem_alloc) <= sk->sk_rcvbuf / 2) { ret =netlink_dump (sk);if (ret) { - sk->sk_err = ret; + sk->sk_err = -ret; sk->sk_error_report (sk); } }
net/sctp/sysctl.c +24 -22
119 lines not on this page · raw message
net/sctp/ulpevent.c +15 -107
175 lines not on this page · raw message
net/tipc/bcast.c +1 -0
@@ -537,6 +537,7 @@ receive: buf = node->bclink.deferred_head; node->bclink.deferred_head = buf->next; + buf->next =NULL ; node->bclink.deferred_size--; goto receive; }
sound/pci/hda/hda_intel.c +5 -5
@@ -2930,7 +2930,7 @@ static int azx_suspend(struct device *dev)struct azx *chip = card->private_data;struct azx_pcm *p; -if (chip->disabled) +if (chip->disabled || chip->init_failed)return 0 ;snd_power_change_state (card, SNDRV_CTL_POWER_D3hot);
@@ -2961,7 +2961,7 @@ static int azx_resume(struct device *dev)struct snd_card *card =dev_get_drvdata (dev);struct azx *chip = card->private_data; -if (chip->disabled) +if (chip->disabled || chip->init_failed)return 0 ;if (chip->driver_caps &AZX_DCAPS_I915_POWERWELL )
@@ -2996,7 +2996,7 @@ static int azx_runtime_suspend(struct device *dev)struct snd_card *card =dev_get_drvdata (dev);struct azx *chip = card->private_data; -if (chip->disabled) +if (chip->disabled || chip->init_failed)return 0 ;if (!(chip->driver_caps &AZX_DCAPS_PM_RUNTIME ))
@@ -3022,7 +3022,7 @@ static int azx_runtime_resume(struct device *dev)struct hda_codec *codec;int status; -if (chip->disabled) +if (chip->disabled || chip->init_failed)return 0 ;if (!(chip->driver_caps &AZX_DCAPS_PM_RUNTIME ))
@@ -3057,7 +3057,7 @@ static int azx_runtime_idle(struct device *dev)struct snd_card *card =dev_get_drvdata (dev);struct azx *chip = card->private_data; -if (chip->disabled) +if (chip->disabled || chip->init_failed)return 0 ; if (!power_save_controller ||
sound/pci/hda/patch_hdmi.c +1 -0
@@ -1062,6 +1062,7 @@ static void hdmi_pin_setup_infoframe(struct hda_codec *codec, {union audio_infoframe ai; +memset (&ai,0 ,sizeof (ai));if (conn_type ==0 ) {/* HDMI */ struct hdmi_audio_infoframe *hdmi_ai = &ai.hdmi;