[PATCH 4.14 17/69] ipv6: sit: reset ip header pointer in ipip6_rcv

2019-04-15 Thread Greg Kroah-Hartman
From: Lorenzo Bianconi [ Upstream commit bb9bd814ebf04f579be466ba61fc922625508807 ] ipip6 tunnels run iptunnel_pull_header on received skbs. This can determine the following use-after-free accessing iph pointer since the packet will be 'uncloned' running pskb_expand_head if it is a cloned gso

[PATCH 4.14 26/69] tcp: Ensure DCTCP reacts to losses

2019-04-15 Thread Greg Kroah-Hartman
From: Koen De Schepper [ Upstream commit aecfde23108b8e637d9f5c5e523b24fb97035dc3 ] RFC8257 ยง3.5 explicitly states that "A DCTCP sender MUST react to loss episodes in the same way as conventional TCP". Currently, Linux DCTCP performs no cwnd reduction when losses are encountered. Optionally,

[PATCH 4.14 36/69] ALSA: seq: Fix OOB-reads from strlcpy

2019-04-15 Thread Greg Kroah-Hartman
From: Zubin Mithra commit 212ac181c158c09038c474ba68068be49caecebb upstream. When ioctl calls are made with non-null-terminated userspace strings, strlcpy causes an OOB-read from within strlen. Fix by changing to use strscpy instead. Signed-off-by: Zubin Mithra Reviewed-by: Guenter Roeck Cc:

[PATCH 4.14 35/69] net: ethtool: not call vzalloc for zero sized memory request

2019-04-15 Thread Greg Kroah-Hartman
From: Li RongQing [ Upstream commit 3d8830266ffc28c16032b859e38a0252e014b631 ] NULL or ZERO_SIZE_PTR will be returned for zero sized memory request, and derefencing them will lead to a segfault so it is unnecessory to call vzalloc for zero sized memory request and not call functions which

[PATCH 4.14 13/69] arm64: kaslr: Reserve size of ARM64_MEMSTART_ALIGN in linear region

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit c8a43c18a97845e7f94ed7d181c11f41964976a2 ] When KASLR is enabled (CONFIG_RANDOMIZE_BASE=y), the top 4K of kernel virtual address space may be mapped to physical addresses despite being reserved for ERR_PTR values. Fix the randomization of the linear region so that we avoid

[PATCH 4.14 14/69] tty: mark Siemens R3964 line discipline as BROKEN

2019-04-15 Thread Greg Kroah-Hartman
From: Greg Kroah-Hartman commit c7084edc3f6d67750f50d4183134c4fb5712a5c8 upstream. The n_r3964 line discipline driver was written in a different time, when SMP machines were rare, and users were trusted to do the right thing. Since then, the world has moved on but not this code, it has stayed

[PATCH 4.14 12/69] stating: ccree: revert "staging: ccree: fix leak of import() after init()"

2019-04-15 Thread Greg Kroah-Hartman
commit 293edc27f8bc8a44978e9e95902b07b74f1c7523 upstream This reverts commit c5f39d07860c ("staging: ccree: fix leak of import() after init()") and commit aece09024414 ("staging: ccree: Uninitialized return in ssi_ahash_import()"). This is the wrong solution and ends up relying on uninitialized

[PATCH 4.14 40/69] parisc: Detect QEMU earlier in boot process

2019-04-15 Thread Greg Kroah-Hartman
From: Helge Deller commit d006e95b5561f708d0385e9677ffe2c46f2ae345 upstream. While adding LASI support to QEMU, I noticed that the QEMU detection in the kernel happens much too late. For example, when a LASI chip is found by the kernel, it registers the LASI LED driver as well. But when we run

[PATCH 4.14 29/69] net/mlx5e: Add a lock on tir list

2019-04-15 Thread Greg Kroah-Hartman
From: Yuval Avnery [ Upstream commit 80a2a9026b24c6bd34b8d58256973e22270bedec ] Refresh tirs is looping over a global list of tirs while netdevs are adding and removing tirs from that list. That is why a lock is required. Fixes: 724b2aa15126 ("net/mlx5e: TIRs management refactoring")

[PATCH 4.14 28/69] net/mlx5e: Fix error handling when refreshing TIRs

2019-04-15 Thread Greg Kroah-Hartman
From: Gavi Teitz [ Upstream commit bc87a0036826a37b43489b029af8143bd07c6cca ] Previously, a false positive would be caught if the TIRs list is empty, since the err value was initialized to -ENOMEM, and was only updated if a TIR is refreshed. This is resolved by initializing the err value to

[PATCH 4.14 27/69] vrf: check accept_source_route on the original netdevice

2019-04-15 Thread Greg Kroah-Hartman
From: Stephen Suryaputra [ Upstream commit 8c83f2df9c6578ea4c5b940d8238ad8a41b87e9e ] Configuration check to accept source route IP options should be made on the incoming netdevice when the skb->dev is an l3mdev master. The route lookup for the source route next hop also needs the incoming

[PATCH 4.14 30/69] nfp: validate the return code from dev_queue_xmit()

