[PATCH 5.1 06/46] selftests/seccomp: Handle namespace failures gracefully

2019-05-15 Thread Greg Kroah-Hartman
From: Kees Cook commit 9dd3fcb0ab73cb1e00b8562ef027a38521aaff87 upstream. When running without USERNS or PIDNS the seccomp test would hang since it was waiting forever for the child to trigger the user notification since it seems the glibc() abort handler makes a call to getpid(), which would

Re: [PATCH 2/3] mmc: meson-gx: add ddr-access-quirk

2019-05-15 Thread Ulf Hansson
On Mon, 13 May 2019 at 11:16, Neil Armstrong wrote: > > On the Amlogic G12A SoC family, (only) the SDIO controller fails to access > the data from DDR, leading to a broken controller. Could you possibly make it more clear that this is about the internal DMA support in the controller that is

[PATCH 5.1 07/46] i2c: core: ratelimit transfer when suspended errors

2019-05-15 Thread Greg Kroah-Hartman
From: Wolfram Sang commit 4db61c2a16fce2ef85d82751de4ba43a39347cfb upstream. There are two problems with WARN_ON() here. One: It is not ratelimited. Two: We don't see which adapter was used when trying to transfer something when already suspended. Implement a custom ratelimit once per adapter

[PATCH 5.1 46/46] f2fs: Fix use of number of devices

2019-05-15 Thread Greg Kroah-Hartman
From: Damien Le Moal commit 0916878da355650d7e77104a7ac0fa1784eca852 upstream. For a single device mount using a zoned block device, the zone information for the device is stored in the sbi->devs single entry array and sbi->s_ndevs is set to 1. This differs from a single device mount using a

[PATCH 5.1 40/46] powerpc/powernv/idle: Restore IAMR after idle

2019-05-15 Thread Greg Kroah-Hartman
From: Russell Currey commit a3f3072db6cad40895c585dce65e36aab997f042 upstream. Without restoring the IAMR after idle, execution prevention on POWER9 with Radix MMU is overwritten and the kernel can freely execute userspace without faulting. This is necessary when returning from any stop state

[PATCH 5.1 41/46] powerpc/booke64: set RI in default MSR

2019-05-15 Thread Greg Kroah-Hartman
From: Laurentiu Tudor commit 5266e58d6cd90ac85c187d673093ad9cb649e16d upstream. Set RI in the default kernel's MSR so that the architected way of detecting unrecoverable machine check interrupts has a chance to work. This is inline with the MSR setup of the rest of booke powerpc architectures

[PATCH 5.1 45/46] PCI: hv: Add pci_destroy_slot() in pci_devices_present_work(), if necessary

2019-05-15 Thread Greg Kroah-Hartman
From: Dexuan Cui commit 340d455699400f2c2c0f9b3f703ade3085cdb501 upstream. When we hot-remove a device, usually the host sends us a PCI_EJECT message, and a PCI_BUS_RELATIONS message with bus_rel->device_count == 0. When we execute the quick hot-add/hot-remove test, the host may not send us

[PATCH 5.1 39/46] powerpc/book3s/64: check for NULL pointer in pgd_alloc()

2019-05-15 Thread Greg Kroah-Hartman
From: Rick Lindsley commit f39356261c265a0689d7ee568132d516e8b6cecc upstream. When the memset code was added to pgd_alloc(), it failed to consider that kmem_cache_alloc() can return NULL. It's uncommon, but not impossible under heavy memory contention. Example oops: Unable to handle kernel

Re: [RFC PATCH] kbuild: check uniqueness of basename of modules

2019-05-15 Thread Greg KH
On Wed, May 15, 2019 at 05:57:50PM +0900, Masahiro Yamada wrote: > On Wed, May 15, 2019 at 5:14 PM Greg KH wrote: > > > > On Wed, May 15, 2019 at 10:08:12AM +0200, Arnd Bergmann wrote: > > > On Wed, May 15, 2019 at 9:39 AM Masahiro Yamada > > > wrote: > > > > > > > > In the recent build test of

[PATCH 5.1 35/46] flow_dissector: disable preemption around BPF calls

2019-05-15 Thread Greg Kroah-Hartman
From: Eric Dumazet [ Upstream commit b1c17a9a353878602fd5bfe9103e4afe5e9a3f96 ] Various things in eBPF really require us to disable preemption before running an eBPF program. syzbot reported : BUG: assuming atomic context at net/core/flow_dissector.c:737 in_atomic(): 0, irqs_disabled(): 0,

[PATCH 5.1 37/46] drivers/virt/fsl_hypervisor.c: dereferencing error pointers in ioctl

2019-05-15 Thread Greg Kroah-Hartman
From: Dan Carpenter commit c8ea3663f7a8e6996d44500ee818c9330ac4fd88 upstream. strndup_user() returns error pointers on error, and then in the error handling we pass the error pointers to kfree(). It will cause an Oops. Link: http://lkml.kernel.org/r/20181218082003.GD32567@kadam Fixes:

[PATCH 5.1 28/46] vrf: sit mtu should not be updated when vrf netdev is the link

2019-05-15 Thread Greg Kroah-Hartman
From: Stephen Suryaputra [ Upstream commit ff6ab32bd4e073976e4d8797b4d514a172cfe6cb ] VRF netdev mtu isn't typically set and have an mtu of 65536. When the link of a tunnel is set, the tunnel mtu is changed from 1480 to the link mtu minus tunnel header. In the case of VRF netdev is the link,

