Linux 4.9.54
Greg KH
maintainerI'm announcing the release of the 4.9.54 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:
http://git.kernel.org/?p=linux/kernel/git/stable/linux-stable.git;a=summary
thanks,
greg k-h
------------
Documentation/devicetree/bindings/display/bridge/ti,ths8135.txt | 46 ++ Documentation/devicetree/bindings/iio/adc/avia-hx711.txt | 18 + Documentation/devicetree/bindings/vendor-prefixes.txt | 1 Makefile | 2 arch/arm/Kconfig-nommu | 3 arch/arm/boot/dts/am335x-chilisom.dtsi | 8 arch/arm/boot/dts/bcm953012k.dts | 2 arch/arm/boot/dts/exynos4412-odroid-common.dtsi | 4 arch/arm/boot/dts/exynos4412-odroidu3.dts | 5 arch/arm/boot/dts/exynos4412-odroidx2.dts | 1 arch/arm/boot/dts/exynos4412-prime.dtsi | 41 ++ arch/arm/boot/dts/exynos4412.dtsi | 2 arch/arm/boot/dts/mt2701.dtsi | 36 ++ arch/arm/boot/dts/r8a7790.dtsi | 12 arch/arm/mach-at91/pm.c | 2 arch/arm/mach-bcm/bcm_kona_smc.c | 2 arch/arm/mach-cns3xxx/core.c | 2 arch/arm/mach-omap2/prm_common.c | 2 arch/arm/mach-omap2/vc.c | 2 arch/arm/mach-spear/time.c | 2 arch/mips/ath79/clock.c | 7 arch/mips/include/asm/irq.h | 15 arch/mips/kernel/asm-offsets.c | 1 arch/mips/kernel/cps-vec.S | 2 arch/mips/kernel/genex.S | 8 arch/mips/kernel/process.c | 56 ++- arch/mips/kernel/vmlinux.lds.S | 2 arch/mips/lantiq/xway/sysctrl.c | 4 arch/mips/ralink/mt7620.c | 18 - arch/mips/ralink/rt3883.c | 2 arch/parisc/kernel/perf.c | 94 +++-- arch/s390/include/asm/pgtable.h | 4 arch/x86/kernel/acpi/boot.c | 7 arch/x86/kernel/apic/apic.c | 26 - arch/x86/purgatory/Makefile | 1 block/partitions/efi.c | 17 - drivers/ata/libata-transport.c | 9 drivers/ata/sata_via.c | 18 - drivers/clk/axs10x/i2s_pll_clock.c | 1 drivers/clk/sunxi-ng/ccu-sun8i-h3.c | 10 drivers/cpufreq/intel_pstate.c | 1 drivers/extcon/extcon-axp288.c | 2 drivers/gpu/drm/amd/amdkfd/kfd_events.c | 4 drivers/gpu/drm/arm/malidp_planes.c | 13 drivers/gpu/drm/i915/intel_overlay.c | 64 ++- drivers/gpu/drm/i915/intel_psr.c | 15 drivers/hid/wacom_sys.c | 2 drivers/hwmon/gl520sm.c | 25 - drivers/i2c/busses/i2c-meson.c | 2 drivers/iio/adc/axp288_adc.c | 32 - drivers/iio/adc/fsl-imx25-gcq.c | 1 drivers/infiniband/hw/qib/qib_iba7322.c | 2 drivers/infiniband/sw/rxe/rxe_pool.c | 1 drivers/infiniband/sw/rxe/rxe_resp.c | 20 - drivers/infiniband/ulp/ipoib/ipoib_main.c | 8 drivers/infiniband/ulp/ipoib/ipoib_vlan.c | 10 drivers/iommu/arm-smmu.c | 2 drivers/iommu/exynos-iommu.c | 5 drivers/iommu/io-pgtable-arm.c | 6 drivers/md/raid10.c | 19 - drivers/media/pci/ttpci/av7110_hw.c | 8 drivers/media/pci/ttpci/av7110_hw.h | 12 drivers/media/platform/exynos-gsc/gsc-core.c | 2 drivers/misc/lkdtm_core.c | 4 drivers/mmc/core/sdio_bus.c | 12 drivers/net/dsa/b53/b53_common.c | 10 drivers/net/dsa/b53/b53_regs.h | 4 drivers/net/ethernet/ibm/ibmvnic.c | 2 drivers/net/ethernet/intel/igb/igb_main.c | 5 drivers/net/ethernet/qlogic/qed/qed_dcbx.c | 2 drivers/net/ethernet/renesas/sh_eth.h | 2 drivers/net/ethernet/sfc/ef10.c | 16 drivers/net/ethernet/sfc/nic.h | 2 drivers/net/ethernet/sfc/tx.c | 1 drivers/net/team/team.c | 8 drivers/net/usb/Kconfig | 2 drivers/net/usb/plusb.c | 15 drivers/net/wireless/ath/ath10k/core.h | 1 drivers/net/wireless/ath/ath10k/mac.c | 18 + drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c | 7 drivers/nvme/host/rdma.c | 28 - drivers/power/supply/axp288_fuel_gauge.c | 4 drivers/rapidio/devices/tsi721.c | 4 drivers/rapidio/devices/tsi721.h | 4 drivers/reset/reset-ti-syscon.c | 4 drivers/scsi/be2iscsi/be_iscsi.c | 163 +++++----- drivers/scsi/be2iscsi/be_main.c | 7 drivers/scsi/be2iscsi/be_main.h | 1 drivers/spi/spi-pxa2xx.c | 4 drivers/tty/goldfish.c | 2 drivers/tty/serial/8250/8250_moxa.c | 1 drivers/tty/serial/8250/8250_port.c | 4 drivers/usb/chipidea/otg.c | 17 - drivers/usb/host/Kconfig | 4 drivers/usb/serial/mos7720.c | 9 drivers/usb/serial/mos7840.c | 19 - fs/btrfs/inode.c | 8 fs/btrfs/volumes.c | 2 fs/gfs2/glock.c | 12 fs/hugetlbfs/inode.c | 25 - fs/nfs/callback.c | 4 fs/xfs/kmem.c | 18 - fs/xfs/kmem.h | 2 fs/xfs/xfs_itable.c | 6 include/linux/audit.h | 20 + include/linux/mmc/sdio_func.h | 2 include/net/netfilter/nf_tables_ipv6.h | 6 include/uapi/drm/drm_fourcc.h | 1 mm/memcontrol.c | 7 net/bridge/br_netlink.c | 7 net/compat.c | 17 - net/core/dev.c | 3 net/ipv4/netfilter/nf_nat_snmp_basic.c | 1 net/ipv4/udp_offload.c | 3 net/netfilter/nf_conntrack_ecache.c | 2 net/netfilter/nf_conntrack_netlink.c | 1 net/netfilter/nf_nat_core.c | 2 net/netfilter/nfnetlink_cthelper.c | 20 - net/netfilter/nfnetlink_cttimeout.c | 2 net/packet/af_packet.c | 2 net/rds/ib_cm.c | 47 ++ net/rds/ib_send.c | 25 - net/rds/rdma.c | 10 net/rds/rds.h | 1 net/rds/send.c | 4 sound/pci/au88x0/au88x0_core.c | 3 sound/soc/codecs/rt5514.c | 4 sound/soc/codecs/rt5659.c | 86 ++--- sound/soc/codecs/rt5660.c | 4 sound/soc/codecs/wm_adsp.c | 7 sound/soc/soc-dapm.c | 62 +++ sound/soc/soc-topology.c | 9 tools/power/x86/turbostat/turbostat.c | 4 133 files changed, 1041 insertions(+), 535 deletions(-)
Afzal Mohammed (1):
ARM: 8635/1: nommu: allow enabling REMAP_VECTORS_TO_RAM
Alden Tondettar (1):
partitions/efi: Fix integer overflow in GPT size calculation
Alexander Potapenko (1):
net/packet: check length in getsockopt() called with PACKET_HDRLEN
Alexey Brodkin (1):
serial: 8250_port: Remove dangerous pr_debug()
Andreas Klinger (1):
iio: adc: hx711: Add DT binding for avia,hx711
Ansis Atteka (1):
udp: disable inner UDP checksum offloads in IPsec case
Arnd Bergmann (6):
MIPS: Lantiq: Fix another request_mem_region() return code check IB/qib: fix false-postive maybe-uninitialized warning
ARM: remove duplicate 'const' annotations'
ASoC: rt5514: fix gcc-7 warning
ALSA: au88x0: avoid theoretical uninitialized access
ttpci: address stringop overflow warning
Arvind Yadav (2):
mips: ath79: clock:- Unmap region obtained by of_iomap
parisc: perf: Fix potential NULL pointer dereference
Axel Köllhofer (1):
rtl8xxxu: Add additional USB IDs for rtl8192eu devices
Bart Van Assche (2):
IB/rxe: Add a runtime check in alloc_index() IB/rxe: Fix a MR reference leak in check_rkey()
Bartlomiej Zolnierkiewicz (1):
ARM: dts: exynos: Add CPU OPPs for Exynos4412 Prime
Bartosz Golaszewski (1):
drm: bridge: add DT bindings for TI ths8135
Benjamin Tissoires (1):
HID: wacom: release the resources before leaving despite devm
Brian Starkey (2):
drm: mali-dp: Fix destination size handling when rotating
drm: mali-dp: Fix transposed horizontal/vertical flip
Charles Keepax (1):
ASoC: wm_adsp: Return an error on write to a disabled volatile control
Christophe JAILLET (1):
tty: goldfish: Fix a parameter of a call to free_irq
Colin Ian King (1):
MIPS: ralink: Fix incorrect assignment on ralink_soc
Dan Carpenter (1):
GFS2: Fix reference to ERR_PTR in gfs2_glock_iter_next
Darrick J. Wong (1):
xfs: remove kmem_zalloc_greedy
David E. Box (1):
spi: pxa2xx: Add support for Intel Gemini Lake
Dou Liyang (1):
x86/acpi: Restore the order of CPU IDs
Edward Cree (1):
sfc: get PIO buffer size from the NIC
Feras Daoud (3):
IB/ipoib: Fix deadlock over vlan_mutex
IB/ipoib: rtnl_unlock can not come after free_netdev IB/ipoib: Replace list_del of the neigh->list with list_del_init
Florian Fainelli (1):
net: dsa: b53: Include IMP/CPU port in dumb forwarding mode
Gerald Schaefer (1):
s390/mm: make pmdp_invalidate() do invalidation only
Greg Kroah-Hartman (1):
Linux 4.9.54
Guenter Roeck (1):
hwmon: (gl520sm) Fix overflows and crash seen when writing into limit attributes
Guilherme G Piccoli (1):
igb: re-assign hw address pointer on reset after PCI error
Gwendal Grignou (1):
libata: transport: Remove circular dependency at free time
Hans de Goede (3):
power: supply: axp288_fuel_gauge: Fix fuel_gauge_reg_readb return on error
extcon: axp288: Use vbus-valid instead of -present to determine cable presence
iio: adc: axp288: Drop bogus AXP288_ADC_TS_PIN_CTRL register modifications
Heiner Kallweit (2):
mmc: sdio: fix alignment issue in struct sdio_func
i2c: meson: fix wrong variable usage in meson_i2c_put_data
Ido Schimmel (1):
bridge: netlink: register netdevice before executing changelink
James Liao (1):
arm: dts: mt2701: Add subsystem clock controller device nodes
Jason Yan (1):
nfs: make nfs4_cb_sv_ops static
Javier Martinez Canillas (1):
iio: adc: imx25-gcq: Fix module autoload
Jiancheng Xue (1):
reset: ti_syscon: fix a ti_syscon_reset_status issue
Jitendra Bhivare (1):
scsi: be2iscsi: Add checks to validate CID alloc/free
Johan Hovold (2):
USB: serial: mos7720: fix control-message error handling
USB: serial: mos7840: fix control-message error handling
John Crispin (2):
MIPS: ralink: Fix a typo in the pinmux setup.
usb: make the MTK XHCI driver compile for older MIPS SoCs
Jon Mason (1):
ARM: dts: BCM5301X: Fix memory start address
Jose Abreu (1):
clk/axs10x: Clear init field in driver probe
Juerg Haefliger (1):
lkdtm: Fix Oops when unloading the module
Kristian H. Kristensen (1):
drm_fourcc: Fix DRM_FORMAT_MOD_LINEAR #define
Laurent Dufour (1):
mm/cgroup: avoid panic when init with low memory
Len Brown (1):
tools/power turbostat: bugfix: GFXMHz column not changing
Linus Walleij (2):
ASoC: dapm: handle probe deferrals
ASoC: dapm: fix some pointer error handling
Liping Zhang (2):
netfilter: invoke synchronize_rcu after set the _hook_ to NULL
netfilter: nfnl_cthelper: fix incorrect helper->expect_class_max
Liu Bo (2):
Btrfs: fix segmentation fault when doing dio read
Btrfs: fix potential use-after-free for cloned bio
Marcin Niestroj (1):
ARM: dts: am335x-chilisom: Wakeup from RTC-only state by power on event
Marek Szyprowski (1):
iommu/exynos: Block SYSMMU while invalidating FLPD cache
Matt Redfearn (2):
MIPS: IRQ Stack: Unwind IRQ stack onto task stack
MIPS: smp-cps: Fix retrieval of VPE mask on big endian CPUs
Matwey V. Kornilov (1):
serial: 8250: moxa: Store num_ports in brd
Michal Kazior (1):
ath10k: prevent sta pointer rcu violation
Mike Galbraith (1):
kasan: do not sanitize kexec purgatory
Mike Kravetz (1):
hugetlbfs: initialize shared policy as part of inode allocation
Myungho Jung (1):
net: core: Prevent from dereferencing null pointer when releasing SKB
Nagaraju, Vathsala (1):
drm/i915/psr: disable psr2 for resolution greater than 32X20
Nathan Fontenot (1):
ibmvnic: Free tx/rx scrq pointer array when releasing sub-crqs
Nicholas Mc Guire (2):
ASoC: rt5659: drop double const
ASoC: rt5660: remove double const
Niklas Söderlund (1):
sh_eth: use correct name for ECMR_MPDE bit
Oleksandr Tyshchenko (1):
iommu/io-pgtable-arm: Check for leaf entry before dereferencing it
Ondrej Jirman (1):
clk: sunxi-ng: fix PLL_CPUX adjusting on H3
Ondrej Zary (1):
sata_via: Enable hotplug only on VT6421
Pablo Neira Ayuso (1):
netfilter: nf_tables: set pktinfo->thoff at AH header if found
Pan Bian (2):
drm/amdkfd: fix improper return value on error
team: fix memory leaks
Paul Burton (1):
MIPS: Ensure bss section ends on a long-aligned address
Peter Chen (1):
usb: chipidea: vbus event may exist before starting gadget
Rafael J. Wysocki (1):
cpufreq: intel_pstate: Update pid_params.sample_rate_ns in pid_param_set()
Randy Dunlap (1):
drivers/rapidio/devices/tsi721.c: make module parameter variable name unique
Richard Guy Briggs (1):
audit: log 32-bit socketcalls
Roman Spychała (1):
usb: plusb: Add support for PL-27A1
Sagi Grimberg (1):
nvme-rdma: handle cpu unplug when re-establishing the controller
Santosh Shilimkar (1):
RDS: RDMA: Fix the composite message user notification
Shaohua Li (1):
md/raid10: submit bio directly to replacement disk
Simon Horman (1):
ARM: dts: r8a7790: Use R-Car Gen 2 fallback binding for msiof nodes
Sricharan R (1):
iommu/arm-smmu: Set privileged attribute to 'default' instead of 'unprivileged'
Thibault Saunier (1):
exynos-gsc: Do not swap cb/cr for semi planar formats
Ville Syrjälä (1):
drm/i915: Fix the overlay frontbuffer tracking
Zhu Yanjun (1):
rds: ib: add error handle
[email protected] (1):
qed: Fix possible system hang in the dcbnl-getdcbx() path.
Greg KH
maintainerDocumentation/devicetree/bindings/display/bridge/ti,ths8135.txt new file +46 -0
@@ -0,0 +1,46 @@ +THS8135 Video DAC +----------------- + +This is the binding for Texas Instruments THS8135 Video DAC bridge. + +Required properties: + +- compatible: Must be "ti,ths8135" + +Required nodes: + +This device has two video ports. Their connections are modelled using the OF +graph bindings specified in Documentation/devicetree/bindings/graph.txt. + +- Video port 0 for RGB input +- Video port 1 for VGA output + +Example +------- + +vga-bridge { + compatible = "ti,ths8135"; + #address-cells = <1>; + #size-cells = <0>; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + + vga_bridge_in: endpoint { + remote-endpoint = <&lcdc_out_vga>; + }; + }; + + port@1 { + reg = <1>; + + vga_bridge_out: endpoint { + remote-endpoint = <&vga_con_in>; + }; + }; + }; +};
Documentation/devicetree/bindings/iio/adc/avia-hx711.txt new file +18 -0
@@ -0,0 +1,18 @@ +* AVIA HX711 ADC chip for weight cells + Bit-banging driver + +Required properties: + - compatible: Should be "avia,hx711" + - sck-gpios: Definition of the GPIO for the clock + - dout-gpios: Definition of the GPIO for data-out + See Documentation/devicetree/bindings/gpio/gpio.txt + - avdd-supply: Definition of the regulator used as analog supply + +Example: +weight@0 { + compatible = "avia,hx711"; + sck-gpios = <&gpio3 10 GPIO_ACTIVE_HIGH>; + dout-gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>; + avdd-suppy = <&avdd>; +}; +
Documentation/devicetree/bindings/vendor-prefixes.txt +1 -0
@@ -38,6 +38,7 @@ atmel Atmel Corporation auo AU Optronics Corporation auvidea Auvidea GmbH avago Avago Technologies +avia avia semiconductor avic Shanghai AVIC Optoelectronics Co., Ltd. axis Axis Communications AB boe BOE Technology Group Co., Ltd.
Makefile +1 -1
@@ -1,6 +1,6 @@ VERSION = 4 PATCHLEVEL = 9 -SUBLEVEL = 53 +SUBLEVEL = 54 EXTRAVERSION = NAME = Roaring Lionus
arch/arm/Kconfig-nommu +1 -2
@@ -34,8 +34,7 @@ config PROCESSOR_ID used instead of the auto-probing which utilizes the register. config REMAP_VECTORS_TO_RAM - bool 'Install vectors to the beginning of RAM' if DRAM_BASE - depends on DRAM_BASE + bool 'Install vectors to the beginning of RAM' help The kernel needs to change the hardware exception vectors. In nommu mode, the hardware exception vectors are normally
arch/arm/boot/dts/am335x-chilisom.dtsi +8 -0
@@ -124,6 +124,14 @@ &rtc { system-power-controller; + + pinctrl-0 = <&ext_wakeup>; + pinctrl-names = "default"; + + ext_wakeup: ext-wakeup { + pins = "ext_wakeup0"; + input-enable; + }; }; /* NAND Flash */
arch/arm/boot/dts/bcm953012k.dts +1 -1
@@ -48,7 +48,7 @@ }; memory { - reg = <0x00000000 0x10000000>; + reg = <0x80000000 0x10000000>; }; };
arch/arm/boot/dts/exynos4412-odroid-common.dtsi +2 -2
@@ -97,11 +97,11 @@ thermal-zones { cpu_thermal: cpu-thermal { cooling-maps { - map0 { + cooling_map0: map0 { /* Corresponds to 800MHz at freq_table */ cooling-device = <&cpu0 7 7>; }; - map1 { + cooling_map1: map1 { /* Corresponds to 200MHz at freq_table */ cooling-device = <&cpu0 13 13>; };
arch/arm/boot/dts/exynos4412-odroidu3.dts +3 -2
@@ -13,6 +13,7 @@ /dts-v1/; #include "exynos4412-odroid-common.dtsi" +#include "exynos4412-prime.dtsi" / { model = "Hardkernel ODROID-U3 board based on Exynos4412";
@@ -47,11 +48,11 @@ cooling-maps { map0 { trip = <&cpu_alert1>; - cooling-device = <&cpu0 7 7>; + cooling-device = <&cpu0 9 9>; }; map1 { trip = <&cpu_alert2>; - cooling-device = <&cpu0 13 13>; + cooling-device = <&cpu0 15 15>; }; map2 { trip = <&cpu_alert0>;
arch/arm/boot/dts/exynos4412-odroidx2.dts +1 -0
@@ -12,6 +12,7 @@ */ #include "exynos4412-odroidx.dts" +#include "exynos4412-prime.dtsi" / { model = "Hardkernel ODROID-X2 board based on Exynos4412";
arch/arm/boot/dts/exynos4412-prime.dtsi new file +41 -0
41 lines not on this page · raw message
arch/arm/boot/dts/exynos4412.dtsi +1 -1
@@ -130,7 +130,7 @@ opp-microvolt = <1287500>; clock-latency-ns = <200000>; }; - opp@1500000000 { + cpu0_opp_1500: opp@1500000000 { opp-hz = /bits/ 64 <1500000000>; opp-microvolt = <1350000>; clock-latency-ns = <200000>;
arch/arm/boot/dts/mt2701.dtsi +36 -0
@@ -174,4 +174,40 @@ clocks = <&uart_clk>; status = "disabled"; }; + + mmsys: syscon@14000000 { + compatible = "mediatek,mt2701-mmsys", "syscon"; + reg = <0 0x14000000 0 0x1000>; + #clock-cells = <1>; + }; + + imgsys: syscon@15000000 { + compatible = "mediatek,mt2701-imgsys", "syscon"; + reg = <0 0x15000000 0 0x1000>; + #clock-cells = <1>; + }; + + vdecsys: syscon@16000000 { + compatible = "mediatek,mt2701-vdecsys", "syscon"; + reg = <0 0x16000000 0 0x1000>; + #clock-cells = <1>; + }; + + hifsys: syscon@1a000000 { + compatible = "mediatek,mt2701-hifsys", "syscon"; + reg = <0 0x1a000000 0 0x1000>; + #clock-cells = <1>; + }; + + ethsys: syscon@1b000000 { + compatible = "mediatek,mt2701-ethsys", "syscon"; + reg = <0 0x1b000000 0 0x1000>; + #clock-cells = <1>; + }; + + bdpsys: syscon@1c000000 { + compatible = "mediatek,mt2701-bdpsys", "syscon"; + reg = <0 0x1c000000 0 0x1000>; + #clock-cells = <1>; + }; };
arch/arm/boot/dts/r8a7790.dtsi +8 -4
@@ -1493,7 +1493,8 @@ }; msiof0: spi@e6e20000 { - compatible = "renesas,msiof-r8a7790"; + compatible = "renesas,msiof-r8a7790", + "renesas,rcar-gen2-msiof"; reg = <0 0xe6e20000 0 0x0064>; interrupts = <GIC_SPI 156 IRQ_TYPE_LEVEL_HIGH>; clocks = <&mstp0_clks R8A7790_CLK_MSIOF0>;
@@ -1507,7 +1508,8 @@ }; msiof1: spi@e6e10000 { - compatible = "renesas,msiof-r8a7790"; + compatible = "renesas,msiof-r8a7790", + "renesas,rcar-gen2-msiof"; reg = <0 0xe6e10000 0 0x0064>; interrupts = <GIC_SPI 157 IRQ_TYPE_LEVEL_HIGH>; clocks = <&mstp2_clks R8A7790_CLK_MSIOF1>;
@@ -1521,7 +1523,8 @@ }; msiof2: spi@e6e00000 { - compatible = "renesas,msiof-r8a7790"; + compatible = "renesas,msiof-r8a7790", + "renesas,rcar-gen2-msiof"; reg = <0 0xe6e00000 0 0x0064>; interrupts = <GIC_SPI 158 IRQ_TYPE_LEVEL_HIGH>; clocks = <&mstp2_clks R8A7790_CLK_MSIOF2>;
@@ -1535,7 +1538,8 @@ }; msiof3: spi@e6c90000 { - compatible = "renesas,msiof-r8a7790"; + compatible = "renesas,msiof-r8a7790", + "renesas,rcar-gen2-msiof"; reg = <0 0xe6c90000 0 0x0064>; interrupts = <GIC_SPI 159 IRQ_TYPE_LEVEL_HIGH>; clocks = <&mstp2_clks R8A7790_CLK_MSIOF3>;
arch/arm/mach-at91/pm.c +1 -1
@@ -335,7 +335,7 @@ static void at91sam9_sdram_standby(void)at91_ramc_write (1 ,AT91_SDRAMC_LPR , saved_lpr1); } -static const struct of_device_id const ramc_ids[]__initconst = { +static const struct of_device_id ramc_ids[]__initconst = { { .compatible ="atmel,at91rm9200-sdramc" , .data = at91rm9200_standby }, { .compatible ="atmel,at91sam9260-sdramc" , .data = at91sam9_sdram_standby }, { .compatible ="atmel,at91sam9g45-ddramc" , .data = at91_ddr_standby },
arch/arm/mach-bcm/bcm_kona_smc.c +1 -1
@@ -33,7 +33,7 @@ struct bcm_kona_smc_data {unsigned result; }; -static const struct of_device_id const bcm_kona_smc_ids[]__initconst = { +static const struct of_device_id bcm_kona_smc_ids[]__initconst = { {.compatible ="brcm,kona-smc" }, {.compatible ="bcm,kona-smc" },/* deprecated name */ {},
arch/arm/mach-cns3xxx/core.c +1 -1
@@ -346,7 +346,7 @@ static struct usb_ohci_pdata cns3xxx_usb_ohci_pdata = { .power_off = csn3xxx_usb_power_off, }; -static const struct of_dev_auxdata const cns3xxx_auxdata[]__initconst = { +static const struct of_dev_auxdata cns3xxx_auxdata[]__initconst = { {"intel,usb-ehci" ,CNS3XXX_USB_BASE ,"ehci-platform" , &cns3xxx_usb_ehci_pdata }, {"intel,usb-ohci" ,CNS3XXX_USB_OHCI_BASE ,"ohci-platform" , &cns3xxx_usb_ohci_pdata }, {"cavium,cns3420-ahci" ,CNS3XXX_SATA2_BASE ,"ahci" ,NULL },
arch/arm/mach-omap2/prm_common.c +1 -1
@@ -713,7 +713,7 @@ static struct omap_prcm_init_data scrm_data __initdata = { };#endif -static const struct of_device_id const omap_prcm_dt_match_table[]__initconst = { +static const struct of_device_id omap_prcm_dt_match_table[]__initconst = { #ifdef CONFIG_SOC_AM33XX { .compatible ="ti,am3-prcm" , .data = &am3_prm_data }, #endif
arch/arm/mach-omap2/vc.c +1 -1
@@ -559,7 +559,7 @@ struct i2c_init_data {u8 hsscll_12; }; -static const struct i2c_init_data const omap4_i2c_timing_data[]__initconst = { +static const struct i2c_init_data omap4_i2c_timing_data[]__initconst = { { .load =50 , .loadbits =0x3 ,
arch/arm/mach-spear/time.c +1 -1
@@ -204,7 +204,7 @@ static void __init spear_clockevent_init(int irq)setup_irq (irq, &spear_timer_irq); } -static const struct of_device_id const timer_of_match[]__initconst = { +static const struct of_device_id timer_of_match[]__initconst = { { .compatible ="st,spear-timer" , }, { }, };
arch/mips/ath79/clock.c +5 -2
@@ -508,16 +508,19 @@ static void __init ath79_clocks_init_dt_ng(struct device_node *np)ar9330_clk_init (ref_clk, pll_base); else {pr_err ("%s: could not find any appropriate clk_init()\n" , dnfn); - goto err_clk; + goto err_iounmap; }if (of_clk_add_provider (np, of_clk_src_onecell_get, &clk_data)) {pr_err ("%s: could not register clk provider\n" , dnfn); - goto err_clk; + goto err_iounmap; }return ; +err_iounmap: +iounmap (pll_base); + err_clk:clk_put (ref_clk);
arch/mips/include/asm/irq.h +15 -0
@@ -18,9 +18,24 @@#include <irq.h> #define IRQ_STACK_SIZE THREAD_SIZE +#define IRQ_STACK_START (IRQ_STACK_SIZE - sizeof(unsigned long))extern void *irq_stack[NR_CPUS ]; +/* +* The highest address on the IRQ stack contains a dummy frame put down in +* genex.S (handle_int & except_vec_vi_handler) which is structured as follows: +* +* top ------------ +* | task sp | <- irq_stack[cpu] + IRQ_STACK_START +* ------------ +* | | <- First frame of IRQ context +* ------------ +* +* task sp holds a copy of the task stack pointer where the struct pt_regs +* from exception entry can be found. +*/ +static inline bool on_irq_stack (int cpu,unsigned long sp) {unsigned long low = (unsigned long )irq_stack[cpu];
arch/mips/kernel/asm-offsets.c +1 -0
@@ -103,6 +103,7 @@ void output_thread_info_defines(void)DEFINE (_THREAD_SIZE,THREAD_SIZE );DEFINE (_THREAD_MASK,THREAD_MASK );DEFINE (_IRQ_STACK_SIZE,IRQ_STACK_SIZE ); +DEFINE (_IRQ_STACK_START,IRQ_STACK_START );BLANK (); }
arch/mips/kernel/cps-vec.S +1 -1
@@ -361,7 +361,7 @@ LEAF(mips_cps_get_bootcfg) END(mips_cps_get_bootcfg) LEAF(mips_cps_boot_vpes) - PTR_L ta2, COREBOOTCFG_VPEMASK(a0) + lw ta2, COREBOOTCFG_VPEMASK(a0) PTR_L ta3, COREBOOTCFG_VPECONFIG(a0) #if defined(CONFIG_CPU_MIPSR6)
arch/mips/kernel/genex.S +6 -2
@@ -215,9 +215,11 @@ NESTED(handle_int, PT_SIZE, sp) beq t0, t1, 2f /* Switch to IRQ stack */ - li t1, _IRQ_STACK_SIZE + li t1, _IRQ_STACK_START PTR_ADD sp, t0, t1 + /* Save task's sp on IRQ stack so that unwinding can follow it */ + LONG_S s1, 0(sp) 2: jal plat_irq_dispatch
@@ -325,9 +327,11 @@ NESTED(except_vec_vi_handler, 0, sp) beq t0, t1, 2f /* Switch to IRQ stack */ - li t1, _IRQ_STACK_SIZE + li t1, _IRQ_STACK_START PTR_ADD sp, t0, t1 + /* Save task's sp on IRQ stack so that unwinding can follow it */ + LONG_S s1, 0(sp) 2: jalr v0
arch/mips/kernel/process.c +38 -18
77 lines not on this page · raw message
arch/mips/kernel/vmlinux.lds.S +1 -1
@@ -182,7 +182,7 @@ SECTIONS * Force .bss to 64K alignment so that .bss..swapper_pg_dir * gets that alignment. .sbss should be empty, so there will be * no holes after __init_end. */ - BSS_SECTION(0, 0x10000, 0) + BSS_SECTION(0, 0x10000, 8) _end = . ;
arch/mips/lantiq/xway/sysctrl.c +2 -2
@@ -469,8 +469,8 @@ void __init ltq_soc_init(void)panic ("Failed to load xbar nodes from devicetree" );if (of_address_to_resource (np_xbar,0 , &res_xbar))panic ("Failed to get xbar resources" ); -if (request_mem_region (res_xbar.start,resource_size (&res_xbar), - res_xbar.name) <0 ) +if (!request_mem_region (res_xbar.start,resource_size (&res_xbar), + res_xbar.name))panic ("Failed to get xbar resources" ); ltq_xbar_membase = ioremap_nocache(res_xbar.start,
arch/mips/ralink/mt7620.c +9 -9
@@ -176,7 +176,7 @@ static struct rt2880_pmx_func spi_cs1_grp_mt7628[] = {static struct rt2880_pmx_func spis_grp_mt7628[] = {FUNC ("pwm_uart2" ,3 ,14 ,4 ), -FUNC ("util" ,2 ,14 ,4 ), +FUNC ("utif" ,2 ,14 ,4 ),FUNC ("gpio" ,1 ,14 ,4 ),FUNC ("spis" ,0 ,14 ,4 ), };
@@ -190,28 +190,28 @@ static struct rt2880_pmx_func gpio_grp_mt7628[] = {static struct rt2880_pmx_func p4led_kn_grp_mt7628[] = {FUNC ("jtag" ,3 ,30 ,1 ), -FUNC ("util" ,2 ,30 ,1 ), +FUNC ("utif" ,2 ,30 ,1 ),FUNC ("gpio" ,1 ,30 ,1 ),FUNC ("p4led_kn" ,0 ,30 ,1 ), };static struct rt2880_pmx_func p3led_kn_grp_mt7628[] = {FUNC ("jtag" ,3 ,31 ,1 ), -FUNC ("util" ,2 ,31 ,1 ), +FUNC ("utif" ,2 ,31 ,1 ),FUNC ("gpio" ,1 ,31 ,1 ),FUNC ("p3led_kn" ,0 ,31 ,1 ), };static struct rt2880_pmx_func p2led_kn_grp_mt7628[] = {FUNC ("jtag" ,3 ,32 ,1 ), -FUNC ("util" ,2 ,32 ,1 ), +FUNC ("utif" ,2 ,32 ,1 ),FUNC ("gpio" ,1 ,32 ,1 ),FUNC ("p2led_kn" ,0 ,32 ,1 ), };static struct rt2880_pmx_func p1led_kn_grp_mt7628[] = {FUNC ("jtag" ,3 ,33 ,1 ), -FUNC ("util" ,2 ,33 ,1 ), +FUNC ("utif" ,2 ,33 ,1 ),FUNC ("gpio" ,1 ,33 ,1 ),FUNC ("p1led_kn" ,0 ,33 ,1 ), };
@@ -232,28 +232,28 @@ static struct rt2880_pmx_func wled_kn_grp_mt7628[] = {static struct rt2880_pmx_func p4led_an_grp_mt7628[] = {FUNC ("jtag" ,3 ,39 ,1 ), -FUNC ("util" ,2 ,39 ,1 ), +FUNC ("utif" ,2 ,39 ,1 ),FUNC ("gpio" ,1 ,39 ,1 ),FUNC ("p4led_an" ,0 ,39 ,1 ), };static struct rt2880_pmx_func p3led_an_grp_mt7628[] = {FUNC ("jtag" ,3 ,40 ,1 ), -FUNC ("util" ,2 ,40 ,1 ), +FUNC ("utif" ,2 ,40 ,1 ),FUNC ("gpio" ,1 ,40 ,1 ),FUNC ("p3led_an" ,0 ,40 ,1 ), };static struct rt2880_pmx_func p2led_an_grp_mt7628[] = {FUNC ("jtag" ,3 ,41 ,1 ), -FUNC ("util" ,2 ,41 ,1 ), +FUNC ("utif" ,2 ,41 ,1 ),FUNC ("gpio" ,1 ,41 ,1 ),FUNC ("p2led_an" ,0 ,41 ,1 ), };static struct rt2880_pmx_func p1led_an_grp_mt7628[] = {FUNC ("jtag" ,3 ,42 ,1 ), -FUNC ("util" ,2 ,42 ,1 ), +FUNC ("utif" ,2 ,42 ,1 ),FUNC ("gpio" ,1 ,42 ,1 ),FUNC ("p1led_an" ,0 ,42 ,1 ), };
arch/mips/ralink/rt3883.c +1 -1
@@ -145,5 +145,5 @@ void prom_soc_init(struct ralink_soc_info *soc_info) rt2880_pinmux_data = rt3883_pinmux_data; - ralink_soc ==RT3883_SOC ; + ralink_soc =RT3883_SOC ; }
arch/parisc/kernel/perf.c +49 -45
281 lines not on this page · raw message
arch/s390/include/asm/pgtable.h +3 -1
@@ -1359,7 +1359,9 @@ static inline pmd_t pmdp_huge_clear_flush(struct vm_area_struct *vma,static inline void pmdp_invalidate (struct vm_area_struct *vma,unsigned long addr,pmd_t *pmdp) { -pmdp_xchg_direct (vma->vm_mm, addr, pmdp,__pmd (_SEGMENT_ENTRY_INVALID)); +pmd_t pmd =__pmd (pmd_val (*pmdp) | _SEGMENT_ENTRY_INVALID); + +pmdp_xchg_direct (vma->vm_mm, addr, pmdp, pmd); }#define __HAVE_ARCH_PMDP_SET_WRPROTECT
arch/x86/kernel/acpi/boot.c +6 -1
@@ -176,10 +176,15 @@ static int acpi_register_lapic(int id, u32 acpiid, u8 enabled)return -EINVAL ; } +if (!enabled) { + ++disabled_cpus; +return -EINVAL ; + } +if (boot_cpu_physical_apicid !=-1U ) ver = boot_cpu_apic_version; - cpu =__generic_processor_info (id, ver, enabled); + cpu =generic_processor_info (id, ver);if (cpu >=0 )early_per_cpu (x86_cpu_to_acpiid, cpu) = acpiid;
arch/x86/kernel/apic/apic.c +7 -19
@@ -2070,7 +2070,7 @@ static int allocate_logical_cpuid(int apicid)return nr_logical_cpuids++; } -int __generic_processor_info (int apicid,int version,bool enabled) +int generic_processor_info (int apicid,int version) {int cpu, max = nr_cpu_ids; bool boot_cpu_detected = physid_isset(boot_cpu_physical_apicid,
@@ -2128,11 +2128,9 @@ int __generic_processor_info(int apicid, int version, bool enabled)if (num_processors >= nr_cpu_ids) {int thiscpu = max + disabled_cpus; -if (enabled) { -pr_warning ("APIC: NR_CPUS/possible_cpus limit of %i " -"reached. Processor %d/0x%x ignored.\n" , - max, thiscpu, apicid); - } +pr_warning ("APIC: NR_CPUS/possible_cpus limit of %i " +"reached. Processor %d/0x%x ignored.\n" , + max, thiscpu, apicid); disabled_cpus++;return -EINVAL ;
@@ -2184,23 +2182,13 @@ int __generic_processor_info(int apicid, int version, bool enabled) apic->x86_32_early_logical_apicid (cpu);#endif set_cpu_possible (cpu, true); - -if (enabled) { - num_processors++; -physid_set (apicid, phys_cpu_present_map); -set_cpu_present (cpu, true); - }else { - disabled_cpus++; - } +physid_set (apicid, phys_cpu_present_map); +set_cpu_present (cpu, true); + num_processors++;return cpu; } -int generic_processor_info (int apicid,int version) -{ -return __generic_processor_info (apicid, version, true); -} -int hard_smp_processor_id (void ) {return read_apic_id ();
arch/x86/purgatory/Makefile +1 -0
@@ -8,6 +8,7 @@ PURGATORY_OBJS = $(addprefix $(obj)/,$(purgatory-y)) LDFLAGS_purgatory.ro := -e purgatory_start -r --no-undefined -nostdlib -z nodefaultlib targets += purgatory.ro +KASAN_SANITIZE := n KCOV_INSTRUMENT := n # Default KBUILD_CFLAGS can have -pg option set when FTRACE is enabled. That
block/partitions/efi.c +12 -5
@@ -293,7 +293,7 @@ static gpt_entry *alloc_read_gpt_entries(struct parsed_partitions *state,if (!gpt)return NULL ; - count =le32_to_cpu (gpt->num_partition_entries) * + count = (size_t )le32_to_cpu (gpt->num_partition_entries) *le32_to_cpu (gpt->sizeof_partition_entry);if (!count)return NULL ;
@@ -352,7 +352,7 @@ static int is_gpt_valid(struct parsed_partitions *state, u64 lba, gpt_header **gpt, gpt_entry **ptes) {u32 crc, origcrc; -u64 lastlba; +u64 lastlba, pt_size;if (!ptes)return 0 ;
@@ -434,13 +434,20 @@ static int is_gpt_valid(struct parsed_partitions *state, u64 lba, goto fail; } +/* Sanity check partition table size */ + pt_size = (u64 )le32_to_cpu ((*gpt)->num_partition_entries) * +le32_to_cpu ((*gpt)->sizeof_partition_entry); +if (pt_size >KMALLOC_MAX_SIZE ) { +pr_debug ("GUID Partition Table is too large: %llu > %lu bytes\n" , + (unsigned long long )pt_size,KMALLOC_MAX_SIZE ); + goto fail; + } +if (!(*ptes =alloc_read_gpt_entries (state, *gpt))) goto fail;/* Check the GUID Partition Entry Array CRC */ - crc =efi_crc32 ((const unsigned char *) (*ptes), -le32_to_cpu ((*gpt)->num_partition_entries) * -le32_to_cpu ((*gpt)->sizeof_partition_entry)); + crc =efi_crc32 ((const unsigned char *) (*ptes), pt_size);if (crc !=le32_to_cpu ((*gpt)->partition_entry_array_crc32)) {pr_debug ("GUID Partition Entry Array CRC check failed.\n" );
drivers/ata/libata-transport.c +3 -6
@@ -224,7 +224,6 @@ static DECLARE_TRANSPORT_CLASS(ata_port_class,static void ata_tport_release (struct device *dev) { -put_device (dev->parent); }/**
@@ -284,7 +283,7 @@ int ata_tport_add(struct device *parent,device_initialize (dev); dev->type = &ata_port_type; - dev->parent =get_device (parent); + dev->parent = parent; dev->release = ata_tport_release;dev_set_name (dev,"ata%d" , ap->print_id);transport_setup_device (dev);
@@ -348,7 +347,6 @@ static DECLARE_TRANSPORT_CLASS(ata_link_class,static void ata_tlink_release (struct device *dev) { -put_device (dev->parent); }/**
@@ -410,7 +408,7 @@ int ata_tlink_add(struct ata_link *link)int error;device_initialize (dev); - dev->parent =get_device (&ap->tdev); + dev->parent = &ap->tdev; dev->release = ata_tlink_release;if (ata_is_host_link (link))dev_set_name (dev,"link%d" , ap->print_id);
@@ -589,7 +587,6 @@ static DECLARE_TRANSPORT_CLASS(ata_dev_class,static void ata_tdev_release (struct device *dev) { -put_device (dev->parent); }/**
@@ -662,7 +659,7 @@ static int ata_tdev_add(struct ata_device *ata_dev)int error;device_initialize (dev); - dev->parent =get_device (&link->tdev); + dev->parent = &link->tdev; dev->release = ata_tdev_release;if (ata_is_host_link (link))dev_set_name (dev,"dev%d.%d" , ap->print_id,ata_dev->devno);
drivers/ata/sata_via.c +10 -8
@@ -644,14 +644,16 @@ static void svia_configure(struct pci_dev *pdev, int board_id,pci_write_config_byte (pdev,SATA_NATIVE_MODE , tmp8); } -/* enable IRQ on hotplug */ -pci_read_config_byte (pdev,SVIA_MISC_3 , &tmp8); -if ((tmp8 &SATA_HOTPLUG ) !=SATA_HOTPLUG ) { -dev_dbg (&pdev->dev, -"enabling SATA hotplug (0x%x)\n" , - (int ) tmp8); - tmp8 |=SATA_HOTPLUG ; -pci_write_config_byte (pdev,SVIA_MISC_3 , tmp8); +if (board_id == vt6421) { +/* enable IRQ on hotplug */ +pci_read_config_byte (pdev,SVIA_MISC_3 , &tmp8); +if ((tmp8 &SATA_HOTPLUG ) !=SATA_HOTPLUG ) { +dev_dbg (&pdev->dev, +"enabling SATA hotplug (0x%x)\n" , + (int ) tmp8); + tmp8 |=SATA_HOTPLUG ; +pci_write_config_byte (pdev,SVIA_MISC_3 , tmp8); + } }/*
drivers/clk/axs10x/i2s_pll_clock.c +1 -0
@@ -182,6 +182,7 @@ static int i2s_pll_clk_probe(struct platform_device *pdev)if (IS_ERR (pll_clk->base))return PTR_ERR (pll_clk->base); +memset (&init,0 ,sizeof (init)); clk_name = node->name; init.name = clk_name; init.ops = &i2s_pll_ops;
drivers/clk/sunxi-ng/ccu-sun8i-h3.c +10 -0
@@ -803,6 +803,13 @@ static const struct sunxi_ccu_desc sun8i_h3_ccu_desc = { .num_resets = ARRAY_SIZE(sun8i_h3_ccu_resets), }; +static struct ccu_mux_nb sun8i_h3_cpu_nb = { + .common = &cpux_clk.common, + .cm = &cpux_clk.mux, + .delay_us =1 ,/* > 8 clock cycles at 24 MHz */ + .bypass_index =1 ,/* index of 24 MHz oscillator */ +}; +static void __init sun8i_h3_ccu_setup (struct device_node *node) {void __iomem *reg;
@@ -821,6 +828,9 @@ static void __init sun8i_h3_ccu_setup(struct device_node *node)writel (val | (3 <<16 ), reg +SUN8I_H3_PLL_AUDIO_REG );sunxi_ccu_probe (node, reg, &sun8i_h3_ccu_desc); + +ccu_mux_notifier_register (pll_cpux_clk.common.hw.clk, + &sun8i_h3_cpu_nb); }CLK_OF_DECLARE (sun8i_h3_ccu,"allwinner,sun8i-h3-ccu" , sun8i_h3_ccu_setup);
drivers/cpufreq/intel_pstate.c +1 -0
@@ -609,6 +609,7 @@ static void intel_pstate_hwp_set_online_cpus(void)static int pid_param_set (void *data,u64 val) { *(u32 *)data = val; + pid_params.sample_rate_ns = pid_params.sample_rate_ms *NSEC_PER_MSEC ;intel_pstate_reset_all_pid ();return 0 ; }
drivers/extcon/extcon-axp288.c +1 -1
@@ -168,7 +168,7 @@ static int axp288_handle_chrg_det_event(struct axp288_extcon_info *info)return ret; } - vbus_attach = (pwr_stat &PS_STAT_VBUS_PRESENT ); + vbus_attach = (pwr_stat &PS_STAT_VBUS_VALID );if (!vbus_attach) goto notify_otg;
drivers/gpu/drm/amd/amdkfd/kfd_events.c +3 -1
@@ -739,8 +739,10 @@ int kfd_wait_on_events(struct kfd_process *p,struct kfd_event_data event_data;if (copy_from_user (&event_data, &events[i], -sizeof (struct kfd_event_data ))) +sizeof (struct kfd_event_data ))) { + ret = -EFAULT ; goto fail; + } ret =init_event_waiter (p, &event_waiters[i], event_data.event_id, i);
drivers/gpu/drm/arm/malidp_planes.c +4 -9
@@ -150,13 +150,8 @@ static void malidp_de_plane_update(struct drm_plane *plane,/* convert src values from Q16 fixed point to integer */ src_w = plane->state->src_w >>16 ; src_h = plane->state->src_h >>16 ; -if (plane->state->rotation &MALIDP_ROTATED_MASK ) { - dest_w = plane->state->crtc_h; - dest_h = plane->state->crtc_w; - }else { - dest_w = plane->state->crtc_w; - dest_h = plane->state->crtc_h; - } + dest_w = plane->state->crtc_w; + dest_h = plane->state->crtc_h;malidp_hw_write (mp->hwdev, format_id, mp->layer->base);
@@ -189,9 +184,9 @@ static void malidp_de_plane_update(struct drm_plane *plane,if (plane->state->rotation &DRM_ROTATE_MASK ) val =ilog2 (plane->state->rotation &DRM_ROTATE_MASK ) <<LAYER_ROT_OFFSET ;if (plane->state->rotation &DRM_REFLECT_X ) - val |=LAYER_V_FLIP ; -if (plane->state->rotation &DRM_REFLECT_Y ) val |=LAYER_H_FLIP ; +if (plane->state->rotation &DRM_REFLECT_Y ) + val |=LAYER_V_FLIP ;/* set the 'enable layer' bit */ val |=LAYER_ENABLE ;
drivers/gpu/drm/i915/intel_overlay.c +41 -23
122 lines not on this page · raw message
drivers/gpu/drm/i915/intel_psr.c +8 -7
@@ -387,6 +387,13 @@ static bool intel_psr_match_conditions(struct intel_dp *intel_dp)return false; } +/* PSR2 is restricted to work with panel resolutions upto 3200x2000 */ +if (intel_crtc->config->pipe_src_w >3200 || + intel_crtc->config->pipe_src_h >2000 ) { + dev_priv->psr.psr2_support = false; +return false; + } + dev_priv->psr.source_ok = true;return true; }
@@ -425,7 +432,6 @@ void intel_psr_enable(struct intel_dp *intel_dp)struct intel_digital_port *intel_dig_port =dp_to_dig_port (intel_dp);struct drm_device *dev = intel_dig_port->base.base.dev;struct drm_i915_private *dev_priv =to_i915 (dev); -struct intel_crtc *crtc =to_intel_crtc (intel_dig_port->base.base.crtc);if (!HAS_PSR (dev)) {DRM_DEBUG_KMS ("PSR not supported on this platform\n" );
@@ -452,12 +458,7 @@ void intel_psr_enable(struct intel_dp *intel_dp)hsw_psr_setup_vsc (intel_dp);if (dev_priv->psr.psr2_support) { -/* PSR2 is restricted to work with panel resolutions upto 3200x2000 */ -if (crtc->config->pipe_src_w >3200 || - crtc->config->pipe_src_h >2000 ) - dev_priv->psr.psr2_support = false; -else -skl_psr_setup_su_vsc (intel_dp); +skl_psr_setup_su_vsc (intel_dp); }/*
drivers/hid/wacom_sys.c +2 -0
@@ -2433,6 +2433,8 @@ static void wacom_remove(struct hid_device *hdev)if (hdev->bus ==BUS_BLUETOOTH )device_remove_file (&hdev->dev, &dev_attr_speed); +wacom_release_resources (wacom); +hid_set_drvdata (hdev,NULL ); }
drivers/hwmon/gl520sm.c +16 -9
@@ -208,11 +208,13 @@ static ssize_t get_cpu_vid(struct device *dev, struct device_attribute *attr, } static DEVICE_ATTR(cpu0_vid, S_IRUGO, get_cpu_vid, NULL); -#define VDD_FROM_REG (val) (((val) * 95 + 2) / 4) -#define VDD_TO_REG (val) clamp_val((((val) * 4 + 47) / 95), 0, 255) +#define VDD_FROM_REG (val) DIV_ROUND_CLOSEST((val) * 95, 4) +#define VDD_CLAMP (val) clamp_val(val, 0, 255 * 95 / 4) +#define VDD_TO_REG (val) DIV_ROUND_CLOSEST(VDD_CLAMP(val) * 4, 95) -#define IN_FROM_REG (val) ((val) * 19) -#define IN_TO_REG (val) clamp_val((((val) + 9) / 19), 0, 255) +#define IN_FROM_REG (val) ((val) * 19) +#define IN_CLAMP (val) clamp_val(val, 0, 255 * 19) +#define IN_TO_REG (val) DIV_ROUND_CLOSEST(IN_CLAMP(val), 19)static ssize_t get_in_input (struct device *dev,struct device_attribute *attr,char *buf)
@@ -349,8 +351,13 @@ static SENSOR_DEVICE_ATTR(in4_max, S_IRUGO | S_IWUSR,#define DIV_FROM_REG (val) (1 << (val))#define FAN_FROM_REG (val, div) ((val) == 0 ? 0 : (480000 / ((val) << (div)))) -#define FAN_TO_REG (val, div) ((val) <= 0 ? 0 : \ - clamp_val((480000 + ((val) << ((div)-1))) / ((val) << (div)), 1, 255)) + +#define FAN_BASE (div) (480000 >> (div)) +#define FAN_CLAMP (val, div) clamp_val(val, FAN_BASE(div) / 255, \ + FAN_BASE(div)) +#define FAN_TO_REG (val, div) ((val) == 0 ? 0 : \ + DIV_ROUND_CLOSEST(480000, \ + FAN_CLAMP(val, div) << (div)))static ssize_t get_fan_input (struct device *dev,struct device_attribute *attr,char *buf)
@@ -513,9 +520,9 @@ static SENSOR_DEVICE_ATTR(fan2_div, S_IRUGO | S_IWUSR, static DEVICE_ATTR(fan1_off, S_IRUGO | S_IWUSR, get_fan_off, set_fan_off); -#define TEMP_FROM_REG (val) (((val) - 130) * 1000) -#define TEMP_TO_REG (val) clamp_val(((((val) < 0 ? \ - (val) - 500 : (val) + 500) / 1000) + 130), 0, 255) +#define TEMP_FROM_REG (val) (((val) - 130) * 1000) +#define TEMP_CLAMP (val) clamp_val(val, -130000, 125000) +#define TEMP_TO_REG (val) (DIV_ROUND_CLOSEST(TEMP_CLAMP(val), 1000) + 130)static ssize_t get_temp_input (struct device *dev,struct device_attribute *attr,char *buf)
drivers/i2c/busses/i2c-meson.c +1 -1
@@ -175,7 +175,7 @@ static void meson_i2c_put_data(struct meson_i2c *i2c, char *buf, int len) wdata1 |= *buf++ << ((i -4 ) *8 );writel (wdata0, i2c->regs +REG_TOK_WDATA0 ); -writel (wdata0, i2c->regs +REG_TOK_WDATA1 ); +writel (wdata1, i2c->regs +REG_TOK_WDATA1 );dev_dbg (i2c->dev,"%s: data %08x %08x len %d\n" , __func__, wdata0, wdata1, len);
drivers/iio/adc/axp288_adc.c +1 -31
@@ -28,8 +28,6 @@#include <linux/iio/driver.h> #define AXP288_ADC_EN_MASK 0xF1 -#define AXP288_ADC_TS_PIN_GPADC 0xF2 -#define AXP288_ADC_TS_PIN_ON 0xF3enum axp288_adc_id {AXP288_ADC_TS ,
@@ -123,16 +121,6 @@ static int axp288_adc_read_channel(int *val, unsigned long address,return IIO_VAL_INT ; } -static int axp288_adc_set_ts (struct regmap *regmap,unsigned int mode, -unsigned long address) -{ -/* channels other than GPADC do not need to switch TS pin */ -if (address !=AXP288_GP_ADC_H ) -return 0 ; - -return regmap_write (regmap,AXP288_ADC_TS_PIN_CTRL , mode); -} -static int axp288_adc_read_raw (struct iio_dev *indio_dev,struct iio_chan_spec const *chan,int *val,int *val2,long mask)
@@ -143,16 +131,7 @@ static int axp288_adc_read_raw(struct iio_dev *indio_dev,mutex_lock (&indio_dev->mlock);switch (mask) {case IIO_CHAN_INFO_RAW : -if (axp288_adc_set_ts (info->regmap,AXP288_ADC_TS_PIN_GPADC , - chan->address)) { -dev_err (&indio_dev->dev,"GPADC mode\n" ); - ret = -EINVAL ; -break ; - } ret =axp288_adc_read_channel (val, chan->address, info->regmap); -if (axp288_adc_set_ts (info->regmap,AXP288_ADC_TS_PIN_ON , - chan->address)) -dev_err (&indio_dev->dev,"TS pin restore\n" );break ;default : ret = -EINVAL ;
@@ -162,15 +141,6 @@ static int axp288_adc_read_raw(struct iio_dev *indio_dev,return ret; } -static int axp288_adc_set_state (struct regmap *regmap) -{ -/* ADC should be always enabled for internal FG to function */ -if (regmap_write (regmap,AXP288_ADC_TS_PIN_CTRL ,AXP288_ADC_TS_PIN_ON )) -return -EIO ; - -return regmap_write (regmap,AXP20X_ADC_EN1 ,AXP288_ADC_EN_MASK ); -} -static const struct iio_info axp288_adc_iio_info = { .read_raw = &axp288_adc_read_raw, .driver_module =THIS_MODULE ,
@@ -199,7 +169,7 @@ static int axp288_adc_probe(struct platform_device *pdev)* Set ADC to enabled state at all time, including system suspend. * otherwise internal fuel gauge functionality may be affected. */ - ret =axp288_adc_set_state (axp20x->regmap); + ret =regmap_write (info->regmap,AXP20X_ADC_EN1 ,AXP288_ADC_EN_MASK );if (ret) {dev_err (&pdev->dev,"unable to enable ADC device\n" );return ret;
drivers/iio/adc/fsl-imx25-gcq.c +1 -0
@@ -401,6 +401,7 @@ static const struct of_device_id mx25_gcq_ids[] = { { .compatible = "fsl,imx25-gcq", }, {/* Sentinel */ } }; +MODULE_DEVICE_TABLE (of, mx25_gcq_ids);static struct platform_driver mx25_gcq_driver = { .driver = {
drivers/infiniband/hw/qib/qib_iba7322.c +1 -1
@@ -7080,7 +7080,7 @@ static void qib_7322_txchk_change(struct qib_devdata *dd, u32 start,unsigned long flags;while (wait) { -unsigned long shadow; +unsigned long shadow =0 ;int cstart, previ =-1 ;/*
drivers/infiniband/sw/rxe/rxe_pool.c +1 -0
@@ -274,6 +274,7 @@ static u32 alloc_index(struct rxe_pool *pool)if (index >= range) index =find_first_zero_bit (pool->table, range); +WARN_ON_ONCE (index >= range);set_bit (index, pool->table); pool->last = index;return index + pool->min_index;
drivers/infiniband/sw/rxe/rxe_resp.c +10 -10
@@ -418,7 +418,7 @@ static enum resp_states check_length(struct rxe_qp *qp,static enum resp_states check_rkey (struct rxe_qp *qp,struct rxe_pkt_info *pkt) { -struct rxe_mem *mem; +struct rxe_mem *mem =NULL ;u64 va;u32 rkey;u32 resid;
@@ -452,38 +452,38 @@ static enum resp_states check_rkey(struct rxe_qp *qp, mem =lookup_mem (qp->pd, access, rkey, lookup_remote);if (!mem) { state =RESPST_ERR_RKEY_VIOLATION ; - goto err1; + goto err; }if (unlikely (mem->state ==RXE_MEM_STATE_FREE )) { state =RESPST_ERR_RKEY_VIOLATION ; - goto err1; + goto err; }if (mem_check_range (mem, va, resid)) { state =RESPST_ERR_RKEY_VIOLATION ; - goto err2; + goto err; }if (pkt->mask &RXE_WRITE_MASK ) {if (resid > mtu) {if (pktlen != mtu ||bth_pad (pkt)) { state =RESPST_ERR_LENGTH ; - goto err2; + goto err; } qp->resp.resid = mtu; }else {if (pktlen != resid) { state =RESPST_ERR_LENGTH ; - goto err2; + goto err; }if ((bth_pad (pkt) != (0x3 & (-resid)))) {/* This case may not be exactly that * but nothing else fits. */ state =RESPST_ERR_LENGTH ; - goto err2; + goto err; } } }
@@ -493,9 +493,9 @@ static enum resp_states check_rkey(struct rxe_qp *qp, qp->resp.mr = mem;return RESPST_EXECUTE ; -err2: -rxe_drop_ref (mem); -err1: +err: +if (mem) +rxe_drop_ref (mem);return state; }
drivers/infiniband/ulp/ipoib/ipoib_main.c +4 -4
@@ -1302,7 +1302,7 @@ static void __ipoib_reap_neigh(struct ipoib_dev_priv *priv)rcu_dereference_protected (neigh->hnext, lockdep_is_held(&priv->lock)));/* remove from path/mc list */ -list_del (&neigh->list); +list_del_init (&neigh->list);call_rcu (&neigh->rcu, ipoib_neigh_reclaim); }else { np = &neigh->hnext;
@@ -1466,7 +1466,7 @@ void ipoib_neigh_free(struct ipoib_neigh *neigh)rcu_dereference_protected (neigh->hnext, lockdep_is_held(&priv->lock)));/* remove from parent list */ -list_del (&neigh->list); +list_del_init (&neigh->list);call_rcu (&neigh->rcu, ipoib_neigh_reclaim);return ; }else {
@@ -1551,7 +1551,7 @@ void ipoib_del_neighs_by_gid(struct net_device *dev, u8 *gid)rcu_dereference_protected (neigh->hnext, lockdep_is_held(&priv->lock)));/* remove from parent list */ -list_del (&neigh->list); +list_del_init (&neigh->list);call_rcu (&neigh->rcu, ipoib_neigh_reclaim); }else { np = &neigh->hnext;
@@ -1593,7 +1593,7 @@ static void ipoib_flush_neighs(struct ipoib_dev_priv *priv)rcu_dereference_protected (neigh->hnext, lockdep_is_held(&priv->lock)));/* remove from path/mc list */ -list_del (&neigh->list); +list_del_init (&neigh->list);call_rcu (&neigh->rcu, ipoib_neigh_reclaim); } }
drivers/infiniband/ulp/ipoib/ipoib_vlan.c +7 -3
@@ -165,11 +165,11 @@ int ipoib_vlan_add(struct net_device *pdev, unsigned short pkey) out:up_write (&ppriv->vlan_rwsem); +rtnl_unlock (); +if (result)free_netdev (priv->dev); -rtnl_unlock (); -return result; }
@@ -193,7 +193,6 @@ int ipoib_vlan_delete(struct net_device *pdev, unsigned short pkey)list_for_each_entry_safe (priv, tpriv, &ppriv->child_intfs, list) {if (priv->pkey == pkey && priv->child_type ==IPOIB_LEGACY_CHILD ) { -unregister_netdevice (priv->dev);list_del (&priv->list); dev = priv->dev;break ;
@@ -201,6 +200,11 @@ int ipoib_vlan_delete(struct net_device *pdev, unsigned short pkey) }up_write (&ppriv->vlan_rwsem); +if (dev) { +ipoib_dbg (ppriv,"delete child vlan %s\n" , dev->name); +unregister_netdevice (dev); + } +rtnl_unlock ();if (dev) {
drivers/iommu/arm-smmu.c +1 -1
@@ -1211,7 +1211,7 @@ static int arm_smmu_domain_add_master(struct arm_smmu_domain *smmu_domain,continue ; s2cr[idx].type = type; - s2cr[idx].privcfg =S2CR_PRIVCFG_UNPRIV ; + s2cr[idx].privcfg =S2CR_PRIVCFG_DEFAULT ; s2cr[idx].cbndx = cbndx;arm_smmu_write_s2cr (smmu, idx); }
drivers/iommu/exynos-iommu.c +4 -1
@@ -542,7 +542,10 @@ static void sysmmu_tlb_invalidate_flpdcache(struct sysmmu_drvdata *data,spin_lock_irqsave (&data->lock, flags);if (is_sysmmu_active (data) && data->version >=MAKE_MMU_VER (3 ,3 )) {clk_enable (data->clk_master); -__sysmmu_tlb_invalidate_entry (data, iova,1 ); +if (sysmmu_block (data)) { +__sysmmu_tlb_invalidate_entry (data, iova,1 ); +sysmmu_unblock (data); + }clk_disable (data->clk_master); }spin_unlock_irqrestore (&data->lock, flags);
drivers/iommu/io-pgtable-arm.c +5 -1
@@ -335,8 +335,12 @@ static int __arm_lpae_map(struct arm_lpae_io_pgtable *data, unsigned long iova,if (cfg->quirks &IO_PGTABLE_QUIRK_ARM_NS ) pte |=ARM_LPAE_PTE_NSTABLE ;__arm_lpae_set_pte (ptep, pte, cfg); - }else { + }else if (!iopte_leaf (pte, lvl)) { cptep =iopte_deref (pte, data); + }else { +/* We require an unmap first */ +WARN_ON (!selftest_running); +return -EEXIST ; }/* Rinse, repeat */
drivers/md/raid10.c +16 -3
@@ -1407,11 +1407,24 @@ static void __make_request(struct mddev *mddev, struct bio *bio) mbio->bi_private = r10_bio;atomic_inc (&r10_bio->remaining); + + cb =blk_check_plugged (raid10_unplug, mddev, +sizeof (*plug)); +if (cb) + plug = container_of(cb, struct raid10_plug_cb, + cb); +else + plug =NULL ;spin_lock_irqsave (&conf->device_lock, flags); -bio_list_add (&conf->pending_bio_list, mbio); - conf->pending_count++; +if (plug) { +bio_list_add (&plug->pending, mbio); + plug->pending_cnt++; + }else { +bio_list_add (&conf->pending_bio_list, mbio); + conf->pending_count++; + }spin_unlock_irqrestore (&conf->device_lock, flags); -if (!mddev_check_plugged (mddev)) +if (!plug)md_wakeup_thread (mddev->thread); } }
drivers/media/pci/ttpci/av7110_hw.c +4 -4
@@ -56,11 +56,11 @@by Nathan Laredo <[email protected]> */ int av7110_debiwrite (struct av7110 *av7110,u32 config, -int addr,u32 val,int count) +int addr,u32 val,unsigned int count) {struct saa7146_dev *dev = av7110->dev; -if (count <=0 || count >32764 ) { +if (count >32764 ) {printk ("%s: invalid count %d\n" , __func__, count);return -1 ; }
@@ -78,12 +78,12 @@ int av7110_debiwrite(struct av7110 *av7110, u32 config,return 0 ; } -u32 av7110_debiread (struct av7110 *av7110,u32 config,int addr,int count) +u32 av7110_debiread (struct av7110 *av7110,u32 config,int addr,unsigned int count) {struct saa7146_dev *dev = av7110->dev;u32 result =0 ; -if (count >32764 || count <=0 ) { +if (count >32764 ) {printk ("%s: invalid count %d\n" , __func__, count);return 0 ; }
drivers/media/pci/ttpci/av7110_hw.h +6 -6
@@ -377,14 +377,14 @@ extern int av7110_fw_request(struct av7110 *av7110, u16 *request_buf,/* DEBI (saa7146 data extension bus interface) access */ extern int av7110_debiwrite (struct av7110 *av7110,u32 config, -int addr,u32 val,int count); +int addr,u32 val,unsigned int count);extern u32 av7110_debiread (struct av7110 *av7110,u32 config, -int addr,int count); +int addr,unsigned int count);/* DEBI during interrupt */ /* single word writes */ -static inline void iwdebi (struct av7110 *av7110,u32 config,int addr,u32 val,int count) +static inline void iwdebi (struct av7110 *av7110,u32 config,int addr,u32 val,unsigned int count) {av7110_debiwrite (av7110, config, addr, val, count); }
@@ -397,7 +397,7 @@ static inline void mwdebi(struct av7110 *av7110, u32 config, int addr,av7110_debiwrite (av7110, config, addr,0 , count); } -static inline u32 irdebi (struct av7110 *av7110,u32 config,int addr,u32 val,int count) +static inline u32 irdebi (struct av7110 *av7110,u32 config,int addr,u32 val,unsigned int count) {u32 res;
@@ -408,7 +408,7 @@ static inline u32 irdebi(struct av7110 *av7110, u32 config, int addr, u32 val, i }/* DEBI outside interrupts, only for count <= 4! */ -static inline void wdebi (struct av7110 *av7110,u32 config,int addr,u32 val,int count) +static inline void wdebi (struct av7110 *av7110,u32 config,int addr,u32 val,unsigned int count) {unsigned long flags;
@@ -417,7 +417,7 @@ static inline void wdebi(struct av7110 *av7110, u32 config, int addr, u32 val, ispin_unlock_irqrestore (&av7110->debilock, flags); } -static inline u32 rdebi (struct av7110 *av7110,u32 config,int addr,u32 val,int count) +static inline u32 rdebi (struct av7110 *av7110,u32 config,int addr,u32 val,unsigned int count) {unsigned long flags;u32 res;
drivers/media/platform/exynos-gsc/gsc-core.c +0 -2
@@ -849,9 +849,7 @@ int gsc_prepare_addr(struct gsc_ctx *ctx, struct vb2_buffer *vb,if ((frame->fmt->pixelformat ==V4L2_PIX_FMT_VYUY ) || (frame->fmt->pixelformat ==V4L2_PIX_FMT_YVYU ) || - (frame->fmt->pixelformat ==V4L2_PIX_FMT_NV61 ) || (frame->fmt->pixelformat ==V4L2_PIX_FMT_YVU420 ) || - (frame->fmt->pixelformat ==V4L2_PIX_FMT_NV21 ) || (frame->fmt->pixelformat ==V4L2_PIX_FMT_YVU420M ))swap (addr->cb, addr->cr);
drivers/misc/lkdtm_core.c +3 -1
@@ -533,7 +533,9 @@ static void __exit lkdtm_module_exit(void)/* Handle test-specific clean-up. */ lkdtm_usercopy_exit (); -unregister_jprobe (lkdtm_jprobe); +if (lkdtm_jprobe !=NULL ) +unregister_jprobe (lkdtm_jprobe); +pr_info ("Crash point unregistered\n" ); }
drivers/mmc/core/sdio_bus.c +11 -1
@@ -266,7 +266,7 @@ static void sdio_release_func(struct device *dev)sdio_free_func_cis (func);kfree (func->info); - +kfree (func->tmpbuf);kfree (func); }
@@ -281,6 +281,16 @@ struct sdio_func *sdio_alloc_func(struct mmc_card *card)if (!func)return ERR_PTR (-ENOMEM ); +/* +* allocate buffer separately to make sure it's properly aligned for +* DMA usage (incl. 64 bit DMA) +*/ + func->tmpbuf =kmalloc (4 ,GFP_KERNEL ); +if (!func->tmpbuf) { +kfree (func); +return ERR_PTR (-ENOMEM ); + } + func->card = card;device_initialize (&func->dev);
drivers/net/dsa/b53/b53_common.c +10 -0
@@ -326,6 +326,7 @@ static void b53_get_vlan_entry(struct b53_device *dev, u16 vid,static void b53_set_forwarding (struct b53_device *dev,int enable) { +struct dsa_switch *ds = dev->ds;u8 mgmt;b53_read8 (dev,B53_CTRL_PAGE ,B53_SWITCH_MODE , &mgmt);
@@ -336,6 +337,15 @@ static void b53_set_forwarding(struct b53_device *dev, int enable) mgmt &= ~SM_SW_FWD_EN ;b53_write8 (dev,B53_CTRL_PAGE ,B53_SWITCH_MODE , mgmt); + +/* Include IMP port in dumb forwarding mode when no tagging protocol is +* set +*/ +if (ds->ops->get_tag_protocol (ds) ==DSA_TAG_PROTO_NONE ) { +b53_read8 (dev,B53_CTRL_PAGE ,B53_SWITCH_CTRL , &mgmt); + mgmt |=B53_MII_DUMB_FWDG_EN ; +b53_write8 (dev,B53_CTRL_PAGE ,B53_SWITCH_CTRL , mgmt); + } }static void b53_enable_vlan (struct b53_device *dev,bool enable)
drivers/net/dsa/b53/b53_regs.h +4 -0
@@ -104,6 +104,10 @@#define B53_UC_FWD_EN BIT(6)#define B53_MC_FWD_EN BIT(7) +/* Switch control (8 bit) */ +#define B53_SWITCH_CTRL 0x22 +#define B53_MII_DUMB_FWDG_EN BIT(6) +/* (16 bit) */ #define B53_UC_FLOOD_MASK 0x32#define B53_MC_FLOOD_MASK 0x34
drivers/net/ethernet/ibm/ibmvnic.c +2 -0
@@ -1253,6 +1253,7 @@ static void release_sub_crqs(struct ibmvnic_adapter *adapter)release_sub_crq_queue (adapter, adapter->tx_scrq[i]); } +kfree (adapter->tx_scrq); adapter->tx_scrq =NULL ; }
@@ -1265,6 +1266,7 @@ static void release_sub_crqs(struct ibmvnic_adapter *adapter)release_sub_crq_queue (adapter, adapter->rx_scrq[i]); } +kfree (adapter->rx_scrq); adapter->rx_scrq =NULL ; }
drivers/net/ethernet/intel/igb/igb_main.c +5 -0
@@ -7882,6 +7882,11 @@ static pci_ers_result_t igb_io_slot_reset(struct pci_dev *pdev)pci_enable_wake (pdev, PCI_D3hot,0 );pci_enable_wake (pdev, PCI_D3cold,0 ); +/* In case of PCI error, adapter lose its HW address +* so we should re-assign it here. +*/ + hw->hw_addr = adapter->io_addr; +igb_reset (adapter);wr32 (E1000_WUS , ~0 ); result =PCI_ERS_RESULT_RECOVERED ;
drivers/net/ethernet/qlogic/qed/qed_dcbx.c +1 -1
@@ -1222,7 +1222,7 @@ static struct qed_dcbx_get *qed_dcbnl_get_dcbx(struct qed_hwfn *hwfn, {struct qed_dcbx_get *dcbx_info; - dcbx_info =kzalloc (sizeof (*dcbx_info),GFP_KERNEL ); + dcbx_info =kmalloc (sizeof (*dcbx_info),GFP_ATOMIC );if (!dcbx_info)return NULL ;
drivers/net/ethernet/renesas/sh_eth.h +1 -1
@@ -339,7 +339,7 @@ enum FELIC_MODE_BIT {ECMR_DPAD =0x00200000 ,ECMR_RZPF =0x00100000 ,ECMR_ZPF =0x00080000 ,ECMR_PFR =0x00040000 ,ECMR_RXF =0x00020000 ,ECMR_TXF =0x00010000 ,ECMR_MCT =0x00002000 ,ECMR_PRCEF =0x00001000 , -ECMR_PMDE =0x00000200 ,ECMR_RE =0x00000040 ,ECMR_TE =0x00000020 , +ECMR_MPDE =0x00000200 ,ECMR_RE =0x00000040 ,ECMR_TE =0x00000020 ,ECMR_RTM =0x00000010 ,ECMR_ILB =0x00000008 ,ECMR_ELB =0x00000004 , ECMR_DM = 0x00000002, ECMR_PRM = 0x00000001, };
drivers/net/ethernet/sfc/ef10.c +10 -6
@@ -197,11 +197,15 @@ static int efx_ef10_init_datapath_caps(struct efx_nic *efx) nic_data->datapath_caps =MCDI_DWORD (outbuf,GET_CAPABILITIES_OUT_FLAGS1 ); -if (outlen >=MC_CMD_GET_CAPABILITIES_V2_OUT_LEN ) +if (outlen >=MC_CMD_GET_CAPABILITIES_V2_OUT_LEN ) { nic_data->datapath_caps2 =MCDI_DWORD (outbuf,GET_CAPABILITIES_V2_OUT_FLAGS2 ); -else + nic_data->piobuf_size =MCDI_WORD (outbuf, +GET_CAPABILITIES_V2_OUT_SIZE_PIO_BUFF ); + }else { nic_data->datapath_caps2 =0 ; + nic_data->piobuf_size =ER_DZ_TX_PIOBUF_SIZE ; + }/* record the DPCPU firmware IDs to determine VEB vswitching support. */
@@ -825,8 +829,8 @@ static int efx_ef10_link_piobufs(struct efx_nic *efx) offset = ((efx->tx_channel_offset + efx->n_tx_channels - tx_queue->channel->channel -1 ) * efx_piobuf_size); - index = offset /ER_DZ_TX_PIOBUF_SIZE ; - offset = offset %ER_DZ_TX_PIOBUF_SIZE ; + index = offset / nic_data->piobuf_size; + offset = offset % nic_data->piobuf_size;/* When the host page size is 4K, the first * host page in the WC mapping may be within
@@ -1161,11 +1165,11 @@ static int efx_ef10_dimension_resources(struct efx_nic *efx)* functions of the controller. */ if (efx_piobuf_size !=0 && -ER_DZ_TX_PIOBUF_SIZE / efx_piobuf_size *EF10_TX_PIOBUF_COUNT >= + nic_data->piobuf_size / efx_piobuf_size *EF10_TX_PIOBUF_COUNT >= efx->n_tx_channels) {unsigned int n_piobufs =DIV_ROUND_UP (efx->n_tx_channels, -ER_DZ_TX_PIOBUF_SIZE / efx_piobuf_size); + nic_data->piobuf_size / efx_piobuf_size); rc =efx_ef10_alloc_piobufs (efx, n_piobufs);if (rc)
drivers/net/ethernet/sfc/nic.h +2 -0
@@ -500,6 +500,7 @@ enum {* @pio_write_base: Base address for writing PIO buffers * @pio_write_vi_base: Relative VI number for @pio_write_base * @piobuf_handle: Handle of each PIO buffer allocated +* @piobuf_size: size of a single PIO buffer * @must_restore_piobufs: Flag: PIO buffers have yet to be restored after MC * reboot * @rx_rss_context: Firmware handle for our RSS context
@@ -537,6 +538,7 @@ struct efx_ef10_nic_data {void __iomem *wc_membase, *pio_write_base;unsigned int pio_write_vi_base;unsigned int piobuf_handle[EF10_TX_PIOBUF_COUNT ]; +u16 piobuf_size;bool must_restore_piobufs;u32 rx_rss_context;bool rx_rss_context_exclusive;
drivers/net/ethernet/sfc/tx.c +0 -1
@@ -27,7 +27,6 @@#ifdef EFX_USE_PIO -#define EFX_PIOBUF_SIZE_MAX ER_DZ_TX_PIOBUF_SIZE#define EFX_PIOBUF_SIZE_DEF ALIGN(256, L1_CACHE_BYTES)unsigned int efx_piobuf_size__read_mostly =EFX_PIOBUF_SIZE_DEF ;
drivers/net/team/team.c +6 -2
@@ -2366,8 +2366,10 @@ static int team_nl_send_options_get(struct team *team, u32 portid, u32 seq, hdr =genlmsg_put (skb, portid, seq, &team_nl_family, flags |NLM_F_MULTI ,TEAM_CMD_OPTIONS_GET ); -if (!hdr) +if (!hdr) { +nlmsg_free (skb);return -EMSGSIZE ; + }if (nla_put_u32 (skb,TEAM_ATTR_TEAM_IFINDEX , team->dev->ifindex)) goto nla_put_failure;
@@ -2639,8 +2641,10 @@ static int team_nl_send_port_list_get(struct team *team, u32 portid, u32 seq, hdr =genlmsg_put (skb, portid, seq, &team_nl_family, flags |NLM_F_MULTI ,TEAM_CMD_PORT_LIST_GET ); -if (!hdr) +if (!hdr) { +nlmsg_free (skb);return -EMSGSIZE ; + }if (nla_put_u32 (skb,TEAM_ATTR_TEAM_IFINDEX , team->dev->ifindex)) goto nla_put_failure;
drivers/net/usb/Kconfig +1 -1
@@ -364,7 +364,7 @@ config USB_NET_NET1080 optionally with LEDs that indicate traffic config USB_NET_PLUSB - tristate "Prolific PL-2301/2302/25A1 based cables" + tristate "Prolific PL-2301/2302/25A1/27A1 based cables" # if the handshake/init/reset problems, from original 'plusb', # are ever resolved ... then remove "experimental" depends on USB_USBNET
drivers/net/usb/plusb.c +13 -2
@@ -102,7 +102,7 @@ static int pl_reset(struct usbnet *dev) }static const struct driver_info prolific_info = { - .description ="Prolific PL-2301/PL-2302/PL-25A1" , + .description ="Prolific PL-2301/PL-2302/PL-25A1/PL-27A1" , .flags =FLAG_POINTTOPOINT |FLAG_NO_SETINT ,/* some PL-2302 versions seem to fail usb_set_interface() */ .reset = pl_reset,
@@ -139,6 +139,17 @@ static const struct usb_device_id products [] = {* Host-to-Host Cable */ .driver_info = (unsigned long) &prolific_info, + +}, + +/* super speed cables */ +{ + USB_DEVICE(0x067b, 0x27a1), /* PL-27A1, no eeprom +* also: goobay Active USB 3.0 +* Data Link, +* Unitek Y-3501 +*/ + .driver_info = (unsigned long) &prolific_info, }, { }, // END
@@ -158,5 +169,5 @@ static struct usb_driver plusb_driver = {module_usb_driver (plusb_driver);MODULE_AUTHOR ("David Brownell" ); -MODULE_DESCRIPTION ("Prolific PL-2301/2302/25A1 USB Host to Host Link Driver" ); +MODULE_DESCRIPTION ("Prolific PL-2301/2302/25A1/27A1 USB Host to Host Link Driver" );MODULE_LICENSE ("GPL" );
drivers/net/wireless/ath/ath10k/core.h +1 -0
@@ -314,6 +314,7 @@ struct ath10k_peer {struct ieee80211_vif *vif;struct ieee80211_sta *sta; +bool removed;int vdev_id;u8 addr[ETH_ALEN ];DECLARE_BITMAP (peer_ids,ATH10K_MAX_NUM_PEER_IDS );
drivers/net/wireless/ath/ath10k/mac.c +18 -0
@@ -3738,6 +3738,9 @@ struct ieee80211_txq *ath10k_mac_txq_lookup(struct ath10k *ar,if (!peer)return NULL ; +if (peer->removed) +return NULL ; +if (peer->sta)return peer->sta->txq[tid];else if (peer->vif)
@@ -7422,6 +7425,20 @@ ath10k_mac_op_switch_vif_chanctx(struct ieee80211_hw *hw,return 0 ; } +static void ath10k_mac_op_sta_pre_rcu_remove (struct ieee80211_hw *hw, +struct ieee80211_vif *vif, +struct ieee80211_sta *sta) +{ +struct ath10k *ar; +struct ath10k_peer *peer; + + ar = hw->priv; + +list_for_each_entry (peer, &ar->peers, list) +if (peer->sta == sta) + peer->removed = true; +} +static const struct ieee80211_ops ath10k_ops = { .tx = ath10k_mac_op_tx, .wake_tx_queue = ath10k_mac_op_wake_tx_queue,
@@ -7462,6 +7479,7 @@ static const struct ieee80211_ops ath10k_ops = { .assign_vif_chanctx = ath10k_mac_op_assign_vif_chanctx, .unassign_vif_chanctx = ath10k_mac_op_unassign_vif_chanctx, .switch_vif_chanctx = ath10k_mac_op_switch_vif_chanctx, + .sta_pre_rcu_remove = ath10k_mac_op_sta_pre_rcu_remove,CFG80211_TESTMODE_CMD (ath10k_tm_cmd)
drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c +7 -0
@@ -6316,6 +6316,13 @@ static struct usb_device_id dev_table[] = { .driver_info = (unsigned long)&rtl8192cu_fops}, {USB_DEVICE_AND_INTERFACE_INFO(0x7392, 0x7822, 0xff, 0xff, 0xff), .driver_info = (unsigned long)&rtl8192cu_fops}, +/* found in rtl8192eu vendor driver */ +{USB_DEVICE_AND_INTERFACE_INFO(0x2357, 0x0107, 0xff, 0xff, 0xff), + .driver_info = (unsigned long)&rtl8192eu_fops}, +{USB_DEVICE_AND_INTERFACE_INFO(0x2019, 0xab33, 0xff, 0xff, 0xff), + .driver_info = (unsigned long)&rtl8192eu_fops}, +{USB_DEVICE_AND_INTERFACE_INFO(USB_VENDOR_ID_REALTEK, 0x818c, 0xff, 0xff, 0xff), + .driver_info = (unsigned long)&rtl8192eu_fops}, #endif { } };
drivers/nvme/host/rdma.c +14 -14
@@ -337,8 +337,6 @@ static int __nvme_rdma_init_request(struct nvme_rdma_ctrl *ctrl,struct ib_device *ibdev = dev->dev;int ret; -BUG_ON (queue_idx >= ctrl->queue_count); - ret =nvme_rdma_alloc_qe (ibdev, &req->sqe,sizeof (struct nvme_command ),DMA_TO_DEVICE );if (ret)
@@ -643,8 +641,22 @@ static int nvme_rdma_connect_io_queues(struct nvme_rdma_ctrl *ctrl)static int nvme_rdma_init_io_queues (struct nvme_rdma_ctrl *ctrl) { +struct nvmf_ctrl_options *opts = ctrl->ctrl.opts; +unsigned int nr_io_queues;int i, ret; + nr_io_queues =min (opts->nr_io_queues,num_online_cpus ()); + ret =nvme_set_queue_count (&ctrl->ctrl, &nr_io_queues); +if (ret) +return ret; + + ctrl->queue_count = nr_io_queues +1 ; +if (ctrl->queue_count <2 ) +return 0 ; + +dev_info (ctrl->ctrl.device, +"creating %d I/O queues.\n" , nr_io_queues); +for (i =1 ; i < ctrl->queue_count; i++) { ret =nvme_rdma_init_queue (ctrl, i, ctrl->ctrl.opts->queue_size);
@@ -1795,20 +1807,8 @@ static const struct nvme_ctrl_ops nvme_rdma_ctrl_ops = {static int nvme_rdma_create_io_queues (struct nvme_rdma_ctrl *ctrl) { -struct nvmf_ctrl_options *opts = ctrl->ctrl.opts;int ret; - ret =nvme_set_queue_count (&ctrl->ctrl, &opts->nr_io_queues); -if (ret) -return ret; - - ctrl->queue_count = opts->nr_io_queues +1 ; -if (ctrl->queue_count <2 ) -return 0 ; - -dev_info (ctrl->ctrl.device, -"creating %d I/O queues.\n" , opts->nr_io_queues); - ret =nvme_rdma_init_io_queues (ctrl);if (ret)return ret;
drivers/power/supply/axp288_fuel_gauge.c +3 -1
@@ -169,8 +169,10 @@ static int fuel_gauge_reg_readb(struct axp288_fg_info *info, int reg)break ; } -if (ret <0 ) +if (ret <0 ) {dev_err (&info->pdev->dev,"axp288 reg read err:%d\n" , ret); +return ret; + }return val; }
drivers/rapidio/devices/tsi721.c +2 -2
@@ -37,8 +37,8 @@#include "tsi721.h" #ifdef DEBUG -u32 dbg_level; -module_param (dbg_level, uint,S_IWUSR |S_IRUGO ); +u32 tsi_dbg_level; +module_param_named (dbg_level, tsi_dbg_level, uint,S_IWUSR |S_IRUGO );MODULE_PARM_DESC (dbg_level,"Debugging output level (default 0 = none)" );#endif
drivers/rapidio/devices/tsi721.h +2 -2
@@ -40,11 +40,11 @@ enum { };#ifdef DEBUG -extern u32 dbg_level; +extern u32 tsi_dbg_level; #define tsi_debug(level, dev, fmt, arg...) \ do { \ - if (DBG_##level & dbg_level) \ + if (DBG_##level & tsi_dbg_level) \ dev_dbg(dev, "%s: " fmt "\n", __func__, ##arg); \ } while (0)#else
drivers/reset/reset-ti-syscon.c +2 -2
@@ -154,8 +154,8 @@ static int ti_syscon_reset_status(struct reset_controller_dev *rcdev,if (ret)return ret; -return (reset_state &BIT (control->status_bit)) && - (control->flags &STATUS_SET ); +return !(reset_state &BIT (control->status_bit)) == + !(control->flags &STATUS_SET ); }static struct reset_control_ops ti_syscon_reset_ops = {
drivers/scsi/be2iscsi/be_iscsi.c +82 -81
259 lines not on this page · raw message
drivers/scsi/be2iscsi/be_main.c +4 -3
@@ -4085,9 +4085,10 @@ static int hba_setup_cid_tbls(struct beiscsi_hba *phba) }/* Allocate memory for CID array */ - ptr_cid_info->cid_array =kzalloc (sizeof (void *) * -BEISCSI_GET_CID_COUNT (phba, - ulp_num),GFP_KERNEL ); + ptr_cid_info->cid_array = +kcalloc (BEISCSI_GET_CID_COUNT (phba, ulp_num), +sizeof (*ptr_cid_info->cid_array), +GFP_KERNEL );if (!ptr_cid_info->cid_array) {beiscsi_log (phba,KERN_ERR ,BEISCSI_LOG_INIT , "BM_%d : Failed to allocate memory"
drivers/scsi/be2iscsi/be_main.h +1 -0
@@ -358,6 +358,7 @@ struct beiscsi_hba {unsigned int age;struct list_head hba_queue;#define BE_MAX_SESSION 2048 +#define BE_INVALID_CID 0xffff#define BE_SET_CID_TO_CRI (cri_index, cid) \ (phba->cid_to_cri_map[cid] = cri_index)#define BE_GET_CRI_FROM_CID (cid) (phba->cid_to_cri_map[cid])
drivers/spi/spi-pxa2xx.c +4 -0
@@ -1458,6 +1458,10 @@ static const struct pci_device_id pxa2xx_spi_pci_compound_match[] = { { PCI_VDEVICE(INTEL, 0x1ac2), LPSS_BXT_SSP }, { PCI_VDEVICE(INTEL, 0x1ac4), LPSS_BXT_SSP }, { PCI_VDEVICE(INTEL, 0x1ac6), LPSS_BXT_SSP }, +/* GLK */ + { PCI_VDEVICE(INTEL, 0x31c2), LPSS_BXT_SSP }, + { PCI_VDEVICE(INTEL, 0x31c4), LPSS_BXT_SSP }, + { PCI_VDEVICE(INTEL, 0x31c6), LPSS_BXT_SSP },/* APL */ { PCI_VDEVICE(INTEL, 0x5ac2), LPSS_BXT_SSP }, { PCI_VDEVICE(INTEL, 0x5ac4), LPSS_BXT_SSP },
drivers/tty/goldfish.c +1 -1
@@ -300,7 +300,7 @@ static int goldfish_tty_probe(struct platform_device *pdev)return 0 ; err_tty_register_device_failed: -free_irq (irq, pdev); +free_irq (irq, qtty); err_request_irq_failed: goldfish_tty_current_line_count--;if (goldfish_tty_current_line_count ==0 )
drivers/tty/serial/8250/8250_moxa.c +1 -0
@@ -68,6 +68,7 @@ static int moxa8250_probe(struct pci_dev *pdev, const struct pci_device_id *id) sizeof(unsigned int) * nr_ports, GFP_KERNEL);if (!brd)return -ENOMEM ; + brd->num_ports = nr_ports;memset (&uart,0 ,sizeof (struct uart_8250_port ));
drivers/tty/serial/8250/8250_port.c +0 -4
@@ -1751,8 +1751,6 @@ void serial8250_tx_chars(struct uart_8250_port *up)if (uart_circ_chars_pending (xmit) <WAKEUP_CHARS )uart_write_wakeup (port); -pr_debug ("%s: THRE\n" , __func__); -/* * With RPM enabled, we have to wait until the FIFO is empty before the * HW can go idle. So we get here once again with empty FIFO and disable
@@ -1817,8 +1815,6 @@ int serial8250_handle_irq(struct uart_port *port, unsigned int iir) status =serial_port_in (port,UART_LSR ); -pr_debug ("%s: status = %x\n" , __func__, status); -if (status & (UART_LSR_DR |UART_LSR_BI )) {if (!up->dma ||handle_rx_dma (up, iir)) status =serial8250_rx_chars (up, status);
drivers/usb/chipidea/otg.c +12 -5
@@ -134,9 +134,9 @@ void ci_handle_vbus_change(struct ci_hdrc *ci)if (!ci->is_otg)return ; -if (hw_read_otgsc (ci,OTGSC_BSV )) +if (hw_read_otgsc (ci,OTGSC_BSV ) && !ci->vbus_active)usb_gadget_vbus_connect (&ci->gadget); -else +else if (!hw_read_otgsc (ci,OTGSC_BSV ) && ci->vbus_active)usb_gadget_vbus_disconnect (&ci->gadget); }
@@ -175,14 +175,21 @@ static void ci_handle_id_switch(struct ci_hdrc *ci)ci_role_stop (ci); -if (role ==CI_ROLE_GADGET ) +if (role ==CI_ROLE_GADGET && +IS_ERR (ci->platdata->vbus_extcon.edev))/* -* wait vbus lower than OTGSC_BSV before connecting -* to host +* Wait vbus lower than OTGSC_BSV before connecting +* to host. If connecting status is from an external +* connector instead of register, we don't need to +* care vbus on the board, since it will not affect +* external connector status. */ hw_wait_vbus_lower_bsv (ci);ci_role_start (ci, role); +/* vbus change may have already occurred */ +if (role ==CI_ROLE_GADGET ) +ci_handle_vbus_change (ci); } }/**
drivers/usb/host/Kconfig +2 -2
@@ -45,9 +45,9 @@ config USB_XHCI_PLATFORM If unsure, say N. config USB_XHCI_MTK - tristate "xHCI support for Mediatek MT65xx" + tristate "xHCI support for Mediatek MT65xx/MT7621" select MFD_SYSCON - depends on ARCH_MEDIATEK || COMPILE_TEST + depends on (MIPS && SOC_MT7621) || ARCH_MEDIATEK || COMPILE_TEST ---help--- Say 'Y' to enable the support for the xHCI host controller found in Mediatek MT65xx SoCs.
drivers/usb/serial/mos7720.c +7 -2
@@ -234,11 +234,16 @@ static int read_mos_reg(struct usb_serial *serial, unsigned int serial_portnum, status =usb_control_msg (usbdev, pipe, request, requesttype, value, index, buf,1 ,MOS_WDR_TIMEOUT ); -if (status ==1 ) +if (status ==1 ) { *data = *buf; -else if (status <0 ) + }else {dev_err (&usbdev->dev,"mos7720: usb_control_msg() failed: %d\n" , status); +if (status >=0 ) + status = -EIO ; + *data =0 ; + } +kfree (buf);return status;
drivers/usb/serial/mos7840.c +15 -4
@@ -285,9 +285,15 @@ static int mos7840_get_reg_sync(struct usb_serial_port *port, __u16 reg, ret =usb_control_msg (dev,usb_rcvctrlpipe (dev,0 ),MCS_RDREQ ,MCS_RD_RTYPE ,0 , reg, buf,VENDOR_READ_LENGTH ,MOS_WDR_TIMEOUT ); +if (ret <VENDOR_READ_LENGTH ) { +if (ret >=0 ) + ret = -EIO ; + goto out; + } + *val = buf[0 ];dev_dbg (&port->dev,"%s offset is %x, return val %x\n" , __func__, reg, *val); - +out:kfree (buf);return ret; }
@@ -353,8 +359,13 @@ static int mos7840_get_uart_reg(struct usb_serial_port *port, __u16 reg, ret =usb_control_msg (dev,usb_rcvctrlpipe (dev,0 ),MCS_RDREQ ,MCS_RD_RTYPE , Wval, reg, buf,VENDOR_READ_LENGTH ,MOS_WDR_TIMEOUT ); +if (ret <VENDOR_READ_LENGTH ) { +if (ret >=0 ) + ret = -EIO ; + goto out; + } *val = buf[0 ]; - +out:kfree (buf);return ret; }
@@ -1490,10 +1501,10 @@ static int mos7840_tiocmget(struct tty_struct *tty)return -ENODEV ; status =mos7840_get_uart_reg (port,MODEM_STATUS_REGISTER , &msr); -if (status !=1 ) +if (status <0 )return -EIO ; status =mos7840_get_uart_reg (port,MODEM_CONTROL_REGISTER , &mcr); -if (status !=1 ) +if (status <0 )return -EIO ; result = ((mcr &MCR_DTR ) ?TIOCM_DTR :0 ) | ((mcr &MCR_RTS ) ?TIOCM_RTS :0 )
fs/btrfs/inode.c +6 -2
@@ -8050,8 +8050,10 @@ static int __btrfs_correct_data_nocsum(struct inode *inode, start += sectorsize; -if (nr_sectors--) { + nr_sectors--; +if (nr_sectors) { pgoff += sectorsize; +ASSERT (pgoff <PAGE_SIZE ); goto next_block_or_try_again; } }
@@ -8157,8 +8159,10 @@ static int __btrfs_subio_endio_read(struct inode *inode,ASSERT (nr_sectors); -if (--nr_sectors) { + nr_sectors--; +if (nr_sectors) { pgoff += sectorsize; +ASSERT (pgoff <PAGE_SIZE ); goto next_block; } }
fs/btrfs/volumes.c +1 -1
@@ -6226,7 +6226,7 @@ int btrfs_map_bio(struct btrfs_root *root, struct bio *bio,for (dev_nr =0 ; dev_nr < total_devs; dev_nr++) { dev = bbio->stripes[dev_nr].dev;if (!dev || !dev->bdev || - (bio_op (bio) ==REQ_OP_WRITE && !dev->writeable)) { + (bio_op (first_bio) ==REQ_OP_WRITE && !dev->writeable)) {bbio_error (bbio, first_bio, logical);continue ; }
fs/gfs2/glock.c +7 -5
@@ -1820,16 +1820,18 @@ void gfs2_glock_exit(void)static void gfs2_glock_iter_next (struct gfs2_glock_iter *gi) { -do { - gi->gl =rhashtable_walk_next (&gi->hti); +while ((gi->gl =rhashtable_walk_next (&gi->hti))) {if (IS_ERR (gi->gl)) {if (PTR_ERR (gi->gl) == -EAGAIN )continue ; gi->gl =NULL ; +return ; } -/* Skip entries for other sb and dead entries */ - }while ((gi->gl) && ((gi->sdp != gi->gl->gl_name.ln_sbd) || -__lockref_is_dead (&gi->gl->gl_lockref))); +/* Skip entries for other sb and dead entries */ +if (gi->sdp == gi->gl->gl_name.ln_sbd && + !__lockref_is_dead (&gi->gl->gl_lockref)) +return ; + } }static void *gfs2_glock_seq_start (struct seq_file *seq,loff_t *pos)
fs/hugetlbfs/inode.c +12 -13
@@ -695,14 +695,11 @@ static struct inode *hugetlbfs_get_root(struct super_block *sb, inode =new_inode (sb);if (inode) { -struct hugetlbfs_inode_info *info; inode->i_ino =get_next_ino (); inode->i_mode =S_IFDIR | config->mode; inode->i_uid = config->uid; inode->i_gid = config->gid; inode->i_atime = inode->i_mtime = inode->i_ctime =current_time (inode); - info =HUGETLBFS_I (inode); -mpol_shared_policy_init (&info->policy,NULL ); inode->i_op = &hugetlbfs_dir_inode_operations; inode->i_fop = &simple_dir_operations;/* directory inodes start off with i_nlink == 2 (for "." entry) */
@@ -733,7 +730,6 @@ static struct inode *hugetlbfs_get_inode(struct super_block *sb, inode =new_inode (sb);if (inode) { -struct hugetlbfs_inode_info *info; inode->i_ino =get_next_ino ();inode_init_owner (inode, dir, mode); lockdep_set_class(&inode->i_mapping->i_mmap_rwsem,
@@ -741,15 +737,6 @@ static struct inode *hugetlbfs_get_inode(struct super_block *sb, inode->i_mapping->a_ops = &hugetlbfs_aops; inode->i_atime = inode->i_mtime = inode->i_ctime =current_time (inode); inode->i_mapping->private_data = resv_map; - info =HUGETLBFS_I (inode); -/* -* The policy is initialized here even if we are creating a -* private inode because initialization simply creates an -* an empty rb tree and calls rwlock_init(), later when we -* call mpol_free_shared_policy() it will just return because -* the rb tree will still be empty. -*/ -mpol_shared_policy_init (&info->policy,NULL );switch (mode &S_IFMT ) {default :init_special_inode (inode, mode, dev);
@@ -937,6 +924,18 @@ static struct inode *hugetlbfs_alloc_inode(struct super_block *sb)hugetlbfs_inc_free_inodes (sbinfo);return NULL ; } + +/* +* Any time after allocation, hugetlbfs_destroy_inode can be called +* for the inode. mpol_free_shared_policy is unconditionally called +* as part of hugetlbfs_destroy_inode. So, initialize policy here +* in case of a quick call to destroy. +* +* Note that the policy is initialized even if we are creating a +* private inode. This simplifies hugetlbfs_destroy_inode. +*/ +mpol_shared_policy_init (&p->policy,NULL ); +return &p->vfs_inode; }
fs/nfs/callback.c +2 -2
@@ -239,12 +239,12 @@ static struct svc_serv_ops nfs41_cb_sv_ops = { .svo_module = THIS_MODULE, }; -struct svc_serv_ops *nfs4_cb_sv_ops[] = { +static struct svc_serv_ops *nfs4_cb_sv_ops[] = { [0 ] = &nfs40_cb_sv_ops, [1 ] = &nfs41_cb_sv_ops, };#else -struct svc_serv_ops *nfs4_cb_sv_ops[] = { +static struct svc_serv_ops *nfs4_cb_sv_ops[] = { [0 ] = &nfs40_cb_sv_ops, [1 ] =NULL , };
fs/xfs/kmem.c +0 -18
@@ -24,24 +24,6 @@#include "kmem.h" #include "xfs_message.h" -/* -* Greedy allocation. May fail and may return vmalloced memory. -*/ -void * -kmem_zalloc_greedy (size_t *size,size_t minsize,size_t maxsize) -{ -void *ptr; -size_t kmsize = maxsize; - -while (!(ptr =vzalloc (kmsize))) { -if ((kmsize >>=1 ) <= minsize) - kmsize = minsize; - } -if (ptr) - *size = kmsize; -return ptr; -} -void *kmem_alloc (size_t size,xfs_km_flags_t flags) {
fs/xfs/kmem.h +0 -2
@@ -69,8 +69,6 @@ static inline void kmem_free(const void *ptr) } -extern void *kmem_zalloc_greedy (size_t *,size_t ,size_t ); -static inline void *kmem_zalloc (size_t size,xfs_km_flags_t flags) {
fs/xfs/xfs_itable.c +2 -4
@@ -361,7 +361,6 @@ xfs_bulkstat(xfs_agino_t agino;/* inode # in allocation group */ xfs_agnumber_t agno;/* allocation group number */ xfs_btree_cur_t *cur;/* btree cursor for ialloc btree */ -size_t irbsize;/* size of irec buffer in bytes */ xfs_inobt_rec_incore_t *irbuf;/* start of irec buffer */ int nirbuf;/* size of irbuf */ int ubcount;/* size of user's buffer */
@@ -388,11 +387,10 @@ xfs_bulkstat( *ubcountp =0 ; *done =0 ; - irbuf =kmem_zalloc_greedy (&irbsize,PAGE_SIZE ,PAGE_SIZE *4 ); + irbuf =kmem_zalloc_large (PAGE_SIZE *4 ,KM_SLEEP );if (!irbuf)return -ENOMEM ; - - nirbuf = irbsize /sizeof (*irbuf); + nirbuf = (PAGE_SIZE *4 ) /sizeof (*irbuf);/* * Loop over the allocation groups, starting from the last
include/linux/audit.h +20 -0
@@ -387,6 +387,20 @@ static inline int audit_socketcall(int nargs, unsigned long *args)return __audit_socketcall (nargs, args);return 0 ; } + +static inline int audit_socketcall_compat (int nargs,u32 *args) +{ +unsigned long a[AUDITSC_ARGS ]; +int i; + +if (audit_dummy_context ()) +return 0 ; + +for (i =0 ; i < nargs; i++) + a[i] = (unsigned long )args[i]; +return __audit_socketcall (nargs, a); +} +static inline int audit_sockaddr (int len,void *addr) {if (unlikely (!audit_dummy_context ()))
@@ -513,6 +527,12 @@ static inline int audit_socketcall(int nargs, unsigned long *args) {return 0 ; } + +static inline int audit_socketcall_compat (int nargs,u32 *args) +{ +return 0 ; +} +static inline void audit_fd_pair (int fd1,int fd2) { }static inline int audit_sockaddr (int len,void *addr)
include/linux/mmc/sdio_func.h +1 -1
@@ -53,7 +53,7 @@ struct sdio_func {unsigned int state;/* function state */ #define SDIO_STATE_PRESENT (1<<0)/* present in sysfs */ -u8 tmpbuf[4 ];/* DMA:able scratch buffer */ +u8 *tmpbuf;/* DMA:able scratch buffer */ unsigned num_info;/* number of info strings */ const char **info;/* info strings */
include/net/netfilter/nf_tables_ipv6.h +4 -2
@@ -9,12 +9,13 @@ nft_set_pktinfo_ipv6(struct nft_pktinfo *pkt,struct sk_buff *skb, const struct nf_hook_state *state) { + unsigned int flags = IP6_FH_F_AUTH;int protohdr, thoff =0 ;unsigned short frag_off;nft_set_pktinfo (pkt, skb, state); - protohdr =ipv6_find_hdr (pkt->skb, &thoff,-1 , &frag_off,NULL ); + protohdr =ipv6_find_hdr (pkt->skb, &thoff,-1 , &frag_off, &flags);if (protohdr <0 ) {nft_set_pktinfo_proto_unspec (pkt, skb);return ;
@@ -32,6 +33,7 @@ __nft_set_pktinfo_ipv6_validate(struct nft_pktinfo *pkt, const struct nf_hook_state *state) {#if IS_ENABLED (CONFIG_IPV6 ) +unsigned int flags =IP6_FH_F_AUTH ;struct ipv6hdr *ip6h, _ip6h;unsigned int thoff =0 ;unsigned short frag_off;
@@ -50,7 +52,7 @@ __nft_set_pktinfo_ipv6_validate(struct nft_pktinfo *pkt,if (pkt_len +sizeof (*ip6h) > skb->len)return -1 ; - protohdr =ipv6_find_hdr (pkt->skb, &thoff,-1 , &frag_off,NULL ); + protohdr =ipv6_find_hdr (pkt->skb, &thoff,-1 , &frag_off, &flags);if (protohdr <0 )return -1 ;
include/uapi/drm/drm_fourcc.h +1 -0
@@ -154,6 +154,7 @@ extern "C" {/* Vendor Ids: */ #define DRM_FORMAT_MOD_NONE 0 +#define DRM_FORMAT_MOD_VENDOR_NONE 0#define DRM_FORMAT_MOD_VENDOR_INTEL 0x01#define DRM_FORMAT_MOD_VENDOR_AMD 0x02#define DRM_FORMAT_MOD_VENDOR_NV 0x03
mm/memcontrol.c +5 -2
@@ -462,6 +462,8 @@ static void mem_cgroup_update_tree(struct mem_cgroup *memcg, struct page *page)struct mem_cgroup_tree_per_node *mctz; mctz =soft_limit_tree_from_page (page); +if (!mctz) +return ;/* * Necessary to update all ancestors when hierarchy is used. * because their event counter is not touched.
@@ -499,7 +501,8 @@ static void mem_cgroup_remove_from_trees(struct mem_cgroup *memcg)for_each_node (nid) { mz =mem_cgroup_nodeinfo (memcg, nid); mctz =soft_limit_tree_node (nid); -mem_cgroup_remove_exceeded (mz, mctz); +if (mctz) +mem_cgroup_remove_exceeded (mz, mctz); } }
@@ -2565,7 +2568,7 @@ unsigned long mem_cgroup_soft_limit_reclaim(pg_data_t *pgdat, int order,* is empty. Do it lockless to prevent lock bouncing. Races * are acceptable as soft limit is best effort anyway. */ -if (RB_EMPTY_ROOT (&mctz->rb_root)) +if (!mctz ||RB_EMPTY_ROOT (&mctz->rb_root))return 0 ;/*
net/bridge/br_netlink.c +5 -2
@@ -1098,11 +1098,14 @@ static int br_dev_newlink(struct net *src_net, struct net_device *dev,spin_unlock_bh (&br->lock); } - err =br_changelink (dev, tb, data); + err =register_netdevice (dev);if (err)return err; -return register_netdevice (dev); + err =br_changelink (dev, tb, data); +if (err) +unregister_netdevice (dev); +return err; }static size_t br_get_size (const struct net_device *brdev)
net/compat.c +14 -3
@@ -22,6 +22,7 @@#include <linux/filter.h> #include <linux/compat.h> #include <linux/security.h> +#include <linux/audit.h> #include <linux/export.h> #include <net/scm.h>
@@ -781,14 +782,24 @@ COMPAT_SYSCALL_DEFINE5(recvmmsg, int, fd, struct compat_mmsghdr __user *, mmsg, COMPAT_SYSCALL_DEFINE2(socketcall, int, call, u32 __user *, args) { -int ret; -u32 a[6 ]; +u32 a[AUDITSC_ARGS ]; +unsigned int len;u32 a0, a1; +int ret;if (call <SYS_SOCKET || call >SYS_SENDMMSG )return -EINVAL ; -if (copy_from_user (a, args, nas[call])) + len = nas[call]; +if (len >sizeof (a)) +return -EINVAL ; + +if (copy_from_user (a, args, len))return -EFAULT ; + + ret =audit_socketcall_compat (len /sizeof (a[0 ]), a); +if (ret) +return ret; + a0 = a[0 ]; a1 = a[1 ];
net/core/dev.c +3 -0
@@ -2355,6 +2355,9 @@ void __dev_kfree_skb_irq(struct sk_buff *skb, enum skb_free_reason reason) {unsigned long flags; +if (unlikely (!skb)) +return ; +if (likely (atomic_read (&skb->users) ==1 )) {smp_rmb ();atomic_set (&skb->users,0 );
net/ipv4/netfilter/nf_nat_snmp_basic.c +1 -0
@@ -1304,6 +1304,7 @@ static int __init nf_nat_snmp_basic_init(void) static void __exit nf_nat_snmp_basic_fini(void) {RCU_INIT_POINTER (nf_nat_snmp_hook,NULL ); +synchronize_rcu ();nf_conntrack_helper_unregister (&snmp_trap_helper); }
net/ipv4/udp_offload.c +3 -0
@@ -29,6 +29,7 @@ static struct sk_buff *__skb_udp_tunnel_segment(struct sk_buff *skb,u16 mac_len = skb->mac_len;int udp_offset, outer_hlen;__wsum partial; +bool need_ipsec;if (unlikely (!pskb_may_pull (skb, tnl_hlen))) goto out;
@@ -62,8 +63,10 @@ static struct sk_buff *__skb_udp_tunnel_segment(struct sk_buff *skb, ufo = !!(skb_shinfo (skb)->gso_type &SKB_GSO_UDP ); + need_ipsec =skb_dst (skb) &&dst_xfrm (skb_dst (skb));/* Try to offload checksum if possible */ offload_csum = !!(need_csum && + !need_ipsec && (skb->dev->features & (is_ipv6 ? (NETIF_F_HW_CSUM |NETIF_F_IPV6_CSUM ) : (NETIF_F_HW_CSUM |NETIF_F_IP_CSUM ))));
net/netfilter/nf_conntrack_ecache.c +2 -0
@@ -290,6 +290,7 @@ void nf_conntrack_unregister_notifier(struct net *net,BUG_ON (notify != new);RCU_INIT_POINTER (net->ct.nf_conntrack_event_cb,NULL );mutex_unlock (&nf_ct_ecache_mutex); +/* synchronize_rcu() is called from ctnetlink_exit. */ }EXPORT_SYMBOL_GPL (nf_conntrack_unregister_notifier);
@@ -326,6 +327,7 @@ void nf_ct_expect_unregister_notifier(struct net *net,BUG_ON (notify != new);RCU_INIT_POINTER (net->ct.nf_expect_event_cb,NULL );mutex_unlock (&nf_ct_ecache_mutex); +/* synchronize_rcu() is called from ctnetlink_exit. */ }EXPORT_SYMBOL_GPL (nf_ct_expect_unregister_notifier);
net/netfilter/nf_conntrack_netlink.c +1 -0
@@ -3413,6 +3413,7 @@ static void __exit ctnetlink_exit(void)#ifdef CONFIG_NETFILTER_NETLINK_GLUE_CT RCU_INIT_POINTER (nfnl_ct_hook,NULL );#endif +synchronize_rcu (); }module_init (ctnetlink_init);
net/netfilter/nf_nat_core.c +2 -0
@@ -892,6 +892,8 @@ static void __exit nf_nat_cleanup(void)#ifdef CONFIG_XFRM RCU_INIT_POINTER (nf_nat_decode_session_hook,NULL );#endif +synchronize_rcu (); +for (i =0 ; i <NFPROTO_NUMPROTO ; i++)kfree (nf_nat_l4protos[i]);
net/netfilter/nfnetlink_cthelper.c +11 -9
@@ -161,6 +161,7 @@ nfnl_cthelper_parse_expect_policy(struct nf_conntrack_helper *helper,int i, ret;struct nf_conntrack_expect_policy *expect_policy;struct nlattr *tb[NFCTH_POLICY_SET_MAX +1 ]; +unsigned int class_max; ret =nla_parse_nested (tb,NFCTH_POLICY_SET_MAX , attr, nfnl_cthelper_expect_policy_set);
@@ -170,19 +171,18 @@ nfnl_cthelper_parse_expect_policy(struct nf_conntrack_helper *helper,if (!tb[NFCTH_POLICY_SET_NUM ])return -EINVAL ; - helper->expect_class_max = -ntohl (nla_get_be32 (tb[NFCTH_POLICY_SET_NUM ])); - -if (helper->expect_class_max !=0 && - helper->expect_class_max >NF_CT_MAX_EXPECT_CLASSES ) + class_max =ntohl (nla_get_be32 (tb[NFCTH_POLICY_SET_NUM ])); +if (class_max ==0 ) +return -EINVAL ; +if (class_max >NF_CT_MAX_EXPECT_CLASSES )return -EOVERFLOW ; expect_policy =kzalloc (sizeof (struct nf_conntrack_expect_policy ) * - helper->expect_class_max,GFP_KERNEL ); + class_max,GFP_KERNEL );if (expect_policy ==NULL )return -ENOMEM ; -for (i=0 ; i<helper->expect_class_max; i++) { +for (i =0 ; i < class_max; i++) {if (!tb[NFCTH_POLICY_SET +i]) goto err;
@@ -191,6 +191,8 @@ nfnl_cthelper_parse_expect_policy(struct nf_conntrack_helper *helper,if (ret <0 ) goto err; } + + helper->expect_class_max = class_max -1 ; helper->expect_policy = expect_policy;return 0 ; err:
@@ -377,10 +379,10 @@ nfnl_cthelper_dump_policy(struct sk_buff *skb, goto nla_put_failure;if (nla_put_be32 (skb,NFCTH_POLICY_SET_NUM , -htonl (helper->expect_class_max))) +htonl (helper->expect_class_max +1 ))) goto nla_put_failure; -for (i=0 ; i<helper->expect_class_max; i++) { +for (i =0 ; i < helper->expect_class_max +1 ; i++) { nest_parms2 =nla_nest_start (skb, (NFCTH_POLICY_SET +i) |NLA_F_NESTED );if (nest_parms2 ==NULL )
net/netfilter/nfnetlink_cttimeout.c +1 -1
@@ -646,8 +646,8 @@ static void __exit cttimeout_exit(void)#ifdef CONFIG_NF_CONNTRACK_TIMEOUT RCU_INIT_POINTER (nf_ct_timeout_find_get_hook,NULL );RCU_INIT_POINTER (nf_ct_timeout_put_hook,NULL ); +synchronize_rcu ();#endif /* CONFIG_NF_CONNTRACK_TIMEOUT */ -rcu_barrier (); }module_init (cttimeout_init);
net/packet/af_packet.c +2 -0
@@ -3884,6 +3884,8 @@ static int packet_getsockopt(struct socket *sock, int level, int optname,case PACKET_HDRLEN :if (len >sizeof (int )) len =sizeof (int ); +if (len <sizeof (int )) +return -EINVAL ;if (copy_from_user (&val, optval, len))return -EFAULT ;switch (val) {
net/rds/ib_cm.c +36 -11
47 lines not on this page · raw message
sound/soc/codecs/rt5659.c +43 -43
86 lines not on this page · raw message
sound/soc/soc-dapm.c +62 -0
62 lines not on this page · 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.