2019-04-15 Thread Greg Kroah-Hartman
From: Jakub Kicinski [ Upstream commit c8ba5b91a04e3e2643e48501c114108802f21cda ] dev_queue_xmit() may return error codes as well as netdev_tx_t, and it always consumes the skb. Make sure we always return a correct netdev_tx_t value. Fixes: eadfa4c3be99 ("nfp: add stats and xmit helpers for

[PATCH 4.14 41/69] parisc: regs_return_value() should return gpr28

2019-04-15 Thread Greg Kroah-Hartman
From: Sven Schnelle commit 45efd871bf0a47648f119d1b41467f70484de5bc upstream. While working on kretprobes for PA-RISC I was wondering while the kprobes sanity test always fails on kretprobes. This is caused by returning gpr20 instead of gpr28. Signed-off-by: Sven Schnelle Signed-off-by: Helge

[PATCH 4.14 56/69] ARM: dts: at91: Fix typo in ISC_D0 on PC9

2019-04-15 Thread Greg Kroah-Hartman
From: David Engraf commit e7dfb6d04e4715be1f3eb2c60d97b753fd2e4516 upstream. The function argument for the ISC_D0 on PC9 was incorrect. According to the documentation it should be 'C' aka 3. Signed-off-by: David Engraf Reviewed-by: Nicolas Ferre Signed-off-by: Ludovic Desroches Fixes:

[PATCH 4.14 54/69] ARM: dts: am335x-evmsk: Correct the regulators for the audio codec

2019-04-15 Thread Greg Kroah-Hartman
From: Peter Ujfalusi commit 6691370646e844be98bb6558c024269791d20bd7 upstream. Correctly map the regulators used by tlv320aic3106. Both 1.8V and 3.3V for the codec is derived from VBAT via fixed regulators. Cc: # v4.14+ Signed-off-by: Peter Ujfalusi Signed-off-by: Tony Lindgren

[PATCH 4.14 53/69] virtio: Honour may_reduce_num in vring_create_virtqueue

2019-04-15 Thread Greg Kroah-Hartman
From: Cornelia Huck commit cf94db21905333e610e479688add629397a4b384 upstream. vring_create_virtqueue() allows the caller to specify via the may_reduce_num parameter whether the vring code is allowed to allocate a smaller ring than specified. However, the split ring allocation code tries to

[PATCH 4.14 34/69] netns: provide pure entropy for net_hash_mix()

2019-04-15 Thread Greg Kroah-Hartman
From: Eric Dumazet [ Upstream commit 355b98553789b646ed97ad801a619ff898471b92 ] net_hash_mix() currently uses kernel address of a struct net, and is used in many places that could be used to reveal this address to a patient attacker, thus defeating KASLR, for the typical case (initial net

[PATCH 4.14 31/69] bnxt_en: Improve RX consumer index validity check.

2019-04-15 Thread Greg Kroah-Hartman
From: Michael Chan [ Upstream commit a1b0e4e684e9c300b9e759b46cb7a0147e61ddff ] There is logic to check that the RX/TPA consumer index is the expected index to work around a hardware problem. However, the potentially bad consumer index is first used to index into an array to reference an

[PATCH 4.14 32/69] bnxt_en: Reset device on RX buffer errors.

2019-04-15 Thread Greg Kroah-Hartman
From: Michael Chan [ Upstream commit 8e44e96c6c8e8fb80b84a2ca11798a8554f710f2 ] If the RX completion indicates RX buffers errors, the RX ring will be disabled by firmware and no packets will be received on that ring from that point on. Recover by resetting the device. Fixes: c0c050c58d84

[PATCH 4.14 33/69] net/sched: act_sample: fix divide by zero in the traffic path

2019-04-15 Thread Greg Kroah-Hartman
From: Davide Caratti [ Upstream commit fae2708174ae95d98d19f194e03d6e8f688ae195 ] the control path of 'sample' action does not validate the value of 'rate' provided by the user, but then it uses it as divisor in the traffic path. Validate it in tcf_sample_init(), and return -EINVAL with a

[PATCH 4.14 44/69] include/linux/bitrev.h: fix constant bitrev

2019-04-15 Thread Greg Kroah-Hartman
From: Arnd Bergmann commit 6147e136ff5071609b54f18982dea87706288e21 upstream. clang points out with hundreds of warnings that the bitrev macros have a problem with constant input: drivers/hwmon/sht15.c:187:11: error: variable '__x' is uninitialized when used within its own initialization

[PATCH 4.14 48/69] btrfs: prop: fix vanished compression property after failed set

2019-04-15 Thread Greg Kroah-Hartman
From: Anand Jain commit 272e5326c7837697882ce3162029ba893059b616 upstream. The compression property resets to NULL, instead of the old value if we fail to set the new compression parameter. $ btrfs prop get /btrfs compression compression=lzo $ btrfs prop set /btrfs compression zli

[PATCH 4.14 61/69] sched/fair: Do not re-read ->h_load_next during hierarchical load calculation

2019-04-15 Thread Greg Kroah-Hartman
From: Mel Gorman commit 0e9f02450da07fc7b1346c8c32c771555173e397 upstream. A NULL pointer dereference bug was reported on a distribution kernel but the same issue should be present on mainline kernel. It occured on s390 but should not be arch-specific. A partial oops looks like: Unable to

[PATCH 4.14 60/69] xen: Prevent buffer overflow in privcmd ioctl

2019-04-15 Thread Greg Kroah-Hartman
From: Dan Carpenter commit 42d8644bd77dd2d747e004e367cb0c895a606f39 upstream. The "call" variable comes from the user in privcmd_ioctl_hypercall(). It's an offset into the hypercall_page[] which has (PAGE_SIZE / 32) elements. We need to put an upper bound on it to prevent an out of bounds

[PATCH 4.14 65/69] x86/perf/amd: Remove need to check "running" bit in NMI handler

2019-04-15 Thread Greg Kroah-Hartman
From: Lendacky, Thomas commit 3966c3feca3fd10b2935caa0b4a08c7dd59469e5 upstream. Spurious interrupt support was added to perf in the following commit, almost a decade ago: 63e6be6d98e1 ("perf, x86: Catch spurious interrupts after disabling counters") The two previous patches (resolving the

[PATCH 4.14 58/69] arm64: dts: rockchip: fix rk3328 rgmii high tx error rate

2019-04-15 Thread Greg Kroah-Hartman
From: Peter Geis commit 6fd8b9780ec1a49ac46e0aaf8775247205e66231 upstream. Several rk3328 based boards experience high rgmii tx error rates. This is due to several pins in the rk3328.dtsi rgmii pinmux that are missing a defined pull strength setting. This causes the pinmux driver to default to

[PATCH 4.14 63/69] x86/perf/amd: Resolve race condition when disabling PMC

2019-04-15 Thread Greg Kroah-Hartman
From: Lendacky, Thomas commit 914123fa39042e651d79eaf86bbf63a1b938dddf upstream. On AMD processors, the detection of an overflowed counter in the NMI handler relies on the current value of the counter. So, for example, to check for overflow on a 48 bit counter, bit 47 is checked to see if it is

[PATCH 4.14 50/69] block: fix the return errno for direct IO

2019-04-15 Thread Greg Kroah-Hartman
From: Jason Yan commit a89afe58f1a74aac768a5eb77af95ef4ee15beaa upstream. If the last bio returned is not dio->bio, the status of the bio will not assigned to dio->bio if it is error. This will cause the whole IO status wrong. ksoftirqd/21-117 [021] ..s. 4017.966090: 8,0C N

[PATCH 4.14 68/69] arm64: dts: rockchip: fix vcc_host1_5v pin assign on rk3328-rock64

2019-04-15 Thread Greg Kroah-Hartman
From: Katsuhiro Suzuki commit ef05bcb60c1a8841e38c91923ba998181117a87c upstream. This patch fixes pin assign of vcc_host1_5v. This regulator is controlled by USB20_HOST_DRV signal. ROCK64 schematic says that GPIO0_A2 pin is used as USB20_HOST_DRV. GPIO0_D3 pin is for SPDIF_TX_M0.

[PATCH 4.14 69/69] arm64: dts: rockchip: Fix vcc_host1_5v GPIO polarity on rk3328-rock64

2019-04-15 Thread Greg Kroah-Hartman
From: Tomohiro Mayama commit a8772e5d826d0f61f8aa9c284b3ab49035d5273d upstream. This patch makes USB ports functioning again. Fixes: 955bebde057e ("arm64: dts: rockchip: add rk3328-rock64 board") Cc: sta...@vger.kernel.org Suggested-by: Robin Murphy Signed-off-by: Tomohiro Mayama Tested-by:

[PATCH 4.14 42/69] alarmtimer: Return correct remaining time

2019-04-15 Thread Greg Kroah-Hartman
From: Andrei Vagin commit 07d7e12091f4ab869cc6a4bb276399057e73b0b3 upstream. To calculate a remaining time, it's required to subtract the current time from the expiration time. In alarm_timer_remaining() the arguments of ktime_sub are swapped. Fixes: d653d8457c76 ("alarmtimer: Implement

[PATCH 4.14 66/69] PCI: Add function 1 DMA alias quirk for Marvell 9170 SATA controller

2019-04-15 Thread Greg Kroah-Hartman
From: Andre Przywara commit 9cde402a59770a0669d895399c13407f63d7d209 upstream. There is a Marvell 88SE9170 PCIe SATA controller I found on a board here. Some quick testing with the ARM SMMU enabled reveals that it suffers from the same requester ID mixup problems as the other Marvell chips

[PATCH 4.19 027/101] nfp: disable netpoll on representors

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit c3e1f7fff69c78169c8ac40cc74ac4307f74e36d ] NFP reprs are software device on top of the PF's vNIC. The comment above __dev_queue_xmit() sayeth: When calling this method, interrupts MUST be enabled. This is because the BH enable code must have IRQs enabled so that it will not

[PATCH 4.19 008/101] ipv6: sit: reset ip header pointer in ipip6_rcv

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit bb9bd814ebf04f579be466ba61fc922625508807 ] ipip6 tunnels run iptunnel_pull_header on received skbs. This can determine the following use-after-free accessing iph pointer since the packet will be 'uncloned' running pskb_expand_head if it is a cloned gso skb (e.g if the packet has

[PATCH 4.19 011/101] net-gro: Fix GRO flush when receiving a GSO packet.

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit 0ab03f353d3613ea49d1f924faf98559003670a8 ] Currently we may merge incorrectly a received GSO packet or a packet with frag_list into a packet sitting in the gro_hash list. skb_segment() may crash case because the assumptions on the skb layout are not met. The correct behaviour

[PATCH 4.19 024/101] net/mlx5e: Fix error handling when refreshing TIRs

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit bc87a0036826a37b43489b029af8143bd07c6cca ] Previously, a false positive would be caught if the TIRs list is empty, since the err value was initialized to -ENOMEM, and was only updated if a TIR is refreshed. This is resolved by initializing the err value to zero. Fixes:

[PATCH 4.19 022/101] tcp: fix a potential NULL pointer dereference in tcp_sk_exit

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit b506bc975f60f06e13e74adb35e708a23dc4e87c ] When tcp_sk_init() failed in inet_ctl_sock_create(), 'net->ipv4.tcp_congestion_control' will be left uninitialized, but tcp_sk_exit() hasn't check for that. This patch add checking on 'net->ipv4.tcp_congestion_control' in

[PATCH 4.19 004/101] hv_netvsc: Fix unwanted wakeup after tx_disable

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit 1b704c4a1ba95574832e730f23817b651db2aa59 ] After queue stopped, the wakeup mechanism may wake it up again when ring buffer usage is lower than a threshold. This may cause send path panic on NULL pointer when we stopped all tx queues in netvsc_detach and start removing the netvsc

[PATCH 4.19 007/101] ipv6: Fix dangling pointer when ipv6 fragment

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit ef0efcd3bd3fd0589732b67fb586ffd3c8705806 ] At the beginning of ip6_fragment func, the prevhdr pointer is obtained in the ip6_find_1stfragopt func. However, all the pointers pointing into skb header may change when calling skb_checksum_help func with skb->ip_summed =

[PATCH 4.19 025/101] net/mlx5e: Add a lock on tir list

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit 80a2a9026b24c6bd34b8d58256973e22270bedec ] Refresh tirs is looping over a global list of tirs while netdevs are adding and removing tirs from that list. That is why a lock is required. Fixes: 724b2aa15126 ("net/mlx5e: TIRs management refactoring") Signed-off-by: Yuval Avnery

