[PATCH 5.4 012/142] net: qrtr: Fix passing invalid reference to qrtr_local_enqueue()

2020-06-01 Thread Greg Kroah-Hartman
From: Manivannan Sadhasivam [ Upstream commit d28ea1fbbf437054ef339afec241019f2c4e2bb6 ] Once the traversal of the list is completed with list_for_each_entry(), the iterator (node) will point to an invalid object. So passing this to qrtr_local_enqueue() which is outside of the iterator block is

[PATCH 5.4 027/142] net/tls: fix encryption error checking

2020-06-01 Thread Greg Kroah-Hartman
From: Vadim Fedorenko commit a7bff11f6f9afa87c25711db8050c9b5324db0e2 upstream. bpf_exec_tx_verdict() can return negative value for copied variable. In that case this value will be pushed back to caller and the real error code will be lost. Fix it using signed type and checking for positive

[PATCH 5.4 014/142] net sched: fix reporting the first-time use timestamp

2020-06-01 Thread Greg Kroah-Hartman
From: Roman Mashak [ Upstream commit b15e62631c5f19fea9895f7632dae9c1b27fe0cd ] When a new action is installed, firstuse field of 'tcf_t' is explicitly set to 0. Value of zero means "new action, not yet used"; as a packet hits the action, 'firstuse' is stamped with the current jiffies value.

[PATCH 5.4 031/142] mlxsw: spectrum: Fix use-after-free of split/unsplit/type_set in case reload fails

2020-06-01 Thread Greg Kroah-Hartman
From: Jiri Pirko commit 4340f42f207eacb81e7a6b6bb1e3b6afad9a2e26 upstream. In case of reload fail, the mlxsw_sp->ports contains a pointer to a freed memory (either by reload_down() or reload_up() error path). Fix this by initializing the pointer to NULL and checking it before dereferencing in

[PATCH 5.4 030/142] net/mlx4_core: fix a memory leak bug.

2020-06-01 Thread Greg Kroah-Hartman
From: Qiushi Wu commit febfd9d3c7f74063e8e630b15413ca91b567f963 upstream. In function mlx4_opreq_action(), pointer "mailbox" is not released, when mlx4_cmd_box() return and error, causing a memory leak bug. Fix this issue by going to "out" label, mlx4_free_cmd_mailbox() can free this pointer.

[PATCH 4.19 78/95] xfrm: fix a warning in xfrm_policy_insert_list

2020-06-01 Thread Greg Kroah-Hartman
From: Xin Long commit ed17b8d377eaf6b4a01d46942b4c647378a79bdd upstream. This waring can be triggered simply by: # ip xfrm policy update src 192.168.1.1/24 dst 192.168.1.2/24 dir in \ priority 1 mark 0 mask 0x10 #[1] # ip xfrm policy update src 192.168.1.1/24 dst 192.168.1.2/24 dir in

[PATCH 4.19 80/95] xfrm: fix error in comment

2020-06-01 Thread Greg Kroah-Hartman
From: Antony Antony commit 29e4276667e24ee6b91d9f91064d8fda9a210ea1 upstream. s/xfrm_state_offload/xfrm_user_offload/ Fixes: d77e38e612a ("xfrm: Add an IPsec hardware offloading API") Signed-off-by: Antony Antony Signed-off-by: Steffen Klassert Signed-off-by: Greg Kroah-Hartman ---

[PATCH 4.19 81/95] vti4: eliminated some duplicate code.

2020-06-01 Thread Greg Kroah-Hartman
From: Jeremy Sowden commit f981c57ffd2d7cf2dd4b6d6f8fcb3965df42f54c upstream. The ipip tunnel introduced in commit dd9ee3444014 ("vti4: Fix a ipip packet processing bug in 'IPCOMP' virtual tunnel") largely duplicated the existing vti_input and vti_recv functions. Refactored to deduplicate the

[PATCH 4.19 76/95] xfrm: call xfrm_output_gso when inner_protocol is set in xfrm_output

2020-06-01 Thread Greg Kroah-Hartman
From: Xin Long commit a204aef9fd77dce1efd9066ca4e44eede99cd858 upstream. An use-after-free crash can be triggered when sending big packets over vxlan over esp with esp offload enabled: [] BUG: KASAN: use-after-free in ipv6_gso_pull_exthdrs.part.8+0x32c/0x4e0 [] Call Trace: []

[PATCH 4.19 90/95] qlcnic: fix missing release in qlcnic_83xx_interrupt_test.

2020-06-01 Thread Greg Kroah-Hartman
From: Qiushi Wu commit 15c973858903009e995b2037683de29dfe968621 upstream. In function qlcnic_83xx_interrupt_test(), function qlcnic_83xx_diag_alloc_res() is not handled by function qlcnic_83xx_diag_free_res() after a call of the function qlcnic_alloc_mbx_args() failed. Fix this issue by adding

[PATCH 5.4 010/142] net: mvpp2: fix RX hashing for non-10G ports

2020-06-01 Thread Greg Kroah-Hartman
From: Russell King [ Upstream commit 3138a07ce219acde4c0d7ea0b6d54ba64153328b ] When rxhash is enabled on any ethernet port except the first in each CP block, traffic flow is prevented. The analysis is below: I've been investigating this afternoon, and what I've found, comparing a kernel

vimc: Add color descriptions to test image

2020-06-01 Thread Kaaira Gupta
On Mon, Jun 01, 2020 at 01:36:59PM -0300, Helen Koike wrote: > > > On 6/1/20 10:53 AM, Kaaira Gupta wrote: > > Hi! > > > > Currently there is no method to know if the test image generated by vimc > > is correct (except for comparing it with a known 'correct' image). So, I > > wanted to

[PATCH 4.19 89/95] xsk: Add overflow check for u64 division, stored into u32

2020-06-01 Thread Greg Kroah-Hartman
From: Björn Töpel commit b16a87d0aef7a6be766f6618976dc5ff2c689291 upstream. The npgs member of struct xdp_umem is an u32 entity, and stores the number of pages the UMEM consumes. The calculation of npgs npgs = size / PAGE_SIZE can overflow. To avoid overflow scenarios, the division is now