[PATCH 5.1 36/46] isdn: bas_gigaset: use usb_fill_int_urb() properly

2019-05-15 Thread Greg Kroah-Hartman
From: Paul Bolle [ Upstream commit 4014dfae3ccaaf3ec19c9ae0691a3f14e7132eae ] The switch to make bas_gigaset use usb_fill_int_urb() - instead of filling that urb "by hand" - missed the subtle ordering of the previous code. See, before the switch urb->dev was set to a member somewhere deep in a

[PATCH 5.1 43/46] PCI: hv: Fix a memory leak in hv_eject_device_work()

2019-05-15 Thread Greg Kroah-Hartman
From: Dexuan Cui commit 05f151a73ec2b23ffbff706e5203e729a995cdc2 upstream. When a device is created in new_pcichild_device(), hpdev->refs is set to 2 (i.e. the initial value of 1 plus the get_pcichild()). When we hot remove the device from the host, in a Linux VM we first call

[PATCH 5.1 44/46] PCI: hv: Add hv_pci_remove_slots() when we unload the driver

2019-05-15 Thread Greg Kroah-Hartman
From: Dexuan Cui commit 15becc2b56c6eda3d9bf5ae993bafd5661c1fad1 upstream. When we unload the pci-hyperv host controller driver, the host does not send us a PCI_EJECT message. In this case we also need to make sure the sysfs PCI slot directory is removed, otherwise a command on a slot file eg:

[PATCH 4.4 097/266] net: ks8851: Reassert reset pin if chip ID check fails

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit 761cfa979a0c177d6c2d93ef5585cd79ae49a7d5 ] Commit 73fdeb82e963 ("net: ks8851: Add optional vdd_io regulator and reset gpio") amended the ks8851 driver to briefly assert the chip's reset pin on probe. It also amended the probe routine's error path to reassert the reset pin if a

[PATCH 5.1 38/46] drivers/virt/fsl_hypervisor.c: prevent integer overflow in ioctl

2019-05-15 Thread Greg Kroah-Hartman
From: Dan Carpenter commit 6a024330650e24556b8a18cc654ad00cfecf6c6c upstream. The "param.count" value is a u64 thatcomes from the user. The code later in the function assumes that param.count is at least one and if it's not then it leads to an Oops when we dereference the ZERO_SIZE_PTR. Also

[PATCH 5.1 09/46] virt: vbox: Sanity-check parameter types for hgcm-calls coming from userspace

2019-05-15 Thread Greg Kroah-Hartman
From: Hans de Goede commit cf4f2ad6b87dda2dbe0573b1ebeb0273f8d4aac6 upstream. Userspace can make host function calls, called hgcm-calls through the /dev/vboxguest device. In this case we should not accept all hgcm-function-parameter-types, some are only valid for in kernel calls. This commit

[PATCH 5.1 33/46] tuntap: synchronize through tfiles array instead of tun->numqueues

2019-05-15 Thread Greg Kroah-Hartman
From: Jason Wang [ Upstream commit 9871a9e47a2646fe30ae7fd2e67668a8d30912f6 ] When a queue(tfile) is detached through __tun_detach(), we move the last enabled tfile to the position where detached one sit but don't NULL out last position. We expect to synchronize the datapath through

Re: [PATCH] powerpc: Remove double free

2019-05-15 Thread Greg Kroah-Hartman
On Wed, May 15, 2019 at 11:26:03AM +0200, Christophe Leroy wrote: > kobject_put() released index_dir->kobj Yes, but what is that kobject enclosed in? > but who will release 'index' ? The final kobject_put() will do that, see cacheinfo_create_index_dir() for the details. And please do not

[PATCH 5.1 00/46] 5.1.3-stable review

2019-05-15 Thread Greg Kroah-Hartman
This is the start of the stable review cycle for the 5.1.3 release. There are 46 patches in this series, all will be posted as a response to this one. If anyone has any issues with these being applied, please let me know. Responses should be made by Fri 17 May 2019 09:04:22 AM UTC. Anything

[PATCH 5.1 34/46] net: phy: fix phy_validate_pause

2019-05-15 Thread Greg Kroah-Hartman
From: Heiner Kallweit [ Upstream commit b4010af981ac8cdf1f7f58eb6b131c482e5dee02 ] We have valid scenarios where ETHTOOL_LINK_MODE_Pause_BIT doesn't need to be supported. Therefore extend the first check to check for rx_pause being set. See also phy_set_asym_pause: rx=0 and tx=1: advertise

[PATCH 5.1 08/46] kernfs: fix barrier usage in __kernfs_new_node()

2019-05-15 Thread Greg Kroah-Hartman
From: Andrea Parri commit 998267900cee901c5d1dfa029a6304d00acbc29f upstream. smp_mb__before_atomic() can not be applied to atomic_set(). Remove the barrier and rely on RELEASE synchronization. Fixes: ba16b2846a8c6 ("kernfs: add an API to get kernfs node from inode number") Cc:

[PATCH 5.1 42/46] virtio_ring: Fix potential mem leak in virtqueue_add_indirect_packed

2019-05-15 Thread Greg Kroah-Hartman
From: YueHaibing commit df0bfe7501e9319546ea380d39674a4179e059c3 upstream. 'desc' should be freed before leaving from err handing path. Fixes: 1ce9e6055fa0 ("virtio_ring: introduce packed ring support") Signed-off-by: YueHaibing Signed-off-by: Michael S. Tsirkin Acked-by: Jason Wang