[PATCH 4.19 003/101] powerpc/tm: Limit TM code inside PPC_TRANSACTIONAL_MEM

2019-04-15 Thread Greg Kroah-Hartman
commit 897bc3df8c5aebb54c32d831f917592e873d0559 upstream. Commit e1c3743e1a20 ("powerpc/tm: Set MSR[TS] just prior to recheckpoint") moved a code block around and this block uses a 'msr' variable outside of the CONFIG_PPC_TRANSACTIONAL_MEM, however the 'msr' variable is declared inside a

[PATCH 4.19 005/101] ibmvnic: Fix completion structure initialization

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit bbd669a868bba591ffd38b7bc75a7b361bb54b04 ] Fix device initialization completion handling for vNIC adapters. Initialize the completion structure on probe and reinitialize when needed. This also fixes a race condition during kdump where the driver can attempt to access the

[PATCH 4.19 010/101] net: ethtool: not call vzalloc for zero sized memory request

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit 3d8830266ffc28c16032b859e38a0252e014b631 ] NULL or ZERO_SIZE_PTR will be returned for zero sized memory request, and derefencing them will lead to a segfault so it is unnecessory to call vzalloc for zero sized memory request and not call functions which maybe derefence the NULL

[PATCH 4.19 029/101] bnxt_en: Reset device on RX buffer errors.

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit 8e44e96c6c8e8fb80b84a2ca11798a8554f710f2 ] If the RX completion indicates RX buffers errors, the RX ring will be disabled by firmware and no packets will be received on that ring from that point on. Recover by resetting the device. Fixes: c0c050c58d84 ("bnxt_en: New Broadcom

[PATCH 4.19 009/101] kcm: switch order of device registration to fix a crash

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit 3c446e6f96997f2a95bf0037ef463802162d2323 ] When kcm is loaded while many processes try to create a KCM socket, a crash occurs: BUG: unable to handle kernel NULL pointer dereference at 000e IP: mutex_lock+0x27/0x40 kernel/locking/mutex.c:240 PGD 800016ef2067

[PATCH 4.19 020/101] sctp: initialize _pad of sockaddr_in before copying to user memory

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit 09279e615c81ce55e04835970601ae286e3facbe ] Syzbot report a kernel-infoleak: BUG: KMSAN: kernel-infoleak in _copy_to_user+0x16b/0x1f0 lib/usercopy.c:32 Call Trace: _copy_to_user+0x16b/0x1f0 lib/usercopy.c:32 copy_to_user include/linux/uaccess.h:174 [inline]

[PATCH 4.19 019/101] r8169: disable ASPM again

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit b75bb8a5b755d0c7bf1ac071e4df2349a7644a1e ] There's a significant number of reports that re-enabling ASPM causes different issues, ranging from decreased performance to system not booting at all. This affects only a minority of users, but the number of affected users is big

[PATCH 4.19 043/101] netfilter: nfnetlink_cttimeout: fetch timeouts for udplite and gre, too

2019-04-15 Thread Greg Kroah-Hartman
commit 89259088c1b7fecb43e8e245dc931909132a4e03 upstream syzbot was able to trigger the WARN in cttimeout_default_get() by passing UDPLITE as l4protocol. Alias UDPLITE to UDP, both use same timeout values. Furthermore, also fetch GRE timeouts. GRE is a bit more complicated, as it still can be

[PATCH 4.19 014/101] net: rds: force to destroy connection if t_sock is NULL in rds_tcp_kill_sock().

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit cb66ddd156203daefb8d71158036b27b0e2caf63 ] When it is to cleanup net namespace, rds_tcp_exit_net() will call rds_tcp_kill_sock(), if t_sock is NULL, it will not call rds_conn_destroy(), rds_conn_path_destroy() and rds_tcp_conn_free() to free connection, and the worker cp_conn_w

[PATCH 4.19 018/101] qmi_wwan: add Olicard 600

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit 6289d0facd9ebce4cc83e5da39e15643ee998dc5 ] This is a Qualcomm based device with a QMI function on interface 4. It is mode switched from 2020:2030 using a standard eject message. T: Bus=01 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#= 6 Spd=480 MxCh= 0 D: Ver= 2.00 Cls=00(>ifc )

[PATCH 4.19 015/101] net/sched: act_sample: fix divide by zero in the traffic path

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit fae2708174ae95d98d19f194e03d6e8f688ae195 ] the control path of 'sample' action does not validate the value of 'rate' provided by the user, but then it uses it as divisor in the traffic path. Validate it in tcf_sample_init(), and return -EINVAL with a proper extack message in