[PATCH 4.19 74/95] copy_xstate_to_kernel(): dont leave parts of destination uninitialized

2020-06-01 Thread Greg Kroah-Hartman
From: Al Viro commit 9e4636545933131de15e1ecd06733538ae939b2f upstream. copy the corresponding pieces of init_fpstate into the gaps instead. Cc: sta...@kernel.org Tested-by: Alexander Potapenko Acked-by: Borislav Petkov Signed-off-by: Al Viro Signed-off-by: Greg Kroah-Hartman ---

[PATCH 4.19 91/95] crypto: chelsio/chtls: properly set tp->lsndtime

2020-06-01 Thread Greg Kroah-Hartman
From: Eric Dumazet commit a4976a3ef844c510ae9120290b23e9f3f47d6bce upstream. TCP tp->lsndtime unit/base is tcp_jiffies32, not tcp_time_stamp() Fixes: 36bedb3f2e5b ("crypto: chtls - Inline TLS record Tx") Signed-off-by: Eric Dumazet Cc: Ayush Sawal Cc: Vinay Kumar Yadav Signed-off-by: David

[PATCH 4.19 93/95] Revert "Input: i8042 - add ThinkPad S230u to i8042 nomux list"

2020-06-01 Thread Greg Kroah-Hartman
From: Dmitry Torokhov commit f4dec2d6160976b14e54be9c3950ce0f52385741 upstream. This reverts commit 18931506465a762ffd3f4803d36a18d336a67da9. From Kevin Locke: "... nomux only appeared to fix the issue because the controller continued working after warm reboots. After more thorough testing

Re: Question: livepatch failed for new fork() task stack unreliable

2020-06-01 Thread Josh Poimboeuf
On Sat, May 30, 2020 at 10:21:19AM +0800, Wangshaobo (bobo) wrote: > 1) when a user mode task just fork start excuting ret_from_fork() till > schedule_tail, unwind_next_frame found > > orc->sp_reg is ORC_REG_UNDEFINED but orc->end not equals zero, this time > arch_stack_walk_reliable() > >

[PATCH 4.19 95/95] mm/vmalloc.c: dont dereference possible NULL pointer in __vunmap()

2020-06-01 Thread Greg Kroah-Hartman
From: Liviu Dudau commit 6ade20327dbb808882888ed8ccded71e93067cf9 upstream. find_vmap_area() can return a NULL pointer and we're going to dereference it without checking it first. Use the existing find_vm_area() function which does exactly what we want and checks for the NULL pointer. Link:

[PATCH 4.19 88/95] bnxt_en: Fix accumulation of bp->net_stats_prev.

2020-06-01 Thread Greg Kroah-Hartman
From: Michael Chan commit b8056e8434b037fdab08158fea99ed7bc8ef3a74 upstream. We have logic to maintain network counters across resets by storing the counters in bp->net_stats_prev before reset. But not all resets will clear the counters. Certain resets that don't need to change the number of

[PATCH 4.19 70/95] mmc: core: Fix recursive locking issue in CQE recovery path

2020-06-01 Thread Greg Kroah-Hartman
From: Sarthak Garg commit 39a22f73744d5baee30b5f134ae2e30b668b66ed upstream. Consider the following stack trace -001|raw_spin_lock_irqsave -002|mmc_blk_cqe_complete_rq -003|__blk_mq_complete_request(inline) -003|blk_mq_complete_request(rq) -004|mmc_cqe_timed_out(inline) -004|mmc_mq_timed_out

[PATCH 4.19 52/95] ARM: dts/imx6q-bx50v3: Set display interface clock parents

2020-06-01 Thread Greg Kroah-Hartman
From: Robert Beckett [ Upstream commit 665e7c73a7724a393b4ec92d1ae1e029925ef2b7 ] Avoid LDB and IPU DI clocks both using the same parent. LDB requires pasthrough clock to avoid breaking timing while IPU DI does not. Force IPU DI clocks to use IMX6QDL_CLK_PLL2_PFD0_352M as parent and LDB to use

[PATCH 4.19 62/95] ALSA: hda/realtek - Add new codec supported for ALC287

2020-06-01 Thread Greg Kroah-Hartman
From: Kailang Yang [ Upstream commit 630e36126e420e1756378b3427b42711ce0b9ddd ] Enable new codec supported for ALC287. Signed-off-by: Kailang Yang Cc: Link: https://lore.kernel.org/r/dcf5ce5507104d0589a917cbb71dc...@realtek.com Signed-off-by: Takashi Iwai Signed-off-by: Sasha Levin ---

Re: [GRUB PATCH RFC 00/18] i386: Intel TXT secure launcher

2020-06-01 Thread Ross Philipson
On 6/1/20 1:56 PM, Daniel P. Smith wrote: > On 6/1/20 12:51 PM, Andy Lutomirski wrote: >> On Mon, Jun 1, 2020 at 8:33 AM Daniel P. Smith >> wrote: >>> >>> On 5/7/20 7:06 AM, Daniel Kiper wrote: Hi Łukasz, On Tue, May 05, 2020 at 04:38:02PM +0200, Lukasz Hawrylko wrote: > On

[PATCH 4.19 50/95] gpio: exar: Fix bad handling for ida_simple_get error path

2020-06-01 Thread Greg Kroah-Hartman
From: Takashi Iwai [ Upstream commit 333830aa149a87cabeb5d30fbcf12eecc8040d2c ] The commit 7ecced0934e5 ("gpio: exar: add a check for the return value of ida_simple_get fails") added a goto jump to the common error handler for ida_simple_get() error, but this is wrong in two ways: it doesn't

[PATCH 4.19 84/95] netfilter: ipset: Fix subcounter update skip