[PATCH 5.1 05/46] hwmon: (occ) Fix extended status bits

2019-05-15 Thread Greg Kroah-Hartman
From: Lei YU commit b88c5049219a7f322bb1fd65fc30d17472a23563 upstream. The occ's extended status is checked and shown as sysfs attributes. But the code was incorrectly checking the "status" bits. Fix it by checking the "ext_status" bits. Cc: sta...@vger.kernel.org Fixes: df04ced684d4 ("hwmon

[PATCH 5.1 32/46] tuntap: fix dividing by zero in ebpf queue selection

2019-05-15 Thread Greg Kroah-Hartman
From: Jason Wang [ Upstream commit a35d310f03a692bf4798eb309a1950a06a150620 ] We need check if tun->numqueues is zero (e.g for the persist device) before trying to use it for modular arithmetic. Reported-by: Eric Dumazet Fixes: 96f84061620c6("tun: add eBPF based queue selection method")

[PATCH 5.1 04/46] hwmon: (pwm-fan) Disable PWM if fetching cooling data fails

2019-05-15 Thread Greg Kroah-Hartman
From: Stefan Wahren commit 53f1647da3e8fb3e89066798f0fdc045064d353d upstream. In case pwm_fan_of_get_cooling_data() fails we should disable the PWM just like in the other error cases. Fixes: 2e5219c77183 ("hwmon: (pwm-fan) Read PWM FAN configuration from device tree") Cc: # 4.14+

Re: INFO: task hung in __get_super

2019-05-15 Thread Tetsuo Handa
On 2019/05/15 19:21, Jan Kara wrote: > The question is how to fix this problem. The simplest fix I can see is that > we'd just refuse to do LOOP_SET_FD if someone has the block device > exclusively open as there are high chances such user will be unpleasantly > surprised by the device changing

[PATCH 5.1 03/46] platform/x86: dell-laptop: fix rfkill functionality

2019-05-15 Thread Greg Kroah-Hartman
From: Mario Limonciello commit 6cc13c28da5beee0f706db6450e190709700b34a upstream. When converting the driver two arguments were transposed leading to rfkill not working. BugLink: https://bugzilla.kernel.org/show_bug.cgi?id=201427 Reported-by: Pepijn de Vos Fixes: 549b49 ("platform/x86:

[PATCH 5.0 126/137] flow_dissector: disable preemption around BPF calls

2019-05-15 Thread Greg Kroah-Hartman
From: Eric Dumazet [ Upstream commit b1c17a9a353878602fd5bfe9103e4afe5e9a3f96 ] Various things in eBPF really require us to disable preemption before running an eBPF program. syzbot reported : BUG: assuming atomic context at net/core/flow_dissector.c:737 in_atomic(): 0, irqs_disabled(): 0,

[PATCH 5.1 24/46] packet: Fix error path in packet_init