[PATCH 4.19 017/101] openvswitch: fix flow actions reallocation

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit f28cd2af22a0c134e4aa1c64a70f70d815d473fb ] The flow action buffer can be resized if it's not big enough to contain all the requested flow actions. However, this resize doesn't take into account the new requested size, the buffer is only increased by a factor of 2x. This might be

[PATCH 4.19 047/101] hwmon: (w83773g) Select REGMAP_I2C to fix build error

2019-04-15 Thread Greg Kroah-Hartman
From: Axel Lin commit a165dcc923ada2ffdee1d4f41f12f81b66d04c55 upstream. Select REGMAP_I2C to avoid below build error: ERROR: "__devm_regmap_init_i2c" [drivers/hwmon/w83773g.ko] undefined! Fixes: ee249f271524 ("hwmon: Add W83773G driver") Cc: sta...@vger.kernel.org Signed-off-by: Axel Lin

[PATCH 4.19 049/101] ACPICA: Namespace: remove address node from global list after method termination

2019-04-15 Thread Greg Kroah-Hartman
From: Erik Schmauss commit c5781ffbbd4f742a58263458145fe7f0ac01d9e0 upstream. ACPICA commit b233720031a480abd438f2e9c643080929d144c3 ASL operation_regions declare a range of addresses that it uses. In a perfect world, the range of addresses should be used exclusively by the AML interpreter.

[PATCH 4.19 048/101] ACPICA: Clear status of GPEs before enabling them

2019-04-15 Thread Greg Kroah-Hartman
From: Furquan Shaikh commit c8b1917c8987a6fa3695d479b4d60fbbbc3e537b upstream. Commit 18996f2db918 ("ACPICA: Events: Stop unconditionally clearing ACPI IRQs during suspend/resume") was added to stop clearing event status bits unconditionally in the system-wide suspend and resume paths. This was

[PATCH 4.19 034/101] net: mlx5: Add a missing check on idr_find, free buf

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit 8e949363f017e2011464812a714fb29710fb95b4 ] idr_find() can return a NULL value to 'flow' which is used without a check. The patch adds a check to avoid potential NULL pointer dereference. In case of mlx5_fpga_sbu_conn_sendmsg() failure, free buf allocated using kzalloc. Fixes:

[PATCH 4.19 033/101] r8169: disable default rx interrupt coalescing on RTL8168

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit 288ac524cf70a8e7ed851a61ed2a9744039dae8d ] It was reported that re-introducing ASPM, in combination with RX interrupt coalescing, results in significantly increased packet latency, see [0]. Disabling ASPM or RX interrupt coalescing fixes the issue. Therefore change the driver's

[PATCH 4.19 051/101] ALSA: hda/realtek: Enable headset MIC of Acer TravelMate B114-21 with ALC233

2019-04-15 Thread Greg Kroah-Hartman
From: Jian-Hong Pan commit ea5c7eba216e832906e594799b8670f1954a588c upstream. The Acer TravelMate B114-21 laptop cannot detect and record sound from headset MIC. This patch adds the ALC233_FIXUP_ACER_HEADSET_MIC HDA verb quirk chained with ALC233_FIXUP_ASUS_MIC_NO_PRESENCE pin quirk to fix

[PATCH 4.19 054/101] mm/huge_memory.c: fix modifying of page protection by insert_pfn_pmd()

2019-04-15 Thread Greg Kroah-Hartman
From: Aneesh Kumar K.V commit c6f3c5ee40c10bb65725047a220570f718507001 upstream. With some architectures like ppc64, set_pmd_at() cannot cope with a situation where there is already some (different) valid entry present. Use pmdp_set_access_flags() instead to modify the pfn which is built to

[PATCH 4.19 069/101] btrfs: prop: fix vanished compression property after failed set

2019-04-15 Thread Greg Kroah-Hartman
From: Anand Jain commit 272e5326c7837697882ce3162029ba893059b616 upstream. The compression property resets to NULL, instead of the old value if we fail to set the new compression parameter. $ btrfs prop get /btrfs compression compression=lzo $ btrfs prop set /btrfs compression zli

[PATCH 4.19 031/101] net: ip6_gre: fix possible use-after-free in ip6erspan_rcv

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit 2a3cabae4536edbcb21d344e7aa8be7a584d2afb ] erspan_v6 tunnels run __iptunnel_pull_header on received skbs to remove erspan header. This can determine a possible use-after-free accessing pkt_md pointer in ip6erspan_rcv since the packet will be 'uncloned' running pskb_expand_head

[PATCH 4.19 038/101] kbuild: clang: choose GCC_TOOLCHAIN_DIR not on LD

2019-04-15 Thread Greg Kroah-Hartman
commit ad15006cc78459d059af56729c4d9bed7c7fd860 upstream. This causes an issue when trying to build with `make LD=ld.lld` if ld.lld and the rest of your cross tools aren't in the same directory (ex. /usr/local/bin) (as is the case for Android's build system), as the GCC_TOOLCHAIN_DIR then gets

[PATCH 4.19 072/101] block: fix the return errno for direct IO

2019-04-15 Thread Greg Kroah-Hartman
From: Jason Yan commit a89afe58f1a74aac768a5eb77af95ef4ee15beaa upstream. If the last bio returned is not dio->bio, the status of the bio will not assigned to dio->bio if it is error. This will cause the whole IO status wrong. ksoftirqd/21-117 [021] ..s. 4017.966090: 8,0C N

[PATCH 4.19 052/101] ALSA: hda/realtek - Add quirk for Tuxedo XC 1509

2019-04-15 Thread Greg Kroah-Hartman
From: Richard Sailer commit 80690a276f444a68a332136d98bfea1c338bc263 upstream. This adds a SND_PCI_QUIRK(...) line for the Tuxedo XC 1509. The Tuxedo XC 1509 and the System76 oryp5 are the same barebone notebooks manufactured by Clevo. To name the fixups both use after the actual underlying

