Linux 4.9.269
Greg Kroah-Hartman
maintainerI'm announcing the release of the 4.9.269 kernel.
All users of the 4.9 kernel series must upgrade.
The updated 4.9.y git tree can be found at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-4.9.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
------------
Makefile | 2 arch/arc/kernel/entry.S | 4 - arch/arm/boot/dts/exynos5250-smdk5250.dts | 2 arch/arm/boot/dts/exynos5250-snow-common.dtsi | 2 arch/arm/kernel/hw_breakpoint.c | 2 arch/arm64/boot/dts/mediatek/mt8173.dtsi | 2 arch/arm64/kernel/vdso/vdso.lds.S | 8 ++ arch/mips/include/asm/div64.h | 55 +++++++++++----- arch/mips/pci/pci-legacy.c | 9 ++ arch/powerpc/Kconfig.debug | 1 arch/powerpc/include/uapi/asm/errno.h | 1 arch/powerpc/kernel/eeh.c | 11 +-- arch/powerpc/kernel/iommu.c | 4 - arch/powerpc/kernel/prom.c | 2 arch/powerpc/lib/feature-fixups.c | 17 ++++- arch/powerpc/perf/isa207-common.c | 4 - arch/powerpc/platforms/52xx/lite5200_sleep.S | 2 arch/powerpc/platforms/pseries/hotplug-cpu.c | 3 arch/powerpc/platforms/pseries/pci_dlpar.c | 4 - arch/s390/kernel/dis.c | 2 arch/um/kernel/dyn.lds.S | 6 + arch/um/kernel/uml.lds.S | 6 + arch/x86/Kconfig | 1 arch/x86/Makefile | 1 arch/x86/events/amd/iommu.c | 6 - arch/x86/kvm/x86.c | 1 arch/x86/lib/msr-smp.c | 4 - drivers/acpi/custom_method.c | 4 - drivers/acpi/scan.c | 1 drivers/ata/libahci_platform.c | 4 - drivers/ata/pata_arasan_cf.c | 15 +++- drivers/ata/pata_ixp4xx_cf.c | 6 + drivers/ata/sata_mv.c | 4 + drivers/bus/qcom-ebi2.c | 4 - drivers/char/ttyprintk.c | 11 +++ drivers/clk/samsung/clk-exynos7.c | 7 +- drivers/clk/socfpga/clk-gate-a10.c | 1 drivers/clk/uniphier/clk-uniphier-mux.c | 4 - drivers/crypto/qat/qat_c3xxxvf/adf_drv.c | 4 - drivers/crypto/qat/qat_c62xvf/adf_drv.c | 4 - drivers/crypto/qat/qat_common/adf_isr.c | 29 ++++++-- drivers/crypto/qat/qat_common/adf_transport.c | 1 drivers/crypto/qat/qat_common/adf_vf_isr.c | 17 +++-- drivers/crypto/qat/qat_dh895xccvf/adf_drv.c | 4 - drivers/extcon/extcon-arizona.c | 17 ++--- drivers/firmware/Kconfig | 1 drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c | 2 drivers/gpu/drm/msm/mdp/mdp5/mdp5_cmd_encoder.c | 10 ++- drivers/gpu/drm/radeon/radeon_atombios.c | 6 - drivers/gpu/drm/radeon/radeon_kms.c | 1 drivers/hid/hid-ids.h | 1 drivers/hid/hid-plantronics.c | 60 +++++++++++++++++- drivers/hsi/hsi_core.c | 3 drivers/hv/channel_mgmt.c | 30 +++++++-- drivers/hwtracing/intel_th/gth.c | 4 - drivers/i2c/busses/i2c-cadence.c | 5 + drivers/i2c/busses/i2c-emev2.c | 5 + drivers/i2c/busses/i2c-jz4780.c | 5 + drivers/i2c/busses/i2c-sh7760.c | 5 + drivers/iio/proximity/pulsedlight-lidar-lite-v2.c | 1 drivers/infiniband/hw/i40iw/i40iw_pble.c | 6 - drivers/input/touchscreen/silead.c | 44 ++++++++++++- drivers/isdn/capi/kcapi.c | 4 - drivers/md/dm-ioctl.c | 2 drivers/md/dm-rq.c | 2 drivers/md/md.c | 43 +++++++----- drivers/md/persistent-data/dm-btree-internal.h | 4 - drivers/md/persistent-data/dm-space-map-common.c | 2 drivers/md/persistent-data/dm-space-map-common.h | 8 +- drivers/media/dvb-core/dvbdev.c | 1 drivers/media/i2c/adv7511-v4l2.c | 2 drivers/media/i2c/adv7604.c | 2 drivers/media/i2c/adv7842.c | 2 drivers/media/pci/saa7164/saa7164-encoder.c | 20 +++--- drivers/media/platform/vivid/vivid-vid-out.c | 2 drivers/media/rc/ite-cir.c | 8 ++ drivers/media/tuners/m88rs6000t.c | 6 - drivers/media/usb/dvb-usb/dvb-usb-init.c | 20 ++++-- drivers/media/usb/dvb-usb/dvb-usb.h | 3 drivers/media/usb/em28xx/em28xx-dvb.c | 1 drivers/media/usb/gspca/gspca.c | 2 drivers/media/usb/gspca/gspca.h | 1 drivers/media/usb/gspca/sq905.c | 2 drivers/media/usb/gspca/stv06xx/stv06xx.c | 9 ++ drivers/memory/omap-gpmc.c | 7 +- drivers/misc/kgdbts.c | 26 +++---- drivers/misc/lis3lv02d/lis3lv02d.c | 21 ++++-- drivers/misc/vmw_vmci/vmci_doorbell.c | 2 drivers/misc/vmw_vmci/vmci_guest.c | 2 drivers/mmc/core/core.c | 2 drivers/mmc/core/sd.c | 6 + drivers/mtd/mtdchar.c | 8 +- drivers/mtd/nand/gpmi-nand/gpmi-nand.c | 2 drivers/net/ethernet/cavium/liquidio/cn23xx_pf_regs.h | 2 drivers/net/ethernet/cavium/thunder/nicvf_queues.c | 2 drivers/net/ethernet/chelsio/cxgb4/cxgb4_debugfs.c | 2 drivers/net/ethernet/mediatek/mtk_eth_soc.c | 2 drivers/net/ethernet/mediatek/mtk_eth_soc.h | 1 drivers/net/ethernet/qualcomm/emac/emac-mac.c | 4 - drivers/net/ethernet/stmicro/stmmac/dwmac-ipq806x.c | 2 drivers/net/ethernet/ti/davinci_emac.c | 4 - drivers/net/fddi/Kconfig | 15 ++-- drivers/net/fddi/defxx.c | 47 +++++++++----- drivers/net/usb/ax88179_178a.c | 4 - drivers/net/wan/lapbether.c | 32 +++++++-- drivers/net/wimax/i2400m/op-rfkill.c | 2 drivers/net/wireless/ath/ath9k/htc_drv_init.c | 2 drivers/net/wireless/ath/ath9k/hw.c | 2 drivers/net/wireless/intel/ipw2x00/libipw_wx.c | 6 + drivers/net/wireless/intel/iwlwifi/pcie/tx.c | 7 +- drivers/net/wireless/marvell/mwl8k.c | 1 drivers/net/wireless/mediatek/mt7601u/eeprom.c | 2 drivers/net/wireless/wl3501.h | 47 ++++++-------- drivers/net/wireless/wl3501_cs.c | 54 ++++++++-------- drivers/nfc/pn533/pn533.c | 3 drivers/of/fdt.c | 12 --- drivers/pci/hotplug/acpiphp_glue.c | 1 drivers/pci/pci.c | 16 ---- drivers/pci/probe.c | 1 drivers/phy/phy-twl4030-usb.c | 2 drivers/platform/x86/thinkpad_acpi.c | 31 ++++++--- drivers/power/supply/generic-adc-battery.c | 2 drivers/power/supply/lp8788-charger.c | 2 drivers/power/supply/pm2301_charger.c | 2 drivers/power/supply/s3c_adc_battery.c | 2 drivers/power/supply/tps65090-charger.c | 2 drivers/power/supply/tps65217_charger.c | 2 drivers/scsi/device_handler/scsi_dh_alua.c | 5 - drivers/scsi/jazz_esp.c | 4 - drivers/scsi/libfc/fc_lport.c | 2 drivers/scsi/lpfc/lpfc_nportdisc.c | 2 drivers/scsi/lpfc/lpfc_sli.c | 1 drivers/scsi/qla2xxx/qla_attr.c | 8 ++ drivers/scsi/sni_53c710.c | 5 + drivers/scsi/sun3x_esp.c | 4 - drivers/spi/spi-dln2.c | 2 drivers/spi/spi-omap-100k.c | 6 - drivers/staging/greybus/uart.c | 2 drivers/staging/media/omap4iss/iss.c | 4 - drivers/staging/rtl8192u/r8192U_core.c | 2 drivers/target/target_core_pscsi.c | 3 drivers/thermal/fair_share.c | 4 + drivers/tty/serial/stm32-usart.c | 12 +++ drivers/tty/tty_io.c | 8 +- drivers/usb/class/cdc-acm.c | 2 drivers/usb/core/hub.c | 6 - drivers/usb/core/quirks.c | 4 + drivers/usb/dwc2/core.h | 2 drivers/usb/dwc2/gadget.c | 3 drivers/usb/dwc3/gadget.c | 9 ++ drivers/usb/gadget/config.c | 4 + drivers/usb/gadget/function/f_fs.c | 3 drivers/usb/gadget/function/f_uvc.c | 7 +- drivers/usb/gadget/udc/dummy_hcd.c | 23 ++++-- drivers/usb/gadget/udc/fotg210-udc.c | 26 +++++-- drivers/usb/gadget/udc/pch_udc.c | 49 +++++++++----- drivers/usb/gadget/udc/r8a66597-udc.c | 2 drivers/usb/host/fotg210-hcd.c | 4 - drivers/usb/host/sl811-hcd.c | 9 +- drivers/usb/host/xhci-ext-caps.h | 5 - drivers/usb/host/xhci-mem.c | 9 ++ drivers/usb/host/xhci.c | 6 - drivers/video/fbdev/core/fbcmap.c | 8 +- fs/btrfs/ioctl.c | 18 ++++- fs/btrfs/relocation.c | 6 - fs/ceph/caps.c | 1 fs/ceph/inode.c | 1 fs/dlm/debug_fs.c | 1 fs/ecryptfs/main.c | 6 + fs/ext4/ialloc.c | 48 +++++++++----- fs/ext4/super.c | 6 + fs/f2fs/inline.c | 3 fs/fuse/cuse.c | 2 fs/jffs2/compr_rtime.c | 3 fs/jffs2/scan.c | 2 fs/nfs/flexfilelayout/flexfilelayout.c | 2 fs/nfs/inode.c | 8 +- fs/nfs/nfs42proc.c | 21 +++--- fs/nfs/pnfs.c | 2 fs/squashfs/file.c | 6 - include/linux/extcon/extcon-adc-jack.h | 2 include/linux/hid.h | 2 include/linux/tty_driver.h | 2 include/net/bluetooth/hci_core.h | 1 include/scsi/libfcoe.h | 2 include/uapi/linux/tty_flags.h | 4 - kernel/futex.c | 3 kernel/kexec_file.c | 4 - kernel/trace/ftrace.c | 5 + kernel/trace/trace.c | 45 +++++-------- kernel/trace/trace_clock.c | 44 +++++++++---- lib/kobject_uevent.c | 9 +- lib/stackdepot.c | 6 - mm/hugetlb.c | 11 ++- mm/khugepaged.c | 18 ++--- mm/ksm.c | 1 net/bluetooth/hci_event.c | 3 net/bluetooth/hci_request.c | 12 ++- net/bluetooth/l2cap_core.c | 4 + net/hsr/hsr_framereg.c | 3 net/ipv6/ip6_gre.c | 3 net/ipv6/ip6_tunnel.c | 3 net/ipv6/ip6_vti.c | 3 net/ipv6/sit.c | 5 - net/mac80211/main.c | 7 +- net/mac80211/mlme.c | 5 + net/netfilter/nf_conntrack_standalone.c | 5 + net/nfc/digital_dep.c | 2 net/nfc/llcp_sock.c | 4 + net/openvswitch/actions.c | 8 +- net/sctp/sm_make_chunk.c | 2 net/sctp/sm_statefuns.c | 3 net/sctp/socket.c | 38 ++++++----- net/tipc/netlink_compat.c | 2 net/vmw_vsock/vmci_transport.c | 3 net/wireless/scan.c | 2 samples/bpf/tracex1_kern.c | 4 - samples/kfifo/bytestream-example.c | 8 +- samples/kfifo/inttype-example.c | 8 +- samples/kfifo/record-example.c | 8 +- scripts/kconfig/nconf.c | 2 sound/core/init.c | 2 sound/isa/sb/emu8000.c | 4 - sound/isa/sb/sb16_csp.c | 8 +- sound/pci/hda/hda_generic.c | 16 +++- sound/pci/hda/patch_realtek.c | 21 +++--- sound/pci/rme9652/hdsp.c | 3 sound/pci/rme9652/hdspm.c | 3 sound/pci/rme9652/rme9652.c | 3 sound/soc/codecs/rt286.c | 23 +++--- sound/usb/card.c | 14 ++-- sound/usb/quirks-table.h | 10 +++ sound/usb/quirks.c | 16 +++- sound/usb/usbaudio.h | 2 tools/perf/util/symbol_fprintf.c | 2 tools/testing/selftests/lib.mk | 4 + 236 files changed, 1236 insertions(+), 620 deletions(-)
Alexander Aring (1):
fs: dlm: fix debugfs dump
Alexey Kardashevskiy (1):
powerpc/iommu: Annotate nested lock for lockdep
Amey Telawane (1):
tracing: Use strlcpy() instead of strcpy() in __trace_find_cmdline()
Andy Shevchenko (4):
usb: gadget: pch_udc: Revert d3cb25a12138 completely
usb: gadget: pch_udc: Replace cpu_to_le32() by lower_32_bits()
usb: gadget: pch_udc: Check if driver is present before calling ->setup()
usb: gadget: pch_udc: Check for DMA mapping error
Anirudh Rayabharam (1):
usb: gadget: dummy_hcd: fix gpf in gadget_setup
Archie Pusaka (2):
Bluetooth: verify AMP hci_chan before amp_destroy
Bluetooth: Set CONF_NOT_COMPLETE as l2cap_chan default
Arnaldo Carvalho de Melo (1):
perf symbols: Fix dso__fprintf_symbols_by_name() to return the number of printed chars
Arnd Bergmann (6):
scsi: fcoe: Fix mismatched fcoe_wwn_from_mac declaration
media: dvb-usb-remote: fix dvb_usb_nec_rc_key_to_event type mismatch x86/msr: Fix wr/rdmsr_safe_regs_on_cpu() prototypes
kgdb: fix gcc-11 warning on indentation
usb: sl811-hcd: improve misleading indentation
isdn: capi: fix mismatched prototypes
Athira Rajeev (1):
powerpc/perf: Fix PMU constraint check for EBB events
Bart Van Assche (2):
scsi: qla2xxx: Always check the return value of qla24xx_get_isp_stats()
scsi: libfc: Fix a format specifier
Benjamin Block (1):
dm rq: fix double free of blk_mq_tag_set in dev remove after table load fails
Bill Wendling (1):
arm64/vdso: Discard .note.gnu.property sections in vDSO
Chaitanya Kulkarni (1):
scsi: target: pscsi: Fix warning in pscsi_complete_cmd()
Chris Chiu (1):
USB: Add reset-resume quirk for WD19's Realtek Hub
Christoph Hellwig (1):
md: factor out a mddev_find_locked helper from mddev_find
Christophe JAILLET (3):
usb: fotg210-hcd: Fix an error message
ACPI: scan: Fix a memory leak in an error handling path
xhci: Do not use GFP_KERNEL in (potentially) atomic context
Christophe Leroy (1):
powerpc/52xx: Fix an invalid ASM expression ('addi' used instead of 'add')
Chunfeng Yun (2):
arm64: dts: mt8173: fix property typo of 'phys' in dsi node
usb: core: hub: fix race condition about TRSMRCY of resume
Colin Ian King (13):
clk: socfpga: arria10: Fix memory leak of socfpga_clk on error return drm/radeon: fix copy of uninitialized variable back to userspace
memory: gpmc: fix out of bounds read and dereference on gpmc_cs[]
staging: rtl8192u: Fix potential infinite loop
usb: gadget: r8a66597: Add missing null check on return from platform_get_resource
media: vivid: fix assignment of dev->fbuf_out_flags
media: m88rs6000t: avoid potential out-of-bounds reads on arrays
clk: uniphier: Fix potential infinite loop
liquidio: Fix unintented sign extension of a left shift of a u16
mt7601u: fix always true expression
net: thunderx: Fix unintentional sign extension issue
net: davinci_emac: Fix incorrect masking of tx and rx error channel
f2fs: fix a redundant call to f2fs_balance_fs if an error occurs
Dan Carpenter (4):
ipw2x00: potential buffer overflow in libipw_wx_set_encodeext()
HSI: core: fix resource leaks in hsi_add_client_from_dt()
nfc: pn533: prevent potential memory corruption
kfifo: fix ternary sign extension bugs
Daniel Niv (1):
media: media/saa7164: fix saa7164_encoder_register() memory leak bugs
David Ward (2):
ASoC: rt286: Generalize support for ALC3263 codec
ASoC: rt286: Make RT286_SET_GPIO_* readable and writable
Davide Caratti (1):
openvswitch: fix stack OOB read while fragmenting IPv4 packets
Dean Anderson (1):
usb: gadget/function/f_fs string table fix for multiple languages
Dinghao Liu (1):
iio: proximity: pulsedlight: Fix rumtime PM imbalance on error
Dmitry Baryshkov (1):
PCI: Release OF node in pci_scan_device()'s error path
DooHyun Hwang (1):
mmc: core: Do a power cycle when the CMD11 fails
Emmanuel Grumbach (1):
mac80211: clear the beacon's CRC after channel switch
Eric Dumazet (4):
ip6_vti: proper dev_{hold|put} in ndo_[un]init methods
sit: proper dev_{hold|put} in ndo_[un]init methods
ip6_tunnel: sit: proper dev_{hold|put} in ndo_[un]init methods
ipv6: remove extra dev_hold() for fallback tunnels
Erwan Le Ray (1):
serial: stm32: fix incorrect characters on console
Ewan D. Milne (1):
scsi: scsi_dh_alua: Remove check for ASC 24h in alua_rtpg()
Fabian Vogt (6):
fotg210-udc: Fix DMA on EP0 for length > max packet size
fotg210-udc: Fix EP0 IN requests bigger than two packets
fotg210-udc: Remove a dubious condition leading to fotg210_done
fotg210-udc: Mask GRP2 interrupts we don't handle
fotg210-udc: Don't DMA more than the buffer can take
fotg210-udc: Complete OUT requests on short packets
Feilong Lin (1):
ACPI / hotplug / PCI: Fix reference count leak in enable_slot()
Felix Fietkau (1):
net: ethernet: mtk_eth_soc: fix RX VLAN offload
Fengnan Chang (1):
ext4: fix error code in ext4_commit_super
Filipe Manana (1):
btrfs: fix metadata extent leak after failure to create subvolume
Giovanni Cabiddu (1):
crypto: qat - fix error path in adf_isr_resource_alloc()
Greg Kroah-Hartman (2):
kobject_uevent: remove warning in init_uevent_argv() Linux 4.9.269
Guchun Chen (1):
drm/amdgpu: fix NULL pointer dereference
Gustavo A. R. Silva (3):
sctp: Fix out-of-bounds warning in sctp_process_asconf_param()
wl3501_cs: Fix out-of-bounds warnings in wl3501_send_pkt
wl3501_cs: Fix out-of-bounds warnings in wl3501_mgmt_join
Hans Verkuil (2):
media: gspca/sq905.c: fix uninitialized variable
media: gscpa/stv06xx: fix memory leak
Hans de Goede (3):
extcon: arizona: Fix some issues when HPDET IRQ fires after the jack has been unplugged
misc: lis3lv02d: Fix false-positive WARN on various HP models
Input: silead - add workaround for x86 BIOS-es which bring the chip up in a stuck state
He Ying (1):
firmware: qcom-scm: Fix QCOM_SCM configuration
Hemant Kumar (1):
usb: gadget: Fix double free of device descriptor pointers
Heming Zhao (1):
md-cluster: fix use-after-free issue when removing rdev
Hoang Le (1):
tipc: convert dest node's address to network order
Hui Wang (1):
ALSA: hda: generic: change the DAC ctl name for LO+SPK or LO+HP
Ilya Lipnitskiy (1):
MIPS: pci-legacy: stop using of_pci_range_to_resource
Ingo Molnar (1):
x86/platform/uv: Fix !KEXEC build failure
James Smart (1):
scsi: lpfc: Fix crash when a REG_RPI mailbox fails triggering a LOGO response
Jeff Layton (1):
ceph: fix fscache invalidation
Jeffrey Mitchell (1):
ecryptfs: fix kernel panic with null dev_name
Jia Zhou (1):
ALSA: core: remove redundant spin_lock pair in snd_card_disconnect
Jia-Ju Bai (1):
kernel: kexec_file: fix error return code of kexec_calculate_store_digests()
Jiri Kosina (1):
iwlwifi: Fix softirq/hardirq disabling in iwl_pcie_enqueue_hcmd()
Joe Thornber (2):
dm persistent data: packed struct should have an aligned() attribute too dm space map common: fix division bug in sm_ll_find_free_block()
Joel Fernandes (1):
tracing: Treat recording comm for idle task as a success
Johan Hovold (4):
staging: greybus: uart: fix unprivileged TIOCCSERIAL
USB: cdc-acm: fix unprivileged TIOCCSERIAL
tty: actually undefine superseded ASYNC flags
tty: fix return value for unsupported ioctls
Johannes Berg (3):
cfg80211: scan: drop entry from hidden_list on overflow
mac80211: bail out if cipher schemes are invalid
um: Mark all kernel symbols as local
John Millikin (1):
x86/build: Propagate $(CLANG_FLAGS) to $(REALMODE_FLAGS)
Jonathan McDowell (1):
net: stmmac: Set FIFO sizes for ipq806x
Jonathon Reinhart (1):
netfilter: conntrack: Make global sysctls readonly in non-init netns
Josef Bacik (1):
btrfs: convert logic BUG_ON()'s in replace_path to ASSERT()'s
Kai-Heng Feng (1):
USB: Add LPM quirk for Lenovo ThinkPad USB-C Dock Gen2 Ethernet
Kaixu Xia (1):
cxgb4: Fix the -Wmisleading-indentation warning
Kees Cook (1):
drm/radeon: Fix off-by-one power_state index heap overwrite
Krzysztof Kozlowski (2):
ARM: dts: exynos: correct PMIC interrupt trigger level on SMDK5250
ARM: dts: exynos: correct PMIC interrupt trigger level on Snow
Lin Ma (1):
bluetooth: eliminate the potential race condition when removing the HCI controller
Lukasz Luba (1):
thermal/core/fair share: Lock the thermal zone while looping over instances
Lv Yunlong (7):
ALSA: emu8000: Fix a use after free in snd_emu8000_create_mixer
ALSA: sb: Fix two use after free in snd_sb_qsound_build
mtd: rawnand: gpmi: Fix a double free in gpmi_nand_init
crypto: qat - Fix a double free in adf_create_ring
mwl8k: Fix a double Free in mwl8k_probe_hw net:emac/emac-mac: Fix a use after free in emac_mac_tx_buf_send net:nfc:digital: Fix a double free in digital_tg_recv_dep_req
Maciej W. Rozycki (5):
FDDI: defxx: Bail out gracefully with unassigned PCI resource for CSR
FDDI: defxx: Make MMIO the configuration default except for EISA
MIPS: Reinstate platform `__div64_32' handler
MIPS: Avoid DIVU in `__div64_32' is result would be zero
MIPS: Avoid handcoded DIVU in `__div64_32' altogether
Mahesh Salgaonkar (1):
powerpc/eeh: Fix EEH handling for hugepages in ioremap space.
Marijn Suijten (1):
drm/msm/mdp5: Configure PP_SYNC_HEIGHT to double the vtotal
Mark Langsdorf (2):
ACPI: custom_method: fix potential use-after-free issue
ACPI: custom_method: fix a possible memory leak
Mark Pearson (1):
platform/x86: thinkpad_acpi: Correct thermal sensor allocation
Maxim Mikityanskiy (1):
HID: plantronics: Workaround for double volume key presses
Maximilian Luz (1):
usb: xhci: Increase timeout for HC halt
Miaohe Lin (3):
khugepaged: fix wrong result value for trace_mm_collapse_huge_page_isolate() mm/hugeltb: handle the error case in hugetlb_fix_reserve_counts()
ksm: fix potential missing rmap_item for stable_node
Michael Ellerman (2):
powerpc/pseries: Stop calling printk in rtas_stop_self() powerpc/64s: Fix crashes when toggling entry flush barrier
Michael Kelley (1):
Drivers: hv: vmbus: Increase wait time for VMbus unload
Michael Walle (1):
mtd: require write permissions for locking and badblock ioctls
Mihai Moldovan (1):
kconfig: nconf: stop endless search loops
Miklos Szeredi (1):
cuse: prevent clone
Mikulas Patocka (1):
dm ioctl: fix out of bounds array access when no devices
Muhammad Usama Anjum (1):
media: em28xx: fix memory leak
Nathan Chancellor (2):
x86/events/amd/iommu: Fix sysfs type mismatch powerpc/prom: Mark identical_pvr_fixup as __init
Nikola Livic (1):
pNFS/flexfiles: fix incorrect size check in decode_nfs_fh()
Olga Kornievskaia (1):
NFSv4.2 fix handling of sr_eof in SEEK's reply
Or Cohen (1):
net/nfc: fix use-after-free llcp_sock_bind/connect
Pan Bian (1):
bus: qcom: Put child node before return
Pavel Machek (1):
intel_th: Consistency and off-by-one fix
Pavel Skripkin (1):
media: dvb-usb: fix memory leak in dvb_usb_adapter_init
Pawel Laszczak (1):
usb: gadget: uvc: add bInterval checking for HS mode
Paweł Chmiel (1):
clk: exynos7: Mark aclk_fsys1_200 as critical
Peilin Ye (1):
media: dvbdev: Fix memory leak in dvb_media_device_free()
Peter Foley (1):
extcon: adc-jack: Fix incompatible pointer type warning
Phil Elwell (1):
usb: dwc2: Fix gadget DMA unmap direction
Phillip Lougher (1):
squashfs: fix divide error in calculate_skip()
Phillip Potter (2):
net: usb: ax88179_178a: initialize local variables before use
fbdev: zero-fill colormap in fbcmap.c
Quentin Perret (2):
Revert "of/fdt: Make sure no-map does not remove already reserved regions" Revert "fdt: Properly handle "no-map" field in the memory region"
Rafael J. Wysocki (1):
PCI: PM: Do not read power state in pci_enable_device_flags()
Randy Dunlap (1):
powerpc: iommu: fix build when neither PCI or IBMVIO is set
Sean Young (1):
media: ite-cir: check for receive overflow
Sergey Shtylyov (12):
pata_arasan_cf: fix IRQ check
pata_ipx4xx_cf: fix IRQ check
sata_mv: add IRQ checks
ata: libahci_platform: fix IRQ check
scsi: jazz_esp: Add IRQ check
scsi: sun3x_esp: Add IRQ check
scsi: sni_53c710: Add IRQ check
i2c: cadence: add IRQ check
i2c: emev2: add IRQ check
i2c: jz4780: add IRQ check
i2c: sh7760: add IRQ check
i2c: sh7760: fix IRQ error path
Seunghui Lee (1):
mmc: core: Set read only for SD cards with permanent write protect bit
Sindhu Devale (1):
RDMA/i40iw: Fix error unwinding when i40iw_hmc_sd_one fails
Stefano Garzarella (1):
vsock/vmci: log once the failed queue pair allocation
Steven Rostedt (VMware) (3):
ftrace: Handle commands when closing set_ftrace_filter file
tracing: Map all PIDs to command lines
tracing: Restructure trace_clock_global() to never block
Taehee Yoo (1):
hsr: use netdev_err() instead of WARN_ONCE()
Takashi Iwai (7):
ALSA: usb-audio: Add MIDI quirk for Vox ToneLab EX
ALSA: hda/realtek: Re-order ALC882 Acer quirk table entries
ALSA: hda/realtek: Re-order ALC882 Sony quirk table entries
ALSA: hda/realtek: Re-order ALC269 Sony quirk table entries
ALSA: hda/realtek: Re-order ALC269 Lenovo quirk table entries
ALSA: hda/realtek: Remove redundant entry for ALC861 Haier/Uniwill devices
ALSA: usb-audio: Add error checks for usb_driver_claim_interface() calls
Tetsuo Handa (4):
misc: vmw_vmci: explicitly initialize vmci_notify_bm_set_msg struct
misc: vmw_vmci: explicitly initialize vmci_datagram payload
ttyprintk: Add TTY hangup callback.
Bluetooth: initialize skb_queue_head at l2cap_chan_create()
Thinh Nguyen (1):
usb: xhci: Fix port minor revision
Thomas Gleixner (2):
Revert 337f13046ff0 ("futex: Allow FUTEX_CLOCK_REALTIME with FUTEX_WAIT op")
KVM: x86: Cancel pvclock_gtod_work on module removal
Toke Høiland-Jørgensen (1):
ath9k: Fix error check in ath9k_hw_read_revisions() for PCI devices
Tong Zhang (5):
crypto: qat - don't release uninitialized resources
crypto: qat - ADF_STATUS_PF_RUNNING should be set after adf_dev_init
ALSA: hdsp: don't disable if not enabled
ALSA: hdspm: don't disable if not enabled
ALSA: rme9652: don't disable if not enabled
Tony Ambardar (1):
powerpc: fix EDEADLOCK redefinition error in uapi/asm/errno.h
Trond Myklebust (3):
NFSv4: Don't discard segments marked for return in _pnfs_return_layout() NFSv4.2: Always flush out writes in nfs42_proc_fallocate()
NFS: Deal correctly with attribute generation counter overflow
Tyrel Datwyler (1):
powerpc/pseries: extract host bridge from pci_bus prior to bus removal
Vasily Gorbik (1):
s390/disassembler: increase ebpf disasm buffer size
Vineet Gupta (1):
ARC: entry: fix off-by-one error in syscall number validation
Wei Yongjun (2):
spi: dln2: Fix reference leak to master
spi: omap-100k: Fix reference leak to master
Wesley Cheng (1):
usb: dwc3: gadget: Ignore EP queue requests during bus reset
Xie He (1):
net: lapbether: Prevent racing when checking whether the netif is running
Xin Long (3):
Revert "net/sctp: fix race condition in sctp_destroy_sock"
sctp: delay auto_asconf init until binding the first addr
sctp: fix a SCTP_MIB_CURRESTAB leak in sctp_sf_do_dupcook_b
Yang Yang (1):
jffs2: check the validity of dstlen in jffs2_zlib_compress()
Yang Yingliang (7):
phy: phy-twl4030-usb: Fix possible use-after-free in twl4030_usb_remove()
power: supply: generic-adc-battery: fix possible use-after-free in gab_remove()
power: supply: s3c_adc_battery: fix possible use-after-free in s3c_adc_bat_remove()
media: adv7604: fix possible use-after-free in adv76xx_remove()
media: i2c: adv7511-v4l2: fix possible use-after-free in adv7511_remove()
media: i2c: adv7842: fix possible use-after-free in adv7842_remove()
media: omap4iss: return error code when omap4iss_get() failed
Yaqi Chen (1):
samples/bpf: Fix broken tracex1 due to kprobe argument change
Yonghong Song (1):
selftests: Set CC to clang in lib.mk if LLVM is set
Zhang Yi (1):
ext4: fix check to prevent false positive report of incorrect used inodes
Zhao Heming (1):
md: md_open returns -EBUSY when entering racing area
Zhen Lei (1):
ARM: 9064/1: hw_breakpoint: Do not directly check the event's overflow_handler hook
Zqiang (1):
lib: stackdepot: turn depot_lock spinlock to raw_spinlock
dongjian (1):
power: supply: Use IRQF_ONESHOT
karthik alapati (1):
staging: wimax/i2400m: fix byte-order issue
lizhe (1):
jffs2: Fix kasan slab-out-of-bounds problem
Greg Kroah-Hartman
maintainerMakefile +1 -1
@@ -1,6 +1,6 @@ VERSION = 4 PATCHLEVEL = 9 -SUBLEVEL = 268 +SUBLEVEL = 269 EXTRAVERSION = NAME = Roaring Lionus
arch/arc/kernel/entry.S +2 -2
@@ -169,7 +169,7 @@ tracesys: ; Do the Sys Call as we normally would. ; Validate the Sys Call number - cmp r8, NR_syscalls + cmp r8, NR_syscalls - 1 mov.hi r0, -ENOSYS bhi tracesys_exit
@@ -252,7 +252,7 @@ ENTRY(EV_Trap) ;============ Normal syscall case ; syscall num shd not exceed the total system calls avail - cmp r8, NR_syscalls + cmp r8, NR_syscalls - 1 mov.hi r0, -ENOSYS bhi .Lret_from_system_call
arch/arm/boot/dts/exynos5250-smdk5250.dts +1 -1
@@ -134,7 +134,7 @@ compatible = "maxim,max77686"; reg = <0x09>; interrupt-parent = <&gpx3>; - interrupts = <2 IRQ_TYPE_NONE>; + interrupts = <2 IRQ_TYPE_LEVEL_LOW>; pinctrl-names = "default"; pinctrl-0 = <&max77686_irq>; wakeup-source;
arch/arm/boot/dts/exynos5250-snow-common.dtsi +1 -1
@@ -280,7 +280,7 @@ max77686: max77686@09 { compatible = "maxim,max77686"; interrupt-parent = <&gpx3>; - interrupts = <2 IRQ_TYPE_NONE>; + interrupts = <2 IRQ_TYPE_LEVEL_LOW>; pinctrl-names = "default"; pinctrl-0 = <&max77686_irq>; wakeup-source;
arch/arm/kernel/hw_breakpoint.c +1 -1
@@ -891,7 +891,7 @@ static void breakpoint_handler(unsigned long unknown, struct pt_regs *regs) info->trigger = addr;pr_debug ("breakpoint fired: address = 0x%x\n" , addr);perf_bp_event (bp, regs); -if (!bp->overflow_handler) +if (is_default_overflow_handler (bp))enable_single_step (bp, addr); goto unlock; }
arch/arm64/boot/dts/mediatek/mt8173.dtsi +1 -1
@@ -914,7 +914,7 @@ <&mmsys CLK_MM_DSI1_DIGITAL>, <&mipi_tx1>; clock-names = "engine", "digital", "hs"; - phy = <&mipi_tx1>; + phys = <&mipi_tx1>; phy-names = "dphy"; status = "disabled"; };
arch/arm64/kernel/vdso/vdso.lds.S +7 -1
@@ -39,6 +39,13 @@ SECTIONS .gnu.version_d : { *(.gnu.version_d) } .gnu.version_r : { *(.gnu.version_r) } + /* + * Discard .note.gnu.property sections which are unused and have + * different alignment requirement from vDSO note sections. + */ + /DISCARD/ : { + *(.note.GNU-stack .note.gnu.property) + } .note : { *(.note.*) } :text :note . = ALIGN(16);
@@ -59,7 +66,6 @@ SECTIONS PROVIDE(end = .); /DISCARD/ : { - *(.note.GNU-stack) *(.data .data.* .gnu.linkonce.d.* .sdata*) *(.bss .sbss .dynbss .dynsbss) }
arch/mips/include/asm/div64.h +39 -16
87 lines not on this page · raw message
arch/mips/pci/pci-legacy.c +7 -2
@@ -158,8 +158,13 @@ void pci_load_of_ranges(struct pci_controller *hose, struct device_node *node) res = hose->mem_resource;break ; } -if (res !=NULL ) -of_pci_range_to_resource (&range, node, res); +if (res !=NULL ) { + res->name = node->full_name; + res->flags = range.flags; + res->start = range.cpu_addr; + res->end = range.cpu_addr + range.size -1 ; + res->parent = res->child = res->sibling =NULL ; + } } }
arch/powerpc/Kconfig.debug +1 -0
@@ -348,6 +348,7 @@ config PPC_EARLY_DEBUG_CPM_ADDR config FAIL_IOMMU bool "Fault-injection capability for IOMMU" depends on FAULT_INJECTION + depends on PCI || IBMVIO help Provide fault-injection capability for IOMMU. Each device can be selectively enabled via the fail_iommu property.
arch/powerpc/include/uapi/asm/errno.h +1 -0
@@ -1,6 +1,7 @@#ifndef _ASM_POWERPC_ERRNO_H#define _ASM_POWERPC_ERRNO_H +#undef EDEADLOCK#include <asm-generic/errno.h> #undef EDEADLOCK
arch/powerpc/kernel/eeh.c +4 -7
@@ -366,14 +366,11 @@ static inline unsigned long eeh_token_to_phys(unsigned long token) pa =pte_pfn (*ptep);/* On radix we can do hugepage mappings for io, so handle that */ -if (hugepage_shift) { - pa <<= hugepage_shift; - pa |= token & ((1ul << hugepage_shift) -1 ); - }else { - pa <<=PAGE_SHIFT ; - pa |= token & (PAGE_SIZE -1 ); - } +if (!hugepage_shift) + hugepage_shift =PAGE_SHIFT ; + pa <<=PAGE_SHIFT ; + pa |= token & ((1ul << hugepage_shift) -1 );return pa; }
arch/powerpc/kernel/iommu.c +2 -2
@@ -1021,7 +1021,7 @@ int iommu_take_ownership(struct iommu_table *tbl)spin_lock_irqsave (&tbl->large_pool.lock, flags);for (i =0 ; i < tbl->nr_pools; i++) -spin_lock (&tbl->pools[i].lock); +spin_lock_nest_lock (&tbl->pools[i].lock, &tbl->large_pool.lock);if (tbl->it_offset ==0 )clear_bit (0 , tbl->it_map);
@@ -1050,7 +1050,7 @@ void iommu_release_ownership(struct iommu_table *tbl)spin_lock_irqsave (&tbl->large_pool.lock, flags);for (i =0 ; i < tbl->nr_pools; i++) -spin_lock (&tbl->pools[i].lock); +spin_lock_nest_lock (&tbl->pools[i].lock, &tbl->large_pool.lock);memset (tbl->it_map,0 , sz);
arch/powerpc/kernel/prom.c +1 -1
@@ -262,7 +262,7 @@ static struct feature_property { };#if defined(CONFIG_44x) && defined(CONFIG_PPC_FPU ) -static inline void identical_pvr_fixup (unsigned long node) +static __init void identical_pvr_fixup (unsigned long node) {unsigned int pvr;const char *model =of_get_flat_dt_prop (node,"model" ,NULL );
arch/powerpc/lib/feature-fixups.c +16 -1
@@ -17,6 +17,7 @@#include <linux/kernel.h> #include <linux/string.h> #include <linux/init.h> +#include <linux/stop_machine.h> #include <asm/cputable.h> #include <asm/code-patching.h> #include <asm/page.h>
@@ -282,8 +283,9 @@ void do_uaccess_flush_fixups(enum l1d_flush_type types) : "unknown"); } -void do_entry_flush_fixups (enum l1d_flush_type types) +static int __do_entry_flush_fixups (void *data) { +enum l1d_flush_type types = *(enum l1d_flush_type *)data;unsigned int instrs[3 ], *dest;long *start, *end;int i;
@@ -334,6 +336,19 @@ void do_entry_flush_fixups(enum l1d_flush_type types) : "ori type" : (types &L1D_FLUSH_MTTRIG ) ?"mttrig type" : "unknown"); + +return 0 ; +} + +void do_entry_flush_fixups (enum l1d_flush_type types) +{ +/* +* The call to the fallback flush can not be safely patched in/out while +* other CPUs are executing it. So call __do_entry_flush_fixups() on one +* CPU while all other CPUs spin in the stop machine core with interrupts +* hard disabled. +*/ +stop_machine (__do_entry_flush_fixups, &types,NULL ); }void do_rfi_flush_fixups (enum l1d_flush_type types)
arch/powerpc/perf/isa207-common.c +2 -2
@@ -139,8 +139,8 @@ int isa207_get_constraint(u64 event, unsigned long *maskp, unsigned long *valp)* EBB events are pinned & exclusive, so this should never actually * hit, but we leave it as a fallback in case. */ - mask |=CNST_EBB_VAL (ebb); - value |=CNST_EBB_MASK ; + mask |=CNST_EBB_MASK ; + value |=CNST_EBB_VAL (ebb); *maskp = mask; *valp = value;
arch/powerpc/platforms/52xx/lite5200_sleep.S +1 -1
@@ -180,7 +180,7 @@ sram_code: udelay: /* r11 - tb_ticks_per_usec, r12 - usecs, overwrites r13 */ mullw r12, r12, r11 mftb r13 /* start */ - addi r12, r13, r12 /* end */ + add r12, r13, r12 /* end */ 1: mftb r13 /* current */ cmp cr0, r13, r12
arch/powerpc/platforms/pseries/hotplug-cpu.c +0 -3
@@ -92,9 +92,6 @@ static void rtas_stop_self(void)BUG_ON (rtas_stop_self_token ==RTAS_UNKNOWN_SERVICE ); -printk ("cpu %u (hwid %u) Ready to die...\n" , -smp_processor_id (),hard_smp_processor_id ()); -rtas_call_unlocked (&args, rtas_stop_self_token,0 ,1 ,NULL );panic ("Alas, I survived.\n" );
arch/powerpc/platforms/pseries/pci_dlpar.c +3 -1
@@ -66,6 +66,7 @@ EXPORT_SYMBOL_GPL(init_phb_dynamic);int remove_phb_dynamic (struct pci_controller *phb) {struct pci_bus *b = phb->bus; +struct pci_host_bridge *host_bridge =to_pci_host_bridge (b->bridge);struct resource *res;int rc, i;
@@ -92,7 +93,8 @@ int remove_phb_dynamic(struct pci_controller *phb)/* Remove the PCI bus and unregister the bridge device from sysfs */ phb->bus =NULL ;pci_remove_bus (b); -device_unregister (b->bridge); + host_bridge->bus =NULL ; +device_unregister (&host_bridge->dev);/* Now release the IO resource */ if (res->flags &IORESOURCE_IO )
arch/s390/kernel/dis.c +1 -1
@@ -2026,7 +2026,7 @@ void show_code(struct pt_regs *regs)void print_fn_code (unsigned char *code,unsigned long len) { -char buffer[64 ], *ptr; +char buffer[128 ], *ptr;int opsize, i;while (len) {
arch/um/kernel/dyn.lds.S +6 -0
@@ -6,6 +6,12 @@ OUTPUT_ARCH(ELF_ARCH) ENTRY(_start) jiffies = jiffies_64; +VERSION { + { + local: *; + }; +} + SECTIONS { PROVIDE (__executable_start = START);
arch/um/kernel/uml.lds.S +6 -0
@@ -6,6 +6,12 @@ OUTPUT_ARCH(ELF_ARCH) ENTRY(_start) jiffies = jiffies_64; +VERSION { + { + local: *; + }; +} + SECTIONS { /* This must contain the right address - not quite the default ELF one.*/
arch/x86/Kconfig +1 -0
@@ -495,6 +495,7 @@ config X86_UV depends on X86_EXTENDED_PLATFORM depends on NUMA depends on EFI + depends on KEXEC_CORE depends on X86_X2APIC depends on PCI ---help---
arch/x86/Makefile +1 -0
@@ -40,6 +40,7 @@ REALMODE_CFLAGS += $(call __cc-option, $(CC), $(REALMODE_CFLAGS), -ffreestanding REALMODE_CFLAGS += $(call __cc-option, $(CC), $(REALMODE_CFLAGS), -fno-stack-protector) REALMODE_CFLAGS += $(call __cc-option, $(CC), $(REALMODE_CFLAGS), -Wno-address-of-packed-member) REALMODE_CFLAGS += $(call __cc-option, $(CC), $(REALMODE_CFLAGS), $(cc_stack_align4)) +REALMODE_CFLAGS += $(CLANG_FLAGS) export REALMODE_CFLAGS # BITS is used as extension for files which are available in a 32 bit
arch/x86/events/amd/iommu.c +3 -3
@@ -80,12 +80,12 @@ static struct attribute_group amd_iommu_format_group = {* sysfs events attributes *---------------------------------------------*/ struct amd_iommu_event_desc { -struct kobj_attribute attr; +struct device_attribute attr;const char *event; }; -static ssize_t _iommu_event_show (struct kobject *kobj, -struct kobj_attribute *attr,char *buf) +static ssize_t _iommu_event_show (struct device *dev, +struct device_attribute *attr,char *buf) {struct amd_iommu_event_desc *event = container_of(attr, struct amd_iommu_event_desc, attr);
arch/x86/kvm/x86.c +1 -0
@@ -6268,6 +6268,7 @@ void kvm_arch_exit(void)cpuhp_remove_state_nocalls (CPUHP_AP_X86_KVM_CLK_ONLINE );#ifdef CONFIG_X86_64 pvclock_gtod_unregister_notifier (&pvclock_gtod_notifier); +cancel_work_sync (&pvclock_gtod_work);#endif kvm_x86_ops =NULL ;kvm_mmu_module_exit ();
arch/x86/lib/msr-smp.c +2 -2
@@ -239,7 +239,7 @@ static void __wrmsr_safe_regs_on_cpu(void *info) rv->err =wrmsr_safe_regs (rv->regs); } -int rdmsr_safe_regs_on_cpu (unsigned int cpu,u32 *regs) +int rdmsr_safe_regs_on_cpu (unsigned int cpu,u32 regs[8 ]) {int err;struct msr_regs_info rv;
@@ -252,7 +252,7 @@ int rdmsr_safe_regs_on_cpu(unsigned int cpu, u32 *regs) }EXPORT_SYMBOL (rdmsr_safe_regs_on_cpu); -int wrmsr_safe_regs_on_cpu (unsigned int cpu,u32 *regs) +int wrmsr_safe_regs_on_cpu (unsigned int cpu,u32 regs[8 ]) {int err;struct msr_regs_info rv;
drivers/acpi/custom_method.c +3 -1
@@ -37,6 +37,8 @@ static ssize_t cm_write(struct file *file, const char __user * user_buf, sizeof(struct acpi_table_header)))return -EFAULT ; uncopied_bytes = max_size = table.length; +/* make sure the buf is not allocated */ +kfree (buf); buf =kzalloc (max_size,GFP_KERNEL );if (!buf)return -ENOMEM ;
@@ -50,6 +52,7 @@ static ssize_t cm_write(struct file *file, const char __user * user_buf, (*ppos + count < count) || (count > uncopied_bytes)) {kfree (buf); + buf =NULL ;return -EINVAL ; }
@@ -71,7 +74,6 @@ static ssize_t cm_write(struct file *file, const char __user * user_buf,add_taint (TAINT_OVERRIDDEN_ACPI_TABLE ,LOCKDEP_NOW_UNRELIABLE ); } -kfree (buf);return count; }
drivers/acpi/scan.c +1 -0
@@ -704,6 +704,7 @@ int acpi_device_add(struct acpi_device *device, result =acpi_device_set_name (device, acpi_device_bus_id);if (result) { +kfree_const (acpi_device_bus_id->bus_id);kfree (acpi_device_bus_id); goto err_unlock; }
drivers/ata/libahci_platform.c +3 -1
@@ -518,11 +518,13 @@ int ahci_platform_init_host(struct platform_device *pdev,int i, irq, n_ports, rc; irq =platform_get_irq (pdev,0 ); -if (irq <=0 ) { +if (irq <0 ) {if (irq != -EPROBE_DEFER )dev_err (dev,"no irq\n" );return irq; } +if (!irq) +return -EINVAL ; hpriv->irq = irq;
drivers/ata/pata_arasan_cf.c +11 -4
@@ -819,12 +819,19 @@ static int arasan_cf_probe(struct platform_device *pdev)else quirk =CF_BROKEN_UDMA ;/* as it is on spear1340 */ -/* if irq is 0, support only PIO */ - acdev->irq =platform_get_irq (pdev,0 ); -if (acdev->irq) +/* +* If there's an error getting IRQ (or we do get IRQ0), +* support only PIO +*/ + ret =platform_get_irq (pdev,0 ); +if (ret >0 ) { + acdev->irq = ret; irq_handler = arasan_cf_interrupt; -else + }else if (ret == -EPROBE_DEFER ) { +return ret; + }else { quirk |=CF_BROKEN_MWDMA |CF_BROKEN_UDMA ; + } acdev->pbase = res->start; acdev->vbase = devm_ioremap_nocache(&pdev->dev, res->start,
drivers/ata/pata_ixp4xx_cf.c +5 -1
@@ -169,8 +169,12 @@ static int ixp4xx_pata_probe(struct platform_device *pdev)return -ENOMEM ; irq =platform_get_irq (pdev,0 ); -if (irq) +if (irq >0 )irq_set_irq_type (irq,IRQ_TYPE_EDGE_RISING ); +else if (irq <0 ) +return irq; +else +return -EINVAL ;/* Setup expansion bus chip selects */ *data->cs0_cfg = data->cs0_bits;
drivers/ata/sata_mv.c +4 -0
@@ -4112,6 +4112,10 @@ static int mv_platform_probe(struct platform_device *pdev) n_ports = mv_platform_data->n_ports; irq =platform_get_irq (pdev,0 ); } +if (irq <0 ) +return irq; +if (!irq) +return -EINVAL ; host =ata_host_alloc_pinfo (&pdev->dev, ppi, n_ports); hpriv =devm_kzalloc (&pdev->dev,sizeof (*hpriv),GFP_KERNEL );
drivers/bus/qcom-ebi2.c +3 -1
@@ -357,8 +357,10 @@ static int qcom_ebi2_probe(struct platform_device *pdev)/* Figure out the chipselect */ ret =of_property_read_u32 (child,"reg" , &csindex); -if (ret) +if (ret) { +of_node_put (child);return ret; + }if (csindex >5 ) { dev_err(dev,
drivers/char/ttyprintk.c +11 -0
@@ -159,12 +159,23 @@ static int tpk_ioctl(struct tty_struct *tty,return 0 ; } +/* +* TTY operations hangup function. +*/ +static void tpk_hangup (struct tty_struct *tty) +{ +struct ttyprintk_port *tpkp = tty->driver_data; + +tty_port_hangup (&tpkp->port); +} +static const struct tty_operations ttyprintk_ops = { .open = tpk_open, .close = tpk_close, .write = tpk_write, .write_room = tpk_write_room, .ioctl = tpk_ioctl, + .hangup = tpk_hangup, };static const struct tty_port_operations null_ops = { };
drivers/clk/samsung/clk-exynos7.c +6 -1
@@ -541,8 +541,13 @@ static const struct samsung_gate_clock top1_gate_clks[] __initconst = {GATE (CLK_ACLK_FSYS0_200 ,"aclk_fsys0_200" ,"dout_aclk_fsys0_200" ,ENABLE_ACLK_TOP13 ,28 ,CLK_SET_RATE_PARENT |CLK_IS_CRITICAL ,0 ), +/* +* This clock is required for the CMU_FSYS1 registers access, keep it +* enabled permanently until proper runtime PM support is added. +*/ GATE (CLK_ACLK_FSYS1_200 ,"aclk_fsys1_200" ,"dout_aclk_fsys1_200" , -ENABLE_ACLK_TOP13 ,24 ,CLK_SET_RATE_PARENT ,0 ), +ENABLE_ACLK_TOP13 ,24 ,CLK_SET_RATE_PARENT | +CLK_IS_CRITICAL ,0 ), GATE(CLK_SCLK_PHY_FSYS1_26M, "sclk_phy_fsys1_26m", "dout_sclk_phy_fsys1_26m", ENABLE_SCLK_TOP1_FSYS11,
drivers/clk/socfpga/clk-gate-a10.c +1 -0
@@ -157,6 +157,7 @@ static void __init __socfpga_gate_init(struct device_node *node,if (IS_ERR (socfpga_clk->sys_mgr_base_addr)) {pr_err ("%s: failed to find altr,sys-mgr regmap!\n" , __func__); +kfree (socfpga_clk);return ; } }
drivers/clk/uniphier/clk-uniphier-mux.c +2 -2
@@ -40,10 +40,10 @@ static int uniphier_clk_mux_set_parent(struct clk_hw *hw, u8 index)static u8 uniphier_clk_mux_get_parent (struct clk_hw *hw) {struct uniphier_clk_mux *mux =to_uniphier_clk_mux (hw); -int num_parents =clk_hw_get_num_parents (hw); +unsigned int num_parents =clk_hw_get_num_parents (hw);int ret;unsigned int val; -u8 i; +unsigned int i; ret =regmap_read (mux->regmap, mux->reg, &val);if (ret)
drivers/crypto/qat/qat_c3xxxvf/adf_drv.c +2 -2
@@ -238,12 +238,12 @@ static int adf_probe(struct pci_dev *pdev, const struct pci_device_id *ent)if (ret) goto out_err_free_reg; -set_bit (ADF_STATUS_PF_RUNNING , &accel_dev->status); - ret =adf_dev_init (accel_dev);if (ret) goto out_err_dev_shutdown; +set_bit (ADF_STATUS_PF_RUNNING , &accel_dev->status); + ret =adf_dev_start (accel_dev);if (ret) goto out_err_dev_stop;
drivers/crypto/qat/qat_c62xvf/adf_drv.c +2 -2
@@ -238,12 +238,12 @@ static int adf_probe(struct pci_dev *pdev, const struct pci_device_id *ent)if (ret) goto out_err_free_reg; -set_bit (ADF_STATUS_PF_RUNNING , &accel_dev->status); - ret =adf_dev_init (accel_dev);if (ret) goto out_err_dev_shutdown; +set_bit (ADF_STATUS_PF_RUNNING , &accel_dev->status); + ret =adf_dev_start (accel_dev);if (ret) goto out_err_dev_stop;
drivers/crypto/qat/qat_common/adf_isr.c +21 -8
@@ -330,19 +330,32 @@ int adf_isr_resource_alloc(struct adf_accel_dev *accel_dev) ret =adf_isr_alloc_msix_entry_table (accel_dev);if (ret) -return ret; -if (adf_enable_msix (accel_dev)) goto err_out; -if (adf_setup_bh (accel_dev)) - goto err_out; + ret =adf_enable_msix (accel_dev); +if (ret) + goto err_free_msix_table; -if (adf_request_irqs (accel_dev)) - goto err_out; + ret =adf_setup_bh (accel_dev); +if (ret) + goto err_disable_msix; + + ret =adf_request_irqs (accel_dev); +if (ret) + goto err_cleanup_bh;return 0 ; + +err_cleanup_bh: +adf_cleanup_bh (accel_dev); + +err_disable_msix: +adf_disable_msix (&accel_dev->accel_pci_dev); + +err_free_msix_table: +adf_isr_free_msix_entry_table (accel_dev); + err_out: -adf_isr_resource_free (accel_dev); -return -EFAULT ; +return ret; }EXPORT_SYMBOL_GPL (adf_isr_resource_alloc);
drivers/crypto/qat/qat_common/adf_transport.c +1 -0
@@ -197,6 +197,7 @@ static int adf_init_ring(struct adf_etr_ring_data *ring)dev_err (&GET_DEV (accel_dev),"Ring address not aligned\n" );dma_free_coherent (&GET_DEV (accel_dev), ring_size_bytes, ring->base_addr, ring->dma_addr); + ring->base_addr =NULL ;return -EFAULT ; }
drivers/crypto/qat/qat_common/adf_vf_isr.c +13 -4
@@ -304,17 +304,26 @@ int adf_vf_isr_resource_alloc(struct adf_accel_dev *accel_dev) goto err_out;if (adf_setup_pf2vf_bh (accel_dev)) - goto err_out; + goto err_disable_msi;if (adf_setup_bh (accel_dev)) - goto err_out; + goto err_cleanup_pf2vf_bh;if (adf_request_msi_irq (accel_dev)) - goto err_out; + goto err_cleanup_bh;return 0 ; + +err_cleanup_bh: +adf_cleanup_bh (accel_dev); + +err_cleanup_pf2vf_bh: +adf_cleanup_pf2vf_bh (accel_dev); + +err_disable_msi: +adf_disable_msi (accel_dev); + err_out: -adf_vf_isr_resource_free (accel_dev);return -EFAULT ; }EXPORT_SYMBOL_GPL (adf_vf_isr_resource_alloc);
drivers/crypto/qat/qat_dh895xccvf/adf_drv.c +2 -2
@@ -238,12 +238,12 @@ static int adf_probe(struct pci_dev *pdev, const struct pci_device_id *ent)if (ret) goto out_err_free_reg; -set_bit (ADF_STATUS_PF_RUNNING , &accel_dev->status); - ret =adf_dev_init (accel_dev);if (ret) goto out_err_dev_shutdown; +set_bit (ADF_STATUS_PF_RUNNING , &accel_dev->status); + ret =adf_dev_start (accel_dev);if (ret) goto out_err_dev_stop;
drivers/extcon/extcon-arizona.c +9 -8
@@ -601,7 +601,7 @@ static irqreturn_t arizona_hpdet_irq(int irq, void *data)struct arizona *arizona = info->arizona;int id_gpio = arizona->pdata.hpdet_id_gpio;unsigned int report =EXTCON_JACK_HEADPHONE ; -int ret, reading; +int ret, reading, state;bool mic = false;mutex_lock (&info->lock);
@@ -614,12 +614,11 @@ static irqreturn_t arizona_hpdet_irq(int irq, void *data) }/* If the cable was removed while measuring ignore the result */ - ret =extcon_get_state (info->edev,EXTCON_MECHANICAL ); -if (ret <0 ) { -dev_err (arizona->dev,"Failed to check cable state: %d\n" , - ret); + state =extcon_get_state (info->edev,EXTCON_MECHANICAL ); +if (state <0 ) { +dev_err (arizona->dev,"Failed to check cable state: %d\n" , state); goto out; - }else if (!ret) { + }else if (!state) {dev_dbg (arizona->dev,"Ignoring HPDET for removed cable\n" ); goto done; }
@@ -672,7 +671,7 @@ static irqreturn_t arizona_hpdet_irq(int irq, void *data) ARIZONA_ACCDET_MODE_MASK, ARIZONA_ACCDET_MODE_MIC);/* If we have a mic then reenable MICDET */ -if (mic || info->mic) +if (state && (mic || info->mic))arizona_start_mic (info);if (info->hpdet_active) {
@@ -680,7 +679,9 @@ static irqreturn_t arizona_hpdet_irq(int irq, void *data) info->hpdet_active = false; } - info->hpdet_done = true; +/* Do not set hp_det done when the cable has been unplugged */ +if (state) + info->hpdet_done = true; out:mutex_unlock (&info->lock);
drivers/firmware/Kconfig +1 -0
@@ -194,6 +194,7 @@ config FW_CFG_SYSFS_CMDLINE config QCOM_SCM bool depends on ARM || ARM64 + depends on HAVE_ARM_SMCCC select RESET_CONTROLLER config QCOM_SCM_32
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c +1 -1
@@ -652,7 +652,7 @@ static void amdgpu_ttm_tt_unpin_userptr(struct ttm_tt *ttm) DMA_BIDIRECTIONAL :DMA_TO_DEVICE ;/* double check that we don't free the table twice */ -if (!ttm->sg->sgl) +if (!ttm->sg || !ttm->sg->sgl)return ;/* free the sg table and pages again */
drivers/gpu/drm/msm/mdp/mdp5/mdp5_cmd_encoder.c +9 -1
@@ -128,9 +128,17 @@ static int pingpong_tearcheck_setup(struct drm_encoder *encoder, | MDP5_PP_SYNC_CONFIG_VSYNC_IN_EN; cfg |=MDP5_PP_SYNC_CONFIG_VSYNC_COUNT (vclks_line); +/* +* Tearcheck emits a blanking signal every vclks_line * vtotal * 2 ticks on +* the vsync_clk equating to roughly half the desired panel refresh rate. +* This is only necessary as stability fallback if interrupts from the +* panel arrive too late or not at all, but is currently used by default +* because these panel interrupts are not wired up yet. +*/ mdp5_write (mdp5_kms,REG_MDP5_PP_SYNC_CONFIG_VSYNC (pp_id), cfg);mdp5_write (mdp5_kms, -REG_MDP5_PP_SYNC_CONFIG_HEIGHT (pp_id),0xfff0 ); +REG_MDP5_PP_SYNC_CONFIG_HEIGHT (pp_id), (2 * mode->vtotal)); +mdp5_write (mdp5_kms,REG_MDP5_PP_VSYNC_INIT_VAL (pp_id), mode->vdisplay);mdp5_write (mdp5_kms,REG_MDP5_PP_RD_PTR_IRQ (pp_id), mode->vdisplay +1 );
drivers/gpu/drm/radeon/radeon_atombios.c +3 -3
@@ -2259,10 +2259,10 @@ static int radeon_atombios_parse_power_table_1_3(struct radeon_device *rdev) rdev->pm.default_power_state_index = state_index -1 ; rdev->pm.power_state[state_index -1 ].default_clock_mode = &rdev->pm.power_state[state_index -1 ].clock_info[0 ]; - rdev->pm.power_state[state_index].flags &= + rdev->pm.power_state[state_index -1 ].flags &= ~RADEON_PM_STATE_SINGLE_DISPLAY_ONLY ; - rdev->pm.power_state[state_index].misc =0 ; - rdev->pm.power_state[state_index].misc2 =0 ; + rdev->pm.power_state[state_index -1 ].misc =0 ; + rdev->pm.power_state[state_index -1 ].misc2 =0 ; }return state_index; }
drivers/gpu/drm/radeon/radeon_kms.c +1 -0
@@ -506,6 +506,7 @@ static int radeon_info_ioctl(struct drm_device *dev, void *data, struct drm_file *value = rdev->config.si.backend_enable_mask; }else {DRM_DEBUG_KMS ("BACKEND_ENABLED_MASK is si+ only!\n" ); +return -EINVAL ; }break ;case RADEON_INFO_MAX_SCLK :
drivers/hid/hid-ids.h +1 -0
@@ -816,6 +816,7 @@#define USB_DEVICE_ID_ORTEK_WKB2000 0x2000#define USB_VENDOR_ID_PLANTRONICS 0x047f +#define USB_DEVICE_ID_PLANTRONICS_BLACKWIRE_3220_SERIES 0xc056#define USB_VENDOR_ID_PANASONIC 0x04da#define USB_DEVICE_ID_PANABOARD_UBT780 0x1044
drivers/hid/hid-plantronics.c +58 -2
113 lines not on this page · raw message
drivers/hsi/hsi_core.c +1 -2
@@ -223,8 +223,6 @@ static void hsi_add_client_from_dt(struct hsi_port *port,if (err) goto err; -dev_set_name (&cl->device,"%s" , name); - err =hsi_of_property_parse_mode (client,"hsi-mode" , &mode);if (err) { err = hsi_of_property_parse_mode(client, "hsi-rx-mode",
@@ -307,6 +305,7 @@ static void hsi_add_client_from_dt(struct hsi_port *port, cl->device.release = hsi_client_release; cl->device.of_node = client; +dev_set_name (&cl->device,"%s" , name);if (device_register (&cl->device) <0 ) {pr_err ("hsi: failed to register client: %s\n" , name);put_device (&cl->device);
drivers/hv/channel_mgmt.c +25 -5
@@ -675,6 +675,12 @@ static void init_vp_index(struct vmbus_channel *channel, u16 dev_type) channel->target_vp = hv_context.vp_index[cur_cpu]; } +#define UNLOAD_DELAY_UNIT_MS 10/* 10 milliseconds */ +#define UNLOAD_WAIT_MS (100*1000)/* 100 seconds */ +#define UNLOAD_WAIT_LOOPS (UNLOAD_WAIT_MS/UNLOAD_DELAY_UNIT_MS) +#define UNLOAD_MSG_MS (5*1000)/* Every 5 seconds */ +#define UNLOAD_MSG_LOOPS (UNLOAD_MSG_MS/UNLOAD_DELAY_UNIT_MS) +static void vmbus_wait_for_unload (void ) {int cpu;
@@ -692,12 +698,17 @@ static void vmbus_wait_for_unload(void)* vmbus_connection.unload_event. If not, the last thing we can do is * read message pages for all CPUs directly. * -* Wait no more than 10 seconds so that the panic path can't get -* hung forever in case the response message isn't seen. +* Wait up to 100 seconds since an Azure host must writeback any dirty +* data in its disk cache before the VMbus UNLOAD request will +* complete. This flushing has been empirically observed to take up +* to 50 seconds in cases with a lot of dirty data, so allow additional +* leeway and for inaccuracies in mdelay(). But eventually time out so +* that the panic path can't get hung forever in case the response +* message isn't seen. */ -for (i =0 ; i <1000 ; i++) { +for (i =1 ; i <=UNLOAD_WAIT_LOOPS ; i++) {if (completion_done (&vmbus_connection.unload_event)) -break ; + goto completed;for_each_online_cpu (cpu) { page_addr = hv_context.synic_message_page[cpu];
@@ -717,9 +728,18 @@ static void vmbus_wait_for_unload(void)vmbus_signal_eom (msg, message_type); } -mdelay (10 ); +/* +* Give a notice periodically so someone watching the +* serial output won't think it is completely hung. +*/ +if (!(i %UNLOAD_MSG_LOOPS )) +pr_notice ("Waiting for VMBus UNLOAD to complete\n" ); + +mdelay (UNLOAD_DELAY_UNIT_MS ); } +pr_err ("Continuing even though VMBus UNLOAD did not complete\n" ); +completed:/* * We're crashing and already got the UNLOAD_RESPONSE, cleanup all * maybe-pending messages on all CPUs to be able to receive new
drivers/hwtracing/intel_th/gth.c +2 -2
@@ -485,7 +485,7 @@ static void intel_th_gth_disable(struct intel_th_device *thdev, output->active = false;for_each_set_bit (master, gth->output[output->port].master, -TH_CONFIGURABLE_MASTERS ) { +TH_CONFIGURABLE_MASTERS +1 ) {gth_master_set (gth, master,-1 ); }spin_unlock (>h->gth_lock);
@@ -605,7 +605,7 @@ static void intel_th_gth_unassign(struct intel_th_device *thdev, othdev->output.port =-1 ; othdev->output.active = false; gth->output[port].output =NULL ; -for (master =0 ; master <=TH_CONFIGURABLE_MASTERS ; master++) +for (master =0 ; master <TH_CONFIGURABLE_MASTERS +1 ; master++)if (gth->master[master] == port) gth->master[master] =-1 ;spin_unlock (>h->gth_lock);
drivers/i2c/busses/i2c-cadence.c +4 -1
@@ -908,7 +908,10 @@ static int cdns_i2c_probe(struct platform_device *pdev)if (IS_ERR (id->membase))return PTR_ERR (id->membase); - id->irq =platform_get_irq (pdev,0 ); + ret =platform_get_irq (pdev,0 ); +if (ret <0 ) +return ret; + id->irq = ret; id->adap.owner =THIS_MODULE ; id->adap.dev.of_node = pdev->dev.of_node;
drivers/i2c/busses/i2c-emev2.c +4 -1
@@ -398,7 +398,10 @@ static int em_i2c_probe(struct platform_device *pdev)em_i2c_reset (&priv->adap); - priv->irq =platform_get_irq (pdev,0 ); + ret =platform_get_irq (pdev,0 ); +if (ret <0 ) + goto err_clk; + priv->irq = ret; ret =devm_request_irq (&pdev->dev, priv->irq, em_i2c_irq_handler,0 ,"em_i2c" , priv);if (ret)
drivers/i2c/busses/i2c-jz4780.c +4 -1
@@ -760,7 +760,10 @@ static int jz4780_i2c_probe(struct platform_device *pdev)jz4780_i2c_writew (i2c,JZ4780_I2C_INTM ,0x0 ); - i2c->irq =platform_get_irq (pdev,0 ); + ret =platform_get_irq (pdev,0 ); +if (ret <0 ) + goto err; + i2c->irq = ret; ret =devm_request_irq (&pdev->dev, i2c->irq, jz4780_i2c_irq,0 ,dev_name (&pdev->dev), i2c);if (ret)
drivers/i2c/busses/i2c-sh7760.c +4 -1
@@ -471,7 +471,10 @@ static int sh7760_i2c_probe(struct platform_device *pdev) goto out2; } - id->irq =platform_get_irq (pdev,0 ); + ret =platform_get_irq (pdev,0 ); +if (ret <0 ) + goto out3; + id->irq = ret; id->adap.nr = pdev->id; id->adap.algo = &sh7760_i2c_algo;
drivers/iio/proximity/pulsedlight-lidar-lite-v2.c +1 -0
@@ -166,6 +166,7 @@ static int lidar_get_measurement(struct lidar_data *data, u16 *reg) ret =lidar_write_control (data,LIDAR_REG_CONTROL_ACQUIRE );if (ret <0 ) {dev_err (&client->dev,"cannot send start measurement command" ); +pm_runtime_put_noidle (&client->dev);return ret; }
drivers/infiniband/hw/i40iw/i40iw_pble.c +2 -4
@@ -399,12 +399,9 @@ static enum i40iw_status_code add_pble_pool(struct i40iw_sc_dev *dev,i40iw_debug (dev,I40IW_DEBUG_PBLE ,"next_fpm_addr = %llx chunk_size[%u] = 0x%x\n" , pble_rsrc->next_fpm_addr, chunk->size, chunk->size); pble_rsrc->unallocated_pble -= (chunk->size >>3 ); -list_add (&chunk->list, &pble_rsrc->pinfo.clist); sd_reg_val = (sd_entry_type ==I40IW_SD_TYPE_PAGED ) ? sd_entry->u.pd_table.pd_page_addr.pa : sd_entry->u.bp.addr.pa; -if (sd_entry->valid) -return 0 ; -if (dev->is_pf) { +if (dev->is_pf && !sd_entry->valid) { ret_code =i40iw_hmc_sd_one (dev, hmc_info->hmc_fn_id, sd_reg_val, idx->sd_idx, sd_entry->entry_type, true);
@@ -415,6 +412,7 @@ static enum i40iw_status_code add_pble_pool(struct i40iw_sc_dev *dev, } sd_entry->valid = true; +list_add (&chunk->list, &pble_rsrc->pinfo.clist);return 0 ; error:kfree (chunk);
drivers/input/touchscreen/silead.c +40 -4
68 lines not on this page · raw message
drivers/isdn/capi/kcapi.c +2 -2
@@ -845,7 +845,7 @@ EXPORT_SYMBOL(capi20_put_message);* Return value: CAPI result code */ -u16 capi20_get_manufacturer (u32 contr,u8 *buf) +u16 capi20_get_manufacturer (u32 contr,u8 buf[CAPI_MANUFACTURER_LEN ]) {struct capi_ctr *ctr;u16 ret;
@@ -915,7 +915,7 @@ EXPORT_SYMBOL(capi20_get_version);* Return value: CAPI result code */ -u16 capi20_get_serial (u32 contr,u8 *serial) +u16 capi20_get_serial (u32 contr,u8 serial[CAPI_SERIAL_LEN ]) {struct capi_ctr *ctr;u16 ret;
drivers/md/dm-ioctl.c +1 -1
@@ -524,7 +524,7 @@ static int list_devices(struct dm_ioctl *param, size_t param_size)* Grab our output buffer. */ nl =get_result_buffer (param, param_size, &len); -if (len < needed) { +if (len < needed || len <sizeof (nl->dev)) { param->flags |=DM_BUFFER_FULL_FLAG ; goto out; }
drivers/md/dm-rq.c +2 -0
@@ -1009,6 +1009,7 @@ int dm_mq_init_request_queue(struct mapped_device *md, struct dm_table *t)blk_mq_free_tag_set (md->tag_set); out_kfree_tag_set:kfree (md->tag_set); + md->tag_set =NULL ;return err; }
@@ -1018,6 +1019,7 @@ void dm_mq_cleanup_mapped_device(struct mapped_device *md)if (md->tag_set) {blk_mq_free_tag_set (md->tag_set);kfree (md->tag_set); + md->tag_set =NULL ; } }
drivers/md/md.c +24 -19
86 lines not on this page · raw message
drivers/md/persistent-data/dm-btree-internal.h +2 -2
@@ -34,12 +34,12 @@ struct node_header {__le32 max_entries;__le32 value_size;__le32 padding; -} __packed; +} __attribute__((packed, aligned(8)));struct btree_node {struct node_header header;__le64 keys[0 ]; -} __packed; +} __attribute__((packed,aligned (8 )));/*
drivers/md/persistent-data/dm-space-map-common.c +2 -0
@@ -337,6 +337,8 @@ int sm_ll_find_free_block(struct ll_disk *ll, dm_block_t begin,*/ begin =do_div (index_begin, ll->entries_per_block); end =do_div (end, ll->entries_per_block); +if (end ==0 ) + end = ll->entries_per_block;for (i = index_begin; i < index_end; i++, begin =0 ) {struct dm_block *blk;
drivers/md/persistent-data/dm-space-map-common.h +4 -4
@@ -33,7 +33,7 @@ struct disk_index_entry {__le64 blocknr;__le32 nr_free;__le32 none_free_before; -} __packed; +} __attribute__ ((packed, aligned(8)));#define MAX_METADATA_BITMAPS 255
@@ -43,7 +43,7 @@ struct disk_metadata_index {__le64 blocknr;struct disk_index_entry index[MAX_METADATA_BITMAPS ]; -} __packed; +} __attribute__ ((packed, aligned(8)));struct ll_disk ;
@@ -86,7 +86,7 @@ struct disk_sm_root {__le64 nr_allocated;__le64 bitmap_root;__le64 ref_count_root; -} __packed; +} __attribute__ ((packed, aligned(8)));#define ENTRIES_PER_BYTE 4
@@ -94,7 +94,7 @@ struct disk_bitmap_header {__le32 csum;__le32 not_used;__le64 blocknr; -} __packed; +} __attribute__ ((packed, aligned(8)));enum allocation_event {SM_NONE ,
drivers/media/dvb-core/dvbdev.c +1 -0
@@ -216,6 +216,7 @@ static void dvb_media_device_free(struct dvb_device *dvbdev)if (dvbdev->adapter->conn) {media_device_unregister_entity (dvbdev->adapter->conn); +kfree (dvbdev->adapter->conn); dvbdev->adapter->conn =NULL ;kfree (dvbdev->adapter->conn_pads); dvbdev->adapter->conn_pads =NULL ;
drivers/media/i2c/adv7511-v4l2.c +1 -1
@@ -1976,7 +1976,7 @@ static int adv7511_remove(struct i2c_client *client)adv7511_set_isr (sd, false);adv7511_init_setup (sd); -cancel_delayed_work (&state->edid_handler); +cancel_delayed_work_sync (&state->edid_handler);i2c_unregister_device (state->i2c_edid);if (state->i2c_cec)i2c_unregister_device (state->i2c_cec);
drivers/media/i2c/adv7604.c +1 -1
@@ -3541,7 +3541,7 @@ static int adv76xx_remove(struct i2c_client *client)io_write (sd,0x6e ,0 );io_write (sd,0x73 ,0 ); -cancel_delayed_work (&state->delayed_work_enable_hotplug); +cancel_delayed_work_sync (&state->delayed_work_enable_hotplug);v4l2_async_unregister_subdev (sd);media_entity_cleanup (&sd->entity);adv76xx_unregister_clients (to_state (sd));
drivers/media/i2c/adv7842.c +1 -1
@@ -3598,7 +3598,7 @@ static int adv7842_remove(struct i2c_client *client)struct adv7842_state *state =to_state (sd);adv7842_irq_enable (sd, false); -cancel_delayed_work (&state->delayed_work_enable_hotplug); +cancel_delayed_work_sync (&state->delayed_work_enable_hotplug);v4l2_device_unregister_subdev (sd);media_entity_cleanup (&sd->entity);adv7842_unregister_clients (sd);
drivers/media/pci/saa7164/saa7164-encoder.c +11 -9
@@ -1030,7 +1030,7 @@ int saa7164_encoder_register(struct saa7164_port *port)"(errno = %d), NO PCI configuration\n" , __func__, result); result = -ENOMEM ; - goto failed; + goto fail_pci; }/* Establish encoder defaults here */
@@ -1084,7 +1084,7 @@ int saa7164_encoder_register(struct saa7164_port *port) 100000, ENCODER_DEF_BITRATE);if (hdl->error) { result = hdl->error; - goto failed; + goto fail_hdl; } port->std =V4L2_STD_NTSC_M ;
@@ -1102,7 +1102,7 @@ int saa7164_encoder_register(struct saa7164_port *port)printk (KERN_INFO "%s: can't allocate mpeg device\n" , dev->name); result = -ENOMEM ; - goto failed; + goto fail_hdl; } port->v4l_device->ctrl_handler = hdl;
@@ -1113,10 +1113,7 @@ int saa7164_encoder_register(struct saa7164_port *port)if (result <0 ) {printk (KERN_INFO "%s: can't register mpeg device\n" , dev->name); -/* TODO: We're going to leak here if we don't dealloc -The buffers above. The unreg function can't deal wit it. -*/ - goto failed; + goto fail_reg; } printk(KERN_INFO "%s: registered device video%d [mpeg]\n",
@@ -1138,9 +1135,14 @@ int saa7164_encoder_register(struct saa7164_port *port)saa7164_api_set_encoder (port);saa7164_api_get_encoder (port); +return 0 ; - result =0 ; -failed: +fail_reg: +video_device_release (port->v4l_device); + port->v4l_device =NULL ; +fail_hdl: +v4l2_ctrl_handler_free (hdl); +fail_pci:return result; }
drivers/media/platform/vivid/vivid-vid-out.c +1 -1
@@ -1003,7 +1003,7 @@ int vivid_vid_out_s_fbuf(struct file *file, void *fh,return -EINVAL ; } dev->fbuf_out_flags &= ~(chroma_flags | alpha_flags); - dev->fbuf_out_flags = a->flags & (chroma_flags | alpha_flags); + dev->fbuf_out_flags |= a->flags & (chroma_flags | alpha_flags);return 0 ; }
drivers/media/rc/ite-cir.c +7 -1
@@ -292,8 +292,14 @@ static irqreturn_t ite_cir_isr(int irq, void *data)/* read the interrupt flags */ iflags = dev->params.get_irq_causes (dev); +/* Check for RX overflow */ +if (iflags &ITE_IRQ_RX_FIFO_OVERRUN ) { +dev_warn (&dev->rdev->dev,"receive overflow\n" ); +ir_raw_event_reset (dev->rdev); + } +/* check for the receive interrupt */ -if (iflags & (ITE_IRQ_RX_FIFO |ITE_IRQ_RX_FIFO_OVERRUN )) { +if (iflags &ITE_IRQ_RX_FIFO ) {/* read the FIFO bytes */ rx_bytes = dev->params.get_rx_bytes(dev, rx_buf,
drivers/media/tuners/m88rs6000t.c +3 -3
@@ -534,7 +534,7 @@ static int m88rs6000t_get_rf_strength(struct dvb_frontend *fe, u16 *strength) PGA2_cri =PGA2_GC >>2 ; PGA2_crf =PGA2_GC &0x03 ; -for (i =0 ; i <=RF_GC ; i++) +for (i =0 ; i <=RF_GC && i <ARRAY_SIZE (RFGS ); i++)RFG +=RFGS [i];if (RF_GC ==0 )
@@ -546,12 +546,12 @@ static int m88rs6000t_get_rf_strength(struct dvb_frontend *fe, u16 *strength)if (RF_GC ==3 )RFG +=100 ; -for (i =0 ; i <=IF_GC ; i++) +for (i =0 ; i <=IF_GC && i <ARRAY_SIZE (IFGS ); i++)IFG +=IFGS [i];TIAG =TIA_GC *TIA_GS ; -for (i =0 ; i <=BB_GC ; i++) +for (i =0 ; i <=BB_GC && i <ARRAY_SIZE (BBGS ); i++)BBG +=BBGS [i];PGA2G = PGA2_cri * PGA2_cri_GS + PGA2_crf * PGA2_crf_GS;
drivers/media/usb/dvb-usb/dvb-usb-init.c +16 -4
@@ -82,11 +82,17 @@ static int dvb_usb_adapter_init(struct dvb_usb_device *d, short *adapter_nrs) } } -if ((ret =dvb_usb_adapter_stream_init (adap)) || - (ret =dvb_usb_adapter_dvb_init (adap, adapter_nrs)) || - (ret =dvb_usb_adapter_frontend_init (adap))) { + ret =dvb_usb_adapter_stream_init (adap); +if (ret)return ret; - } + + ret =dvb_usb_adapter_dvb_init (adap, adapter_nrs); +if (ret) + goto dvb_init_err; + + ret =dvb_usb_adapter_frontend_init (adap); +if (ret) + goto frontend_init_err;/* use exclusive FE lock if there is multiple shared FEs */ if (adap->fe_adap[1 ].fe)
@@ -106,6 +112,12 @@ static int dvb_usb_adapter_init(struct dvb_usb_device *d, short *adapter_nrs) }return 0 ; + +frontend_init_err: +dvb_usb_adapter_dvb_exit (adap); +dvb_init_err: +dvb_usb_adapter_stream_exit (adap); +return ret; }static int dvb_usb_adapter_exit (struct dvb_usb_device *d)
drivers/media/usb/dvb-usb/dvb-usb.h +2 -1
@@ -471,7 +471,8 @@ extern int dvb_usb_generic_rw(struct dvb_usb_device *, u8 *, u16, u8 *, u16,int)extern int dvb_usb_generic_write (struct dvb_usb_device *,u8 *,u16 );/* commonly used remote control parsing */ -extern int dvb_usb_nec_rc_key_to_event (struct dvb_usb_device *,u8 [],u32 *,int *); +int dvb_usb_nec_rc_key_to_event (struct dvb_usb_device *d,u8 keybuf[5 ], +u32 *event,int *state);/* commonly used firmware download types and function */ struct hexline {
drivers/media/usb/em28xx/em28xx-dvb.c +1 -0
@@ -1967,6 +1967,7 @@ static int em28xx_dvb_init(struct em28xx *dev)return result; out_free: +em28xx_uninit_usb_xfer (dev,EM28XX_DIGITAL_MODE );kfree (dvb); dev->dvb =NULL ; goto ret;
drivers/media/usb/gspca/gspca.c +2 -0
@@ -2146,6 +2146,8 @@ int gspca_dev_probe2(struct usb_interface *intf,#endif v4l2_ctrl_handler_free (gspca_dev->vdev.ctrl_handler);v4l2_device_unregister (&gspca_dev->v4l2_dev); +if (sd_desc->probe_error) + sd_desc->probe_error (gspca_dev);kfree (gspca_dev->usb_buf);kfree (gspca_dev);return ret;
drivers/media/usb/gspca/gspca.h +1 -0
@@ -101,6 +101,7 @@ struct sd_desc {cam_cf_op config;/* called on probe */ cam_op init;/* called on probe and resume */ cam_op init_controls;/* called on probe */ +cam_v_op probe_error;/* called if probe failed, do cleanup here */ cam_op start;/* called on stream on after URBs creation */ cam_pkt_op pkt_scan;/* optional operations */
drivers/media/usb/gspca/sq905.c +1 -1
@@ -172,7 +172,7 @@ static int sq905_read_data(struct gspca_dev *gspca_dev, u8 *data, int size, int need_lock) { int ret; -int act_len; +int act_len =0 ; gspca_dev->usb_buf[0 ] ='\0' ;if (need_lock)
drivers/media/usb/gspca/stv06xx/stv06xx.c +9 -0
@@ -541,12 +541,21 @@ static int sd_int_pkt_scan(struct gspca_dev *gspca_dev,static int stv06xx_config (struct gspca_dev *gspca_dev,const struct usb_device_id *id); +static void stv06xx_probe_error (struct gspca_dev *gspca_dev) +{ +struct sd *sd = (struct sd *)gspca_dev; + +kfree (sd->sensor_priv); + sd->sensor_priv =NULL ; +} +/* sub-driver description */ static const struct sd_desc sd_desc = { .name =MODULE_NAME , .config = stv06xx_config, .init = stv06xx_init, .init_controls = stv06xx_init_controls, + .probe_error = stv06xx_probe_error, .start = stv06xx_start, .stopN = stv06xx_stopN, .pkt_scan = stv06xx_pkt_scan,
drivers/memory/omap-gpmc.c +5 -2
@@ -1028,8 +1028,8 @@ EXPORT_SYMBOL(gpmc_cs_request);void gpmc_cs_free (int cs) { -struct gpmc_cs_data *gpmc = &gpmc_cs[cs]; -struct resource *res = &gpmc->mem; +struct gpmc_cs_data *gpmc; +struct resource *res;spin_lock (&gpmc_mem_lock);if (cs >= gpmc_cs_num || cs <0 || !gpmc_cs_reserved (cs)) {
@@ -1038,6 +1038,9 @@ void gpmc_cs_free(int cs)spin_unlock (&gpmc_mem_lock);return ; } + gpmc = &gpmc_cs[cs]; + res = &gpmc->mem; +gpmc_cs_disable_mem (cs);if (res->flags)release_resource (res);
drivers/misc/kgdbts.c +13 -13
@@ -105,19 +105,19 @@#include <linux/module.h> #include <asm/sections.h> -#define v1printk(a...) do { \ - if (verbose) \ - printk(KERN_INFO a); \ - } while (0) -#define v2printk(a...) do { \ - if (verbose > 1) \ - printk(KERN_INFO a); \ - touch_nmi_watchdog(); \ - } while (0) -#define eprintk(a...) do { \ - printk(KERN_ERR a); \ - WARN_ON(1); \ - } while (0) +#define v1printk(a...) do { \ + if (verbose) \ + printk(KERN_INFO a); \ +} while (0) +#define v2printk(a...) do { \ + if (verbose > 1) \ + printk(KERN_INFO a); \ + touch_nmi_watchdog(); \ +} while (0) +#define eprintk(a...) do { \ + printk(KERN_ERR a); \ + WARN_ON(1); \ +} while (0)#define MAX_CONFIG_LEN 40static struct kgdb_io kgdbts_io_ops;
drivers/misc/lis3lv02d/lis3lv02d.c +16 -5
@@ -220,7 +220,7 @@ static int lis3_3dc_rates[16] = {0, 1, 10, 25, 50, 100, 200, 400, 1600, 5000};static int lis3_3dlh_rates[4 ] = {50 ,100 ,400 ,1000 };/* ODR is Output Data Rate */ -static int lis3lv02d_get_odr (struct lis3lv02d *lis3) +static int lis3lv02d_get_odr_index (struct lis3lv02d *lis3) {u8 ctrl;int shift;
@@ -228,15 +228,23 @@ static int lis3lv02d_get_odr(struct lis3lv02d *lis3) lis3->read (lis3,CTRL_REG1 , &ctrl); ctrl &= lis3->odr_mask; shift =ffs (lis3->odr_mask) -1 ; -return lis3->odrs[(ctrl >> shift)]; +return (ctrl >> shift); }static int lis3lv02d_get_pwron_wait (struct lis3lv02d *lis3) { -int div =lis3lv02d_get_odr (lis3); +int odr_idx =lis3lv02d_get_odr_index (lis3); +int div = lis3->odrs[odr_idx]; -if (WARN_ONCE (div ==0 ,"device returned spurious data" )) +if (div ==0 ) { +if (odr_idx ==0 ) { +/* Power-down mode, not sampling no need to sleep */ +return 0 ; + } + +dev_err (&lis3->pdev->dev,"Error unknown odrs-index: %d\n" , odr_idx);return -ENXIO ; + }/* LIS3 power on delay is quite long */ msleep (lis3->pwron_delay / div);
@@ -819,9 +827,12 @@ static ssize_t lis3lv02d_rate_show(struct device *dev, struct device_attribute *attr, char *buf) { struct lis3lv02d *lis3 = dev_get_drvdata(dev); +int odr_idx;lis3lv02d_sysfs_poweron (lis3); -return sprintf (buf,"%d\n" ,lis3lv02d_get_odr (lis3)); + + odr_idx =lis3lv02d_get_odr_index (lis3); +return sprintf (buf,"%d\n" , lis3->odrs[odr_idx]); } static ssize_t lis3lv02d_rate_set(struct device *dev,
drivers/misc/vmw_vmci/vmci_doorbell.c +1 -1
@@ -334,7 +334,7 @@ int vmci_dbell_host_context_notify(u32 src_cid, struct vmci_handle handle)bool vmci_dbell_register_notification_bitmap (u32 bitmap_ppn) {int result; -struct vmci_notify_bm_set_msg bitmap_set_msg; +struct vmci_notify_bm_set_msg bitmap_set_msg = { }; bitmap_set_msg.hdr.dst =vmci_make_handle (VMCI_HYPERVISOR_CONTEXT_ID ,VMCI_SET_NOTIFY_BITMAP );
drivers/misc/vmw_vmci/vmci_guest.c +1 -1
@@ -172,7 +172,7 @@ static int vmci_check_host_caps(struct pci_dev *pdev) VMCI_UTIL_NUM_RESOURCES * sizeof(u32);struct vmci_datagram *check_msg; - check_msg =kmalloc (msg_size,GFP_KERNEL ); + check_msg =kzalloc (msg_size,GFP_KERNEL );if (!check_msg) {dev_err (&pdev->dev,"%s: Insufficient memory\n" , __func__);return -ENOMEM ;
drivers/mmc/core/core.c +1 -1
@@ -1691,7 +1691,7 @@ int mmc_set_signal_voltage(struct mmc_host *host, int signal_voltage, u32 ocr) err =mmc_wait_for_cmd (host, &cmd,0 );if (err) -return err; + goto power_cycle;if (!mmc_host_is_spi (host) && (cmd.resp[0 ] &R1_ERROR ))return -EIO ;
drivers/mmc/core/sd.c +6 -0
@@ -136,6 +136,9 @@ static int mmc_decode_csd(struct mmc_card *card) csd->erase_size =UNSTUFF_BITS (resp,39 ,7 ) +1 ; csd->erase_size <<= csd->write_blkbits -9 ; } + +if (UNSTUFF_BITS (resp,13 ,1 )) +mmc_card_set_readonly (card);break ;case 1 :/*
@@ -170,6 +173,9 @@ static int mmc_decode_csd(struct mmc_card *card) csd->write_blkbits =9 ; csd->write_partial =0 ; csd->erase_size =1 ; + +if (UNSTUFF_BITS (resp,13 ,1 )) +mmc_card_set_readonly (card);break ;default : pr_err("%s: unrecognised CSD structure version %d\n",
drivers/mtd/mtdchar.c +4 -4
@@ -689,16 +689,12 @@ static int mtdchar_ioctl(struct file *file, u_int cmd, u_long arg)case MEMGETINFO :case MEMREADOOB :case MEMREADOOB64 : -case MEMLOCK : -case MEMUNLOCK :case MEMISLOCKED :case MEMGETOOBSEL :case MEMGETBADBLOCK : -case MEMSETBADBLOCK :case OTPSELECT :case OTPGETREGIONCOUNT :case OTPGETREGIONINFO : -case OTPLOCK :case ECCGETLAYOUT :case ECCGETSTATS :case MTDFILEMODE :
@@ -709,9 +705,13 @@ static int mtdchar_ioctl(struct file *file, u_int cmd, u_long arg)/* "dangerous" commands */ case MEMERASE :case MEMERASE64 : +case MEMLOCK : +case MEMUNLOCK : +case MEMSETBADBLOCK :case MEMWRITEOOB :case MEMWRITEOOB64 :case MEMWRITE : +case OTPLOCK :if (!(file->f_mode &FMODE_WRITE ))return -EPERM ;break ;
drivers/mtd/nand/gpmi-nand/gpmi-nand.c +1 -1
@@ -2020,7 +2020,7 @@ static int gpmi_nand_init(struct gpmi_nand_data *this) this->bch_geometry.auxiliary_size =128 ; ret =gpmi_alloc_dma_buffer (this);if (ret) - goto err_out; +return ret; ret =nand_scan_ident (mtd,GPMI_IS_MX6 (this) ?2 :1 ,NULL );if (ret)
drivers/net/ethernet/cavium/liquidio/cn23xx_pf_regs.h +1 -1
@@ -526,7 +526,7 @@#define CN23XX_BAR1_INDEX_OFFSET 3#define CN23XX_PEM_BAR1_INDEX_REG (port, idx) \ - (CN23XX_PEM_BAR1_INDEX_START + ((port) << CN23XX_PEM_OFFSET) + \ + (CN23XX_PEM_BAR1_INDEX_START + (((u64)port) << CN23XX_PEM_OFFSET) + \ ((idx) << CN23XX_BAR1_INDEX_OFFSET))/*############################ DPI #########################*/
drivers/net/ethernet/cavium/thunder/nicvf_queues.c +1 -1
@@ -537,7 +537,7 @@ static void nicvf_rcv_queue_config(struct nicvf *nic, struct queue_set *qs, mbx.rq.msg =NIC_MBOX_MSG_RQ_CFG ; mbx.rq.qs_num = qs->vnic_id; mbx.rq.rq_num = qidx; - mbx.rq.cfg = (rq->caching <<26 ) | (rq->cq_qs <<19 ) | + mbx.rq.cfg = ((u64 )rq->caching <<26 ) | (rq->cq_qs <<19 ) | (rq->cq_idx <<16 ) | (rq->cont_rbdr_qs <<9 ) | (rq->cont_qs_rbdr_idx <<8 ) | (rq->start_rbdr_qs <<1 ) | (rq->start_qs_rbdr_idx);
drivers/net/ethernet/chelsio/cxgb4/cxgb4_debugfs.c +1 -1
@@ -2446,7 +2446,7 @@ do { \seq_printf (seq,"%-12s" , s); \for (i =0 ; i < n; ++i) \seq_printf (seq," %16" fmt_spec, v); \ -seq_putc (seq,'\n' ); \ +seq_putc (seq,'\n' ); \ } while (0)#define S (s, v) S3("s", s, v)#define T3 (fmt_spec, s, v) S3(fmt_spec, s, tx[i].v)
drivers/net/ethernet/mediatek/mtk_eth_soc.c +1 -1
@@ -964,7 +964,7 @@ static int mtk_poll_rx(struct napi_struct *napi, int budget, skb->protocol =eth_type_trans (skb, netdev);if (netdev->features &NETIF_F_HW_VLAN_CTAG_RX && -RX_DMA_VID (trxd.rxd3)) + (trxd.rxd2 &RX_DMA_VTAG ))__vlan_hwaccel_put_tag (skb,htons (ETH_P_8021Q ),RX_DMA_VID (trxd.rxd3));napi_gro_receive (napi, skb);
drivers/net/ethernet/mediatek/mtk_eth_soc.h +1 -0
@@ -272,6 +272,7 @@#define RX_DMA_DONE BIT(31)#define RX_DMA_PLEN0 (_x) (((_x) & 0x3fff) << 16)#define RX_DMA_GET_PLEN0 (_x) (((_x) >> 16) & 0x3fff) +#define RX_DMA_VTAG BIT(15)/* QDMA descriptor rxd3 */ #define RX_DMA_VID (_x) ((_x) & 0xfff)
drivers/net/ethernet/qualcomm/emac/emac-mac.c +3 -1
@@ -1504,6 +1504,7 @@ int emac_mac_tx_buf_send(struct emac_adapter *adpt, struct emac_tx_queue *tx_q, {struct emac_tpd tpd;u32 prod_idx; +int len;memset (&tpd,0 ,sizeof (tpd));
@@ -1523,9 +1524,10 @@ int emac_mac_tx_buf_send(struct emac_adapter *adpt, struct emac_tx_queue *tx_q,if (skb_network_offset (skb) !=ETH_HLEN )TPD_TYP_SET (&tpd,1 ); + len = skb->len;emac_tx_fill_tpd (adpt, tx_q, skb, &tpd); -netdev_sent_queue (adpt->netdev, skb->len); +netdev_sent_queue (adpt->netdev, len);/* Make sure the are enough free descriptors to hold one * maximum-sized SKB. We need one desc for each fragment,
drivers/net/ethernet/stmicro/stmmac/dwmac-ipq806x.c +2 -0
@@ -363,6 +363,8 @@ static int ipq806x_gmac_probe(struct platform_device *pdev) plat_dat->bsp_priv = gmac; plat_dat->fix_mac_speed = ipq806x_gmac_fix_mac_speed; plat_dat->multicast_filter_bins =0 ; + plat_dat->tx_fifo_size =8192 ; + plat_dat->rx_fifo_size =8192 ; err =stmmac_dvr_probe (&pdev->dev, plat_dat, &stmmac_res);if (err)
drivers/net/ethernet/ti/davinci_emac.c +2 -2
@@ -183,11 +183,11 @@ static const char emac_version_string[] = "TI DaVinci EMAC Linux v6.1";/* EMAC mac_status register */ #define EMAC_MACSTATUS_TXERRCODE_MASK (0xF00000)#define EMAC_MACSTATUS_TXERRCODE_SHIFT (20) -#define EMAC_MACSTATUS_TXERRCH_MASK (0x7) +#define EMAC_MACSTATUS_TXERRCH_MASK (0x70000)#define EMAC_MACSTATUS_TXERRCH_SHIFT (16)#define EMAC_MACSTATUS_RXERRCODE_MASK (0xF000)#define EMAC_MACSTATUS_RXERRCODE_SHIFT (12) -#define EMAC_MACSTATUS_RXERRCH_MASK (0x7) +#define EMAC_MACSTATUS_RXERRCH_MASK (0x700)#define EMAC_MACSTATUS_RXERRCH_SHIFT (8)/* EMAC RX register masks */
drivers/net/fddi/Kconfig +9 -6
@@ -28,17 +28,20 @@ config DEFXX config DEFXX_MMIO bool - prompt "Use MMIO instead of PIO" if PCI || EISA + prompt "Use MMIO instead of IOP" if PCI || EISA depends on DEFXX - default n if PCI || EISA + default n if EISA default y ---help--- This instructs the driver to use EISA or PCI memory-mapped I/O - (MMIO) as appropriate instead of programmed I/O ports (PIO). + (MMIO) as appropriate instead of programmed I/O ports (IOP). Enabling this gives an improvement in processing time in parts - of the driver, but it may cause problems with EISA (DEFEA) - adapters. TURBOchannel does not have the concept of I/O ports, - so MMIO is always used for these (DEFTA) adapters. + of the driver, but it requires a memory window to be configured + for EISA (DEFEA) adapters that may not always be available. + Conversely some PCIe host bridges do not support IOP, so MMIO + may be required to access PCI (DEFPA) adapters on downstream PCI + buses with some systems. TURBOchannel does not have the concept + of I/O ports, so MMIO is always used for these (DEFTA) adapters. If unsure, say N.
drivers/net/fddi/defxx.c +30 -17
78 lines not on this page · raw message
drivers/net/usb/ax88179_178a.c +2 -2
@@ -307,12 +307,12 @@ static int ax88179_read_cmd(struct usbnet *dev, u8 cmd, u16 value, u16 index,int ret;if (2 == size) { -u16 buf; +u16 buf =0 ; ret =__ax88179_read_cmd (dev, cmd, value, index, size, &buf,0 );le16_to_cpus (&buf); *((u16 *)data) = buf; }else if (4 == size) { -u32 buf; +u32 buf =0 ; ret =__ax88179_read_cmd (dev, cmd, value, index, size, &buf,0 );le32_to_cpus (&buf); *((u32 *)data) = buf;
drivers/net/wan/lapbether.c +25 -7
@@ -56,6 +56,8 @@ struct lapbethdev {struct list_head node;struct net_device *ethdev;/* link to ethernet device */ struct net_device *axdev;/* lapbeth device (lapb#) */ +bool up; +spinlock_t up_lock;/* Protects "up" */ };static LIST_HEAD (lapbeth_devices);
@@ -103,8 +105,9 @@ static int lapbeth_rcv(struct sk_buff *skb, struct net_device *dev, struct packercu_read_lock (); lapbeth =lapbeth_get_x25_dev (dev);if (!lapbeth) - goto drop_unlock; -if (!netif_running (lapbeth->axdev)) + goto drop_unlock_rcu; +spin_lock_bh (&lapbeth->up_lock); +if (!lapbeth->up) goto drop_unlock; len = skb->data[0 ] + skb->data[1 ] *256 ;
@@ -119,11 +122,14 @@ static int lapbeth_rcv(struct sk_buff *skb, struct net_device *dev, struct packe goto drop_unlock; } out: +spin_unlock_bh (&lapbeth->up_lock);rcu_read_unlock ();return 0 ; drop_unlock:kfree_skb (skb); goto out; +drop_unlock_rcu: +rcu_read_unlock (); drop:kfree_skb (skb);return 0 ;
@@ -151,13 +157,11 @@ static int lapbeth_data_indication(struct net_device *dev, struct sk_buff *skb)static netdev_tx_t lapbeth_xmit (struct sk_buff *skb,struct net_device *dev) { +struct lapbethdev *lapbeth =netdev_priv (dev);int err; -/* -* Just to be *really* sure not to send anything if the interface -* is down, the ethernet device may have gone. -*/ -if (!netif_running (dev)) +spin_lock_bh (&lapbeth->up_lock); +if (!lapbeth->up) goto drop;/* There should be a pseudo header of 1 byte added by upper layers.
@@ -188,6 +192,7 @@ static netdev_tx_t lapbeth_xmit(struct sk_buff *skb, goto drop; } out: +spin_unlock_bh (&lapbeth->up_lock);return NETDEV_TX_OK ; drop:kfree_skb (skb);
@@ -279,6 +284,7 @@ static const struct lapb_register_struct lapbeth_callbacks = {*/ static int lapbeth_open (struct net_device *dev) { +struct lapbethdev *lapbeth =netdev_priv (dev);int err;if ((err =lapb_register (dev, &lapbeth_callbacks)) !=LAPB_OK ) {
@@ -286,13 +292,22 @@ static int lapbeth_open(struct net_device *dev)return -ENODEV ; } +spin_lock_bh (&lapbeth->up_lock); + lapbeth->up = true; +spin_unlock_bh (&lapbeth->up_lock); +return 0 ; }static int lapbeth_close (struct net_device *dev) { +struct lapbethdev *lapbeth =netdev_priv (dev);int err; +spin_lock_bh (&lapbeth->up_lock); + lapbeth->up = false; +spin_unlock_bh (&lapbeth->up_lock); +if ((err =lapb_unregister (dev)) !=LAPB_OK )pr_err ("lapb_unregister error: %d\n" , err);
@@ -350,6 +365,9 @@ static int lapbeth_new_device(struct net_device *dev)dev_hold (dev); lapbeth->ethdev = dev; + lapbeth->up = false; +spin_lock_init (&lapbeth->up_lock); + rc = -EIO ;if (register_netdevice (ndev)) goto fail;
drivers/net/wimax/i2400m/op-rfkill.c +1 -1
@@ -101,7 +101,7 @@ int i2400m_op_rfkill_sw_toggle(struct wimax_dev *wimax_dev,if (cmd ==NULL ) goto error_alloc; cmd->hdr.type =cpu_to_le16 (I2400M_MT_CMD_RF_CONTROL ); - cmd->hdr.length =sizeof (cmd->sw_rf); + cmd->hdr.length =cpu_to_le16 (sizeof (cmd->sw_rf)); cmd->hdr.version =cpu_to_le16 (I2400M_L3L4_VERSION ); cmd->sw_rf.hdr.type =cpu_to_le16 (I2400M_TLV_RF_OPERATION ); cmd->sw_rf.hdr.length =cpu_to_le16 (sizeof (cmd->sw_rf.status));
drivers/net/wireless/ath/ath9k/htc_drv_init.c +1 -1
@@ -246,7 +246,7 @@ static unsigned int ath9k_regread(void *hw_priv, u32 reg_offset)if (unlikely (r)) {ath_dbg (common,WMI ,"REGISTER READ FAILED: (0x%04x, %d)\n" , reg_offset, r); -return -EIO ; +return -1 ; }return be32_to_cpu (val);
drivers/net/wireless/ath/ath9k/hw.c +1 -1
@@ -285,7 +285,7 @@ static bool ath9k_hw_read_revisions(struct ath_hw *ah) srev =REG_READ (ah,AR_SREV ); -if (srev == -EIO ) { +if (srev ==-1 ) {ath_err (ath9k_hw_common (ah),"Failed to read SREV register" );return false;
drivers/net/wireless/intel/ipw2x00/libipw_wx.c +4 -2
@@ -649,8 +649,10 @@ int libipw_wx_set_encodeext(struct libipw_device *ieee, }if (ext->alg !=IW_ENCODE_ALG_NONE ) { -memcpy (sec.keys[idx], ext->key, ext->key_len); - sec.key_sizes[idx] = ext->key_len; +int key_len =clamp_val (ext->key_len,0 ,SCM_KEY_LEN ); + +memcpy (sec.keys[idx], ext->key, key_len); + sec.key_sizes[idx] = key_len; sec.flags |= (1 << idx);if (ext->alg ==IW_ENCODE_ALG_WEP ) { sec.encode_alg[idx] =SEC_ALG_WEP ;
drivers/net/wireless/intel/iwlwifi/pcie/tx.c +4 -3
@@ -1510,6 +1510,7 @@ static int iwl_pcie_enqueue_hcmd(struct iwl_trans *trans,u32 cmd_pos;const u8 *cmddata[IWL_MAX_CMD_TBS_PER_TFD ];u16 cmdlen[IWL_MAX_CMD_TBS_PER_TFD ]; +unsigned long flags2; if (WARN(!trans->wide_cmd_header && group_id > IWL_ALWAYS_LONG_GROUP,
@@ -1593,10 +1594,10 @@ static int iwl_pcie_enqueue_hcmd(struct iwl_trans *trans, goto free_dup_buf; } -spin_lock_bh (&txq->lock); +spin_lock_irqsave (&txq->lock, flags2);if (iwl_queue_space (txq) < ((cmd->flags &CMD_ASYNC ) ?2 :1 )) { -spin_unlock_bh (&txq->lock); +spin_unlock_irqrestore (&txq->lock, flags2);IWL_ERR (trans,"No space in command queue\n" );iwl_op_mode_cmd_queue_full (trans->op_mode);
@@ -1757,7 +1758,7 @@ static int iwl_pcie_enqueue_hcmd(struct iwl_trans *trans,spin_unlock_irqrestore (&trans_pcie->reg_lock, flags); out: -spin_unlock_bh (&txq->lock); +spin_unlock_irqrestore (&txq->lock, flags2); free_dup_buf:if (idx <0 )kfree (dup_buf);
drivers/net/wireless/marvell/mwl8k.c +1 -0
@@ -1459,6 +1459,7 @@ static int mwl8k_txq_init(struct ieee80211_hw *hw, int index) txq->skb =kcalloc (MWL8K_TX_DESCS ,sizeof (*txq->skb),GFP_KERNEL );if (txq->skb ==NULL ) {pci_free_consistent (priv->pdev, size, txq->txd, txq->txd_dma); + txq->txd =NULL ;return -ENOMEM ; }
drivers/net/wireless/mediatek/mt7601u/eeprom.c +1 -1
@@ -106,7 +106,7 @@ mt7601u_has_tssi(struct mt7601u_dev *dev, u8 *eeprom) {u16 nic_conf1 =get_unaligned_le16 (eeprom +MT_EE_NIC_CONF_1 ); -return ~nic_conf1 && (nic_conf1 &MT_EE_NIC_CONF_1_TX_ALC_EN ); +return (u16 )~nic_conf1 && (nic_conf1 &MT_EE_NIC_CONF_1_TX_ALC_EN ); } static void
drivers/net/wireless/wl3501.h +23 -24
77 lines not on this page · raw message
drivers/net/wireless/wl3501_cs.c +29 -25
149 lines not on this page · raw message
drivers/nfc/pn533/pn533.c +3 -0
@@ -678,6 +678,9 @@ static bool pn533_target_type_a_is_valid(struct pn533_target_type_a *type_a,if (PN533_TYPE_A_SEL_CASCADE (type_a->sel_res) !=0 )return false; +if (type_a->nfcid_len >NFC_NFCID1_MAXSIZE ) +return false; +return true; }
drivers/of/fdt.c +2 -10
@@ -1158,16 +1158,8 @@ void __init __weak early_init_dt_add_memory_arch(u64 base, u64 size)int __init __weak early_init_dt_reserve_memory_arch (phys_addr_t base,phys_addr_t size,bool nomap) { -if (nomap) { -/* -* If the memory is already reserved (by another region), we -* should not allow it to be marked nomap. -*/ -if (memblock_is_region_reserved (base, size)) -return -EBUSY ; - -return memblock_mark_nomap (base, size); - } +if (nomap) +return memblock_remove (base, size);return memblock_reserve (base, size); }
drivers/pci/hotplug/acpiphp_glue.c +1 -0
@@ -538,6 +538,7 @@ static void enable_slot(struct acpiphp_slot *slot) slot->flags &= (~SLOT_ENABLED );continue ; } +pci_dev_put (dev); } }
drivers/pci/pci.c +3 -13
@@ -1378,20 +1378,10 @@ static int pci_enable_device_flags(struct pci_dev *dev, unsigned long flags)int err;int i, bars =0 ; -/* -* Power state could be unknown at this point, either due to a fresh -* boot or a device removal call. So get the current power state -* so that things like MSI message writing will behave as expected -* (e.g. if the device really is in D0 at enable time). -*/ -if (dev->pm_cap) { -u16 pmcsr; -pci_read_config_word (dev, dev->pm_cap +PCI_PM_CTRL , &pmcsr); - dev->current_state = (pmcsr &PCI_PM_CTRL_STATE_MASK ); - } - -if (atomic_inc_return (&dev->enable_cnt) >1 ) +if (atomic_inc_return (&dev->enable_cnt) >1 ) { +pci_update_current_state (dev, dev->current_state);return 0 ;/* already enabled */ + } bridge =pci_upstream_bridge (dev);if (bridge)
drivers/pci/probe.c +1 -0
@@ -1694,6 +1694,7 @@ static struct pci_dev *pci_scan_device(struct pci_bus *bus, int devfn)pci_set_of_node (dev);if (pci_setup_device (dev)) { +pci_release_of_node (dev);pci_bus_put (dev->bus);kfree (dev);return NULL ;
drivers/phy/phy-twl4030-usb.c +1 -1
@@ -798,7 +798,7 @@ static int twl4030_usb_remove(struct platform_device *pdev)usb_remove_phy (&twl->phy);pm_runtime_get_sync (twl->dev); -cancel_delayed_work (&twl->id_workaround_work); +cancel_delayed_work_sync (&twl->id_workaround_work);device_remove_file (twl->dev, &dev_attr_vbus);/* set transceiver mode to power on defaults */
drivers/platform/x86/thinkpad_acpi.c +22 -9
@@ -6044,6 +6044,7 @@ enum thermal_access_mode {enum {/* TPACPI_THERMAL_TPEC_* */ TP_EC_THERMAL_TMP0 =0x78 ,/* ACPI EC regs TMP 0..7 */ TP_EC_THERMAL_TMP8 =0xC0 ,/* ACPI EC regs TMP 8..15 */ +TP_EC_FUNCREV =0xEF ,/* ACPI EC Functional revision */ TP_EC_THERMAL_TMP_NA =-128 ,/* ACPI EC sensor not available */ TPACPI_THERMAL_SENSOR_NA =-128000 ,/* Sensor not available */
@@ -6242,7 +6243,7 @@ static const struct attribute_group thermal_temp_input8_group = {static int __init thermal_init (struct ibm_init_struct *iibm) { -u8 t, ta1, ta2; +u8 t, ta1, ta2, ver =0 ;int i;int acpi_tmp7;int res;
@@ -6257,7 +6258,14 @@ static int __init thermal_init(struct ibm_init_struct *iibm)* 0x78-0x7F, 0xC0-0xC7. Registers return 0x00 for * non-implemented, thermal sensors return 0x80 when * not available +* The above rule is unfortunately flawed. This has been seen with +* 0xC2 (power supply ID) causing thermal control problems. +* The EC version can be determined by offset 0xEF and at least for +* version 3 the Lenovo firmware team confirmed that registers 0xC0-0xC7 +* are not thermal registers. */ +if (!acpi_ec_read (TP_EC_FUNCREV , &ver)) +pr_warn ("Thinkpad ACPI EC unable to access EC version\n" ); ta1 = ta2 =0 ;for (i =0 ; i <8 ; i++) {
@@ -6267,11 +6275,13 @@ static int __init thermal_init(struct ibm_init_struct *iibm) ta1 =0 ;break ; } -if (acpi_ec_read (TP_EC_THERMAL_TMP8 + i, &t)) { - ta2 |= t; - }else { - ta1 =0 ; -break ; +if (ver <3 ) { +if (acpi_ec_read (TP_EC_THERMAL_TMP8 + i, &t)) { + ta2 |= t; + }else { + ta1 =0 ; +break ; + } } }if (ta1 ==0 ) {
@@ -6287,9 +6297,12 @@ static int __init thermal_init(struct ibm_init_struct *iibm) thermal_read_mode =TPACPI_THERMAL_NONE ; } }else { - thermal_read_mode = - (ta2 !=0 ) ? -TPACPI_THERMAL_TPEC_16 :TPACPI_THERMAL_TPEC_8 ; +if (ver >=3 ) + thermal_read_mode =TPACPI_THERMAL_TPEC_8 ; +else + thermal_read_mode = + (ta2 !=0 ) ? +TPACPI_THERMAL_TPEC_16 :TPACPI_THERMAL_TPEC_8 ; } }else if (acpi_tmp7) { if (tpacpi_is_ibm() &&
drivers/power/supply/generic-adc-battery.c +1 -1
@@ -384,7 +384,7 @@ static int gab_remove(struct platform_device *pdev) }kfree (adc_bat->psy_desc.properties); -cancel_delayed_work (&adc_bat->bat_work); +cancel_delayed_work_sync (&adc_bat->bat_work);return 0 ; }
drivers/power/supply/lp8788-charger.c +1 -1
@@ -532,7 +532,7 @@ static int lp8788_set_irqs(struct platform_device *pdev, ret =request_threaded_irq (virq,NULL , lp8788_charger_irq_thread, -0 , name, pchg); +IRQF_ONESHOT , name, pchg);if (ret)break ; }
drivers/power/supply/pm2301_charger.c +1 -1
@@ -1098,7 +1098,7 @@ static int pm2xxx_wall_charger_probe(struct i2c_client *i2c_client, ret =request_threaded_irq (gpio_to_irq (pm2->pdata->gpio_irq_number),NULL , pm2xxx_charger_irq[0 ].isr, - pm2->pdata->irq_type, + pm2->pdata->irq_type |IRQF_ONESHOT , pm2xxx_charger_irq[0 ].name, pm2);if (ret !=0 ) {
drivers/power/supply/s3c_adc_battery.c +1 -1
@@ -392,7 +392,7 @@ static int s3c_adc_bat_remove(struct platform_device *pdev)gpio_free (pdata->gpio_charge_finished); } -cancel_delayed_work (&bat_work); +cancel_delayed_work_sync (&bat_work);if (pdata->exit) pdata->exit ();
drivers/power/supply/tps65090-charger.c +1 -1
@@ -311,7 +311,7 @@ static int tps65090_charger_probe(struct platform_device *pdev)if (irq != -ENXIO ) { ret =devm_request_threaded_irq (&pdev->dev, irq,NULL , - tps65090_charger_isr,0 ,"tps65090-charger" , cdata); + tps65090_charger_isr,IRQF_ONESHOT ,"tps65090-charger" , cdata);if (ret) { dev_err(cdata->dev, "Unable to register irq %d err %d\n", irq,
drivers/power/supply/tps65217_charger.c +1 -1
@@ -238,7 +238,7 @@ static int tps65217_charger_probe(struct platform_device *pdev)if (irq != -ENXIO ) { ret =devm_request_threaded_irq (&pdev->dev, irq,NULL , tps65217_charger_irq, -0 ,"tps65217-charger" , +IRQF_ONESHOT ,"tps65217-charger" , charger);if (ret) { dev_err(charger->dev,
drivers/scsi/device_handler/scsi_dh_alua.c +3 -2
@@ -564,10 +564,11 @@ static int alua_rtpg(struct scsi_device *sdev, struct alua_port_group *pg)* even though it shouldn't according to T10. * The retry without rtpg_ext_hdr_req set * handles this. +* Note: some arrays return a sense key of ILLEGAL_REQUEST +* with ASC 00h if they don't support the extended header. */ if (!(pg->flags &ALUA_RTPG_EXT_HDR_UNSUPP ) && - sense_hdr.sense_key ==ILLEGAL_REQUEST && - sense_hdr.asc ==0x24 && sense_hdr.ascq ==0 ) { + sense_hdr.sense_key ==ILLEGAL_REQUEST ) { pg->flags |=ALUA_RTPG_EXT_HDR_UNSUPP ; goto retry; }
drivers/scsi/jazz_esp.c +3 -1
@@ -170,7 +170,9 @@ static int esp_jazz_probe(struct platform_device *dev)if (!esp->command_block) goto fail_unmap_regs; - host->irq =platform_get_irq (dev,0 ); + host->irq = err =platform_get_irq (dev,0 ); +if (err <0 ) + goto fail_unmap_command_block; err =request_irq (host->irq, scsi_esp_intr,IRQF_SHARED ,"ESP" , esp);if (err <0 ) goto fail_unmap_command_block;
drivers/scsi/libfc/fc_lport.c +1 -1
@@ -1751,7 +1751,7 @@ void fc_lport_flogi_resp(struct fc_seq *sp, struct fc_frame *fp,if (mfs <FC_SP_MIN_MAX_PAYLOAD || mfs >FC_SP_MAX_MAX_PAYLOAD ) {FC_LPORT_DBG (lport,"FLOGI bad mfs:%hu response, " -"lport->mfs:%hu\n" , mfs, lport->mfs); +"lport->mfs:%u\n" , mfs, lport->mfs);fc_lport_error (lport, fp); goto out; }
drivers/scsi/lpfc/lpfc_nportdisc.c +0 -2
@@ -1606,8 +1606,6 @@ lpfc_cmpl_reglogin_reglogin_issue(struct lpfc_vport *vport, ndlp->nlp_last_elscmd =ELS_CMD_PLOGI ;lpfc_issue_els_logo (vport, ndlp,0 ); - ndlp->nlp_prev_state =NLP_STE_REG_LOGIN_ISSUE ; -lpfc_nlp_set_state (vport, ndlp,NLP_STE_NPR_NODE );return ndlp->nlp_state; }
drivers/scsi/lpfc/lpfc_sli.c +0 -1
@@ -15252,7 +15252,6 @@ lpfc_sli4_seq_abort_rsp_cmpl(struct lpfc_hba *phba,if (cmd_iocbq) { ndlp = (struct lpfc_nodelist *)cmd_iocbq->context1;lpfc_nlp_put (ndlp); -lpfc_nlp_not_used (ndlp);lpfc_sli_release_iocbq (phba, cmd_iocbq); }
drivers/scsi/qla2xxx/qla_attr.c +7 -1
@@ -1909,6 +1909,8 @@ qla2x00_reset_host_stats(struct Scsi_Host *shost) vha->qla_stats.jiffies_at_last_reset =get_jiffies_64 ();if (IS_FWI2_CAPABLE (ha)) { +int rval; + stats =dma_alloc_coherent (&ha->pdev->dev,sizeof (*stats), &stats_dma,GFP_KERNEL );if (!stats) {
@@ -1918,7 +1920,11 @@ qla2x00_reset_host_stats(struct Scsi_Host *shost) }/* reset firmware statistics */ -qla24xx_get_isp_stats (base_vha, stats, stats_dma,BIT_0 ); + rval =qla24xx_get_isp_stats (base_vha, stats, stats_dma,BIT_0 ); +if (rval !=QLA_SUCCESS ) +ql_log (ql_log_warn, vha,0x70de , +"Resetting ISP statistics failed: rval = %d\n" , + rval);dma_free_coherent (&ha->pdev->dev,sizeof (*stats), stats, stats_dma);
drivers/scsi/sni_53c710.c +4 -1
@@ -71,6 +71,7 @@ static int snirm710_probe(struct platform_device *dev)struct NCR_700_Host_Parameters *hostdata;struct Scsi_Host *host;struct resource *res; +int rc; res =platform_get_resource (dev,IORESOURCE_MEM ,0 );if (!res)
@@ -96,7 +97,9 @@ static int snirm710_probe(struct platform_device *dev) goto out_kfree; host->this_id =7 ; host->base = base; - host->irq =platform_get_irq (dev,0 ); + host->irq = rc =platform_get_irq (dev,0 ); +if (rc <0 ) + goto out_put_host;if (request_irq (host->irq, NCR_700_intr,IRQF_SHARED ,"snirm710" , host)) {printk (KERN_ERR "snirm710: request_irq failed!\n" ); goto out_put_host;
drivers/scsi/sun3x_esp.c +3 -1
@@ -233,7 +233,9 @@ static int esp_sun3x_probe(struct platform_device *dev)if (!esp->command_block) goto fail_unmap_regs_dma; - host->irq =platform_get_irq (dev,0 ); + host->irq = err =platform_get_irq (dev,0 ); +if (err <0 ) + goto fail_unmap_command_block; err =request_irq (host->irq, scsi_esp_intr,IRQF_SHARED ,"SUN3X ESP" , esp);if (err <0 )
drivers/spi/spi-dln2.c +1 -1
@@ -783,7 +783,7 @@ static int dln2_spi_probe(struct platform_device *pdev)static int dln2_spi_remove (struct platform_device *pdev) { -struct spi_master *master =spi_master_get (platform_get_drvdata (pdev)); +struct spi_master *master =platform_get_drvdata (pdev);struct dln2_spi *dln2 =spi_master_get_devdata (master);pm_runtime_disable (&pdev->dev);
drivers/spi/spi-omap-100k.c +3 -3
@@ -435,7 +435,7 @@ static int omap1_spi100k_probe(struct platform_device *pdev)static int omap1_spi100k_remove (struct platform_device *pdev) { -struct spi_master *master =spi_master_get (platform_get_drvdata (pdev)); +struct spi_master *master =platform_get_drvdata (pdev);struct omap1_spi100k *spi100k =spi_master_get_devdata (master);pm_runtime_disable (&pdev->dev);
@@ -449,7 +449,7 @@ static int omap1_spi100k_remove(struct platform_device *pdev)#ifdef CONFIG_PM static int omap1_spi100k_runtime_suspend (struct device *dev) { -struct spi_master *master =spi_master_get (dev_get_drvdata (dev)); +struct spi_master *master =dev_get_drvdata (dev);struct omap1_spi100k *spi100k =spi_master_get_devdata (master);clk_disable_unprepare (spi100k->ick);
@@ -460,7 +460,7 @@ static int omap1_spi100k_runtime_suspend(struct device *dev)static int omap1_spi100k_runtime_resume (struct device *dev) { -struct spi_master *master =spi_master_get (dev_get_drvdata (dev)); +struct spi_master *master =dev_get_drvdata (dev);struct omap1_spi100k *spi100k =spi_master_get_devdata (master);int ret;
drivers/staging/greybus/uart.c +0 -2
@@ -661,8 +661,6 @@ static int set_serial_info(struct gb_tty *gb_tty,if ((close_delay != gb_tty->port.close_delay) || (closing_wait != gb_tty->port.closing_wait)) retval = -EPERM ; -else - retval = -EOPNOTSUPP ; }else { gb_tty->port.close_delay = close_delay; gb_tty->port.closing_wait = closing_wait;
drivers/staging/media/omap4iss/iss.c +3 -1
@@ -1244,8 +1244,10 @@ static int iss_probe(struct platform_device *pdev)if (ret <0 ) goto error; -if (!omap4iss_get (iss)) +if (!omap4iss_get (iss)) { + ret = -EINVAL ; goto error; + } ret =iss_reset (iss);if (ret <0 )
drivers/staging/rtl8192u/r8192U_core.c +1 -1
@@ -3420,7 +3420,7 @@ static void rtl819x_update_rxcounts(struct r8192_priv *priv, u32 *TotalRxBcnNum, u32 *TotalRxDataNum) {u16 SlotIndex; -u8 i; +u16 i; *TotalRxBcnNum =0 ; *TotalRxDataNum =0 ;
drivers/target/target_core_pscsi.c +2 -1
@@ -629,8 +629,9 @@ static void pscsi_transport_complete(struct se_cmd *cmd, struct scatterlist *sg,unsigned char *buf; buf =transport_kmap_data_sg (cmd); -if (!buf) +if (!buf) { ;/* XXX: TCM_LOGICAL_UNIT_COMMUNICATION_FAILURE */ + }if (cdb[0 ] ==MODE_SENSE_10 ) {if (!(buf[3 ] &0x80 ))
drivers/thermal/fair_share.c +4 -0
@@ -93,6 +93,8 @@ static int fair_share_throttle(struct thermal_zone_device *tz, int trip)int total_instance =0 ;int cur_trip_level =get_trip_level (tz); +mutex_lock (&tz->lock); +list_for_each_entry (instance, &tz->thermal_instances, tz_node) {if (instance->trip != trip)continue ;
@@ -121,6 +123,8 @@ static int fair_share_throttle(struct thermal_zone_device *tz, int trip)mutex_unlock (&instance->cdev->lock);thermal_cdev_update (cdev); } + +mutex_unlock (&tz->lock);return 0 ; }
drivers/tty/serial/stm32-usart.c +11 -1
@@ -476,8 +476,9 @@ static void stm32_set_termios(struct uart_port *port, struct ktermios *termios,unsigned int baud;u32 usartdiv, mantissa, fraction, oversampling;tcflag_t cflag = termios->c_cflag; -u32 cr1, cr2, cr3; +u32 cr1, cr2, cr3, isr;unsigned long flags; +int ret;if (!stm32_port->hw_flow_control) cflag &= ~CRTSCTS ;
@@ -486,6 +487,15 @@ static void stm32_set_termios(struct uart_port *port, struct ktermios *termios,spin_lock_irqsave (&port->lock, flags); + ret =readl_relaxed_poll_timeout_atomic (port->membase + ofs->isr, + isr, + (isr &USART_SR_TC ), +10 ,100000 ); + +/* Send the TC error message only when ISR_TC is not set. */ +if (ret) +dev_err (port->dev,"Transmission is not complete\n" ); +/* Stop serial port and reset value */ writel_relaxed (0 , port->membase + ofs->cr1);
drivers/tty/tty_io.c +4 -4
@@ -2791,14 +2791,14 @@ static int send_break(struct tty_struct *tty, unsigned int duration)* @p: pointer to result * * Obtain the modem status bits from the tty driver if the feature -* is supported. Return -EINVAL if it is not available. +* is supported. Return -ENOTTY if it is not available. * * Locking: none (up to the driver) */ static int tty_tiocmget (struct tty_struct *tty,int __user *p) { -int retval = -EINVAL ; +int retval = -ENOTTY ;if (tty->ops->tiocmget) { retval = tty->ops->tiocmget (tty);
@@ -2816,7 +2816,7 @@ static int tty_tiocmget(struct tty_struct *tty, int __user *p)* @p: pointer to desired bits * * Set the modem status bits from the tty driver if the feature -* is supported. Return -EINVAL if it is not available. +* is supported. Return -ENOTTY if it is not available. * * Locking: none (up to the driver) */
@@ -2828,7 +2828,7 @@ static int tty_tiocmset(struct tty_struct *tty, unsigned int cmd,unsigned int set, clear, val;if (tty->ops->tiocmset ==NULL ) -return -EINVAL ; +return -ENOTTY ; retval =get_user (val, p);if (retval)
drivers/usb/class/cdc-acm.c +0 -2
@@ -870,8 +870,6 @@ static int set_serial_info(struct acm *acm,if ((new_serial.close_delay != old_close_delay) || (new_serial.closing_wait != old_closing_wait)) retval = -EPERM ; -else - retval = -EOPNOTSUPP ; }else { acm->port.close_delay = close_delay; acm->port.closing_wait = closing_wait;
drivers/usb/core/hub.c +3 -3
@@ -3486,9 +3486,6 @@ int usb_port_resume(struct usb_device *udev, pm_message_t msg)* sequence. */ status =hub_port_status (hub, port1, &portstatus, &portchange); - -/* TRSMRCY = 10 msec */ -msleep (10 ); } SuspendCleared:
@@ -3503,6 +3500,9 @@ int usb_port_resume(struct usb_device *udev, pm_message_t msg)usb_clear_port_feature (hub->hdev, port1,USB_PORT_FEAT_C_SUSPEND ); } + +/* TRSMRCY = 10 msec */ +msleep (10 ); }if (udev->persist_enabled)
drivers/usb/core/quirks.c +4 -0
@@ -245,6 +245,7 @@ static const struct usb_device_id usb_quirk_list[] = {/* Realtek hub in Dell WD19 (Type-C) */ { USB_DEVICE(0x0bda, 0x0487), .driver_info = USB_QUIRK_NO_LPM }, + { USB_DEVICE(0x0bda, 0x5487), .driver_info = USB_QUIRK_RESET_RESUME }, /* Generic RTL8153 based ethernet adapters */ { USB_DEVICE(0x0bda, 0x8153), .driver_info = USB_QUIRK_NO_LPM },
@@ -264,6 +265,9 @@ static const struct usb_device_id usb_quirk_list[] = { { USB_DEVICE(0x1532, 0x0116), .driver_info = USB_QUIRK_LINEAR_UFRAME_INTR_BINTERVAL }, + /* Lenovo ThinkPad USB-C Dock Gen2 Ethernet (RTL8153 GigE) */ + { USB_DEVICE(0x17ef, 0xa387), .driver_info = USB_QUIRK_NO_LPM }, + /* BUILDWIN Photo Frame */ { USB_DEVICE(0x1908, 0x1315), .driver_info = USB_QUIRK_HONOR_BNUMINTERFACES },
drivers/usb/dwc2/core.h +2 -0
@@ -164,6 +164,7 @@ struct dwc2_hsotg_req;* @lock: State lock to protect contents of endpoint. * @dir_in: Set to true if this endpoint is of the IN direction, which * means that it is sending data to the Host. +* @map_dir: Set to the value of dir_in when the DMA buffer is mapped. * @index: The index for the endpoint registers. * @mc: Multi Count - number of transactions per microframe * @interval - Interval for periodic endpoints, in frames or microframes.
@@ -207,6 +208,7 @@ struct dwc2_hsotg_ep {unsigned short fifo_index;unsigned char dir_in; +unsigned char map_dir;unsigned char index;unsigned char mc;u16 interval;
drivers/usb/dwc2/gadget.c +2 -1
@@ -308,7 +308,7 @@ static void dwc2_hsotg_unmap_dma(struct dwc2_hsotg *hsotg,if (hs_req->req.length ==0 )return ; -usb_gadget_unmap_request (&hsotg->gadget, req, hs_ep->dir_in); +usb_gadget_unmap_request (&hsotg->gadget, req, hs_ep->map_dir); }/**
@@ -745,6 +745,7 @@ static int dwc2_hsotg_map_dma(struct dwc2_hsotg *hsotg,if (hs_req->req.length ==0 )return 0 ; + hs_ep->map_dir = hs_ep->dir_in; ret =usb_gadget_map_request (&hsotg->gadget, req, hs_ep->dir_in);if (ret) goto dma_error;
drivers/usb/dwc3/gadget.c +9 -0
@@ -2409,6 +2409,15 @@ static void dwc3_gadget_reset_interrupt(struct dwc3 *dwc) dwc->connected = true; +/* +* Ideally, dwc3_reset_gadget() would trigger the function +* drivers to stop any active transfers through ep disable. +* However, for functions which defer ep disable, such as mass +* storage, we will need to rely on the call to stop active +* transfers here, and avoid allowing of request queuing. +*/ + dwc->connected = false; +/* * WORKAROUND: DWC3 revisions <1.88a have an issue which * would cause a missing Disconnect Event if there's a
drivers/usb/gadget/config.c +4 -0
@@ -198,9 +198,13 @@ EXPORT_SYMBOL_GPL(usb_assign_descriptors);void usb_free_all_descriptors (struct usb_function *f) {usb_free_descriptors (f->fs_descriptors); + f->fs_descriptors =NULL ;usb_free_descriptors (f->hs_descriptors); + f->hs_descriptors =NULL ;usb_free_descriptors (f->ss_descriptors); + f->ss_descriptors =NULL ;usb_free_descriptors (f->ssp_descriptors); + f->ssp_descriptors =NULL ; }EXPORT_SYMBOL_GPL (usb_free_all_descriptors);
drivers/usb/gadget/function/f_fs.c +2 -1
@@ -2543,6 +2543,7 @@ static int __ffs_data_got_strings(struct ffs_data *ffs, do { /* lang_count > 0 so we can use do-while */ unsigned needed = needed_count; + u32 str_per_lang = str_count; if (unlikely(len < 3)) goto error_free;
@@ -2578,7 +2579,7 @@ static int __ffs_data_got_strings(struct ffs_data *ffs, data += length +1 ; len -= length +1 ; - }while (--str_count); + }while (--str_per_lang); s->id =0 ;/* terminator */ s->s =NULL ;
drivers/usb/gadget/function/f_uvc.c +6 -1
@@ -625,7 +625,12 @@ uvc_function_bind(struct usb_configuration *c, struct usb_function *f) uvc_hs_streaming_ep.wMaxPacketSize =cpu_to_le16 (max_packet_size | ((max_packet_mult -1 ) <<11 )); - uvc_hs_streaming_ep.bInterval = opts->streaming_interval; + +/* A high-bandwidth endpoint must specify a bInterval value of 1 */ +if (max_packet_mult >1 ) + uvc_hs_streaming_ep.bInterval =1 ; +else + uvc_hs_streaming_ep.bInterval = opts->streaming_interval; uvc_ss_streaming_ep.wMaxPacketSize =cpu_to_le16 (max_packet_size); uvc_ss_streaming_ep.bInterval = opts->streaming_interval;
drivers/usb/gadget/udc/dummy_hcd.c +15 -8
@@ -918,6 +918,21 @@ static int dummy_pullup(struct usb_gadget *_gadget, int value)spin_lock_irqsave (&dum->lock, flags); dum->pullup = (value !=0 );set_link_state (dum_hcd); +if (value ==0 ) { +/* +* Emulate synchronize_irq(): wait for callbacks to finish. +* This seems to be the best place to emulate the call to +* synchronize_irq() that's in usb_gadget_remove_driver(). +* Doing it in dummy_udc_stop() would be too late since it +* is called after the unbind callback and unbind shouldn't +* be invoked until all the other callbacks are finished. +*/ +while (dum->callback_usage >0 ) { +spin_unlock_irqrestore (&dum->lock, flags); +usleep_range (1000 ,2000 ); +spin_lock_irqsave (&dum->lock, flags); + } + }spin_unlock_irqrestore (&dum->lock, flags);usb_hcd_poll_rh_status (dummy_hcd_to_hcd (dum_hcd));
@@ -998,14 +1013,6 @@ static int dummy_udc_stop(struct usb_gadget *g)spin_lock_irq (&dum->lock); dum->ints_enabled =0 ;stop_activity (dum); - -/* emulate synchronize_irq(): wait for callbacks to finish */ -while (dum->callback_usage >0 ) { -spin_unlock_irq (&dum->lock); -usleep_range (1000 ,2000 ); -spin_lock_irq (&dum->lock); - } - dum->driver =NULL ;spin_unlock_irq (&dum->lock);
drivers/usb/gadget/udc/fotg210-udc.c +18 -8
@@ -340,15 +340,16 @@ static void fotg210_start_dma(struct fotg210_ep *ep, }else { buffer = req->req.buf + req->req.actual; length =ioread32 (ep->fotg210->reg + -FOTG210_FIBCR (ep->epnum -1 )); - length &=FIBCR_BCFX ; +FOTG210_FIBCR (ep->epnum -1 )) &FIBCR_BCFX ; +if (length > req->req.length - req->req.actual) + length = req->req.length - req->req.actual; } }else { buffer = req->req.buf + req->req.actual;if (req->req.length - req->req.actual > ep->ep.maxpacket) length = ep->ep.maxpacket;else - length = req->req.length; + length = req->req.length - req->req.actual; } d = dma_map_single(NULL, buffer, length,
@@ -385,8 +386,7 @@ static void fotg210_ep0_queue(struct fotg210_ep *ep, }if (ep->dir_in) {/* if IN */ fotg210_start_dma (ep, req); -if ((req->req.length == req->req.actual) || - (req->req.actual < ep->ep.maxpacket)) +if (req->req.length == req->req.actual)fotg210_done (ep, req,0 ); }else {/* OUT */ u32 value =ioread32 (ep->fotg210->reg +FOTG210_DMISGR0 );
@@ -827,7 +827,7 @@ static void fotg210_ep0in(struct fotg210_udc *fotg210)if (req->req.length)fotg210_start_dma (ep, req); -if ((req->req.length - req->req.actual) < ep->ep.maxpacket) +if (req->req.actual == req->req.length)fotg210_done (ep, req,0 ); }else {fotg210_set_cxdone (fotg210);
@@ -856,12 +856,16 @@ static void fotg210_out_fifo_handler(struct fotg210_ep *ep) {struct fotg210_request *req =list_entry (ep->queue.next, struct fotg210_request, queue); +int disgr1 =ioread32 (ep->fotg210->reg +FOTG210_DISGR1 );fotg210_start_dma (ep, req); -/* finish out transfer */ +/* Complete the request when it's full or a short packet arrived. +* Like other drivers, short_not_ok isn't handled. +*/ +if (req->req.length == req->req.actual || - req->req.actual < ep->ep.maxpacket) + (disgr1 &DISGR1_SPK_INT (ep->epnum -1 )))fotg210_done (ep, req,0 ); }
@@ -1034,6 +1038,12 @@ static void fotg210_init(struct fotg210_udc *fotg210) value &= ~DMCR_GLINT_EN ;iowrite32 (value, fotg210->reg +FOTG210_DMCR ); +/* enable only grp2 irqs we handle */ +iowrite32 (~(DISGR2_DMA_ERROR |DISGR2_RX0BYTE_INT |DISGR2_TX0BYTE_INT + |DISGR2_ISO_SEQ_ABORT_INT |DISGR2_ISO_SEQ_ERR_INT + |DISGR2_RESM_INT |DISGR2_SUSP_INT |DISGR2_USBRST_INT ), + fotg210->reg +FOTG210_DMISGR2 ); +/* disable all fifo interrupt */ iowrite32 (~(u32 )0 , fotg210->reg +FOTG210_DMISGR1 );
drivers/usb/gadget/udc/pch_udc.c +33 -16
78 lines not on this page · raw message
fs/ext4/ialloc.c +32 -16
48 lines not on this page · raw message
kernel/trace/trace.c +19 -26
45 lines not on this page · raw message
kernel/trace/trace_clock.c +30 -14
44 lines not on this page · raw message
net/netfilter/nf_conntrack_standalone.c +4 -1
Lines of this file are not shown. View the raw message.
The rest of this diff is not shown. View the raw message.
Part of the diff is not shown here. View the raw message.