2019-05-15 Thread Greg Kroah-Hartman
From: YueHaibing [ Upstream commit 36096f2f4fa05f7678bc87397665491700bae757 ] kernel BUG at lib/list_debug.c:47! invalid opcode: [#1 CPU: 0 PID: 12914 Comm: rmmod Tainted: GW 5.1.0+ #47 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS

[PATCH 5.1 23/46] net: ucc_geth - fix Oops when changing number of buffers in the ring

2019-05-15 Thread Greg Kroah-Hartman
From: Christophe Leroy [ Upstream commit ee0df19305d9fabd9479b785918966f6e25b733b ] When changing the number of buffers in the RX ring while the interface is running, the following Oops is encountered due to the new number of buffers being taken into account immediately while their allocation

[PATCH 5.1 22/46] net: seeq: fix crash caused by not set dev.parent

2019-05-15 Thread Greg Kroah-Hartman
From: Thomas Bogendoerfer [ Upstream commit 5afcd14cfc7fed1bcc8abcee2cef82732772bfc2 ] The old MIPS implementation of dma_cache_sync() didn't use the dev argument, but commit c9eb6172c328 ("dma-mapping: turn dma_cache_sync into a dma_map_ops method") changed that, so we now need to set

[PATCH 5.1 25/46] selinux: do not report error on connect(AF_UNSPEC)

2019-05-15 Thread Greg Kroah-Hartman
From: Paolo Abeni [ Upstream commit c7e0d6cca86581092cbbf2cd868b3601495554cf ] calling connect(AF_UNSPEC) on an already connected TCP socket is an established way to disconnect() such socket. After commit 68741a8adab9 ("selinux: Fix ltp test connect-syscall failure") it no longer works and, in

[PATCH 5.1 13/46] Dont jump to compute_result state from check_result state

2019-05-15 Thread Greg Kroah-Hartman
From: Nigel Croxon commit 4f4fd7c5798bbdd5a03a60f6269cf1177fbd11ef upstream. Changing state from check_state_check_result to check_state_compute_result not only is unsafe but also doesn't appear to serve a valid purpose. A raid6 check should only be pushing out extra writes if doing repair and

[PATCH 5.1 15/46] bridge: Fix error path for kobject_init_and_add()

2019-05-15 Thread Greg Kroah-Hartman
From: "Tobin C. Harding" [ Upstream commit bdfad5aec1392b93495b77b864d58d7f101dc1c1 ] Currently error return from kobject_init_and_add() is not followed by a call to kobject_put(). This means there is a memory leak. We currently set p to NULL so that kfree() may be called on it as a noop, the

[PATCH 5.0 121/137] aqc111: fix writing to the phy on BE

2019-05-15 Thread Greg Kroah-Hartman
From: Oliver Neukum [ Upstream commit 369b46e9fbcfa5136f2cb5f486c90e5f7fa92630 ] When writing to the phy on BE architectures an internal data structure was directly given, leading to it being byte swapped in the wrong way for the CPU in 50% of all cases. A temporary buffer must be used.

[PATCH 5.0 127/137] isdn: bas_gigaset: use usb_fill_int_urb() properly

2019-05-15 Thread Greg Kroah-Hartman
From: Paul Bolle [ Upstream commit 4014dfae3ccaaf3ec19c9ae0691a3f14e7132eae ] The switch to make bas_gigaset use usb_fill_int_urb() - instead of filling that urb "by hand" - missed the subtle ordering of the previous code. See, before the switch urb->dev was set to a member somewhere deep in a

[PATCH 5.1 18/46] ipv4: Fix raw socket lookup for local traffic

2019-05-15 Thread Greg Kroah-Hartman
From: David Ahern [ Upstream commit 19e4e768064a87b073a4b4c138b55db70e0cfb9f ] inet_iif should be used for the raw socket lookup. inet_iif considers rt_iif which handles the case of local traffic. As it stands, ping to a local address with the '-I ' option fails ever since ping was changed to

[PATCH 5.1 11/46] mwl8k: Fix rate_idx underflow

2019-05-15 Thread Greg Kroah-Hartman
From: Petr Štetiar commit 6b583201fa219b7b1b6aebd8966c8fd9357ef9f4 upstream. It was reported on OpenWrt bug tracking system[1], that several users are affected by the endless reboot of their routers if they configure 5GHz interface with channel 44 or 48. The reboot loop is caused by the

[PATCH 5.1 16/46] dpaa_eth: fix SG frame cleanup

2019-05-15 Thread Greg Kroah-Hartman
From: Laurentiu Tudor [ Upstream commit 17170e6570c082717c142733d9a638bcd20551f8 ] Fix issue with the entry indexing in the sg frame cleanup code being off-by-1. This problem showed up when doing some basic iperf tests and manifested in traffic coming to a halt. Signed-off-by: Laurentiu Tudor

[PATCH 5.1 01/46] platform/x86: sony-laptop: Fix unintentional fall-through

2019-05-15 Thread Greg Kroah-Hartman
From: Gustavo A. R. Silva commit 1cbd7a64959d33e7a2a1fa2bf36a62b350a9fcbd upstream. It seems that the default case should return AE_CTRL_TERMINATE, instead of falling through to case ACPI_RESOURCE_TYPE_END_TAG and returning AE_OK; otherwise the line of code at the end of the function is

[PATCH 5.0 130/137] powerpc/book3s/64: check for NULL pointer in pgd_alloc()

2019-05-15 Thread Greg Kroah-Hartman
From: Rick Lindsley commit f39356261c265a0689d7ee568132d516e8b6cecc upstream. When the memset code was added to pgd_alloc(), it failed to consider that kmem_cache_alloc() can return NULL. It's uncommon, but not impossible under heavy memory contention. Example oops: Unable to handle kernel

[PATCH 5.0 128/137] drivers/virt/fsl_hypervisor.c: dereferencing error pointers in ioctl

2019-05-15 Thread Greg Kroah-Hartman
From: Dan Carpenter commit c8ea3663f7a8e6996d44500ee818c9330ac4fd88 upstream. strndup_user() returns error pointers on error, and then in the error handling we pass the error pointers to kfree(). It will cause an Oops. Link: http://lkml.kernel.org/r/20181218082003.GD32567@kadam Fixes:

[PATCH 5.0 134/137] PCI: hv: Fix a memory leak in hv_eject_device_work()

2019-05-15 Thread Greg Kroah-Hartman
From: Dexuan Cui commit 05f151a73ec2b23ffbff706e5203e729a995cdc2 upstream. When a device is created in new_pcichild_device(), hpdev->refs is set to 2 (i.e. the initial value of 1 plus the get_pcichild()). When we hot remove the device from the host, in a Linux VM we first call

[PATCH 5.0 137/137] f2fs: Fix use of number of devices

2019-05-15 Thread Greg Kroah-Hartman
From: Damien Le Moal commit 0916878da355650d7e77104a7ac0fa1784eca852 upstream. For a single device mount using a zoned block device, the zone information for the device is stored in the sbi->devs single entry array and sbi->s_ndevs is set to 1. This differs from a single device mount using a

[PATCH 5.0 079/137] dmaengine: bcm2835: Avoid GFP_KERNEL in device_prep_slave_sg

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit f147384774a7b24dda4783a3dcd61af272757ea8 ] The commit af19b7ce76ba ("mmc: bcm2835: Avoid possible races on data requests") introduces a possible circular locking dependency, which is triggered by swapping to the sdhost interface. So instead of reintroduce the race condition

[PATCH 5.0 120/137] aqc111: fix endianness issue in aqc111_change_mtu