[PATCH 4.19 035/101] net/mlx5e: Update xoff formula

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit 5ec983e924c7978aaec3cf8679ece9436508bb20 ] Set minimum speed in xoff threshold formula to 40Gbps Fixes: 0696d60853d5 ("net/mlx5e: Receive buffer configuration") Signed-off-by: Huy Nguyen Signed-off-by: Saeed Mahameed Signed-off-by: Sasha Levin ---

[PATCH 4.19 064/101] mm: writeback: use exact memcg dirty counts

2019-04-15 Thread Greg Kroah-Hartman
From: Greg Thelen commit 0b3d6e6f2dd0a7b697b1aa8c167265908940624b upstream. Since commit a983b5ebee57 ("mm: memcontrol: fix excessive complexity in memory.stat reporting") memcg dirty and writeback counters are managed as: 1) per-memcg per-cpu values in range of [-32..32] 2) per-memcg

[PATCH 4.19 040/101] lib/string.c: implement a basic bcmp

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit 5f074f3e192f10c9fade898b9b3b8812e3d83342 ] A recent optimization in Clang (r355672) lowers comparisons of the return value of memcmp against zero to comparisons of the return value of bcmp against zero. This helps some platforms that implement bcmp more efficiently than memcmp.

[PATCH 4.19 068/101] btrfs: prop: fix zstd compression parameter validation

2019-04-15 Thread Greg Kroah-Hartman
From: Anand Jain commit 50398fde997f6be8faebdb5f38e9c9c467370f51 upstream. We let pass zstd compression parameter even if it is not fully valid. For example: $ btrfs prop set /btrfs compression zst $ btrfs prop get /btrfs compression compression=zst zlib and lzo are fine. Fix it by

[PATCH 4.19 037/101] kbuild: deb-pkg: fix bindeb-pkg breakage when O= is used

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit 02826a6ba301b72461c3706e1cc66d5571cd327e ] Ard Biesheuvel reports bindeb-pkg with O= option is broken in the following way: ... LD [M] sound/soc/rockchip/snd-soc-rk3399-gru-sound.ko LD [M] sound/soc/rockchip/snd-soc-rockchip-pcm.ko LD [M]

[PATCH 4.19 066/101] ASoC: fsl_esai: fix channel swap issue when stream starts

2019-04-15 Thread Greg Kroah-Hartman
From: S.j. Wang commit 0ff4e8c61b794a4bf6c854ab071a1abaaa80f358 upstream. There is very low possibility ( < 0.1% ) that channel swap happened in beginning when multi output/input pin is enabled. The issue is that hardware can't send data to correct pin in the beginning with the normal enable

[PATCH 4.19 055/101] arm64: dts: rockchip: fix rk3328 sdmmc0 write errors

2019-04-15 Thread Greg Kroah-Hartman
From: Peter Geis commit 09f91381fa5de1d44bc323d8bf345f5d57b3d9b5 upstream. Various rk3328 based boards experience occasional sdmmc0 write errors. This is due to the rk3328.dtsi tx drive levels being set to 4ma, vs 8ma per the rk3328 datasheet default settings. Fix this by setting the tx signal

[PATCH 4.19 073/101] genirq: Respect IRQCHIP_SKIP_SET_WAKE in irq_chip_set_wake_parent()

2019-04-15 Thread Greg Kroah-Hartman
From: Stephen Boyd commit 325aa19598e410672175ed50982f902d4e3f31c5 upstream. If a child irqchip calls irq_chip_set_wake_parent() but its parent irqchip has the IRQCHIP_SKIP_SET_WAKE flag set an error is returned. This is inconsistent behaviour vs. set_irq_wake_real() which returns 0 when the

[PATCH 4.19 065/101] ASoC: intel: Fix crash at suspend/resume after failed codec registration