2020-06-01 Thread Greg Kroah-Hartman
From: Phil Sutter commit a164b95ad6055c50612795882f35e0efda1f1390 upstream. If IPSET_FLAG_SKIP_SUBCOUNTER_UPDATE is set, user requested to not update counters in sub sets. Therefore IPSET_FLAG_SKIP_COUNTER_UPDATE must be set, not unset. Fixes: 6e01781d1c80e ("netfilter: ipset: set match: add

[PATCH 4.19 38/95] Input: i8042 - add ThinkPad S230u to i8042 nomux list

2020-06-01 Thread Greg Kroah-Hartman
From: Kevin Locke [ Upstream commit 18931506465a762ffd3f4803d36a18d336a67da9 ] On the Lenovo ThinkPad Twist S230u (3347-4HU) with BIOS version "GDETC1WW (1.81 ) 06/27/2019", whether booted in UEFI or Legacy/CSM mode the keyboard, Synaptics TouchPad, and TrackPoint either do not function or stop

[PATCH 4.19 83/95] netfilter: nft_reject_bridge: enable reject with bridge vlan

2020-06-01 Thread Greg Kroah-Hartman
From: Michael Braun commit e9c284ec4b41c827f4369973d2792992849e4fa5 upstream. Currently, using the bridge reject target with tagged packets results in untagged packets being sent back. Fix this by mirroring the vlan id as well. Fixes: 85f5b3086a04 ("netfilter: bridge: add reject support")

[PATCH 4.19 36/95] samples: bpf: Fix build error

2020-06-01 Thread Greg Kroah-Hartman
From: Matteo Croce [ Upstream commit 23ad04669f81f958e9a4121b0266228d2eb3c357 ] GCC 10 is very strict about symbol clash, and lwt_len_hist_user contains a symbol which clashes with libbpf: /usr/bin/ld: samples/bpf/lwt_len_hist_user.o:(.bss+0x0): multiple definition of `bpf_log_buf';

[PATCH 4.19 66/95] fs/binfmt_elf.c: allocate initialized memory in fill_thread_core_info()

2020-06-01 Thread Greg Kroah-Hartman
From: Alexander Potapenko [ Upstream commit 1d605416fb7175e1adf094251466caa52093b413 ] KMSAN reported uninitialized data being written to disk when dumping core. As a result, several kilobytes of kmalloc memory may be written to the core file and then read by a non-privileged user.

[PATCH 4.19 71/95] RDMA/core: Fix double destruction of uobject

2020-06-01 Thread Greg Kroah-Hartman
From: Jason Gunthorpe commit c85f4abe66bea0b5db8d28d55da760c4fe0a0301 upstream. Fix use after free when user user space request uobject concurrently for the same object, within the RCU grace period. In that case, remove_handle_idr_uobject() is called twice and we will have an extra put on the

[PATCH 4.19 68/95] iommu: Fix reference count leak in iommu_group_alloc.

2020-06-01 Thread Greg Kroah-Hartman
From: Qiushi Wu [ Upstream commit 7cc31613734c4870ae32f5265d576ef296621343 ] kobject_init_and_add() takes reference even when it fails. Thus, when kobject_init_and_add() returns an error, kobject_put() must be called to properly clean up the kobject. Fixes: d72e31c93746 ("iommu: IOMMU Groups")

[PATCH 4.19 51/95] IB/qib: Call kobject_put() when kobject_init_and_add() fails

2020-06-01 Thread Greg Kroah-Hartman
From: Kaike Wan [ Upstream commit a35cd6447effd5c239b564c80fa109d05ff3d114 ] When kobject_init_and_add() returns an error in the function qib_create_port_files(), the function kobject_put() is not called for the corresponding kobject, which potentially leads to memory leak. This patch fixes

[PATCH 4.19 54/95] ARM: dts: bcm: HR2: Fix PPI interrupt types

2020-06-01 Thread Greg Kroah-Hartman
From: Hamish Martin [ Upstream commit be0ec060b54f0481fb95d59086c1484a949c903c ] These error messages are output when booting on a BCM HR2 system: GIC: PPI11 is secure or misconfigured GIC: PPI13 is secure or misconfigured Per ARM documentation these interrupts are triggered on a

[PATCH 4.19 73/95] x86/dma: Fix max PFN arithmetic overflow on 32 bit systems

2020-06-01 Thread Greg Kroah-Hartman
From: Alexander Dahl commit 88743470668ef5eb6b7ba9e0f99888e5999bf172 upstream. The intermediate result of the old term (4UL * 1024 * 1024 * 1024) is 4 294 967 296 or 0x1 which is no problem on 64 bit systems. The patch does not change the later overall result of 0x10 for

[PATCH 4.19 47/95] ARM: uaccess: consolidate uaccess asm to asm/uaccess-asm.h

2020-06-01 Thread Greg Kroah-Hartman
From: Russell King [ Upstream commit 747ffc2fcf969eff9309d7f2d1d61cb8b9e1bb40 ] Consolidate the user access assembly code to asm/uaccess-asm.h. This moves the csdb, check_uaccess, uaccess_mask_range_ptr, uaccess_enable, uaccess_disable, uaccess_save, uaccess_restore macros, and creates two new

[PATCH 4.19 42/95] Input: i8042 - add ThinkPad S230u to i8042 reset list

2020-06-01 Thread Greg Kroah-Hartman
From: Kevin Locke [ Upstream commit 2712c91a54a1058d55c284152b4d93c979b67be6 ] On the Lenovo ThinkPad Twist S230u (3347-4HU) with BIOS version "GDETC1WW (1.81 ) 06/27/2019", the keyboard, Synaptics TouchPad, and TrackPoint either do not function or stop functioning a few minutes after boot.

[PATCH 4.19 41/95] Input: dlink-dir685-touchkeys - fix a typo in driver name

2020-06-01 Thread Greg Kroah-Hartman
From: Christophe JAILLET [ Upstream commit 38347374ae3f1ec4df56dd688bd603a64e79a0ed ] According to the file name and Kconfig, a 'k' is missing in this driver name. It should be "dlink-dir685-touchkeys". Fixes: 131b3de7016b ("Input: add D-Link DIR-685 touchkeys driver") Signed-off-by:

[PATCH 4.19 48/95] ARM: uaccess: integrate uaccess_save and uaccess_restore

2020-06-01 Thread Greg Kroah-Hartman
From: Russell King [ Upstream commit 8ede890b0bcebe8c760aacfe20e934d98c3dc6aa ] Integrate uaccess_save / uaccess_restore macros into the new uaccess_entry / uaccess_exit macros respectively. Signed-off-by: Russell King Signed-off-by: Sasha Levin --- arch/arm/include/asm/uaccess-asm.h | 30

[PATCH 4.19 03/95] net: dsa: mt7530: fix roaming from DSA user ports

2020-06-01 Thread Greg Kroah-Hartman
From: DENG Qingfang [ Upstream commit 5e5502e012b8129e11be616acb0f9c34bc8f8adb ] When a client moves from a DSA user port to a software port in a bridge, it cannot reach any other clients that connected to the DSA user ports. That is because SA learning on the CPU port is disabled, so the

[PATCH 4.19 24/95] gpio: tegra: mask GPIO IRQs during IRQ shutdown

2020-06-01 Thread Greg Kroah-Hartman
From: Stephen Warren [ Upstream commit 0cf253eed5d2bdf7bb3152457b38f39b012955f7 ] The driver currently leaves GPIO IRQs unmasked even when the GPIO IRQ client has released the GPIO IRQ. This allows the HW to raise IRQs, and SW to process them, after shutdown. Fix this by masking the IRQ when

[PATCH 4.19 46/95] ARM: 8843/1: use unified assembler in headers

2020-06-01 Thread Greg Kroah-Hartman
From: Stefan Agner [ Upstream commit c001899a5d6c2d7a0f3b75b2307ddef137fb46a6 ] Use unified assembler syntax (UAL) in headers. Divided syntax is considered deprecated. This will also allow to build the kernel using LLVM's integrated assembler. Signed-off-by: Stefan Agner Acked-by: Nicolas

[PATCH 4.19 21/95] arm64: dts: rockchip: swap interrupts interrupt-names rk3399 gpu node

2020-06-01 Thread Greg Kroah-Hartman
From: Johan Jonker [ Upstream commit c604fd810bda667bdc20b2c041917baa7803e0fb ] Dts files with Rockchip rk3399 'gpu' nodes were manually verified. In order to automate this process arm,mali-midgard.txt has been converted to yaml. In the new setup dtbs_check with arm,mali-midgard.yaml expects

[PATCH 4.19 26/95] net: microchip: encx24j600: add missed kthread_stop

2020-06-01 Thread Greg Kroah-Hartman
From: Chuhong Yuan [ Upstream commit ff8ce319e9c25e920d994cc35236f0bb32dfc8f3 ] This driver calls kthread_run() in probe, but forgets to call kthread_stop() in probe failure and remove. Add the missed kthread_stop() to fix it. Signed-off-by: Chuhong Yuan Signed-off-by: David S. Miller

[PATCH 4.19 06/95] net: ipip: fix wrong address family in init error path

2020-06-01 Thread Greg Kroah-Hartman
From: Vadim Fedorenko [ Upstream commit 57ebc8f08504f176eb0f25b3e0fde517dec61a4f ] In case of error with MPLS support the code is misusing AF_INET instead of AF_MPLS. Fixes: 1b69e7e6c4da ("ipip: support MPLS over IPv4") Signed-off-by: Vadim Fedorenko Signed-off-by: David S. Miller

[PATCH 4.19 31/95] usb: gadget: legacy: fix redundant initialization warnings

2020-06-01 Thread Greg Kroah-Hartman
From: Masahiro Yamada [ Upstream commit d13cce757954fa663c69845611957396843ed87a ] Fix the following cppcheck warnings: drivers/usb/gadget/legacy/inode.c:1364:8: style: Redundant initialization for 'value'. The initialized value is overwritten$ value = -EOPNOTSUPP; ^

[PATCH 4.19 00/95] 4.19.126-rc1 review

2020-06-01 Thread Greg Kroah-Hartman
This is the start of the stable review cycle for the 4.19.126 release. There are 95 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 Wed, 03 Jun 2020 17:38:19 +. Anything

[PATCH 4.19 05/95] net: inet_csk: Fix so_reuseport bind-address cache in tb->fast*

2020-06-01 Thread Greg Kroah-Hartman
From: Martin KaFai Lau [ Upstream commit 88d7fcfa3b1fe670f0412b95be785aafca63352b ] The commit 637bc8bbe6c0 ("inet: reset tb->fastreuseport when adding a reuseport sk") added a bind-address cache in tb->fast*. The tb->fast* caches the address of a sk which has successfully been binded with

[PATCH 4.19 25/95] ALSA: usb-audio: add mapping for ASRock TRX40 Creator

2020-06-01 Thread Greg Kroah-Hartman
From: Andrew Oakley [ Upstream commit da7a8f1a8fc3e14c6dcc52b4098bddb8f20390be ] This is another TRX40 based motherboard with ALC1220-VB USB-audio that requires a static mapping table. This motherboard also has a PCI device which advertises no codecs. The PCI ID is 1022:1487 and PCI SSID is

[PATCH 4.19 08/95] net: qrtr: Fix passing invalid reference to qrtr_local_enqueue()

2020-06-01 Thread Greg Kroah-Hartman
From: Manivannan Sadhasivam [ Upstream commit d28ea1fbbf437054ef339afec241019f2c4e2bb6 ] Once the traversal of the list is completed with list_for_each_entry(), the iterator (node) will point to an invalid object. So passing this to qrtr_local_enqueue() which is outside of the iterator block is

[PATCH 4.19 19/95] ARM: dts: rockchip: fix phy nodename for rk3228-evb

2020-06-01 Thread Greg Kroah-Hartman
From: Johan Jonker [ Upstream commit 287e0d538fcec2f6e8eb1e565bf0749f3b90186d ] A test with the command below gives for example this error: arch/arm/boot/dts/rk3228-evb.dt.yaml: phy@0: '#phy-cells' is a required property The phy nodename is normally used by a phy-handle. This node is however

[PATCH 4.19 39/95] Input: evdev - call input_flush_device() on release(), not flush()

2020-06-01 Thread Greg Kroah-Hartman
From: Brendan Shanks [ Upstream commit 09264098ff153f60866039d60b31d39b66f55a31 ] input_flush_device() should only be called once the struct file is being released and no open descriptors remain, but evdev_flush() was calling it whenever a file descriptor was closed. This caused uploaded

[PATCH 4.19 23/95] ARM: dts: rockchip: fix pinctrl sub nodename for spi in rk322x.dtsi

2020-06-01 Thread Greg Kroah-Hartman
From: Johan Jonker [ Upstream commit 855bdca1781c79eb661f89c8944c4a719ce720e8 ] A test with the command below gives these errors: arch/arm/boot/dts/rk3229-evb.dt.yaml: spi-0: '#address-cells' is a required property arch/arm/boot/dts/rk3229-evb.dt.yaml: spi-1: '#address-cells' is a required

[PATCH 4.19 07/95] net/mlx5: Add command entry handling completion

2020-06-01 Thread Greg Kroah-Hartman
From: Moshe Shemesh [ Upstream commit 17d00e839d3b592da9659c1977d45f85b77f986a ] When FW response to commands is very slow and all command entries in use are waiting for completion we can have a race where commands can get timeout before they get out of the queue and handled. Timeout completion

[PATCH 4.14 66/77] netfilter: nf_conntrack_pptp: prevent buffer overflows in debug code

2020-06-01 Thread Greg Kroah-Hartman
From: Pablo Neira Ayuso commit 4c559f15efcc43b996f4da528cd7f9483aaca36d upstream. Dan Carpenter says: "Smatch complains that the value for "cmd" comes from the network and can't be trusted." Add pptp_msg_name() helper function that checks for the array boundary. Fixes: f09943fefe6b

[PATCH 4.19 14/95] net/mlx5e: Update netdev txq on completions during closure

2020-06-01 Thread Greg Kroah-Hartman
From: Moshe Shemesh [ Upstream commit 5e911e2c06bd8c17df29147a5e2d4b17fafda024 ] On sq closure when we free its descriptors, we should also update netdev txq on completions which would not arrive. Otherwise if we reopen sqs and attach them back, for example on fw fatal recovery flow, we may get

[PATCH 4.14 68/77] qlcnic: fix missing release in qlcnic_83xx_interrupt_test.

2020-06-01 Thread Greg Kroah-Hartman
From: Qiushi Wu commit 15c973858903009e995b2037683de29dfe968621 upstream. In function qlcnic_83xx_interrupt_test(), function qlcnic_83xx_diag_alloc_res() is not handled by function qlcnic_83xx_diag_free_res() after a call of the function qlcnic_alloc_mbx_args() failed. Fix this issue by adding

[PATCH 4.19 16/95] net: sun: fix missing release regions in cas_init_one().

2020-06-01 Thread Greg Kroah-Hartman
From: Qiushi Wu commit 5a730153984dd13f82ffae93d7170d76eba204e9 upstream. In cas_init_one(), "pdev" is requested by "pci_request_regions", but it was not released after a call of the function “pci_write_config_byte” failed. Thus replace the jump target “err_write_cacheline” by

[PATCH 4.14 65/77] netfilter: nfnetlink_cthelper: unbreak userspace helper support

2020-06-01 Thread Greg Kroah-Hartman
From: Pablo Neira Ayuso commit 703acd70f2496537457186211c2f03e792409e68 upstream. Restore helper data size initialization and fix memcopy of the helper data size. Fixes: 157eb5dc ("netfilter: nfnetlink_cthelper: reject too large userspace allocation requests") Reviewed-by: Florian

[PATCH 4.19 13/95] sctp: Start shutdown on association restart if in SHUTDOWN-SENT state and socket is closed

2020-06-01 Thread Greg Kroah-Hartman
From: "Jere Lepp�nen" [ Upstream commit d3e8e4c11870413789f029a71e72ae6e971fe678 ] Commit bdf6fa52f01b ("sctp: handle association restarts when the socket is closed.") starts shutdown when an association is restarted, if in SHUTDOWN-PENDING state and the socket is closed. However, the rationale

[PATCH 4.14 74/77] rxrpc: Fix transport sockopts to get IPv4 errors on an IPv6 socket

2020-06-01 Thread Greg Kroah-Hartman
From: David Howells commit 37a675e768d7606fe8a53e0c459c9b53e121ac20 upstream. It seems that enabling IPV6_RECVERR on an IPv6 socket doesn't also turn on IP_RECVERR, so neither local errors nor ICMP-transported remote errors from IPv4 peer addresses are returned to the AF_RXRPC protocol. Make

[PATCH 4.14 77/77] net: hns: Fixes the missing put_device in positive leg for roce reset

2020-06-01 Thread Greg Kroah-Hartman
From: Salil Mehta commit 4d96e13ee9cd1f7f801e8c7f4b12f09d1da4a5d8 upstream. This patch fixes the missing device reference release-after-use in the positive leg of the roce reset API of the HNS DSAF. Fixes: c969c6e7ab8c ("net: hns: Fix object reference leaks in hns_dsaf_roce_reset()")

[PATCH 4.14 72/77] mm/vmalloc.c: dont dereference possible NULL pointer in __vunmap()

2020-06-01 Thread Greg Kroah-Hartman
From: Liviu Dudau commit 6ade20327dbb808882888ed8ccded71e93067cf9 upstream. find_vmap_area() can return a NULL pointer and we're going to dereference it without checking it first. Use the existing find_vm_area() function which does exactly what we want and checks for the NULL pointer. Link:

[PATCH 4.14 73/77] sc16is7xx: move label err_spi to correct section

2020-06-01 Thread Greg Kroah-Hartman
From: Guoqing Jiang commit e00164a0f000de893944981f41a568c981aca658 upstream. err_spi is used when SERIAL_SC16IS7XX_SPI is enabled, so make the label only available under SERIAL_SC16IS7XX_SPI option. Otherwise, the below warning appears. drivers/tty/serial/sc16is7xx.c:1523:1: warning: label

[PATCH 4.14 71/77] netfilter: nf_conntrack_pptp: fix compilation warning with W=1 build

2020-06-01 Thread Greg Kroah-Hartman
From: Pablo Neira Ayuso commit 4946ea5c1237036155c3b3a24f049fd5f849f8f6 upstream. >> include/linux/netfilter/nf_conntrack_pptp.h:13:20: warning: 'const' type >> qualifier on return type has no effect [-Wignored-qualifiers] extern const char *const pptp_msg_name(u_int16_t msg); ^~

[PATCH 4.14 76/77] net: hns: fix unsigned comparison to less than zero

2020-06-01 Thread Greg Kroah-Hartman
From: Colin Ian King commit ea401685a20b5d631957f024bda86e1f6118eb20 upstream. Currently mskid is unsigned and hence comparisons with negative error return values are always false. Fix this by making mskid an int. Fixes: f058e46855dc ("net: hns: fix ICMP6 neighbor solicitation messages

[PATCH 4.14 50/77] include/asm-generic/topology.h: guard cpumask_of_node() macro argument

2020-06-01 Thread Greg Kroah-Hartman
From: Arnd Bergmann [ Upstream commit 4377748c7b5187c3342a60fa2ceb60c8a57a8488 ] drivers/hwmon/amd_energy.c:195:15: error: invalid operands to binary expression ('void' and 'int') (channel - data->nr_cpus));

[PATCH 4.14 37/77] IB/qib: Call kobject_put() when kobject_init_and_add() fails

2020-06-01 Thread Greg Kroah-Hartman
From: Kaike Wan [ Upstream commit a35cd6447effd5c239b564c80fa109d05ff3d114 ] When kobject_init_and_add() returns an error in the function qib_create_port_files(), the function kobject_put() is not called for the corresponding kobject, which potentially leads to memory leak. This patch fixes

[PATCH 4.14 60/77] xfrm: fix error in comment

2020-06-01 Thread Greg Kroah-Hartman
From: Antony Antony commit 29e4276667e24ee6b91d9f91064d8fda9a210ea1 upstream. s/xfrm_state_offload/xfrm_user_offload/ Fixes: d77e38e612a ("xfrm: Add an IPsec hardware offloading API") Signed-off-by: Antony Antony Signed-off-by: Steffen Klassert Signed-off-by: Greg Kroah-Hartman ---

[PATCH 4.14 23/77] samples: bpf: Fix build error

2020-06-01 Thread Greg Kroah-Hartman
From: Matteo Croce [ Upstream commit 23ad04669f81f958e9a4121b0266228d2eb3c357 ] GCC 10 is very strict about symbol clash, and lwt_len_hist_user contains a symbol which clashes with libbpf: /usr/bin/ld: samples/bpf/lwt_len_hist_user.o:(.bss+0x0): multiple definition of `bpf_log_buf';

[PATCH 4.14 21/77] net: freescale: select CONFIG_FIXED_PHY where needed

2020-06-01 Thread Greg Kroah-Hartman
From: Arnd Bergmann [ Upstream commit 99352c79af3e5f2e4724abf37fa5a2a3299b1c81 ] I ran into a randconfig build failure with CONFIG_FIXED_PHY=m and CONFIG_GIANFAR=y: x86_64-linux-ld: drivers/net/ethernet/freescale/gianfar.o:(.rodata+0x418): undefined reference to `fixed_phy_change_carrier' It

[PATCH 4.14 20/77] usb: gadget: legacy: fix redundant initialization warnings

2020-06-01 Thread Greg Kroah-Hartman
From: Masahiro Yamada [ Upstream commit d13cce757954fa663c69845611957396843ed87a ] Fix the following cppcheck warnings: drivers/usb/gadget/legacy/inode.c:1364:8: style: Redundant initialization for 'value'. The initialized value is overwritten$ value = -EOPNOTSUPP; ^

[PATCH 4.14 19/77] cachefiles: Fix race between read_waiter and read_copier involving op->to_do

2020-06-01 Thread Greg Kroah-Hartman
From: Lei Xue [ Upstream commit 7bb0c5338436dae953622470d52689265867f032 ] There is a potential race in fscache operation enqueuing for reading and copying multiple pages from cachefiles to netfs. The problem can be seen easily on a heavy loaded system (for example many processes reading files

[PATCH 4.14 58/77] xfrm: fix a warning in xfrm_policy_insert_list

2020-06-01 Thread Greg Kroah-Hartman
From: Xin Long commit ed17b8d377eaf6b4a01d46942b4c647378a79bdd upstream. This waring can be triggered simply by: # ip xfrm policy update src 192.168.1.1/24 dst 192.168.1.2/24 dir in \ priority 1 mark 0 mask 0x10 #[1] # ip xfrm policy update src 192.168.1.1/24 dst 192.168.1.2/24 dir in

[PATCH 4.14 48/77] mm: remove VM_BUG_ON(PageSlab()) from page_mapcount()

2020-06-01 Thread Greg Kroah-Hartman
From: Konstantin Khlebnikov [ Upstream commit 6988f31d558aa8c744464a7f6d91d34ada48ad12 ] Replace superfluous VM_BUG_ON() with comment about correct usage. Technically reverts commit 1d148e218a0d ("mm: add VM_BUG_ON_PAGE() to page_mapcount()"), but context lines have changed. Function

[PATCH 4.14 56/77] xfrm: allow to accept packets with ipv6 NEXTHDR_HOP in xfrm_input

2020-06-01 Thread Greg Kroah-Hartman
From: Xin Long commit afcaf61be9d1dbdee5ec186d1dcc67b6b692180f upstream. For beet mode, when it's ipv6 inner address with nexthdrs set, the packet format might be: | outer | | dest | | | ESP| ESP | | IP hdr |

[PATCH 4.14 40/77] ARM: dts: bcm2835-rpi-zero-w: Fix led polarity

2020-06-01 Thread Greg Kroah-Hartman
From: Vincent Stehlé [ Upstream commit 58bb90ab415562eededb932455046924e65df342 ] The status "ACT" led on the Raspberry Pi Zero W is on when GPIO 47 is low. This has been verified on a board and somewhat confirmed by both the GPIO name ("STATUS_LED_N") and the reduced schematics [1]. [1]:

[PATCH 4.14 49/77] fs/binfmt_elf.c: allocate initialized memory in fill_thread_core_info()

2020-06-01 Thread Greg Kroah-Hartman
From: Alexander Potapenko [ Upstream commit 1d605416fb7175e1adf094251466caa52093b413 ] KMSAN reported uninitialized data being written to disk when dumping core. As a result, several kilobytes of kmalloc memory may be written to the core file and then read by a non-privileged user.

[PATCH 4.14 45/77] exec: Always set cap_ambient in cap_bprm_set_creds

2020-06-01 Thread Greg Kroah-Hartman
From: Eric W. Biederman [ Upstream commit a4ae32c71fe90794127b32d26d7ad795813b502e ] An invariant of cap_bprm_set_creds is that every field in the new cred structure that cap_bprm_set_creds might set, needs to be set every time to ensure the fields does not get a stale value. The field

[PATCH 4.14 01/77] ax25: fix setsockopt(SO_BINDTODEVICE)

2020-06-01 Thread Greg Kroah-Hartman
From: Eric Dumazet [ Upstream commit 687775cec056b38a4c8f3291e0dd7a9145f7b667 ] syzbot was able to trigger this trace [1], probably by using a zero optlen. While we are at it, cap optlen to IFNAMSIZ - 1 instead of IFNAMSIZ. [1] BUG: KMSAN: uninit-value in strnlen+0xf9/0x170 lib/string.c:569

[PATCH 4.9 43/61] mac80211: mesh: fix discovery timer re-arming issue / crash

2020-06-01 Thread Greg Kroah-Hartman
From: Linus Lüssing commit e2d4a80f93fcfaf72e2e20daf6a28e39c3b90677 upstream. On a non-forwarding 802.11s link between two fairly busy neighboring nodes (iperf with -P 16 at ~850MBit/s TCP; 1733.3 MBit/s VHT-MCS 9 80MHz short GI VHT-NSS 4), so with frequent PREQ retries, usually after around

[PATCH 4.14 12/77] ARM: dts: rockchip: fix phy nodename for rk3228-evb

2020-06-01 Thread Greg Kroah-Hartman
From: Johan Jonker [ Upstream commit 287e0d538fcec2f6e8eb1e565bf0749f3b90186d ] A test with the command below gives for example this error: arch/arm/boot/dts/rk3228-evb.dt.yaml: phy@0: '#phy-cells' is a required property The phy nodename is normally used by a phy-handle. This node is however

[PATCH 4.14 28/77] Input: dlink-dir685-touchkeys - fix a typo in driver name

2020-06-01 Thread Greg Kroah-Hartman
From: Christophe JAILLET [ Upstream commit 38347374ae3f1ec4df56dd688bd603a64e79a0ed ] According to the file name and Kconfig, a 'k' is missing in this driver name. It should be "dlink-dir685-touchkeys". Fixes: 131b3de7016b ("Input: add D-Link DIR-685 touchkeys driver") Signed-off-by:

[PATCH 4.14 36/77] gpio: exar: Fix bad handling for ida_simple_get error path

2020-06-01 Thread Greg Kroah-Hartman
From: Takashi Iwai [ Upstream commit 333830aa149a87cabeb5d30fbcf12eecc8040d2c ] The commit 7ecced0934e5 ("gpio: exar: add a check for the return value of ida_simple_get fails") added a goto jump to the common error handler for ida_simple_get() error, but this is wrong in two ways: it doesn't

[PATCH 4.14 15/77] gpio: tegra: mask GPIO IRQs during IRQ shutdown

2020-06-01 Thread Greg Kroah-Hartman
From: Stephen Warren [ Upstream commit 0cf253eed5d2bdf7bb3152457b38f39b012955f7 ] The driver currently leaves GPIO IRQs unmasked even when the GPIO IRQ client has released the GPIO IRQ. This allows the HW to raise IRQs, and SW to process them, after shutdown. Fix this by masking the IRQ when

[PATCH 4.14 14/77] ARM: dts: rockchip: fix pinctrl sub nodename for spi in rk322x.dtsi

2020-06-01 Thread Greg Kroah-Hartman
From: Johan Jonker [ Upstream commit 855bdca1781c79eb661f89c8944c4a719ce720e8 ] A test with the command below gives these errors: arch/arm/boot/dts/rk3229-evb.dt.yaml: spi-0: '#address-cells' is a required property arch/arm/boot/dts/rk3229-evb.dt.yaml: spi-1: '#address-cells' is a required

[PATCH 4.14 30/77] Input: synaptics-rmi4 - really fix attn_data use-after-free

2020-06-01 Thread Greg Kroah-Hartman
From: Evan Green [ Upstream commit d5a5e5b5fa7b86c05bf073acc0ba98fa280174ec ] Fix a use-after-free noticed by running with KASAN enabled. If rmi_irq_fn() is run twice in a row, then rmi_f11_attention() (among others) will end up reading from drvdata->attn_data.data, which was freed and left

[PATCH 4.14 34/77] ARM: uaccess: integrate uaccess_save and uaccess_restore

2020-06-01 Thread Greg Kroah-Hartman
From: Russell King [ Upstream commit 8ede890b0bcebe8c760aacfe20e934d98c3dc6aa ] Integrate uaccess_save / uaccess_restore macros into the new uaccess_entry / uaccess_exit macros respectively. Signed-off-by: Russell King Signed-off-by: Sasha Levin --- arch/arm/include/asm/uaccess-asm.h | 30

[PATCH 4.9 08/61] net/mlx5: Add command entry handling completion

2020-06-01 Thread Greg Kroah-Hartman
From: Moshe Shemesh [ Upstream commit 17d00e839d3b592da9659c1977d45f85b77f986a ] When FW response to commands is very slow and all command entries in use are waiting for completion we can have a race where commands can get timeout before they get out of the queue and handled. Timeout completion

[PATCH 4.9 44/61] x86/dma: Fix max PFN arithmetic overflow on 32 bit systems

2020-06-01 Thread Greg Kroah-Hartman
From: Alexander Dahl commit 88743470668ef5eb6b7ba9e0f99888e5999bf172 upstream. The intermediate result of the old term (4UL * 1024 * 1024 * 1024) is 4 294 967 296 or 0x1 which is no problem on 64 bit systems. The patch does not change the later overall result of 0x10 for

[PATCH 4.9 57/61] genirq/generic_pending: Do not lose pending affinity update

2020-06-01 Thread Greg Kroah-Hartman
From: Thomas Gleixner commit a33a5d2d16cb84bea8d5f5510f3a41aa48b5c467 upstream. The generic pending interrupt mechanism moves interrupts from the interrupt handler on the original target CPU to the new destination CPU. This is required for x86 and ia64 due to the way the interrupt delivery and

[PATCH 4.9 06/61] net/mlx5e: Update netdev txq on completions during closure

2020-06-01 Thread Greg Kroah-Hartman
From: Moshe Shemesh [ Upstream commit 5e911e2c06bd8c17df29147a5e2d4b17fafda024 ] On sq closure when we free its descriptors, we should also update netdev txq on completions which would not arrive. Otherwise if we reopen sqs and attach them back, for example on fw fatal recovery flow, we may get

[PATCH 4.9 53/61] qlcnic: fix missing release in qlcnic_83xx_interrupt_test.

2020-06-01 Thread Greg Kroah-Hartman
From: Qiushi Wu commit 15c973858903009e995b2037683de29dfe968621 upstream. In function qlcnic_83xx_interrupt_test(), function qlcnic_83xx_diag_alloc_res() is not handled by function qlcnic_83xx_diag_free_res() after a call of the function qlcnic_alloc_mbx_args() failed. Fix this issue by adding

[PATCH 4.9 52/61] netfilter: nf_conntrack_pptp: prevent buffer overflows in debug code

2020-06-01 Thread Greg Kroah-Hartman
From: Pablo Neira Ayuso commit 4c559f15efcc43b996f4da528cd7f9483aaca36d upstream. Dan Carpenter says: "Smatch complains that the value for "cmd" comes from the network and can't be trusted." Add pptp_msg_name() helper function that checks for the array boundary. Fixes: f09943fefe6b

[PATCH 4.9 46/61] xfrm: fix a warning in xfrm_policy_insert_list

2020-06-01 Thread Greg Kroah-Hartman
From: Xin Long commit ed17b8d377eaf6b4a01d46942b4c647378a79bdd upstream. This waring can be triggered simply by: # ip xfrm policy update src 192.168.1.1/24 dst 192.168.1.2/24 dir in \ priority 1 mark 0 mask 0x10 #[1] # ip xfrm policy update src 192.168.1.1/24 dst 192.168.1.2/24 dir in

[PATCH 4.9 05/61] sctp: Start shutdown on association restart if in SHUTDOWN-SENT state and socket is closed

2020-06-01 Thread Greg Kroah-Hartman
From: "Jere Lepp�nen" [ Upstream commit d3e8e4c11870413789f029a71e72ae6e971fe678 ] Commit bdf6fa52f01b ("sctp: handle association restarts when the socket is closed.") starts shutdown when an association is restarted, if in SHUTDOWN-PENDING state and the socket is closed. However, the rationale

[PATCH 4.9 39/61] fs/binfmt_elf.c: allocate initialized memory in fill_thread_core_info()

2020-06-01 Thread Greg Kroah-Hartman
From: Alexander Potapenko [ Upstream commit 1d605416fb7175e1adf094251466caa52093b413 ] KMSAN reported uninitialized data being written to disk when dumping core. As a result, several kilobytes of kmalloc memory may be written to the core file and then read by a non-privileged user.

[PATCH 4.9 04/61] net sched: fix reporting the first-time use timestamp

2020-06-01 Thread Greg Kroah-Hartman
From: Roman Mashak [ Upstream commit b15e62631c5f19fea9895f7632dae9c1b27fe0cd ] When a new action is installed, firstuse field of 'tcf_t' is explicitly set to 0. Value of zero means "new action, not yet used"; as a packet hits the action, 'firstuse' is stamped with the current jiffies value.

[PATCH 4.9 40/61] include/asm-generic/topology.h: guard cpumask_of_node() macro argument

2020-06-01 Thread Greg Kroah-Hartman
From: Arnd Bergmann [ Upstream commit 4377748c7b5187c3342a60fa2ceb60c8a57a8488 ] drivers/hwmon/amd_energy.c:195:15: error: invalid operands to binary expression ('void' and 'int') (channel - data->nr_cpus));

[PATCH 4.9 37/61] libceph: ignore pool overlay and cache logic on redirects

2020-06-01 Thread Greg Kroah-Hartman
From: Jerry Lee [ Upstream commit 890bd0f8997ae6ac0a367dd5146154a3963306dd ] OSD client should ignore cache/overlay flag if got redirect reply. Otherwise, the client hangs when the cache tier is in forward mode. [ idryomov: Redirects are effectively deprecated and no longer used or tested.

[PATCH 4.9 30/61] IB/qib: Call kobject_put() when kobject_init_and_add() fails

2020-06-01 Thread Greg Kroah-Hartman
From: Kaike Wan [ Upstream commit a35cd6447effd5c239b564c80fa109d05ff3d114 ] When kobject_init_and_add() returns an error in the function qib_create_port_files(), the function kobject_put() is not called for the corresponding kobject, which potentially leads to memory leak. This patch fixes

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