2019-05-15 Thread Greg Kroah-Hartman
From: Oliver Neukum [ Upstream commit b8b277525e9df2fd2dc3d1f4fe01c6796bb107fc ] If the MTU is large enough, the first write to the device is just repeated. On BE architectures, however, the first word of the command will be swapped a second time and garbage will be written. Avoid that.

[PATCH 5.0 131/137] powerpc/powernv/idle: Restore IAMR after idle

2019-05-15 Thread Greg Kroah-Hartman
From: Russell Currey commit a3f3072db6cad40895c585dce65e36aab997f042 upstream. Without restoring the IAMR after idle, execution prevention on POWER9 with Radix MMU is overwritten and the kernel can freely execute userspace without faulting. This is necessary when returning from any stop state

[PATCH 5.0 135/137] PCI: hv: Add hv_pci_remove_slots() when we unload the driver

2019-05-15 Thread Greg Kroah-Hartman
From: Dexuan Cui commit 15becc2b56c6eda3d9bf5ae993bafd5661c1fad1 upstream. When we unload the pci-hyperv host controller driver, the host does not send us a PCI_EJECT message. In this case we also need to make sure the sysfs PCI slot directory is removed, otherwise a command on a slot file eg:

[PATCH 5.0 133/137] virtio_ring: Fix potential mem leak in virtqueue_add_indirect_packed

2019-05-15 Thread Greg Kroah-Hartman
From: YueHaibing commit df0bfe7501e9319546ea380d39674a4179e059c3 upstream. 'desc' should be freed before leaving from err handing path. Fixes: 1ce9e6055fa0 ("virtio_ring: introduce packed ring support") Signed-off-by: YueHaibing Signed-off-by: Michael S. Tsirkin Acked-by: Jason Wang

[PATCH 5.0 123/137] tuntap: fix dividing by zero in ebpf queue selection

2019-05-15 Thread Greg Kroah-Hartman
From: Jason Wang [ Upstream commit a35d310f03a692bf4798eb309a1950a06a150620 ] We need check if tun->numqueues is zero (e.g for the persist device) before trying to use it for modular arithmetic. Reported-by: Eric Dumazet Fixes: 96f84061620c6("tun: add eBPF based queue selection method")

[PATCH 5.0 122/137] aqc111: fix double endianness swap on BE

2019-05-15 Thread Greg Kroah-Hartman
From: Oliver Neukum [ Upstream commit 2cf672709beb005f6e90cb4edbed6f2218ba953e ] If you are using a function that does a swap in place, you cannot just reuse the buffer on the assumption that it has not been changed. Signed-off-by: Oliver Neukum Signed-off-by: David S. Miller Signed-off-by:

[PATCH 5.0 081/137] gpu: ipu-v3: dp: fix CSC handling

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit d4fad0a426c6e26f48c9a7cdd21a7fe9c198d645 ] Initialize the flow input colorspaces to unknown and reset to that value when the channel gets disabled. This avoids the state getting mixed up with a previous mode. Also keep the CSC settings for the background flow intact when

[PATCH 5.0 082/137] drm/imx: dont skip DP channel disable for background plane

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit 7bcde275eb1d0ac8793c77c7e666a886eb16633d ] In order to make sure that the plane color space gets reset correctly. Signed-off-by: Lucas Stach Signed-off-by: Philipp Zabel Signed-off-by: Sasha Levin --- drivers/gpu/drm/imx/ipuv3-crtc.c | 2 +- 1 file changed, 1 insertion(+),

[PATCH 5.0 112/137] net: macb: Change interrupt and napi enable order in open

2019-05-15 Thread Greg Kroah-Hartman
From: Harini Katakam [ Upstream commit 0504453139ef5a593c9587e1e851febee859c7d8 ] Current order in open: -> Enable interrupts (macb_init_hw) -> Enable NAPI -> Start PHY Sequence of RX handling: -> RX interrupt occurs -> Interrupt is cleared and interrupt bits disabled in handler -> NAPI is

[PATCH 5.0 116/137] selinux: do not report error on connect(AF_UNSPEC)

2019-05-15 Thread Greg Kroah-Hartman
From: Paolo Abeni [ Upstream commit c7e0d6cca86581092cbbf2cd868b3601495554cf ] calling connect(AF_UNSPEC) on an already connected TCP socket is an established way to disconnect() such socket. After commit 68741a8adab9 ("selinux: Fix ltp test connect-syscall failure") it no longer works and, in

[PATCH 5.0 115/137] packet: Fix error path in packet_init

