Linux 4.4.206
Greg KH
maintainerI'm announcing the release of the 4.4.206 kernel.
All users of the 4.4 kernel series must upgrade.
The updated 4.4.y git tree can be found at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-4.4.y
and can be browsed at the normal kernel.org git web browser:
https://git.kernel.org/?p=linux/kernel/git/stable/linux-stable.git;a=summary
thanks,
greg k-h
------------
Documentation/hid/uhid.txt | 2 Makefile | 2 arch/arm/Kconfig.debug | 28 +++++------ arch/arm/boot/dts/imx53-voipac-dmm-668.dtsi | 8 --- arch/arm/mach-ks8695/board-acs5k.c | 2 arch/arm64/kernel/smp.c | 1 arch/microblaze/Makefile | 12 ++-- arch/microblaze/boot/Makefile | 4 - arch/openrisc/kernel/entry.S | 2 arch/openrisc/kernel/head.S | 2 arch/powerpc/boot/dts/bamboo.dts | 4 + arch/powerpc/kernel/prom.c | 6 +- arch/powerpc/mm/fault.c | 17 +++---- arch/powerpc/mm/ppc_mmu_32.c | 4 - arch/powerpc/platforms/pseries/dlpar.c | 4 + arch/powerpc/xmon/xmon.c | 2 arch/s390/kvm/kvm-s390.c | 17 +++++-- arch/um/Kconfig.debug | 1 crypto/crypto_user.c | 37 ++++++++------- drivers/acpi/acpi_lpss.c | 7 -- drivers/acpi/apei/ghes.c | 30 ++++++------ drivers/block/drbd/drbd_main.c | 1 drivers/block/drbd/drbd_nl.c | 6 +- drivers/block/drbd/drbd_receiver.c | 19 +++++++ drivers/block/drbd/drbd_state.h | 2 drivers/char/hw_random/stm32-rng.c | 8 +++ drivers/clk/samsung/clk-exynos5420.c | 6 ++ drivers/hid/hid-core.c | 51 ++++++++++++++++++--- drivers/infiniband/hw/qib/qib_sdma.c | 4 + drivers/infiniband/ulp/srp/ib_srp.c | 1 drivers/input/serio/gscps2.c | 4 - drivers/input/serio/hp_sdc.c | 4 - drivers/media/v4l2-core/v4l2-ctrls.c | 1 drivers/misc/mei/bus.c | 9 ++- drivers/mtd/mtdcore.h | 2 drivers/mtd/mtdpart.c | 35 ++++++++++++-- drivers/mtd/ubi/build.c | 2 drivers/mtd/ubi/kapi.c | 2 drivers/net/can/c_can/c_can.c | 26 ++++++++++ drivers/net/can/usb/peak_usb/pcan_usb.c | 15 ++++-- drivers/net/ethernet/atheros/atl1e/atl1e_main.c | 4 + drivers/net/ethernet/cadence/macb.c | 12 ++-- drivers/net/ethernet/sfc/ef10.c | 29 ++++++++--- drivers/net/ethernet/stmicro/stmmac/dwmac-sunxi.c | 4 + drivers/net/macvlan.c | 3 - drivers/net/slip/slip.c | 1 drivers/net/wireless/ath/ath6kl/cfg80211.c | 4 - drivers/net/wireless/mwifiex/debugfs.c | 14 ++--- drivers/net/wireless/mwifiex/scan.c | 18 ++++--- drivers/net/wireless/realtek/rtl818x/rtl8187/dev.c | 3 - drivers/pinctrl/sh-pfc/pfc-sh7264.c | 9 ++- drivers/pinctrl/sh-pfc/pfc-sh7734.c | 16 +++--- drivers/platform/x86/hp-wmi.c | 6 +- drivers/power/avs/smartreflex.c | 3 - drivers/pwm/core.c | 1 drivers/pwm/pwm-samsung.c | 1 drivers/regulator/palmas-regulator.c | 5 +- drivers/regulator/tps65910-regulator.c | 4 + drivers/scsi/csiostor/csio_init.c | 2 drivers/scsi/libsas/sas_expander.c | 29 +++++++++++ drivers/scsi/lpfc/lpfc_scsi.c | 18 +++++++ drivers/scsi/qla2xxx/tcm_qla2xxx.c | 48 +++---------------- drivers/scsi/qla2xxx/tcm_qla2xxx.h | 3 - drivers/staging/rtl8192e/rtl8192e/rtl_core.c | 5 +- drivers/tty/serial/max310x.c | 7 -- drivers/usb/serial/ftdi_sio.c | 3 + drivers/usb/serial/ftdi_sio_ids.h | 7 ++ drivers/xen/xen-pciback/pci_stub.c | 3 - fs/btrfs/delayed-ref.c | 3 - fs/gfs2/bmap.c | 2 fs/ocfs2/journal.c | 6 -- fs/xfs/xfs_ioctl32.c | 6 ++ fs/xfs/xfs_rtalloc.c | 4 - include/linux/gpio/consumer.h | 2 include/linux/netdevice.h | 2 include/linux/reset-controller.h | 2 include/net/sock.h | 2 lib/genalloc.c | 5 +- net/core/neighbour.c | 13 +++-- net/core/net_namespace.c | 3 - net/core/sock.c | 2 net/decnet/dn_dev.c | 2 net/openvswitch/datapath.c | 17 +++++-- net/sched/sch_mq.c | 2 net/sched/sch_mqprio.c | 3 - net/sched/sch_multiq.c | 2 net/sched/sch_prio.c | 2 net/tipc/link.c | 2 net/tipc/netlink_compat.c | 8 ++- net/vmw_vsock/af_vsock.c | 7 ++ scripts/gdb/linux/symbols.py | 3 - sound/core/compress_offload.c | 2 sound/soc/kirkwood/kirkwood-i2s.c | 8 +-- 93 files changed, 492 insertions(+), 270 deletions(-)
Aditya Pakki (1):
net/net_namespace: Check the return value of register_pernet_subsys()
Alexander Shiyan (1):
serial: max310x: Fix tx_empty() callback
Alexander Usyskin (1):
mei: bus: prefix device names on bus with the bus name
Anatoliy Glagolev (1):
scsi: qla2xxx: deadlock by configfs_depend_item
Andy Shevchenko (1):
net: dev: Use unsigned integer as an argument to left-shift
Arnd Bergmann (1):
ARM: ks8695: fix section mismatch warning
Bart Van Assche (1):
RDMA/srp: Propagate ib_post_send() failures to the SCSI mid-layer
Benjamin Herrenschmidt (1):
powerpc/44x/bamboo: Fix PCI range
Bert Kenward (1):
sfc: initialise found bitmap in efx_ef10_mtd_probe
Bob Peterson (1):
gfs2: take jdata unstuff into account in do_grow
Boris Brezillon (2):
mtd: Check add_mtd_device() ret code
mtd: Remove a debug trace in mtdpart.c
Brian Norris (1):
mwifiex: debugfs: correct histogram spacing, formatting
Candle Sun (1):
HID: core: check whether Usage Page item is after Usage ID items
Christophe Leroy (4):
powerpc/book3s/32: fix number of bats in p/v_block_mapped() powerpc/xmon: fix dump_segments()
powerpc/prom: fix early DEBUG messages
powerpc/mm: Make NULL pointer deferences explicit on bad page faults.
Dan Carpenter (2):
block: drbd: remove a stray unlock in __drbd_send_protocol() IB/qib: Fix an error code in qib_sdma_verbs_send()
Darrick J. Wong (1):
xfs: require both realtime inodes to mount
Dust Li (1):
net: sched: fix tc -s class show no bstats on class with nolock subqueues
Edward Cree (1):
sfc: suppress duplicate nvmem partition types in efx_ef10_mtd_probe
Eric Biggers (1):
crypto: user - support incremental algorithm dumps
Eric Dumazet (1):
net: fix possible overflow in __sk_mem_raise_allocated()
Eugen Hristev (1):
media: v4l2-ctrl: fix flags for DO_WHITE_BALANCE
Fabio D'Urso (1):
USB: serial: ftdi_sio: add device IDs for U-Blox C099-F9P
Fabio Estevam (1):
ARM: dts: imx53-voipac-dmm-668: Fix memory node duplication
Geert Uytterhoeven (3):
pinctrl: sh-pfc: sh7264: Fix PFCR3 and PFCR0 register configuration
pinctrl: sh-pfc: sh7734: Fix shifted values in IPSR10
openrisc: Fix broken paths to arch/or32
Gen Zhang (1):
powerpc/pseries/dlpar: Fix a missing check in dlpar_parse_cc_property()
Greg Kroah-Hartman (1):
Linux 4.4.206
Gustavo A. R. Silva (1):
tipc: fix memory leak in tipc_nl_compat_publ_dump
Hans de Goede (2):
ACPI / LPSS: Ignore acpi_device_fix_up_power() return value platform/x86: hp-wmi: Fix ACPI errors caused by too small buffer
Helge Deller (2):
parisc: Fix serio address output
parisc: Fix HP SDC hpa address output
Hoang Le (1):
tipc: fix skb may be leaky in tipc_link_input
Huang Shijie (1):
lib/genalloc.c: use vzalloc_node() to allocate the bitmap
Ilya Leoshkevich (1):
scripts/gdb: fix debugging modules compiled with hot/cold partitioning
James Morse (1):
ACPI / APEI: Switch estatus pool to use vmalloc memory
James Smart (1):
scsi: lpfc: Fix dif and first burst use in write commands
Jeroen Hofstee (2):
can: peak_usb: report bus recovery as well
can: c_can: D_CAN: c_can_chip_config(): perform a sofware reset on open
Johannes Berg (1):
decnet: fix DN_IFREQ_SIZE
John Garry (2):
scsi: libsas: Support SATA PHY connection rate unmatch fixing during discovery
scsi: libsas: Check SMP PHY control function result
John Rutherford (1):
tipc: fix link name length check
Josef Bacik (1):
btrfs: only track ref_heads in delayed_ref_updates
Jouni Hogander (1):
slip: Fix use-after-free Read in slip_open
Junxiao Bi (1):
ocfs2: clear journal dirty flag after shutdown journal
Kangjie Lu (5):
drivers/regulator: fix a missing check of return value
regulator: tps65910: fix a missing check of return value
net: stmicro: fix a missing check of clk_prepare
atl1e: checking the status of atl1e_write_phy_reg
tipc: fix a missing check of genlmsg_put
Konstantin Khlebnikov (2):
net/core/neighbour: tell kmemleak about hash tables net/core/neighbour: fix kmemleak minimal reference count for hash tables
Krzysztof Kozlowski (1):
gpiolib: Fix return value of gpio_to_desc() stub if !GPIOLIB
Kyle Roeschley (2):
ath6kl: Only use match sets when firmware supports it
ath6kl: Fix off by one error in scan completion
Lars Ellenberg (1):
drbd: reject attach of unsuitable uuids even if connected
Lepton Wu (1):
VSOCK: bind to random port for VMADDR_PORT_ANY
Lionel Debieve (1):
hwrng: stm32 - fix unbalanced pm_runtime_enable
Luc Van Oostenryck (1):
drbd: fix print_st_err()'s prototype to match the definition
Luca Ceresoli (1):
net: macb: fix error format in dev_err()
Marek Szyprowski (1):
clk: samsung: exynos5420: Preserve PLL configuration during suspend/resume
Masahiro Yamada (2):
microblaze: adjust the help to the real behavior
microblaze: move "... is ready" messages to arch/microblaze/Makefile
Menglong Dong (1):
macvlan: schedule bc_work even if error
Michael Mueller (1):
KVM: s390: unregister debug feature on failing arch init
Nick Bowler (1):
xfs: Align compat attrlist_by_handle with native implementation.
Olof Johansson (1):
lib/genalloc.c: include vmalloc.h
Pan Bian (5):
mwifiex: fix potential NULL dereference and use after free
rtl818x: fix potential use after free
ubi: Put MTD device after it is not used
ubi: Do not drop UBI device reference before using
staging: rtl8192e: fix potential use after free
Paolo Abeni (3):
openvswitch: fix flow command message size
openvswitch: drop unneeded BUG_ON() in ovs_flow_cmd_build_info()
openvswitch: remove another BUG_ON()
Peter Hutterer (1):
HID: doc: fix wrong data structure reference for UHID_OUTPUT
Randy Dunlap (1):
reset: fix reset_control_ops kerneldoc comment
Richard Weinberger (1):
um: Make GCOV depend on !KCOV
Ross Lagerwall (1):
xen/pciback: Check dev_data before using it
Russell King (1):
ASoC: kirkwood: fix external clock probe defer
Suzuki K Poulose (1):
arm64: smp: Handle errors reported by the firmware
Thomas Meyer (1):
PM / AVS: SmartReflex: NULL check before some freeing functions is not needed
Uwe Kleine-König (2):
ARM: debug-imx: only define DEBUG_IMX_UART_PORT if needed
pwm: Clear chip_data in pwm_put()
Varun Prakash (1):
scsi: csiostor: fix incorrect dma device in case of vport
Xiaojun Sang (1):
ASoC: compress: fix unsigned integer overflow check
Greg KH
maintainerDocumentation/hid/uhid.txt +1 -1
@@ -160,7 +160,7 @@ them but you should handle them according to your needs. UHID_OUTPUT: This is sent if the HID device driver wants to send raw data to the I/O device on the interrupt channel. You should read the payload and forward it to - the device. The payload is of type "struct uhid_data_req". + the device. The payload is of type "struct uhid_output_req". This may be received even though you haven't received UHID_OPEN, yet. UHID_GET_REPORT:
Makefile +1 -1
@@ -1,6 +1,6 @@ VERSION = 4 PATCHLEVEL = 4 -SUBLEVEL = 205 +SUBLEVEL = 206 EXTRAVERSION = NAME = Blurry Fish Butt
arch/arm/Kconfig.debug +14 -14
@@ -1260,21 +1260,21 @@ config DEBUG_OMAP2PLUS_UART depends on ARCH_OMAP2PLUS config DEBUG_IMX_UART_PORT - int "i.MX Debug UART Port Selection" if DEBUG_IMX1_UART || \ - DEBUG_IMX25_UART || \ - DEBUG_IMX21_IMX27_UART || \ - DEBUG_IMX31_UART || \ - DEBUG_IMX35_UART || \ - DEBUG_IMX50_UART || \ - DEBUG_IMX51_UART || \ - DEBUG_IMX53_UART || \ - DEBUG_IMX6Q_UART || \ - DEBUG_IMX6SL_UART || \ - DEBUG_IMX6SX_UART || \ - DEBUG_IMX6UL_UART || \ - DEBUG_IMX7D_UART + int "i.MX Debug UART Port Selection" + depends on DEBUG_IMX1_UART || \ + DEBUG_IMX25_UART || \ + DEBUG_IMX21_IMX27_UART || \ + DEBUG_IMX31_UART || \ + DEBUG_IMX35_UART || \ + DEBUG_IMX50_UART || \ + DEBUG_IMX51_UART || \ + DEBUG_IMX53_UART || \ + DEBUG_IMX6Q_UART || \ + DEBUG_IMX6SL_UART || \ + DEBUG_IMX6SX_UART || \ + DEBUG_IMX6UL_UART || \ + DEBUG_IMX7D_UART default 1 - depends on ARCH_MXC help Choose UART port on which kernel low-level debug messages should be output.
arch/arm/boot/dts/imx53-voipac-dmm-668.dtsi +2 -6
@@ -17,12 +17,8 @@ memory@70000000 { device_type = "memory"; - reg = <0x70000000 0x20000000>; - }; - - memory@b0000000 { - device_type = "memory"; - reg = <0xb0000000 0x20000000>; + reg = <0x70000000 0x20000000>, + <0xb0000000 0x20000000>; }; regulators {
arch/arm/mach-ks8695/board-acs5k.c +1 -1
@@ -92,7 +92,7 @@ static struct i2c_board_info acs5k_i2c_devs[] __initdata = { }, }; -static void acs5k_i2c_init (void ) +static void __init acs5k_i2c_init (void ) {/* The gpio interface */ platform_device_register (&acs5k_i2c_device);
arch/arm64/kernel/smp.c +1 -0
@@ -115,6 +115,7 @@ int __cpu_up(unsigned int cpu, struct task_struct *idle) } }else {pr_err ("CPU%u: failed to boot: %d\n" , cpu, ret); +return ret; } secondary_data.stack =NULL ;
arch/microblaze/Makefile +7 -5
@@ -75,19 +75,21 @@ archclean: linux.bin linux.bin.gz linux.bin.ub: vmlinux $(Q)$(MAKE) $(build)=$(boot) $(boot)/$@ + @echo 'Kernel: $(boot)/$@ is ready' ' (#'`cat .version`')' simpleImage.%: vmlinux $(Q)$(MAKE) $(build)=$(boot) $(boot)/$@ + @echo 'Kernel: $(boot)/$@ is ready' ' (#'`cat .version`')' define archhelp echo '* linux.bin - Create raw binary' echo ' linux.bin.gz - Create compressed raw binary' echo ' linux.bin.ub - Create U-Boot wrapped raw binary' - echo ' simpleImage.<dt> - ELF image with $(arch)/boot/dts/<dt>.dts linked in' - echo ' - stripped elf with fdt blob' - echo ' simpleImage.<dt>.unstrip - full ELF image with fdt blob' - echo ' *_defconfig - Select default config from arch/microblaze/configs' - echo '' + echo ' simpleImage.<dt> - Create the following images with <dt>.dtb linked in' + echo ' simpleImage.<dt> : raw image' + echo ' simpleImage.<dt>.ub : raw image with U-Boot header' + echo ' simpleImage.<dt>.unstrip: ELF (identical to vmlinux)' + echo ' simpleImage.<dt>.strip : stripped ELF' echo ' Targets with <dt> embed a device tree blob inside the image' echo ' These targets support board with firmware that does not' echo ' support passing a device tree directly. Replace <dt> with the'
arch/microblaze/boot/Makefile +0 -4
@@ -8,15 +8,12 @@ OBJCOPYFLAGS := -R .note -R .comment -R .note.gnu.build-id -O binary $(obj)/linux.bin: vmlinux FORCE $(call if_changed,objcopy) - @echo 'Kernel: $@ is ready' ' (#'`cat .version`')' $(obj)/linux.bin.ub: $(obj)/linux.bin FORCE $(call if_changed,uimage) - @echo 'Kernel: $@ is ready' ' (#'`cat .version`')' $(obj)/linux.bin.gz: $(obj)/linux.bin FORCE $(call if_changed,gzip) - @echo 'Kernel: $@ is ready' ' (#'`cat .version`')' quiet_cmd_cp = CP $< $@$2 cmd_cp = cat $< >$@$2 || (rm -f $@ && echo false)
@@ -34,6 +31,5 @@ $(obj)/simpleImage.%: vmlinux FORCE $(call if_changed,objcopy) $(call if_changed,uimage) $(call if_changed,strip,.strip) - @echo 'Kernel: $(UIMAGE_OUT) is ready' ' (#'`cat .version`')' clean-files += simpleImage.*.unstrip linux.bin.ub dts/*.dtb
arch/openrisc/kernel/entry.S +1 -1
@@ -179,7 +179,7 @@ handler: ;\ * occured. in fact they never do. if you need them use * values saved on stack (for SPR_EPC, SPR_ESR) or content * of r4 (for SPR_EEAR). for details look at EXCEPTION_HANDLE() - * in 'arch/or32/kernel/head.S' + * in 'arch/openrisc/kernel/head.S' */ /* =====================================================[ exceptions] === */
arch/openrisc/kernel/head.S +1 -1
@@ -1596,7 +1596,7 @@ _string_esr_irq_bug: /* * .data section should be page aligned - * (look into arch/or32/kernel/vmlinux.lds) + * (look into arch/openrisc/kernel/vmlinux.lds.S) */ .section .data,"aw" .align 8192
arch/powerpc/boot/dts/bamboo.dts +3 -1
@@ -268,8 +268,10 @@ /* Outbound ranges, one memory and one IO, * later cannot be changed. Chip supports a second * IO range but we don't use it for now + * The chip also supports a larger memory range but + * it's not naturally aligned, so our code will break */ - ranges = <0x02000000 0x00000000 0xa0000000 0x00000000 0xa0000000 0x00000000 0x40000000 + ranges = <0x02000000 0x00000000 0xa0000000 0x00000000 0xa0000000 0x00000000 0x20000000 0x02000000 0x00000000 0x00000000 0x00000000 0xe0000000 0x00000000 0x00100000 0x01000000 0x00000000 0x00000000 0x00000000 0xe8000000 0x00000000 0x00010000>;
arch/powerpc/kernel/prom.c +3 -3
@@ -125,7 +125,7 @@ static void __init move_device_tree(void) p =__va (memblock_alloc (size,PAGE_SIZE ));memcpy (p, initial_boot_params, size); initial_boot_params = p; -DBG ("Moved device tree to 0x%p\n" , p); +DBG ("Moved device tree to 0x%px\n" , p); }DBG ("<- move_device_tree\n" );
@@ -647,7 +647,7 @@ void __init early_init_devtree(void *params) {phys_addr_t limit; -DBG (" -> early_init_devtree(%p)\n" , params); +DBG (" -> early_init_devtree(%px)\n" , params);/* Too early to BUG_ON(), do it by hand */ if (!early_init_dt_verify (params))
@@ -707,7 +707,7 @@ void __init early_init_devtree(void *params)memblock_allow_resize ();memblock_dump_all (); -DBG ("Phys. mem: %llx\n" ,memblock_phys_mem_size ()); +DBG ("Phys. mem: %llx\n" , (unsigned long long )memblock_phys_mem_size ());/* We may need to relocate the flat tree, do it now. * FIXME .. and the initrd too? */
arch/powerpc/mm/fault.c +9 -8
@@ -521,21 +521,22 @@ void bad_page_fault(struct pt_regs *regs, unsigned long address, int sig)switch (regs->trap) {case 0x300 :case 0x380 : -printk (KERN_ALERT "Unable to handle kernel paging request for " -"data at address 0x%08lx\n" , regs->dar); +pr_alert ("BUG: %s at 0x%08lx\n" , + regs->dar <PAGE_SIZE ?"Kernel NULL pointer dereference" : +"Unable to handle kernel data access" , regs->dar);break ;case 0x400 :case 0x480 : -printk (KERN_ALERT "Unable to handle kernel paging request for " -"instruction fetch\n" ); +pr_alert ("BUG: Unable to handle kernel instruction fetch%s" , + regs->nip <PAGE_SIZE ?" (NULL pointer?)\n" :"\n" );break ;case 0x600 : -printk (KERN_ALERT "Unable to handle kernel paging request for " -"unaligned access at address 0x%08lx\n" , regs->dar); +pr_alert ("BUG: Unable to handle kernel unaligned access at 0x%08lx\n" , + regs->dar);break ;default : -printk (KERN_ALERT "Unable to handle kernel paging request for " -"unknown fault\n" ); +pr_alert ("BUG: Unable to handle unknown paging fault at 0x%08lx\n" , + regs->dar);break ; } printk(KERN_ALERT "Faulting instruction address: 0x%08lx\n",
arch/powerpc/mm/ppc_mmu_32.c +2 -2
@@ -52,7 +52,7 @@ struct batrange { /* stores address ranges mapped by BATs */phys_addr_t v_mapped_by_bats (unsigned long va) {int b; -for (b =0 ; b <4 ; ++b) +for (b =0 ; b <ARRAY_SIZE (bat_addrs); ++b)if (va >= bat_addrs[b].start && va < bat_addrs[b].limit)return bat_addrs[b].phys + (va - bat_addrs[b].start);return 0 ;
@@ -64,7 +64,7 @@ phys_addr_t v_mapped_by_bats(unsigned long va)unsigned long p_mapped_by_bats (phys_addr_t pa) {int b; -for (b =0 ; b <4 ; ++b) +for (b =0 ; b <ARRAY_SIZE (bat_addrs); ++b)if (pa >= bat_addrs[b].phys && pa < (bat_addrs[b].limit-bat_addrs[b].start) +bat_addrs[b].phys)
arch/powerpc/platforms/pseries/dlpar.c +4 -0
@@ -55,6 +55,10 @@ static struct property *dlpar_parse_cc_property(struct cc_workarea *ccwa) name = (char *)ccwa +be32_to_cpu (ccwa->name_offset); prop->name =kstrdup (name,GFP_KERNEL ); +if (!prop->name) { +dlpar_free_cc_property (prop); +return NULL ; + } prop->length =be32_to_cpu (ccwa->prop_length); value = (char *)ccwa +be32_to_cpu (ccwa->prop_offset);
arch/powerpc/xmon/xmon.c +1 -1
@@ -2840,7 +2840,7 @@ void dump_segments(void)printf ("sr0-15 =" );for (i =0 ; i <16 ; ++i) -printf (" %x" ,mfsrin (i)); +printf (" %x" ,mfsrin (i <<28 )); printf("\n"); }#endif
arch/s390/kvm/kvm-s390.c +14 -3
@@ -185,17 +185,28 @@ void kvm_arch_hardware_unsetup(void)int kvm_arch_init (void *opaque) { +int rc; + kvm_s390_dbf =debug_register ("kvm-trace" ,32 ,1 ,7 *sizeof (long ));if (!kvm_s390_dbf)return -ENOMEM ;if (debug_register_view (kvm_s390_dbf, &debug_sprintf_view)) { -debug_unregister (kvm_s390_dbf); -return -ENOMEM ; + rc = -ENOMEM ; + goto out_debug_unreg; }/* Register floating interrupt controller interface. */ -return kvm_register_device_ops (&kvm_flic_ops,KVM_DEV_TYPE_FLIC ); + rc =kvm_register_device_ops (&kvm_flic_ops,KVM_DEV_TYPE_FLIC ); +if (rc) { +pr_err ("Failed to register FLIC rc=%d\n" , rc); + goto out_debug_unreg; + } +return 0 ; + +out_debug_unreg: +debug_unregister (kvm_s390_dbf); +return rc; }void kvm_arch_exit (void )
arch/um/Kconfig.debug +1 -0
@@ -18,6 +18,7 @@ config GPROF config GCOV bool "Enable gcov support" depends on DEBUG_INFO + depends on !KCOV help This option allows developers to retrieve coverage data from a UML session.
crypto/crypto_user.c +20 -17
@@ -257,30 +257,33 @@ drop_alg:static int crypto_dump_report (struct sk_buff *skb,struct netlink_callback *cb) { -struct crypto_alg *alg; +const size_t start_pos = cb->args[0 ]; +size_t pos =0 ;struct crypto_dump_info info; -int err; - -if (cb->args[0 ]) - goto out; - - cb->args[0 ] =1 ; +struct crypto_alg *alg; +int res; info.in_skb = cb->skb; info.out_skb = skb; info.nlmsg_seq = cb->nlh->nlmsg_seq; info.nlmsg_flags =NLM_F_MULTI ; +down_read (&crypto_alg_sem);list_for_each_entry (alg, &crypto_alg_list, cra_list) { - err =crypto_report_alg (alg, &info); -if (err) - goto out_err; +if (pos >= start_pos) { + res =crypto_report_alg (alg, &info); +if (res == -EMSGSIZE ) +break ; +if (res) + goto out; + } + pos++; } - + cb->args[0 ] = pos; + res = skb->len; out: -return skb->len; -out_err: -return err; +up_read (&crypto_alg_sem); +return res; }static int crypto_dump_report_done (struct netlink_callback *cb)
@@ -498,7 +501,7 @@ static int crypto_user_rcv_msg(struct sk_buff *skb, struct nlmsghdr *nlh)if ((type == (CRYPTO_MSG_GETALG -CRYPTO_MSG_BASE ) && (nlh->nlmsg_flags &NLM_F_DUMP ))) {struct crypto_alg *alg; -u16 dump_alloc =0 ; +unsigned long dump_alloc =0 ;if (link->dump ==NULL )return -EINVAL ;
@@ -506,16 +509,16 @@ static int crypto_user_rcv_msg(struct sk_buff *skb, struct nlmsghdr *nlh)down_read (&crypto_alg_sem);list_for_each_entry (alg, &crypto_alg_list, cra_list) dump_alloc +=CRYPTO_REPORT_MAXSIZE ; +up_read (&crypto_alg_sem); {struct netlink_dump_control c = { .dump = link->dump, .done = link->done, - .min_dump_alloc = dump_alloc, + .min_dump_alloc =min (dump_alloc,65535UL ), }; err =netlink_dump_start (crypto_nlsk, skb, nlh, &c); } -up_read (&crypto_alg_sem);return err; }
drivers/acpi/acpi_lpss.c +1 -6
@@ -405,12 +405,7 @@ static int acpi_lpss_create_device(struct acpi_device *adev,* have _PS0 and _PS3 without _PSC (and no power resources), so * acpi_bus_init_power() will assume that the BIOS has put them into D0. */ - ret =acpi_device_fix_up_power (adev); -if (ret) { -/* Skip the device, but continue the namespace scan. */ - ret =0 ; - goto err_out; - } +acpi_device_fix_up_power (adev); adev->driver_data = pdata; pdev =acpi_create_platform_device (adev);
drivers/acpi/apei/ghes.c +15 -15
@@ -198,40 +198,40 @@ static int ghes_estatus_pool_init(void)return 0 ; } -static void ghes_estatus_pool_free_chunk_page (struct gen_pool *pool, +static void ghes_estatus_pool_free_chunk (struct gen_pool *pool,struct gen_pool_chunk *chunk,void *data) { -free_page (chunk->start_addr); +vfree ((void *)chunk->start_addr); }static void ghes_estatus_pool_exit (void ) {gen_pool_for_each_chunk (ghes_estatus_pool, - ghes_estatus_pool_free_chunk_page,NULL ); + ghes_estatus_pool_free_chunk,NULL );gen_pool_destroy (ghes_estatus_pool); }static int ghes_estatus_pool_expand (unsigned long len) { -unsigned long i, pages, size, addr; -int ret; +unsigned long size, addr; ghes_estatus_pool_size_request +=PAGE_ALIGN (len); size =gen_pool_size (ghes_estatus_pool);if (size >= ghes_estatus_pool_size_request)return 0 ; - pages = (ghes_estatus_pool_size_request - size) /PAGE_SIZE ; -for (i =0 ; i < pages; i++) { - addr =__get_free_page (GFP_KERNEL ); -if (!addr) -return -ENOMEM ; - ret =gen_pool_add (ghes_estatus_pool, addr,PAGE_SIZE ,-1 ); -if (ret) -return ret; - } -return 0 ; + addr = (unsigned long )vmalloc (PAGE_ALIGN (len)); +if (!addr) +return -ENOMEM ; + +/* +* New allocation must be visible in all pgd before it can be found by +* an NMI allocating from the pool. +*/ +vmalloc_sync_all (); + +return gen_pool_add (ghes_estatus_pool, addr,PAGE_ALIGN (len),-1 ); }static struct ghes *ghes_new (struct acpi_hest_generic *generic)
drivers/block/drbd/drbd_main.c +0 -1
@@ -792,7 +792,6 @@ int __drbd_send_protocol(struct drbd_connection *connection, enum drbd_packet cmif (nc->tentative && connection->agreed_pro_version <92 ) {rcu_read_unlock (); -mutex_unlock (&sock->mutex);drbd_err (connection,"--dry-run is not supported by peer" );return -EOPNOTSUPP ; }
drivers/block/drbd/drbd_nl.c +3 -3
@@ -1685,9 +1685,9 @@ int drbd_adm_attach(struct sk_buff *skb, struct genl_info *info) } } -if (device->state.conn <C_CONNECTED && - device->state.role ==R_PRIMARY && device->ed_uuid && - (device->ed_uuid & ~((u64 )1 )) != (nbc->md.uuid[UI_CURRENT ] & ~((u64 )1 ))) { +if (device->state.pdsk !=D_UP_TO_DATE && device->ed_uuid && + (device->state.role ==R_PRIMARY || device->state.peer ==R_PRIMARY ) && + (device->ed_uuid & ~((u64 )1 )) != (nbc->md.uuid[UI_CURRENT ] & ~((u64 )1 ))) {drbd_err (device,"Can only attach to data with current UUID=%016llX\n" , (unsigned long long )device->ed_uuid); retcode =ERR_DATA_NOT_CURRENT ;
drivers/block/drbd/drbd_receiver.c +19 -0
@@ -4116,6 +4116,25 @@ static int receive_state(struct drbd_connection *connection, struct packet_infoif (peer_state.conn ==C_AHEAD ) ns.conn =C_BEHIND ; +/* TODO: +* if (primary and diskless and peer uuid != effective uuid) +* abort attach on peer; +* +* If this node does not have good data, was already connected, but +* the peer did a late attach only now, trying to "negotiate" with me, +* AND I am currently Primary, possibly frozen, with some specific +* "effective" uuid, this should never be reached, really, because +* we first send the uuids, then the current state. +* +* In this scenario, we already dropped the connection hard +* when we received the unsuitable uuids (receive_uuids(). +* +* Should we want to change this, that is: not drop the connection in +* receive_uuids() already, then we would need to add a branch here +* that aborts the attach of "unsuitable uuids" on the peer in case +* this node is currently Diskless Primary. +*/ +if (device->p_uuid && peer_state.disk >=D_NEGOTIATING &&get_ldev_if_state (device,D_NEGOTIATING )) {int cr;/* consider resync */
drivers/block/drbd/drbd_state.h +1 -1
@@ -126,7 +126,7 @@ extern enum drbd_state_rv __drbd_set_state(struct drbd_device *, union drbd_stat enum chg_state_flags, struct completion *done);extern void print_st_err (struct drbd_device *,union drbd_state , -union drbd_state ,int ); +union drbd_state ,enum drbd_state_rv ); enum drbd_state_rv _conn_request_state(struct drbd_connection *connection, union drbd_state mask, union drbd_state val,
drivers/char/hw_random/stm32-rng.c +8 -0
@@ -166,6 +166,13 @@ static int stm32_rng_probe(struct platform_device *ofdev)return devm_hwrng_register (dev, &priv->rng); } +static int stm32_rng_remove (struct platform_device *ofdev) +{ +pm_runtime_disable (&ofdev->dev); + +return 0 ; +} +#ifdef CONFIG_PM static int stm32_rng_runtime_suspend (struct device *dev) {
@@ -202,6 +209,7 @@ static struct platform_driver stm32_rng_driver = { .of_match_table = stm32_rng_match, }, .probe = stm32_rng_probe, + .remove = stm32_rng_remove, };module_platform_driver (stm32_rng_driver);
drivers/clk/samsung/clk-exynos5420.c +6 -0
@@ -166,12 +166,18 @@ static unsigned long exynos5x_clk_regs[] __initdata = {GATE_BUS_CPU ,GATE_SCLK_CPU ,CLKOUT_CMU_CPU , +CPLL_CON0 , +DPLL_CON0 ,EPLL_CON0 ,EPLL_CON1 ,EPLL_CON2 ,RPLL_CON0 ,RPLL_CON1 ,RPLL_CON2 , +IPLL_CON0 , +SPLL_CON0 , +VPLL_CON0 , +MPLL_CON0 ,SRC_TOP0 ,SRC_TOP1 , SRC_TOP2,
drivers/hid/hid-core.c +45 -6
84 lines not on this page · raw message
drivers/infiniband/hw/qib/qib_sdma.c +3 -1
@@ -597,8 +597,10 @@ retry: dw = (len +3 ) >>2 ; addr =dma_map_single (&ppd->dd->pcidev->dev, sge->vaddr, dw <<2 ,DMA_TO_DEVICE ); -if (dma_mapping_error (&ppd->dd->pcidev->dev, addr)) +if (dma_mapping_error (&ppd->dd->pcidev->dev, addr)) { + ret = -ENOMEM ; goto unmap; + } sdmadesc[0 ] =0 ;make_sdma_desc (ppd, sdmadesc, (u64 ) addr, dw, dwoffset);/* SDmaUseLargeBuf has to be set in every descriptor */
drivers/infiniband/ulp/srp/ib_srp.c +1 -0
@@ -2135,6 +2135,7 @@ static int srp_queuecommand(struct Scsi_Host *shost, struct scsi_cmnd *scmnd)if (srp_post_send (ch, iu, len)) {shost_printk (KERN_ERR , target->scsi_host,PFX "Send failed\n" ); + scmnd->result =DID_ERROR <<16 ; goto err_unmap; }
drivers/input/serio/gscps2.c +2 -2
@@ -382,9 +382,9 @@ static int gscps2_probe(struct parisc_device *dev) goto fail;#endif -printk (KERN_INFO "serio: %s port at 0x%p irq %d @ %s\n" , +pr_info ("serio: %s port at 0x%08lx irq %d @ %s\n" , ps2port->port->name, - ps2port->addr, + hpa, ps2port->padev->irq, ps2port->port->phys);
drivers/input/serio/hp_sdc.c +2 -2
@@ -887,8 +887,8 @@ static int __init hp_sdc_init(void) "HP SDC NMI", &hp_sdc)) goto err2; - printk(KERN_INFO PREFIX "HP SDC at 0x%p, IRQ %d (NMI IRQ %d)\n", - (void *)hp_sdc.base_io, hp_sdc.irq, hp_sdc.nmi); +pr_info (PREFIX "HP SDC at 0x%08lx, IRQ %d (NMI IRQ %d)\n" , + hp_sdc.base_io, hp_sdc.irq, hp_sdc.nmi);hp_sdc_status_in8 ();hp_sdc_data_in8 ();
drivers/media/v4l2-core/v4l2-ctrls.c +1 -0
@@ -991,6 +991,7 @@ void v4l2_ctrl_fill(u32 id, const char **name, enum v4l2_ctrl_type *type,case V4L2_CID_FLASH_STROBE_STOP :case V4L2_CID_AUTO_FOCUS_START :case V4L2_CID_AUTO_FOCUS_STOP : +case V4L2_CID_DO_WHITE_BALANCE : *type =V4L2_CTRL_TYPE_BUTTON ; *flags |=V4L2_CTRL_FLAG_WRITE_ONLY |V4L2_CTRL_FLAG_EXECUTE_ON_WRITE ;
drivers/misc/mei/bus.c +5 -4
@@ -761,15 +761,16 @@ static struct device_type mei_cl_device_type = {/** * mei_cl_bus_set_name - set device name for me client device +* <controller>-<client device> +* Example: 0000:00:16.0-55213584-9a29-4916-badf-0fb7ed682aeb * * @cldev: me client device */ static inline void mei_cl_bus_set_name (struct mei_cl_device *cldev) { -dev_set_name (&cldev->dev,"mei:%s:%pUl:%02X" , - cldev->name, -mei_me_cl_uuid (cldev->me_cl), -mei_me_cl_ver (cldev->me_cl)); +dev_set_name (&cldev->dev,"%s-%pUl" , +dev_name (cldev->bus->dev), +mei_me_cl_uuid (cldev->me_cl)); }/**
drivers/mtd/mtdcore.h +1 -1
@@ -6,7 +6,7 @@extern struct mutex mtd_table_mutex;struct mtd_info *__mtd_next_device (int i); -int add_mtd_device (struct mtd_info *mtd); +int __must_check add_mtd_device (struct mtd_info *mtd);int del_mtd_device (struct mtd_info *mtd);int add_mtd_partitions (struct mtd_info *,const struct mtd_partition *,int );int del_mtd_partitions (struct mtd_info *);
drivers/mtd/mtdpart.c +30 -5
@@ -610,10 +610,21 @@ int mtd_add_partition(struct mtd_info *master, const char *name,list_add (&new->list, &mtd_partitions);mutex_unlock (&mtd_partitions_mutex); -add_mtd_device (&new->mtd); + ret =add_mtd_device (&new->mtd); +if (ret) + goto err_remove_part;mtd_add_partition_attrs (new); +return 0 ; + +err_remove_part: +mutex_lock (&mtd_partitions_mutex); +list_del (&new->list); +mutex_unlock (&mtd_partitions_mutex); + +free_partition (new); +return ret; }EXPORT_SYMBOL_GPL (mtd_add_partition);
@@ -658,28 +669,42 @@ int add_mtd_partitions(struct mtd_info *master, {struct mtd_part *slave;uint64_t cur_offset =0 ; -int i; +int i, ret;printk (KERN_NOTICE "Creating %d MTD partitions on \"%s\":\n" , nbparts, master->name);for (i =0 ; i < nbparts; i++) { slave =allocate_partition (master, parts + i, i, cur_offset);if (IS_ERR (slave)) { -del_mtd_partitions (master); -return PTR_ERR (slave); + ret =PTR_ERR (slave); + goto err_del_partitions; }mutex_lock (&mtd_partitions_mutex);list_add (&slave->list, &mtd_partitions);mutex_unlock (&mtd_partitions_mutex); -add_mtd_device (&slave->mtd); + ret =add_mtd_device (&slave->mtd); +if (ret) { +mutex_lock (&mtd_partitions_mutex); +list_del (&slave->list); +mutex_unlock (&mtd_partitions_mutex); + +free_partition (slave); + goto err_del_partitions; + } +mtd_add_partition_attrs (slave); cur_offset = slave->offset + slave->mtd.size; }return 0 ; + +err_del_partitions: +del_mtd_partitions (master); + +return ret; }static DEFINE_SPINLOCK (part_parser_lock);
drivers/mtd/ubi/build.c +1 -1
@@ -1141,10 +1141,10 @@ int ubi_detach_mtd_dev(int ubi_num, int anyway)ubi_wl_close (ubi);ubi_free_internal_volumes (ubi);vfree (ubi->vtbl); -put_mtd_device (ubi->mtd);vfree (ubi->peb_buf);vfree (ubi->fm_buf);ubi_msg (ubi,"mtd%d is detached" , ubi->mtd->index); +put_mtd_device (ubi->mtd);put_device (&ubi->dev);return 0 ; }
drivers/mtd/ubi/kapi.c +1 -1
@@ -227,9 +227,9 @@ out_unlock: out_free:kfree (desc); out_put_ubi: -ubi_put_device (ubi);ubi_err (ubi,"cannot open device %d, volume %d, error %d" , ubi_num, vol_id, err); +ubi_put_device (ubi);return ERR_PTR (err); }EXPORT_SYMBOL_GPL (ubi_open_volume);
drivers/net/can/c_can/c_can.c +26 -0
@@ -52,6 +52,7 @@#define CONTROL_EX_PDR BIT(8)/* control register */ +#define CONTROL_SWR BIT(15)#define CONTROL_TEST BIT(7)#define CONTROL_CCE BIT(6)#define CONTROL_DISABLE_AR BIT(5)
@@ -572,6 +573,26 @@ static void c_can_configure_msg_objects(struct net_device *dev) IF_MCONT_RCV_EOB); } +static int c_can_software_reset (struct net_device *dev) +{ +struct c_can_priv *priv =netdev_priv (dev); +int retry =0 ; + +if (priv->type !=BOSCH_D_CAN ) +return 0 ; + + priv->write_reg (priv,C_CAN_CTRL_REG ,CONTROL_SWR |CONTROL_INIT ); +while (priv->read_reg (priv,C_CAN_CTRL_REG ) &CONTROL_SWR ) { +msleep (20 ); +if (retry++ >100 ) { +netdev_err (dev,"CCTRL: software reset failed\n" ); +return -EIO ; + } + } + +return 0 ; +} +/* * Configure C_CAN chip: * - enable/disable auto-retransmission
@@ -581,6 +602,11 @@ static void c_can_configure_msg_objects(struct net_device *dev)static int c_can_chip_config (struct net_device *dev) {struct c_can_priv *priv =netdev_priv (dev); +int err; + + err =c_can_software_reset (dev); +if (err) +return err;/* enable automatic retransmission */ priv->write_reg (priv,C_CAN_CTRL_REG ,CONTROL_ENABLE_AR );
drivers/net/can/usb/peak_usb/pcan_usb.c +10 -5
@@ -441,8 +441,8 @@ static int pcan_usb_decode_error(struct pcan_usb_msg_context *mc, u8 n, }if ((n &PCAN_USB_ERROR_BUS_LIGHT ) ==0 ) {/* no error (back to active state) */ - mc->pdev->dev.can.state =CAN_STATE_ERROR_ACTIVE ; -return 0 ; + new_state =CAN_STATE_ERROR_ACTIVE ; +break ; }break ;
@@ -465,9 +465,9 @@ static int pcan_usb_decode_error(struct pcan_usb_msg_context *mc, u8 n, }if ((n &PCAN_USB_ERROR_BUS_HEAVY ) ==0 ) { -/* no error (back to active state) */ - mc->pdev->dev.can.state =CAN_STATE_ERROR_ACTIVE ; -return 0 ; +/* no error (back to warning state) */ + new_state =CAN_STATE_ERROR_WARNING ; +break ; }break ;
@@ -506,6 +506,11 @@ static int pcan_usb_decode_error(struct pcan_usb_msg_context *mc, u8 n, mc->pdev->dev.can.can_stats.error_warning++;break ; +case CAN_STATE_ERROR_ACTIVE : + cf->can_id |=CAN_ERR_CRTL ; + cf->data[1 ] =CAN_ERR_CRTL_ACTIVE ; +break ; +default :/* CAN_STATE_MAX (trick to handle other errors) */ cf->can_id |=CAN_ERR_CRTL ;
drivers/net/ethernet/atheros/atl1e/atl1e_main.c +3 -1
@@ -478,7 +478,9 @@ static void atl1e_mdio_write(struct net_device *netdev, int phy_id, {struct atl1e_adapter *adapter =netdev_priv (netdev); -atl1e_write_phy_reg (&adapter->hw, reg_num &MDIO_REG_ADDR_MASK , val); +if (atl1e_write_phy_reg (&adapter->hw, + reg_num &MDIO_REG_ADDR_MASK , val)) +netdev_err (netdev,"write phy register failed\n" ); } static int atl1e_mii_ioctl(struct net_device *netdev,
drivers/net/ethernet/cadence/macb.c +6 -6
@@ -2275,14 +2275,14 @@ static int macb_clk_init(struct platform_device *pdev, struct clk **pclk, *pclk =devm_clk_get (&pdev->dev,"pclk" );if (IS_ERR (*pclk)) { err =PTR_ERR (*pclk); -dev_err (&pdev->dev,"failed to get macb_clk (%u)\n" , err); +dev_err (&pdev->dev,"failed to get macb_clk (%d)\n" , err);return err; } *hclk =devm_clk_get (&pdev->dev,"hclk" );if (IS_ERR (*hclk)) { err =PTR_ERR (*hclk); -dev_err (&pdev->dev,"failed to get hclk (%u)\n" , err); +dev_err (&pdev->dev,"failed to get hclk (%d)\n" , err);return err; }
@@ -2292,19 +2292,19 @@ static int macb_clk_init(struct platform_device *pdev, struct clk **pclk, err =clk_prepare_enable (*pclk);if (err) { -dev_err (&pdev->dev,"failed to enable pclk (%u)\n" , err); +dev_err (&pdev->dev,"failed to enable pclk (%d)\n" , err);return err; } err =clk_prepare_enable (*hclk);if (err) { -dev_err (&pdev->dev,"failed to enable hclk (%u)\n" , err); +dev_err (&pdev->dev,"failed to enable hclk (%d)\n" , err); goto err_disable_pclk; } err =clk_prepare_enable (*tx_clk);if (err) { -dev_err (&pdev->dev,"failed to enable tx_clk (%u)\n" , err); +dev_err (&pdev->dev,"failed to enable tx_clk (%d)\n" , err); goto err_disable_hclk; }
@@ -2704,7 +2704,7 @@ static int at91ether_clk_init(struct platform_device *pdev, struct clk **pclk, err =clk_prepare_enable (*pclk);if (err) { -dev_err (&pdev->dev,"failed to enable pclk (%u)\n" , err); +dev_err (&pdev->dev,"failed to enable pclk (%d)\n" , err);return err; }
drivers/net/ethernet/sfc/ef10.c +21 -8
@@ -4433,22 +4433,25 @@ static const struct efx_ef10_nvram_type_info efx_ef10_nvram_types[] = { { NVRAM_PARTITION_TYPE_LICENSE, 0, 0, "sfc_license" }, { NVRAM_PARTITION_TYPE_PHY_MIN, 0xff, 0, "sfc_phy_fw" }, }; +#define EF10_NVRAM_PARTITION_COUNT ARRAY_SIZE(efx_ef10_nvram_types)static int efx_ef10_mtd_probe_partition (struct efx_nic *efx,struct efx_mcdi_mtd_partition *part, -unsigned int type) +unsigned int type, +unsigned long *found) {MCDI_DECLARE_BUF (inbuf,MC_CMD_NVRAM_METADATA_IN_LEN );MCDI_DECLARE_BUF (outbuf,MC_CMD_NVRAM_METADATA_OUT_LENMAX );const struct efx_ef10_nvram_type_info *info;size_t size, erase_size, outlen; +int type_idx =0 ;bool protected;int rc; -for (info = efx_ef10_nvram_types; ; info++) { -if (info == - efx_ef10_nvram_types +ARRAY_SIZE (efx_ef10_nvram_types)) +for (type_idx =0 ; ; type_idx++) { +if (type_idx ==EF10_NVRAM_PARTITION_COUNT )return -ENODEV ; + info = efx_ef10_nvram_types + type_idx;if ((type & ~info->type_mask) == info->type)break ; }
@@ -4461,6 +4464,13 @@ static int efx_ef10_mtd_probe_partition(struct efx_nic *efx,if (protected)return -ENODEV ;/* hide it */ +/* If we've already exposed a partition of this type, hide this +* duplicate. All operations on MTDs are keyed by the type anyway, +* so we can't act on the duplicate. +*/ +if (__test_and_set_bit (type_idx, found)) +return -EEXIST ; + part->nvram_type = type;MCDI_SET_DWORD (inbuf,NVRAM_METADATA_IN_TYPE , type);
@@ -4489,6 +4499,7 @@ static int efx_ef10_mtd_probe_partition(struct efx_nic *efx,static int efx_ef10_mtd_probe (struct efx_nic *efx) {MCDI_DECLARE_BUF (outbuf,MC_CMD_NVRAM_PARTITIONS_OUT_LENMAX ); + DECLARE_BITMAP(found, EF10_NVRAM_PARTITION_COUNT) = { 0 };struct efx_mcdi_mtd_partition *parts;size_t outlen, n_parts_total, i, n_parts;unsigned int type;
@@ -4517,11 +4528,13 @@ static int efx_ef10_mtd_probe(struct efx_nic *efx)for (i =0 ; i < n_parts_total; i++) { type =MCDI_ARRAY_DWORD (outbuf,NVRAM_PARTITIONS_OUT_TYPE_ID , i); - rc =efx_ef10_mtd_probe_partition (efx, &parts[n_parts], type); -if (rc ==0 ) - n_parts++; -else if (rc != -ENODEV ) + rc =efx_ef10_mtd_probe_partition (efx, &parts[n_parts], type, + found); +if (rc == -EEXIST || rc == -ENODEV ) +continue ; +if (rc) goto fail; + n_parts++; } rc =efx_mtd_add (efx, &parts[0 ].common, n_parts,sizeof (*parts));
drivers/net/ethernet/stmicro/stmmac/dwmac-sunxi.c +3 -1
@@ -59,7 +59,9 @@ static int sun7i_gmac_init(struct platform_device *pdev, void *priv) gmac->clk_enabled =1 ; }else {clk_set_rate (gmac->tx_clk,SUN7I_GMAC_MII_RATE ); -clk_prepare (gmac->tx_clk); + ret =clk_prepare (gmac->tx_clk); +if (ret) +return ret; }return 0 ;
drivers/net/macvlan.c +2 -1
@@ -326,10 +326,11 @@ static void macvlan_broadcast_enqueue(struct macvlan_port *port, }spin_unlock (&port->bc_queue.lock); +schedule_work (&port->bc_work); +if (err) goto free_nskb; -schedule_work (&port->bc_work);return ; free_nskb:
drivers/net/slip/slip.c +1 -0
@@ -860,6 +860,7 @@ err_free_chan: sl->tty =NULL ; tty->disc_data =NULL ;clear_bit (SLF_INUSE , &sl->flags); +sl_free_netdev (sl->dev);free_netdev (sl->dev); err_exit:
drivers/net/wireless/ath/ath6kl/cfg80211.c +2 -2
@@ -932,7 +932,7 @@ static int ath6kl_set_probed_ssids(struct ath6kl *ar,else ssid_list[i].flag =ANY_SSID_FLAG ; -if (n_match_ssid ==0 ) +if (ar->wiphy->max_match_sets !=0 && n_match_ssid ==0 ) ssid_list[i].flag |=MATCH_SSID_FLAG ; }
@@ -1083,7 +1083,7 @@ void ath6kl_cfg80211_scan_complete_event(struct ath6kl_vif *vif, bool aborted)if (vif->scan_req->n_ssids && vif->scan_req->ssids[0 ].ssid_len) {for (i =0 ; i < vif->scan_req->n_ssids; i++) {ath6kl_wmi_probedssid_cmd (ar->wmi, vif->fw_vif_idx, - i +1 ,DISABLE_SSID_FLAG , + i,DISABLE_SSID_FLAG ,0 ,NULL ); } }
drivers/net/wireless/mwifiex/debugfs.c +6 -8
@@ -295,15 +295,13 @@ mwifiex_histogram_read(struct file *file, char __user *ubuf,"total samples = %d\n" , atomic_read(&phist_data->num_samples)); - p +=sprintf (p,"rx rates (in Mbps): 0=1M 1=2M" ); - p +=sprintf (p,"2=5.5M 3=11M 4=6M 5=9M 6=12M\n" ); - p +=sprintf (p,"7=18M 8=24M 9=36M 10=48M 11=54M" ); - p +=sprintf (p,"12-27=MCS0-15(BW20) 28-43=MCS0-15(BW40)\n" ); + p +=sprintf (p, +"rx rates (in Mbps): 0=1M 1=2M 2=5.5M 3=11M 4=6M 5=9M 6=12M\n" +"7=18M 8=24M 9=36M 10=48M 11=54M 12-27=MCS0-15(BW20) 28-43=MCS0-15(BW40)\n" );if (ISSUPP_11ACENABLED (priv->adapter->fw_cap_info)) { - p +=sprintf (p,"44-53=MCS0-9(VHT:BW20)" ); - p +=sprintf (p,"54-63=MCS0-9(VHT:BW40)" ); - p +=sprintf (p,"64-73=MCS0-9(VHT:BW80)\n\n" ); + p +=sprintf (p, +"44-53=MCS0-9(VHT:BW20) 54-63=MCS0-9(VHT:BW40) 64-73=MCS0-9(VHT:BW80)\n\n" ); }else { p +=sprintf (p,"\n" ); }
@@ -332,7 +330,7 @@ mwifiex_histogram_read(struct file *file, char __user *ubuf,for (i =0 ; i <MWIFIEX_MAX_NOISE_FLR ; i++) { value =atomic_read (&phist_data->noise_flr[i]);if (value) - p +=sprintf (p,"noise_flr[-%02ddBm] = %d\n" , + p +=sprintf (p,"noise_flr[%02ddBm] = %d\n" , (int )(i-128 ), value); }for (i =0 ; i <MWIFIEX_MAX_SIG_STRENGTH ; i++) {
drivers/net/wireless/mwifiex/scan.c +10 -8
@@ -1873,15 +1873,17 @@ mwifiex_parse_single_response_buf(struct mwifiex_private *priv, u8 **bss_info, ETH_ALEN))mwifiex_update_curr_bss_params (priv ,bss ); -cfg80211_put_bss (priv->wdev.wiphy, bss); - } -if ((chan->flags &IEEE80211_CHAN_RADAR ) || - (chan->flags &IEEE80211_CHAN_NO_IR )) { -mwifiex_dbg (adapter,INFO , -"radar or passive channel %d\n" , - channel); -mwifiex_save_hidden_ssid_channels (priv, bss); +if ((chan->flags &IEEE80211_CHAN_RADAR ) || + (chan->flags &IEEE80211_CHAN_NO_IR )) { +mwifiex_dbg (adapter,INFO , +"radar or passive channel %d\n" , + channel); +mwifiex_save_hidden_ssid_channels (priv, + bss); + } + +cfg80211_put_bss (priv->wdev.wiphy, bss); } } }else {
drivers/net/wireless/realtek/rtl818x/rtl8187/dev.c +2 -1
@@ -446,12 +446,13 @@ static int rtl8187_init_urbs(struct ieee80211_hw *dev)skb_queue_tail (&priv->rx_queue, skb);usb_anchor_urb (entry, &priv->anchored); ret =usb_submit_urb (entry,GFP_KERNEL ); -usb_put_urb (entry);if (ret) {skb_unlink (skb, &priv->rx_queue);usb_unanchor_urb (entry); +usb_put_urb (entry); goto err; } +usb_put_urb (entry); }return ret;
drivers/pinctrl/sh-pfc/pfc-sh7264.c +7 -2
@@ -1716,6 +1716,9 @@ static const struct pinmux_cfg_reg pinmux_config_regs[] = { }, { PINMUX_CFG_REG("PFCR3", 0xfffe38a8, 16, 4) { +0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 , +0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 , +0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,PF12MD_000 ,PF12MD_001 ,0 ,PF12MD_011 ,PF12MD_100 ,PF12MD_101 ,0 ,0 , 0, 0, 0, 0, 0, 0, 0, 0 }
@@ -1759,8 +1762,10 @@ static const struct pinmux_cfg_reg pinmux_config_regs[] = {0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,PF1MD_000 ,PF1MD_001 ,PF1MD_010 ,PF1MD_011 ,PF1MD_100 ,PF1MD_101 ,0 ,0 , -0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 - } +0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 , +PF0MD_000 ,PF0MD_001 ,PF0MD_010 ,PF0MD_011 , +PF0MD_100 ,PF0MD_101 ,0 ,0 , + 0, 0, 0, 0, 0, 0, 0, 0 } }, { PINMUX_CFG_REG("PFIOR0", 0xfffe38b2, 16, 1) {
drivers/pinctrl/sh-pfc/pfc-sh7734.c +8 -8
@@ -2218,22 +2218,22 @@ static const struct pinmux_cfg_reg pinmux_config_regs[] = {/* IP10_22 [1] */ FN_CAN_CLK_A ,FN_RX4_D ,/* IP10_21_19 [3] */ -FN_AUDIO_CLKOUT ,FN_TX1_E ,FN_HRTS0_C ,FN_FSE_B , -FN_LCD_M_DISP_B ,0 ,0 ,0 , +FN_AUDIO_CLKOUT ,FN_TX1_E ,0 ,FN_HRTS0_C ,FN_FSE_B , +FN_LCD_M_DISP_B ,0 ,0 ,/* IP10_18_16 [3] */ -FN_AUDIO_CLKC ,FN_SCK1_E ,FN_HCTS0_C ,FN_FRB_B , -FN_LCD_VEPWC_B ,0 ,0 ,0 , +FN_AUDIO_CLKC ,FN_SCK1_E ,0 ,FN_HCTS0_C ,FN_FRB_B , +FN_LCD_VEPWC_B ,0 ,0 ,/* IP10_15 [1] */ FN_AUDIO_CLKB_A ,FN_LCD_CLK_B ,/* IP10_14_12 [3] */ FN_AUDIO_CLKA_A ,FN_VI1_CLK_B ,FN_SCK1_D ,FN_IECLK_B ,FN_LCD_FLM_B ,0 ,0 ,0 ,/* IP10_11_9 [3] */ -FN_SSI_SDATA3 ,FN_VI1_7_B ,FN_HTX0_C ,FN_FWE_B , -FN_LCD_CL2_B ,0 ,0 ,0 , +FN_SSI_SDATA3 ,FN_VI1_7_B ,0 ,FN_HTX0_C ,FN_FWE_B , +FN_LCD_CL2_B ,0 ,0 ,/* IP10_8_6 [3] */ -FN_SSI_SDATA2 ,FN_VI1_6_B ,FN_HRX0_C ,FN_FRE_B , -FN_LCD_CL1_B ,0 ,0 ,0 , +FN_SSI_SDATA2 ,FN_VI1_6_B ,0 ,FN_HRX0_C ,FN_FRE_B , +FN_LCD_CL1_B ,0 ,0 ,/* IP10_5_3 [3] */ FN_SSI_WS23 ,FN_VI1_5_B ,FN_TX1_D ,FN_HSCK0_C ,FN_FALE_B , FN_LCD_DON_B, 0, 0, 0,
drivers/platform/x86/hp-wmi.c +3 -3
@@ -90,7 +90,7 @@ struct bios_args {u32 command;u32 commandtype;u32 datasize; -u32 data; +u8 data[128 ]; };struct bios_return {
@@ -199,7 +199,7 @@ static int hp_wmi_perform_query(int query, int write, void *buffer, .command = write ? 0x2 : 0x1, .commandtype = query, .datasize = insize, - .data = 0, + .data = { 0 }, };struct acpi_buffer input = {sizeof (struct bios_args ), &args };struct acpi_buffer output = {ACPI_ALLOCATE_BUFFER ,NULL };
@@ -207,7 +207,7 @@ static int hp_wmi_perform_query(int query, int write, void *buffer,if (WARN_ON (insize >sizeof (args.data)))return -EINVAL ; -memcpy (&args.data, buffer, insize); +memcpy (&args.data[0 ], buffer, insize);wmi_evaluate_method (HPWMI_BIOS_GUID ,0 ,0x3 , &input, &output);
drivers/power/avs/smartreflex.c +1 -2
@@ -1001,8 +1001,7 @@ static int omap_sr_remove(struct platform_device *pdev)if (sr_info->autocomp_active)sr_stop_vddautocomp (sr_info); -if (sr_info->dbg_dir) -debugfs_remove_recursive (sr_info->dbg_dir); +debugfs_remove_recursive (sr_info->dbg_dir);pm_runtime_disable (&pdev->dev);list_del (&sr_info->node);
drivers/pwm/core.c +1 -0
@@ -781,6 +781,7 @@ void pwm_put(struct pwm_device *pwm)if (pwm->chip->ops->free) pwm->chip->ops->free (pwm->chip, pwm); +pwm_set_chip_data (pwm,NULL ); pwm->label =NULL ;module_put (pwm->chip->ops->owner);
drivers/pwm/pwm-samsung.c +0 -1
@@ -226,7 +226,6 @@ static int pwm_samsung_request(struct pwm_chip *chip, struct pwm_device *pwm)static void pwm_samsung_free (struct pwm_chip *chip,struct pwm_device *pwm) {devm_kfree (chip->dev,pwm_get_chip_data (pwm)); -pwm_set_chip_data (pwm,NULL ); }static int pwm_samsung_enable (struct pwm_chip *chip,struct pwm_device *pwm)
drivers/regulator/palmas-regulator.c +4 -1
@@ -435,13 +435,16 @@ static int palmas_ldo_write(struct palmas *palmas, unsigned int reg,static int palmas_set_mode_smps (struct regulator_dev *dev,unsigned int mode) {int id =rdev_get_id (dev); +int ret;struct palmas_pmic *pmic =rdev_get_drvdata (dev);struct palmas_pmic_driver_data *ddata = pmic->palmas->pmic_ddata;struct palmas_regs_info *rinfo = &ddata->palmas_regs_info[id];unsigned int reg;bool rail_enable = true; -palmas_smps_read (pmic->palmas, rinfo->ctrl_addr, ®); + ret =palmas_smps_read (pmic->palmas, rinfo->ctrl_addr, ®); +if (ret) +return ret; reg &= ~PALMAS_SMPS12_CTRL_MODE_ACTIVE_MASK ;
drivers/regulator/tps65910-regulator.c +3 -1
@@ -1102,8 +1102,10 @@ static int tps65910_probe(struct platform_device *pdev)platform_set_drvdata (pdev, pmic);/* Give control of all register to control port */ -tps65910_reg_set_bits (pmic->mfd,TPS65910_DEVCTRL , + err =tps65910_reg_set_bits (pmic->mfd,TPS65910_DEVCTRL ,DEVCTRL_SR_CTL_I2C_SEL_MASK ); +if (err <0 ) +return err;switch (tps65910_chip_id (tps65910)) {case TPS65910 :
drivers/scsi/csiostor/csio_init.c +1 -1
@@ -648,7 +648,7 @@ csio_shost_init(struct csio_hw *hw, struct device *dev,if (csio_lnode_init (ln, hw, pln)) goto err_shost_put; -if (scsi_add_host (shost, dev)) +if (scsi_add_host_with_dma (shost, dev, &hw->pdev->dev)) goto err_lnode_exit;return ln;
drivers/scsi/libsas/sas_expander.c +28 -1
@@ -603,7 +603,14 @@ int sas_smp_phy_control(struct domain_device *dev, int phy_id, } res =smp_execute_task (dev, pc_req,PC_REQ_SIZE , pc_resp,PC_RESP_SIZE ); - +if (res) { +pr_err ("ex %016llx phy%02d PHY control failed: %d\n" , +SAS_ADDR (dev->sas_addr), phy_id, res); + }else if (pc_resp[2 ] !=SMP_RESP_FUNC_ACC ) { +pr_err ("ex %016llx phy%02d PHY control failed: function result 0x%x\n" , +SAS_ADDR (dev->sas_addr), phy_id, pc_resp[2 ]); + res = pc_resp[2 ]; + }kfree (pc_resp);kfree (pc_req);return res;
@@ -806,6 +813,26 @@ static struct domain_device *sas_ex_discover_end_dev(#ifdef CONFIG_SCSI_SAS_ATA if ((phy->attached_tproto &SAS_PROTOCOL_STP ) || phy->attached_sata_dev) { +if (child->linkrate > parent->min_linkrate) { +struct sas_phy_linkrates rates = { + .maximum_linkrate = parent->min_linkrate, + .minimum_linkrate = parent->min_linkrate, + }; +int ret; + +pr_notice ("ex %016llx phy%02d SATA device linkrate > min pathway connection rate, attempting to lower device linkrate\n" , +SAS_ADDR (child->sas_addr), phy_id); + ret =sas_smp_phy_control (parent, phy_id, +PHY_FUNC_LINK_RESET , &rates); +if (ret) { +pr_err ("ex %016llx phy%02d SATA device could not set linkrate (%d)\n" , +SAS_ADDR (child->sas_addr), phy_id, ret); + goto out_free; + } +pr_notice ("ex %016llx phy%02d SATA device set linkrate successfully\n" , +SAS_ADDR (child->sas_addr), phy_id); + child->linkrate = child->min_linkrate; + } res =sas_get_ata_info (child, phy);if (res) goto out_free;
drivers/scsi/lpfc/lpfc_scsi.c +18 -0
@@ -2707,6 +2707,7 @@ lpfc_bg_scsi_prep_dma_buf_s3(struct lpfc_hba *phba,int datasegcnt, protsegcnt, datadir = scsi_cmnd->sc_data_direction;int prot_group_type =0 ;int fcpdl; +struct lpfc_vport *vport = phba->pport;/* * Start the lpfc command prep by bumping the bpl beyond fcp_cmnd
@@ -2812,6 +2813,14 @@ lpfc_bg_scsi_prep_dma_buf_s3(struct lpfc_hba *phba,*/ iocb_cmd->un.fcpi.fcpi_parm = fcpdl; +/* +* For First burst, we may need to adjust the initial transfer +* length for DIF +*/ +if (iocb_cmd->un.fcpi.fcpi_XRdy && + (fcpdl < vport->cfg_first_burst_size)) + iocb_cmd->un.fcpi.fcpi_XRdy = fcpdl; +return 0 ; err:if (lpfc_cmd->seg_cnt)
@@ -3361,6 +3370,7 @@ lpfc_bg_scsi_prep_dma_buf_s4(struct lpfc_hba *phba,int datasegcnt, protsegcnt, datadir = scsi_cmnd->sc_data_direction;int prot_group_type =0 ;int fcpdl; +struct lpfc_vport *vport = phba->pport;/* * Start the lpfc command prep by bumping the sgl beyond fcp_cmnd
@@ -3476,6 +3486,14 @@ lpfc_bg_scsi_prep_dma_buf_s4(struct lpfc_hba *phba,*/ iocb_cmd->un.fcpi.fcpi_parm = fcpdl; +/* +* For First burst, we may need to adjust the initial transfer +* length for DIF +*/ +if (iocb_cmd->un.fcpi.fcpi_XRdy && + (fcpdl < vport->cfg_first_burst_size)) + iocb_cmd->un.fcpi.fcpi_XRdy = fcpdl; +/* * If the OAS driver feature is enabled and the lun is enabled for * OAS, set the oas iocb related flags.
drivers/scsi/qla2xxx/tcm_qla2xxx.c +8 -40
70 lines not on this page · raw message
drivers/scsi/qla2xxx/tcm_qla2xxx.h +0 -3
@@ -47,9 +47,6 @@ struct tcm_qla2xxx_tpg {struct tcm_qla2xxx_tpg_attrib tpg_attrib;/* Returned by tcm_qla2xxx_make_tpg() */ struct se_portal_group se_tpg; -/* Items for dealing with configfs_depend_item */ -struct completion tpg_base_comp; -struct work_struct tpg_base_work; };struct tcm_qla2xxx_fc_loopid {
drivers/staging/rtl8192e/rtl8192e/rtl_core.c +3 -2
@@ -1631,14 +1631,15 @@ static void _rtl92e_hard_data_xmit(struct sk_buff *skb, struct net_device *dev,memcpy ((unsigned char *)(skb->cb), &dev,sizeof (dev));skb_push (skb, priv->rtllib->tx_headroom); ret =_rtl92e_tx (dev, skb); -if (ret !=0 ) -kfree_skb (skb);if (queue_index !=MGNT_QUEUE ) { priv->rtllib->stats.tx_bytes += (skb->len - priv->rtllib->tx_headroom); priv->rtllib->stats.tx_packets++; } + +if (ret !=0 ) +kfree_skb (skb); }static int _rtl92e_hard_start_xmit (struct sk_buff *skb,struct net_device *dev)
drivers/tty/serial/max310x.c +2 -5
@@ -763,12 +763,9 @@ static void max310x_start_tx(struct uart_port *port)static unsigned int max310x_tx_empty (struct uart_port *port) { -unsigned int lvl, sts; +u8 lvl =max310x_port_read (port,MAX310X_TXFIFOLVL_REG ); - lvl =max310x_port_read (port,MAX310X_TXFIFOLVL_REG ); - sts =max310x_port_read (port,MAX310X_IRQSTS_REG ); - -return ((sts &MAX310X_IRQ_TXEMPTY_BIT ) && !lvl) ?TIOCSER_TEMT :0 ; +return lvl ?0 :TIOCSER_TEMT ; }static unsigned int max310x_get_mctrl (struct uart_port *port)
drivers/usb/serial/ftdi_sio.c +3 -0
@@ -1028,6 +1028,9 @@ static const struct usb_device_id id_table_combined[] = {/* Sienna devices */ { USB_DEVICE(FTDI_VID, FTDI_SIENNA_PID) }, { USB_DEVICE(ECHELON_VID, ECHELON_U20_PID) }, +/* U-Blox devices */ + { USB_DEVICE(UBLOX_VID, UBLOX_C099F9P_ZED_PID) }, + { USB_DEVICE(UBLOX_VID, UBLOX_C099F9P_ODIN_PID) }, { } /* Terminating entry */ };
drivers/usb/serial/ftdi_sio_ids.h +7 -0
@@ -1557,3 +1557,10 @@*/ #define UNJO_VID 0x22B7#define UNJO_ISODEBUG_V1_PID 0x150D + +/* +* U-Blox products (http://www.u-blox.com). +*/ +#define UBLOX_VID 0x1546 +#define UBLOX_C099F9P_ZED_PID 0x0502 +#define UBLOX_C099F9P_ODIN_PID 0x0503
drivers/xen/xen-pciback/pci_stub.c +2 -1
@@ -104,7 +104,8 @@ static void pcistub_device_release(struct kref *kref)* is called from "unbind" which takes a device_lock mutex. */ __pci_reset_function_locked (dev); -if (pci_load_and_free_saved_state (dev, &dev_data->pci_saved_state)) +if (dev_data && +pci_load_and_free_saved_state (dev, &dev_data->pci_saved_state))dev_info (&dev->dev,"Could not reload PCI state\n" );else pci_restore_state (dev);
fs/btrfs/delayed-ref.c +0 -3
@@ -193,8 +193,6 @@ static inline void drop_delayed_ref(struct btrfs_trans_handle *trans, ref->in_tree =0 ;btrfs_put_delayed_ref (ref);atomic_dec (&delayed_refs->num_entries); -if (trans->delayed_ref_updates) - trans->delayed_ref_updates--; } static bool merge_ref(struct btrfs_trans_handle *trans,
@@ -444,7 +442,6 @@ add_delayed_ref_tail_merge(struct btrfs_trans_handle *trans, add_tail:list_add_tail (&ref->list, &href->ref_list);atomic_inc (&root->num_entries); - trans->delayed_ref_updates++;spin_unlock (&href->lock);return ret; }
fs/gfs2/bmap.c +2 -0
@@ -1235,6 +1235,8 @@ static int do_grow(struct inode *inode, u64 size) } error =gfs2_trans_begin (sdp,RES_DINODE +RES_STATFS +RES_RG_BIT + + (unstuff && +gfs2_is_jdata (ip) ?RES_JDATA :0 ) + (sdp->sd_args.ar_quota ==GFS2_QUOTA_OFF ?0 :RES_QUOTA ),0 );if (error)
fs/ocfs2/journal.c +2 -4
@@ -1017,7 +1017,8 @@ void ocfs2_journal_shutdown(struct ocfs2_super *osb)mlog_errno (status); } -if (status ==0 ) { +/* Shutdown the kernel journal system */ +if (!jbd2_journal_destroy (journal->j_journal) && !status) {/* * Do not toggle if flush was unsuccessful otherwise * will leave dirty metadata in a "clean" journal
@@ -1026,9 +1027,6 @@ void ocfs2_journal_shutdown(struct ocfs2_super *osb)if (status <0 )mlog_errno (status); } - -/* Shutdown the kernel journal system */ -jbd2_journal_destroy (journal->j_journal); journal->j_journal =NULL ;OCFS2_I (inode)->ip_open_count--;
fs/xfs/xfs_ioctl32.c +6 -0
@@ -346,6 +346,7 @@ xfs_compat_attrlist_by_handle( {int error;attrlist_cursor_kern_t *cursor; +compat_xfs_fsop_attrlist_handlereq_t __user *p = arg;compat_xfs_fsop_attrlist_handlereq_t al_hreq;struct dentry *dentry;char *kbuf;
@@ -380,6 +381,11 @@ xfs_compat_attrlist_by_handle(if (error) goto out_kfree; +if (copy_to_user (&p->pos, cursor,sizeof (attrlist_cursor_kern_t))) { + error = -EFAULT ; + goto out_kfree; + } +if (copy_to_user (compat_ptr (al_hreq.buffer), kbuf, al_hreq.buflen)) error = -EFAULT ;
fs/xfs/xfs_rtalloc.c +1 -3
@@ -1225,13 +1225,11 @@ xfs_rtmount_inodes(xfs_sb_t *sbp; sbp = &mp->m_sb; -if (sbp->sb_rbmino ==NULLFSINO ) -return 0 ; error =xfs_iget (mp,NULL , sbp->sb_rbmino,0 ,0 , &mp->m_rbmip);if (error)return error;ASSERT (mp->m_rbmip !=NULL ); -ASSERT (sbp->sb_rsumino !=NULLFSINO ); + error =xfs_iget (mp,NULL , sbp->sb_rsumino,0 ,0 , &mp->m_rsumip);if (error) {IRELE (mp->m_rbmip);
include/linux/gpio/consumer.h +1 -1
@@ -398,7 +398,7 @@ static inline int gpiod_to_irq(const struct gpio_desc *desc)static inline struct gpio_desc *gpio_to_desc (unsigned gpio) { -return ERR_PTR (-EINVAL ); +return NULL ; }static inline int desc_to_gpio (const struct gpio_desc *desc)
include/linux/netdevice.h +1 -1
@@ -3298,7 +3298,7 @@ static inline u32 netif_msg_init(int debug_value, int default_msg_enable_bits)if (debug_value ==0 )/* no output */ return 0 ;/* set low N bits */ -return (1 << debug_value) -1 ; +return (1U << debug_value) -1 ; }static inline void __netif_tx_lock (struct netdev_queue *txq,int cpu)
include/linux/reset-controller.h +1 -1
@@ -6,7 +6,7 @@struct reset_controller_dev ;/** -* struct reset_control_ops +* struct reset_control_ops - reset controller driver callbacks * * @reset: for self-deasserting resets, does all necessary * things to reset the device
include/net/sock.h +1 -1
@@ -1282,7 +1282,7 @@ static inline void sk_sockets_allocated_inc(struct sock *sk)percpu_counter_inc (prot->sockets_allocated); } -static inline int +static inline u64 sk_sockets_allocated_read_positive (struct sock *sk) {struct proto *prot = sk->sk_prot;
lib/genalloc.c +3 -2
@@ -35,6 +35,7 @@#include <linux/interrupt.h> #include <linux/genalloc.h> #include <linux/of_device.h> +#include <linux/vmalloc.h> static inline size_t chunk_size (const struct gen_pool_chunk *chunk) {
@@ -187,7 +188,7 @@ int gen_pool_add_virt(struct gen_pool *pool, unsigned long virt, phys_addr_t phyint nbytes =sizeof (struct gen_pool_chunk ) +BITS_TO_LONGS (nbits) *sizeof (long ); - chunk =kzalloc_node (nbytes,GFP_KERNEL , nid); + chunk =vzalloc_node (nbytes, nid);if (unlikely (chunk ==NULL ))return -ENOMEM ;
@@ -251,7 +252,7 @@ void gen_pool_destroy(struct gen_pool *pool) bit =find_next_bit (chunk->bits, end_bit,0 );BUG_ON (bit < end_bit); -kfree (chunk); +vfree (chunk); }kfree_const (pool->name);kfree (pool);
net/core/neighbour.c +9 -4
@@ -18,6 +18,7 @@#define pr_fmt (fmt) KBUILD_MODNAME ": " fmt#include <linux/slab.h> +#include <linux/kmemleak.h> #include <linux/types.h> #include <linux/kernel.h> #include <linux/module.h>
@@ -325,12 +326,14 @@ static struct neigh_hash_table *neigh_hash_alloc(unsigned int shift) ret =kmalloc (sizeof (*ret),GFP_ATOMIC );if (!ret)return NULL ; -if (size <=PAGE_SIZE ) +if (size <=PAGE_SIZE ) { buckets =kzalloc (size,GFP_ATOMIC ); -else + }else { buckets = (struct neighbour __rcu **)__get_free_pages (GFP_ATOMIC | __GFP_ZERO,get_order (size)); +kmemleak_alloc (buckets, size,1 ,GFP_ATOMIC ); + }if (!buckets) {kfree (ret);return NULL ;
@@ -350,10 +353,12 @@ static void neigh_hash_free_rcu(struct rcu_head *head)size_t size = (1 << nht->hash_shift) *sizeof (struct neighbour *);struct neighbour __rcu **buckets = nht->hash_buckets; -if (size <=PAGE_SIZE ) +if (size <=PAGE_SIZE ) {kfree (buckets); -else + }else { +kmemleak_free (buckets);free_pages ((unsigned long )buckets,get_order (size)); + }kfree (nht); }
net/core/net_namespace.c +2 -1
@@ -778,7 +778,8 @@ static int __init net_ns_init(void)mutex_unlock (&net_mutex); -register_pernet_subsys (&net_ns_ops); +if (register_pernet_subsys (&net_ns_ops)) +panic ("Could not register network namespace subsystems" );rtnl_register (PF_UNSPEC ,RTM_NEWNSID , rtnl_net_newid,NULL ,NULL ); rtnl_register(PF_UNSPEC, RTM_GETNSID, rtnl_net_getid, rtnl_net_dumpid,
net/core/sock.c +1 -1
@@ -2122,7 +2122,7 @@ int __sk_mem_schedule(struct sock *sk, int size, int kind) }if (sk_has_memory_pressure (sk)) { -int alloc; +u64 alloc;if (!sk_under_memory_pressure (sk))return 1 ;
net/decnet/dn_dev.c +1 -1
@@ -55,7 +55,7 @@#include <net/dn_neigh.h> #include <net/dn_fib.h> -#define DN_IFREQ_SIZE (sizeof(struct ifreq) - sizeof(struct sockaddr) + sizeof(struct sockaddr_dn)) +#define DN_IFREQ_SIZE (offsetof(struct ifreq, ifr_ifru) + sizeof(struct sockaddr_dn))static char dn_rt_all_end_mcast[ETH_ALEN ] = {0xAB ,0x00 ,0x00 ,0x04 ,0x00 ,0x00 };static char dn_rt_all_rt_mcast[ETH_ALEN ] = {0xAB ,0x00 ,0x00 ,0x03 ,0x00 ,0x00 };
net/openvswitch/datapath.c +14 -3
@@ -725,9 +725,13 @@ static size_t ovs_flow_cmd_msg_size(const struct sw_flow_actions *acts, {size_t len =NLMSG_ALIGN (sizeof (struct ovs_header )); -/* OVS_FLOW_ATTR_UFID */ +/* OVS_FLOW_ATTR_UFID, or unmasked flow key as fallback +* see ovs_nla_put_identifier() +*/ if (sfid &&ovs_identifier_is_ufid (sfid)) len +=nla_total_size (sfid->ufid_len); +else + len +=nla_total_size (ovs_key_attr_size ());/* OVS_FLOW_ATTR_KEY */ if (!sfid ||should_fill_key (sfid, ufid_flags))
@@ -900,7 +904,10 @@ static struct sk_buff *ovs_flow_cmd_build_info(const struct sw_flow *flow, retval =ovs_flow_cmd_fill_info (flow, dp_ifindex, skb, info->snd_portid, info->snd_seq,0 , cmd, ufid_flags); -BUG_ON (retval <0 ); +if (WARN_ON_ONCE (retval <0 )) { +kfree_skb (skb); + skb =ERR_PTR (retval); + }return skb; }
@@ -1318,7 +1325,10 @@ static int ovs_flow_cmd_del(struct sk_buff *skb, struct genl_info *info)OVS_FLOW_CMD_DEL , ufid_flags);rcu_read_unlock (); -BUG_ON (err <0 ); +if (WARN_ON_ONCE (err <0 )) { +kfree_skb (reply); + goto out_free; + }ovs_notify (&dp_flow_genl_family, reply, info); }else {
@@ -1326,6 +1336,7 @@ static int ovs_flow_cmd_del(struct sk_buff *skb, struct genl_info *info) } } +out_free:ovs_flow_free (flow, true);return 0 ; unlock:
net/sched/sch_mq.c +1 -1
@@ -195,7 +195,7 @@ static int mq_dump_class_stats(struct Qdisc *sch, unsigned long cl,struct netdev_queue *dev_queue =mq_queue_get (sch, cl); sch = dev_queue->qdisc_sleeping; -if (gnet_stats_copy_basic (d,NULL , &sch->bstats) <0 || +if (gnet_stats_copy_basic (d, sch->cpu_bstats, &sch->bstats) <0 ||gnet_stats_copy_queue (d,NULL , &sch->qstats, sch->q.qlen) <0 )return -1 ;return 0 ;
net/sched/sch_mqprio.c +2 -1
@@ -355,7 +355,8 @@ static int mqprio_dump_class_stats(struct Qdisc *sch, unsigned long cl,struct netdev_queue *dev_queue =mqprio_queue_get (sch, cl); sch = dev_queue->qdisc_sleeping; -if (gnet_stats_copy_basic (d,NULL , &sch->bstats) <0 || +if (gnet_stats_copy_basic (d, sch->cpu_bstats, + &sch->bstats) <0 ||gnet_stats_copy_queue (d,NULL , &sch->qstats, sch->q.qlen) <0 )return -1 ;
net/sched/sch_multiq.c +1 -1
@@ -351,7 +351,7 @@ static int multiq_dump_class_stats(struct Qdisc *sch, unsigned long cl,struct Qdisc *cl_q; cl_q = q->queues[cl -1 ]; -if (gnet_stats_copy_basic (d,NULL , &cl_q->bstats) <0 || +if (gnet_stats_copy_basic (d, cl_q->cpu_bstats, &cl_q->bstats) <0 ||gnet_stats_copy_queue (d,NULL , &cl_q->qstats, cl_q->q.qlen) <0 )return -1 ;
net/sched/sch_prio.c +1 -1
@@ -319,7 +319,7 @@ static int prio_dump_class_stats(struct Qdisc *sch, unsigned long cl,struct Qdisc *cl_q; cl_q = q->queues[cl -1 ]; -if (gnet_stats_copy_basic (d,NULL , &cl_q->bstats) <0 || +if (gnet_stats_copy_basic (d, cl_q->cpu_bstats, &cl_q->bstats) <0 ||gnet_stats_copy_queue (d,NULL , &cl_q->qstats, cl_q->q.qlen) <0 )return -1 ;
net/tipc/link.c +1 -1
@@ -883,7 +883,7 @@ static bool tipc_data_input(struct tipc_link *l, struct sk_buff *skb,default :pr_warn ("Dropping received illegal msg type\n" );kfree_skb (skb); -return false; +return true; }; }
net/tipc/netlink_compat.c +6 -2
@@ -516,7 +516,7 @@ static int tipc_nl_compat_link_stat_dump(struct tipc_nl_compat_msg *msg,if (len <=0 )return -EINVAL ; - len =min_t (int, len,TIPC_MAX_BEARER_NAME ); + len =min_t (int, len,TIPC_MAX_LINK_NAME );if (!string_is_valid (name, len))return -EINVAL ;
@@ -791,7 +791,7 @@ static int tipc_nl_compat_link_reset_stats(struct tipc_nl_compat_cmd_doit *cmd,if (len <=0 )return -EINVAL ; - len =min_t (int, len,TIPC_MAX_BEARER_NAME ); + len =min_t (int, len,TIPC_MAX_LINK_NAME );if (!string_is_valid (name, len))return -EINVAL ;
@@ -926,6 +926,10 @@ static int tipc_nl_compat_publ_dump(struct tipc_nl_compat_msg *msg, u32 sock) hdr =genlmsg_put (args,0 ,0 , &tipc_genl_family,NLM_F_MULTI ,TIPC_NL_PUBL_GET ); +if (!hdr) { +kfree_skb (args); +return -EMSGSIZE ; + } nest =nla_nest_start (args,TIPC_NLA_SOCK );if (!nest) {
net/vmw_vsock/af_vsock.c +6 -1
@@ -89,6 +89,7 @@#include <linux/mutex.h> #include <linux/net.h> #include <linux/poll.h> +#include <linux/random.h> #include <linux/skbuff.h> #include <linux/smp.h> #include <linux/socket.h>
@@ -483,9 +484,13 @@ out:static int __vsock_bind_stream (struct vsock_sock *vsk,struct sockaddr_vm *addr) { -static u32 port =LAST_RESERVED_PORT +1 ; +static u32 port =0 ;struct sockaddr_vm new_addr; +if (!port) + port =LAST_RESERVED_PORT +1 + +prandom_u32_max (U32_MAX -LAST_RESERVED_PORT ); +vsock_addr_init (&new_addr, addr->svm_cid, addr->svm_port);if (addr->svm_port ==VMADDR_PORT_ANY ) {
scripts/gdb/linux/symbols.py +2 -1
@@ -99,7 +99,8 @@ lx-symbols command.""" attrs[n]['name'].string(): attrs[n]['address'] for n in range(int(sect_attrs['nsections']))} args = [] - for section_name in [".data", ".data..read_mostly", ".rodata", ".bss"]: + for section_name in [".data", ".data..read_mostly", ".rodata", ".bss", + ".text", ".text.hot", ".text.unlikely"]: address = section_name_to_address.get(section_name) if address: args.append(" -s {name} {addr}".format(
sound/core/compress_offload.c +1 -1
@@ -501,7 +501,7 @@ static int snd_compress_check_input(struct snd_compr_params *params) {/* first let's check the buffer parameter's */ if (params->buffer.fragment_size ==0 || - params->buffer.fragments >INT_MAX / params->buffer.fragment_size || + params->buffer.fragments >U32_MAX / params->buffer.fragment_size || params->buffer.fragments ==0 )return -EINVAL ;
sound/soc/kirkwood/kirkwood-i2s.c +4 -4
@@ -570,10 +570,6 @@ static int kirkwood_i2s_dev_probe(struct platform_device *pdev)return PTR_ERR (priv->clk); } - err =clk_prepare_enable (priv->clk); -if (err <0 ) -return err; - priv->extclk =devm_clk_get (&pdev->dev,"extclk" );if (IS_ERR (priv->extclk)) {if (PTR_ERR (priv->extclk) == -EPROBE_DEFER )
@@ -589,6 +585,10 @@ static int kirkwood_i2s_dev_probe(struct platform_device *pdev) } } + err =clk_prepare_enable (priv->clk); +if (err <0 ) +return err; +/* Some sensible defaults - this reflects the powerup values */ priv->ctl_play =KIRKWOOD_PLAYCTL_SIZE_24 ; priv->ctl_rec =KIRKWOOD_RECCTL_SIZE_24 ;