2019-04-15 Thread Greg Kroah-Hartman
From: Guenter Roeck commit 8f71370f4b02730e8c27faf460af7a3586e24e1f upstream. If codec registration fails after the ASoC Intel SST driver has been probed, the kernel will Oops and crash at suspend/resume. general protection fault: [#1] PREEMPT SMP KASAN PTI CPU: 1 PID: 2811 Comm: cat

[PATCH 4.19 057/101] parisc: regs_return_value() should return gpr28

2019-04-15 Thread Greg Kroah-Hartman
From: Sven Schnelle commit 45efd871bf0a47648f119d1b41467f70484de5bc upstream. While working on kretprobes for PA-RISC I was wondering while the kprobes sanity test always fails on kretprobes. This is caused by returning gpr20 instead of gpr28. Signed-off-by: Sven Schnelle Signed-off-by: Helge

[PATCH 4.19 060/101] drm/i915/gvt: do not deliver a workload if its creation fails

2019-04-15 Thread Greg Kroah-Hartman
From: Yan Zhao commit dade58ed5af6365ac50ff4259c2a0bf31219e285 upstream. in workload creation routine, if any failure occurs, do not queue this workload for delivery. if this failure is fatal, enter into failsafe mode. Fixes: 6d76303553ba ("drm/i915/gvt: Move common vGPU workload creation into

[PATCH 4.19 062/101] kvm: svm: fix potential get_num_contig_pages overflow

2019-04-15 Thread Greg Kroah-Hartman
From: David Rientjes commit ede885ecb2cdf8a8dd5367702e3d964ec846a2d5 upstream. get_num_contig_pages() could potentially overflow int so make its type consistent with its usage. Reported-by: Cfir Cohen Cc: sta...@vger.kernel.org Signed-off-by: David Rientjes Signed-off-by: Paolo Bonzini

[PATCH 4.19 053/101] ALSA: hda - Add two more machines to the power_save_blacklist

2019-04-15 Thread Greg Kroah-Hartman
From: Hui Wang commit cae30527901d9590db0e12ace994c1d58bea87fd upstream. Recently we set CONFIG_SND_HDA_POWER_SAVE_DEFAULT to 1 when configuring the kernel, then two machines were reported to have noise after installing the new kernel. Put them in the blacklist, the noise disappears.

[PATCH 4.19 076/101] ARM: dts: rockchip: fix rk3288 cpu opp node reference

2019-04-15 Thread Greg Kroah-Hartman
From: Jonas Karlman commit 6b2fde3dbfab6ebc45b0cd605e17ca5057ff9a3b upstream. The following error can be seen during boot: of: /cpus/cpu@501: Couldn't find opp node Change cpu nodes to use operating-points-v2 in order to fix this. Fixes: ce76de984649 ("ARM: dts: rockchip: convert rk3288 to

[PATCH 4.19 086/101] x86/asm: Remove dead __GNUC__ conditionals

2019-04-15 Thread Greg Kroah-Hartman
From: Rasmus Villemoes commit 88ca66d8540ca26119b1428cddb96b37925bdf01 upstream. The minimum supported gcc version is >= 4.6, so these can be removed. Signed-off-by: Rasmus Villemoes Signed-off-by: Borislav Petkov Cc: "H. Peter Anvin" Cc: Dan Williams Cc: Geert Uytterhoeven Cc: Ingo

[PATCH 4.19 085/101] xtensa: fix return_address

2019-04-15 Thread Greg Kroah-Hartman
From: Max Filippov commit ada770b1e74a77fff2d5f539bf6c42c25f4784db upstream. return_address returns the address that is one level higher in the call stack than requested in its argument, because level 0 corresponds to its caller's return address. Use requested level as the number of stack

[PATCH 4.19 089/101] x86/perf/amd: Resolve NMI latency issues for active PMCs

2019-04-15 Thread Greg Kroah-Hartman
From: Lendacky, Thomas commit 6d3edaae16c6c7d238360f2841212c2b26774d5e upstream. On AMD processors, the detection of an overflowed PMC counter in the NMI handler relies on the current value of the PMC. So, for example, to check for overflow on a 48-bit counter, bit 47 is checked to see if it is

[PATCH 4.19 087/101] x86/asm: Use stricter assembly constraints in bitops

2019-04-15 Thread Greg Kroah-Hartman
From: Alexander Potapenko commit 5b77e95dd7790ff6c8fbf1cd8d0104ebed818a03 upstream. There's a number of problems with how arch/x86/include/asm/bitops.h is currently using assembly constraints for the memory region bitops are modifying: 1) Use memory clobber in bitops that touch arbitrary

[PATCH 4.19 092/101] PCI: pciehp: Ignore Link State Changes after powering off a slot

2019-04-15 Thread Greg Kroah-Hartman
From: Sergey Miroshnichenko commit 3943af9d01e94330d0cfac6fccdbc829aad50c92 upstream. During a safe hot remove, the OS powers off the slot, which may cause a Data Link Layer State Changed event. The slot has already been set to OFF_STATE, so that event results in re-enabling the device, making

[PATCH 4.19 090/101] x86/perf/amd: Remove need to check "running" bit in NMI handler

2019-04-15 Thread Greg Kroah-Hartman
From: Lendacky, Thomas commit 3966c3feca3fd10b2935caa0b4a08c7dd59469e5 upstream. Spurious interrupt support was added to perf in the following commit, almost a decade ago: 63e6be6d98e1 ("perf, x86: Catch spurious interrupts after disabling counters") The two previous patches (resolving the

[PATCH 4.19 091/101] PCI: Add function 1 DMA alias quirk for Marvell 9170 SATA controller

2019-04-15 Thread Greg Kroah-Hartman
From: Andre Przywara commit 9cde402a59770a0669d895399c13407f63d7d209 upstream. There is a Marvell 88SE9170 PCIe SATA controller I found on a board here. Some quick testing with the ARM SMMU enabled reveals that it suffers from the same requester ID mixup problems as the other Marvell chips

[PATCH 4.19 084/101] sched/fair: Do not re-read ->h_load_next during hierarchical load calculation

2019-04-15 Thread Greg Kroah-Hartman
From: Mel Gorman commit 0e9f02450da07fc7b1346c8c32c771555173e397 upstream. A NULL pointer dereference bug was reported on a distribution kernel but the same issue should be present on mainline kernel. It occured on s390 but should not be arch-specific. A partial oops looks like: Unable to

[PATCH 4.19 081/101] arm64: dts: rockchip: fix rk3328 rgmii high tx error rate

2019-04-15 Thread Greg Kroah-Hartman
From: Peter Geis commit 6fd8b9780ec1a49ac46e0aaf8775247205e66231 upstream. Several rk3328 based boards experience high rgmii tx error rates. This is due to several pins in the rk3328.dtsi rgmii pinmux that are missing a defined pull strength setting. This causes the pinmux driver to default to

[PATCH 4.19 077/101] ARM: dts: am335x-evmsk: Correct the regulators for the audio codec

2019-04-15 Thread Greg Kroah-Hartman
From: Peter Ujfalusi commit 6691370646e844be98bb6558c024269791d20bd7 upstream. Correctly map the regulators used by tlv320aic3106. Both 1.8V and 3.3V for the codec is derived from VBAT via fixed regulators. Cc: # v4.14+ Signed-off-by: Peter Ujfalusi Signed-off-by: Tony Lindgren

[PATCH 4.19 079/101] ARM: dts: at91: Fix typo in ISC_D0 on PC9

2019-04-15 Thread Greg Kroah-Hartman
From: David Engraf commit e7dfb6d04e4715be1f3eb2c60d97b753fd2e4516 upstream. The function argument for the ISC_D0 on PC9 was incorrect. According to the documentation it should be 'C' aka 3. Signed-off-by: David Engraf Reviewed-by: Nicolas Ferre Signed-off-by: Ludovic Desroches Fixes:

[PATCH 4.19 097/101] arm64: dts: rockchip: fix vcc_host1_5v pin assign on rk3328-rock64

2019-04-15 Thread Greg Kroah-Hartman
From: Katsuhiro Suzuki commit ef05bcb60c1a8841e38c91923ba998181117a87c upstream. This patch fixes pin assign of vcc_host1_5v. This regulator is controlled by USB20_HOST_DRV signal. ROCK64 schematic says that GPIO0_A2 pin is used as USB20_HOST_DRV. GPIO0_D3 pin is for SPDIF_TX_M0.

[PATCH 4.19 082/101] arm64: backtrace: Dont bother trying to unwind the userspace stack

2019-04-15 Thread Greg Kroah-Hartman
From: Will Deacon commit 1e6f5440a6814d28c32d347f338bfef68bc3e69d upstream. Calling dump_backtrace() with a pt_regs argument corresponding to userspace doesn't make any sense and our unwinder will simply print "Call trace:" before unwinding the stack looking for user frames. Rather than go

[PATCH 4.19 096/101] dm integrity: fix deadlock with overlapping I/O

2019-04-15 Thread Greg Kroah-Hartman
From: Mikulas Patocka commit 4ed319c6ac08e9a28fca7ac188181ac122f4de84 upstream. dm-integrity will deadlock if overlapping I/O is issued to it, the bug was introduced by commit 724376a04d1a ("dm integrity: implement fair range locks"). Users rarely use overlapping I/O so this bug went

[PATCH 4.19 075/101] virtio: Honour may_reduce_num in vring_create_virtqueue

2019-04-15 Thread Greg Kroah-Hartman
From: Cornelia Huck commit cf94db21905333e610e479688add629397a4b384 upstream. vring_create_virtqueue() allows the caller to specify via the may_reduce_num parameter whether the vring code is allowed to allocate a smaller ring than specified. However, the split ring allocation code tries to

[PATCH 5.0 003/117] netfilter: nft_compat: use .release_ops and remove list of extension

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit b8e204006340b7aaf32bd2b9806c692f6e0cb38a ] Add .release_ops, that is called in case of error at a later stage in the expression initialization path, ie. .select_ops() has been already set up operations and that needs to be undone. This allows us to unwind .select_ops from the

[PATCH 4.19 100/101] KVM: x86: nVMX: close leak of L0s x2APIC MSRs (CVE-2019-3887)

2019-04-15 Thread Greg Kroah-Hartman
From: Marc Orr commit acff78477b9b4f26ecdf65733a4ed77fe837e9dc upstream. The nested_vmx_prepare_msr_bitmap() function doesn't directly guard the x2APIC MSR intercepts with the "virtualize x2APIC mode" MSR. As a result, we discovered the potential for a buggy or malicious L1 to get access to

[PATCH 4.19 095/101] dm table: propagate BDI_CAP_STABLE_WRITES to fix sporadic checksum errors

2019-04-15 Thread Greg Kroah-Hartman
From: Ilya Dryomov commit eb40c0acdc342b815d4d03ae6abb09e80c0f2988 upstream. Some devices don't use blk_integrity but still want stable pages because they do their own checksumming. Examples include rbd and iSCSI when data digests are negotiated. Stacking DM (and thus LVM) on top of these

[PATCH 5.0 008/117] ip6_tunnel: Match to ARPHRD_TUNNEL6 for dev type

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit b2e54b09a3d29c4db883b920274ca8dca4d9f04d ] The device type for ip6 tunnels is set to ARPHRD_TUNNEL6. However, the ip4ip6_err function is expecting the device type of the tunnel to be ARPHRD_TUNNEL. Since the device types do not match, the function exits and the ICMP error

[PATCH 5.0 011/117] kcm: switch order of device registration to fix a crash

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit 3c446e6f96997f2a95bf0037ef463802162d2323 ] When kcm is loaded while many processes try to create a KCM socket, a crash occurs: BUG: unable to handle kernel NULL pointer dereference at 000e IP: mutex_lock+0x27/0x40 kernel/locking/mutex.c:240 PGD 800016ef2067

[PATCH 5.0 006/117] hv_netvsc: Fix unwanted wakeup after tx_disable

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit 1b704c4a1ba95574832e730f23817b651db2aa59 ] After queue stopped, the wakeup mechanism may wake it up again when ring buffer usage is lower than a threshold. This may cause send path panic on NULL pointer when we stopped all tx queues in netvsc_detach and start removing the netvsc

[PATCH 5.0 009/117] ipv6: Fix dangling pointer when ipv6 fragment

2019-04-15 Thread Greg Kroah-Hartman
[ Upstream commit ef0efcd3bd3fd0589732b67fb586ffd3c8705806 ] At the beginning of ip6_fragment func, the prevhdr pointer is obtained in the ip6_find_1stfragopt func. However, all the pointers pointing into skb header may change when calling skb_checksum_help func with skb->ip_summed =

<    3   4   5   6   7   8   9   10   11   12   >