2019-05-15 Thread Greg Kroah-Hartman
From: YueHaibing [ Upstream commit 36096f2f4fa05f7678bc87397665491700bae757 ] kernel BUG at lib/list_debug.c:47! invalid opcode: [#1 CPU: 0 PID: 12914 Comm: rmmod Tainted: GW 5.1.0+ #47 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS

[PATCH 5.0 118/137] vlan: disable SIOCSHWTSTAMP in container

2019-05-15 Thread Greg Kroah-Hartman
From: Hangbin Liu [ Upstream commit 873017af778439f2f8e3d87f28ddb1fcaf244a76 ] With NET_ADMIN enabled in container, a normal user could be mapped to root and is able to change the real device's rx filter via ioctl on vlan, which would affect the other ptp process on host. Fix it by disabling

[PATCH 5.0 108/137] fib_rules: return 0 directly if an exactly same rule exists when NLM_F_EXCL not supplied

2019-05-15 Thread Greg Kroah-Hartman
From: Hangbin Liu [ Upstream commit e9919a24d3022f72bcadc407e73a6ef17093a849 ] With commit 153380ec4b9 ("fib_rules: Added NLM_F_EXCL support to fib_nl_newrule") we now able to check if a rule already exists. But this only works with iproute2. For other tools like libnl, NetworkManager, it still

[PATCH 5.0 101/137] cw1200: fix missing unlock on error in cw1200_hw_scan()

2019-05-15 Thread Greg Kroah-Hartman
From: Wei Yongjun commit 51c8d24101c79ffce3e79137e2cee5dfeb956dd7 upstream. Add the missing unlock before return from function cw1200_hw_scan() in the error handling case. Fixes: 4f68ef64cd7f ("cw1200: Fix concurrency use-after-free bugs in cw1200_hw_scan()") Signed-off-by: Wei Yongjun

[PATCH 5.0 107/137] dpaa_eth: fix SG frame cleanup

2019-05-15 Thread Greg Kroah-Hartman
From: Laurentiu Tudor [ Upstream commit 17170e6570c082717c142733d9a638bcd20551f8 ] Fix issue with the entry indexing in the sg frame cleanup code being off-by-1. This problem showed up when doing some basic iperf tests and manifested in traffic coming to a halt. Signed-off-by: Laurentiu Tudor

[PATCH 5.0 076/137] selftests/net: correct the return value for run_afpackettests

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit 8c03557c3f25271e62e39154af66ebdd1b59c9ca ] The run_afpackettests will be marked as passed regardless the return value of those sub-tests in the script: running psock_tpacket test [FAIL] selftests: run_afpackettests

[PATCH 5.0 100/137] drm/rockchip: fix for mailbox read validation.

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit e4056bbb6719fe713bfc4030ac78e8e97ddf7574 ] This is basically the same fix as in commit fa68d4f8476b ("drm/rockchip: fix for mailbox read size") but for cdn_dp_mailbox_validate_receive function. See patchwork.kernel.org/patch/10671981/ for details. Signed-off-by: Damian Kos

[PATCH 5.0 103/137] rtlwifi: rtl8723ae: Fix missing break in switch statement

2019-05-15 Thread Greg Kroah-Hartman
From: Gustavo A. R. Silva commit 84242b82d81c54e009a2aaa74d3d9eff70babf56 upstream. Add missing break statement in order to prevent the code from falling through to case 0x1025, and erroneously setting rtlhal->oem_id to RT_CID_819X_ACER when rtlefuse->eeprom_svid is equal to 0x10EC and none of

[PATCH 5.0 093/137] gpio: Fix gpiochip_add_data_with_key() error path

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit 357798909164bf423eac6a78ff7da7e98d2d7f7f ] The err_remove_chip block is too coarse, and may perform cleanup that must not be done. E.g. if of_gpiochip_add() fails, of_gpiochip_remove() is still called, causing: OF: ERROR: Bad of_node_put() on /soc/gpio@e605 CPU: 1

[PATCH 5.0 105/137] bonding: fix arp_validate toggling in active-backup mode

2019-05-15 Thread Greg Kroah-Hartman
From: Jarod Wilson [ Upstream commit a9b8a2b39ce65df45687cf9ef648885c2a99fe75 ] There's currently a problem with toggling arp_validate on and off with an active-backup bond. At the moment, you can start up a bond, like so: modprobe bonding mode=1 arp_interval=100 arp_validate=0

[PATCH 5.0 096/137] mm/page_alloc.c: avoid potential NULL pointer dereference

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit 8139ad043d632c0e9e12d760068a7a8e91659aa1 ] ac.preferred_zoneref->zone passed to alloc_flags_nofragment() can be NULL. 'zone' pointer unconditionally derefernced in alloc_flags_nofragment(). Bail out on NULL zone to avoid potential crash. Currently we don't see any crashes only

[PATCH 5.0 085/137] spi: Micrel eth switch: declare missing of table

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit 2f23a2a768bee7ad2ff1e9527c3f7e279e794a46 ] Add missing table for SPI driver relying on SPI device match since compatible is in a DT binding or in a DTS. Before this patch: modinfo drivers/net/phy/spi_ks8995.ko | grep alias alias: spi:ksz8795 alias:

[PATCH 5.0 097/137] bpf: only test gso type on gso packets

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit 4c3024debf62de4c6ac6d3cb4c0063be21d4f652 ] BPF can adjust gso only for tcp bytestreams. Fail on other gso types. But only on gso packets. It does not touch this field if !gso_size. Fixes: b90efd225874 ("bpf: only adjust gso_size on bytestream protocols") Signed-off-by: Willem

[PATCH 5.0 032/137] clocksource/drivers/npcm: select TIMER_OF

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit 99834eead2a04e93a120abb112542b87c42ff5e1 ] When this is disabled, we get a link failure: drivers/clocksource/timer-npcm7xx.o: In function `npcm7xx_timer_init': timer-npcm7xx.c:(.init.text+0xf): undefined reference to `timer_of_init' Fixes: 1c00289ecd12

[PATCH 5.0 073/137] drm/sun4i: Fix component unbinding and component master deletion

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit f5a9ed867c83875546c9aadd4ed8e785e9adcc3c ] For our component-backed driver to be properly removed, we need to delete the component master in sun4i_drv_remove and make sure to call component_unbind_all in the master's unbind so that all components are unbound when the master is.

[PATCH 5.0 075/137] selftests/net: correct the return value for run_netsocktests

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit 30c04d796b693e22405c38e9b78e9a364e4c77e6 ] The run_netsocktests will be marked as passed regardless the actual test result from the ./socket: selftests: net: run_netsocktests running socket test

[PATCH 5.0 034/137] selftests: fib_tests: Fix Command line is not complete errors

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit a5f622984a623df9a84cf43f6b098d8dd76fbe05 ] A couple of tests are verifying a route has been removed. The helper expects the prefix as the first part of the expected output. When checking that a route has been deleted the prefix is empty leading to an invalid ip command: $ ip

[PATCH 5.0 092/137] net: vrf: Fix operation not supported when set vrf mac

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit 6819e3f6d83a24777813b0d031ebe0861694db5a ] Vrf device is not able to change mac address now because lack of ndo_set_mac_address. Complete this in case some apps need to do this. Reported-by: Hui Wang Signed-off-by: Miaohe Lin Signed-off-by: David S. Miller Signed-off-by:

[PATCH 5.0 088/137] Revert "drm/virtio: drop prime import/export callbacks"

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit a0cecc23cfcbf2626497a8c8770856dd56b67917 ] This patch does more harm than good, as it breaks both Xwayland and gnome-shell with X11. Xwayland requires DRI3 & DRI3 requires PRIME. X11 crash for obscure double-free reason which are hard to debug (starting X11 by hand doesn't

[PATCH 5.0 091/137] Input: synaptics-rmi4 - fix possible double free

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit bce1a78423961fce676ac65540a31b6ffd179e6d ] The RMI4 function structure has been released in rmi_register_function if error occurs. However, it will be released again in the function rmi_create_function, which may result in a double-free bug. Signed-off-by: Pan Bian

[PATCH 5.0 089/137] drm/sun4i: Unbind components before releasing DRM and memory

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit e02bc29b2cfa7806830d6da8b2322cddd67e8dfe ] Our components may still be using the DRM device driver (if only to access our driver's private data), so make sure to unbind them before the final drm_dev_put. Also release our reserved memory after component unbind instead of before

[PATCH 5.0 064/137] selftests: netfilter: check icmp pkttoobig errors are set as related

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit becf2319f320cae43e20cf179cc51a355a0deb5f ] When an icmp error such as pkttoobig is received, conntrack checks if the "inner" header (header of packet that did not fit link mtu) is matches an existing connection, and, if so, sets that packet as being related to the conntrack

[PATCH 5.0 061/137] mm: fix inactive list balancing between NUMA nodes and cgroups

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit 3b991208b897f52507168374033771a984b947b1 ] During !CONFIG_CGROUP reclaim, we expand the inactive list size if it's thrashing on the node that is about to be reclaimed. But when cgroups are enabled, we suddenly ignore the node scope and use the cgroup scope only. The result is

[PATCH 5.0 057/137] perf tools: Fix map reference counting

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit b9abbdfa88024d52c8084d8f46ea4f161606c692 ] By calling maps__insert() we assume to get 2 references on the map, which we relese within maps__remove call. However if there's already same map name, we currently don't bump the reference and can crash, like: Program received

[PATCH 5.0 036/137] mISDN: Check address length before reading address family

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit 238ffdc49ef98b15819cfd5e3fb23194e3ea3d39 ] KMSAN will complain if valid address length passed to bind() is shorter than sizeof("struct sockaddr_mISDN"->family) bytes. Signed-off-by: Tetsuo Handa Signed-off-by: David S. Miller Signed-off-by: Sasha Levin ---

[PATCH 5.0 063/137] drm: bridge: dw-hdmi: Fix overflow workaround for Rockchip SoCs

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit d15d9fd02575ecfada92d42f655940c4f10af842 ] The Rockchip RK3288 SoC (v2.00a) and RK3328/RK3399 SoCs (v2.11a) have also been identified as needing this workaround with a single iteration. Fixes: be41fc55f1aa ("drm: bridge: dw-hdmi: Handle overflow workaround based on device

[PATCH 5.0 060/137] mm/hotplug: treat CMA pages as unmovable

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit 1a9f219157b22d0ffb340a9c5f431afd02cd2cf3 ] has_unmovable_pages() is used by allocating CMA and gigantic pages as well as the memory hotplug. The later doesn't know how to offline CMA pool properly now, but if an unused (free) CMA page is encountered, then has_unmovable_pages()

[PATCH 5.0 058/137] scsi: aic7xxx: fix EISA support

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit 144ec97493af34efdb77c5aba146e9c7de8d0a06 ] Instead of relying on the now removed NULL argument to pci_alloc_consistent, switch to the generic DMA API, and store the struct device so that we can pass it. Fixes: 4167b2ad5182 ("PCI: Remove NULL device handling from PCI DMA API")

[PATCH 5.0 066/137] netfilter: ctnetlink: dont use conntrack/expect object addresses as id

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit 3c79107631db1f7fd32cf3f7368e4672004a3010 ] else, we leak the addresses to userspace via ctnetlink events and dumps. Compute an ID on demand based on the immutable parts of nf_conn struct. Another advantage compared to using an address is that there is no immediate re-use of

[PATCH 5.0 031/137] drm/amd/display: extending AUX SW Timeout

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit f4bbebf8e7eb4d294b040ab2d2ba71e70e69b930 ] [Why] AUX takes longer to reply when using active DP-DVI dongle on some asics resulting in up to 2000+ us edid read (timeout). [How] 1. Adjust AUX poll to match spec 2. Extend the SW timeout. This does not affect normal operation since

[PATCH 5.0 068/137] netfilter: nat: fix icmp id randomization

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit 5bdac418f33f60b07a34e01e722889140ee8fac9 ] Sven Auhagen reported that a 2nd ping request will fail if 'fully-random' mode is used. Reason is that if no proto information is given, min/max are both 0, so we set the icmp id to 0 instead of chosing a random value between 0 and

[PATCH 5.0 067/137] netfilter: nf_tables: prevent shift wrap in nft_chain_parse_hook()

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit 33d1c018179d0a30c39cc5f1682b77867282694b ] I believe that "hook->num" can be up to UINT_MAX. Shifting more than 31 bits would is undefined in C but in practice it would lead to shift wrapping. That would lead to an array overflow in nf_tables_addchain(): ops->hook

[PATCH 5.0 069/137] MIPS: perf: ath79: Fix perfcount IRQ assignment

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit a1e8783db8e0d58891681bc1e6d9ada66eae8e20 ] Currently it's not possible to use perf on ath79 due to genirq flags mismatch happening on static virtual IRQ 13 which is used for performance counters hardware IRQ 5. On TP-Link Archer C7v5: CPU0 2: 0 MIPS

[PATCH 5.0 071/137] s390: ctcm: fix ctcm_new_device error return code

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit 27b141fc234a3670d21bd742c35d7205d03cbb3a ] clang points out that the return code from this function is undefined for one of the error paths: ../drivers/s390/net/ctcm_main.c:1595:7: warning: variable 'result' is used uninitialized whenever 'if' condition is true

[PATCH 5.0 054/137] perf top: Always sample time to satisfy needs of use of ordered queuing

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit 1e6db2ee86e6a4399fc0ae5689e55e0fd1c43caf ] Bastian reported broken 'perf top -p PID' command, it won't display any data. The problem is that for -p option we monitor single thread, so we don't enable time in samples, because it's not needed. However since commit 16c66bc167cc

[PATCH 5.0 055/137] ipmi: ipmi_si_hardcode.c: init si_type array to fix a crash

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit a885bcfd152f97b25005298ab2d6b741aed9b49c ] The intended behavior of function ipmi_hardcode_init_one() is to default to kcs interface when no type argument is presented when initializing ipmi with hard coded addresses. However, the array of char pointers allocated on the stack

[PATCH 5.0 052/137] KVM: x86: avoid misreporting level-triggered irqs as edge-triggered in tracing

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit 7a223e06b1a411cef6c4cd7a9b9a33c8d225b10e ] In __apic_accept_irq() interface trig_mode is int and actually on some code paths it is set above u8: kvm_apic_set_irq() extracts it from 'struct kvm_lapic_irq' where trig_mode is u16. This is done on purpose as e.g. kvm_set_msi_irq()

[PATCH 5.0 046/137] s390/pkey: add one more argument space for debug feature entry

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit 6b1f16ba730d4c0cda1247568c3a1bf4fa3a2f2f ] The debug feature entries have been used with up to 5 arguents (including the pointer to the format string) but there was only space reserved for 4 arguemnts. So now the registration does reserve space for 5 times a long value. This

[PATCH 5.0 029/137] s390/3270: fix lockdep false positive on view->lock

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit 5712f3301a12c0c3de9cc423484496b0464f2faf ] The spinlock in the raw3270_view structure is used by con3270, tty3270 and fs3270 in different ways. For con3270 the lock can be acquired in irq context, for tty3270 and fs3270 the highest context is bh. Lockdep sees the view->lock as

[PATCH 5.0 051/137] KVM: fix spectrev1 gadgets

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit 1d487e9bf8ba66a7174c56a0029c54b1eca8f99c ] These were found with smatch, and then generalized when applicable. Signed-off-by: Paolo Bonzini Signed-off-by: Sasha Levin --- arch/x86/kvm/lapic.c | 4 +++- include/linux/kvm_host.h | 10 ++ virt/kvm/irqchip.c |

[PATCH 5.0 048/137] x86/mm: Prevent bogus warnings with "noexec=off"

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit 510bb96fe5b3480b4b22d815786377e54cb701e7 ] Xose Vazquez Perez reported boot warnings when NX is disabled on the kernel command line. __early_set_fixmap() triggers this warning: attempted to set unsupported pgprot:8163 bits:

[PATCH 5.0 042/137] qed: Fix the doorbell address sanity check

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit b61b04ad81d5f975349d66abbecabf96ba211140 ] Fix the condition which verifies that doorbell address is inside the doorbell bar by checking that the end of the address is within range as well. Signed-off-by: Denis Bolotin Signed-off-by: Michal Kalderon Signed-off-by: Ariel Elior

[PATCH 5.0 043/137] qed: Fix missing DORQ attentions

2019-05-15 Thread Greg Kroah-Hartman
[ Upstream commit d4476b8a6151b2dd86c09b5acec64f66430db55d ] When the DORQ (doorbell block) is overflowed, all PFs get attentions at the same time. If one PF finished handling the attention before another PF even started, the second PF might miss the DORQ's attention bit and not handle the

<    5   6   7   8   9   10   11   12   13   14   >