[PATCH AUTOSEL 4.4 37/37] vxlan: Avoid infinite loop when suppressing NS messages with invalid options

2020-06-08 Thread Sasha Levin
From: Ido Schimmel [ Upstream commit 8066e6b449e050675df48e7c4b16c29f00507ff0 ] When proxy mode is enabled the vxlan device might reply to Neighbor Solicitation (NS) messages on behalf of remote hosts. In case the NS message includes the "Source link-layer address" option [1], the vxlan device

[PATCH AUTOSEL 4.4 35/37] spi: dw: Return any value retrieved from the dma_transfer callback

2020-06-08 Thread Sasha Levin
From: Serge Semin [ Upstream commit f0410bbf7d0fb80149e3b17d11d31f5b5197873e ] DW APB SSI DMA-part of the driver may need to perform the requested SPI-transfer synchronously. In that case the dma_transfer() callback will return 0 as a marker of the SPI transfer being finished so the SPI core

[PATCH AUTOSEL 4.19 083/106] crypto: stm32/crc32 - fix multi-instance

2020-06-08 Thread Sasha Levin
From: Nicolas Toromanoff [ Upstream commit 10b89c43a64eb0d236903b79a3bc9d8f6cbfd9c7 ] Ensure CRC algorithm is registered only once in crypto framework when there are several instances of CRC devices. Update the CRC device list management to avoid that only the first CRC instance is used.

[PATCH AUTOSEL 4.19 065/106] platform/x86: intel-vbtn: Do not advertise switches to userspace if they are not there

2020-06-08 Thread Sasha Levin
From: Hans de Goede [ Upstream commit 990fbb48067bf8cfa34b7d1e6e1674eaaef2f450 ] Commit de9647efeaa9 ("platform/x86: intel-vbtn: Only activate tablet mode switch on 2-in-1's") added a DMI chassis-type check to avoid accidentally reporting SW_TABLET_MODE = 1 to userspace on laptops (specifically

[PATCH AUTOSEL 4.19 063/106] platform/x86: intel-vbtn: Use acpi_evaluate_integer()

2020-06-08 Thread Sasha Levin
From: Hans de Goede [ Upstream commit 18937875a231d831c309716d6d8fc358f8381881 ] Use acpi_evaluate_integer() instead of open-coding it. This is a preparation patch for adding a intel_vbtn_has_switches() helper function. Fixes: de9647efeaa9 ("platform/x86: intel-vbtn: Only activate tablet mode

[PATCH AUTOSEL 4.19 051/106] net: lpc-enet: fix error return code in lpc_mii_init()

2020-06-08 Thread Sasha Levin
From: Wei Yongjun [ Upstream commit 88ec7cb22ddde725ed4ce15991f0bd9dd817fd85 ] Fix to return a negative error code from the error handling case instead of 0, as done elsewhere in this function. Fixes: b7370112f519 ("lpc32xx: Added ethernet driver") Signed-off-by: Wei Yongjun Acked-by:

[PATCH AUTOSEL 4.19 042/106] audit: fix a net reference leak in audit_list_rules_send()

2020-06-08 Thread Sasha Levin
From: Paul Moore [ Upstream commit 3054d06719079388a543de6adb812638675ad8f5 ] If audit_list_rules_send() fails when trying to create a new thread to send the rules it also fails to cleanup properly, leaking a reference to a net structure. This patch fixes the error patch and renames

[PATCH AUTOSEL 4.19 046/106] lib/mpi: Fix 64-bit MIPS build with Clang

2020-06-08 Thread Sasha Levin
From: Nathan Chancellor [ Upstream commit 18f1ca46858eac22437819937ae44aa9a8f9f2fa ] When building 64r6_defconfig with CONFIG_MIPS32_O32 disabled and CONFIG_CRYPTO_RSA enabled: lib/mpi/generic_mpih-mul1.c:37:24: error: invalid use of a cast in a inline asm context requiring an l-value: remove

[PATCH AUTOSEL 4.19 061/106] xfs: reset buffer write failure state on successful completion

2020-06-08 Thread Sasha Levin
From: Brian Foster [ Upstream commit b6983e80b03bd4fd42de71993b3ac7403edac758 ] The buffer write failure flag is intended to control the internal write retry that XFS has historically implemented to help mitigate the severity of transient I/O errors. The flag is set when a buffer is resubmitted

[PATCH AUTOSEL 4.19 066/106] platform/x86: intel-vbtn: Also handle tablet-mode switch on "Detachable" and "Portable" chassis-types

2020-06-08 Thread Sasha Levin
From: Hans de Goede [ Upstream commit 1fac39fd0316b19c3e57a182524332332d1643ce ] Commit de9647efeaa9 ("platform/x86: intel-vbtn: Only activate tablet mode switch on 2-in-1's") added a DMI chassis-type check to avoid accidentally reporting SW_TABLET_MODE = 1 to userspace on laptops. Some

[PATCH AUTOSEL 4.19 055/106] ath9k_htc: Silence undersized packet warnings

2020-06-08 Thread Sasha Levin
From: Masashi Honma [ Upstream commit 450edd2805982d14ed79733a82927d2857b27cac ] Some devices like TP-Link TL-WN722N produces this kind of messages frequently. kernel: ath: phy0: Short RX data len, dropping (dlen: 4) This warning is useful for developers to recognize that the device (Wi-Fi

[PATCH AUTOSEL 4.19 062/106] xfs: fix duplicate verification from xfs_qm_dqflush()

2020-06-08 Thread Sasha Levin
From: Brian Foster [ Upstream commit 629dcb38dc351947ed6a26a997d4b587f3bd5c7e ] The pre-flush dquot verification in xfs_qm_dqflush() duplicates the read verifier by checking the dquot in the on-disk buffer. Instead, verify the in-core variant before it is flushed to the buffer. Fixes:

[PATCH AUTOSEL 4.19 054/106] powerpc/spufs: fix copy_to_user while atomic

2020-06-08 Thread Sasha Levin
From: Jeremy Kerr [ Upstream commit 88413a6bfbbe2f648df399b62f85c934460b7a4d ] Currently, we may perform a copy_to_user (through simple_read_from_buffer()) while holding a context's register_lock, while accessing the context save area. This change uses a temporary buffer for the context save

[PATCH AUTOSEL 4.4 02/37] ath9k: Fix use-after-free Write in ath9k_htc_rx_msg

2020-06-08 Thread Sasha Levin
From: Qiujun Huang [ Upstream commit e4ff08a4d727146bb6717a39a8d399d834654345 ] Write out of slab bounds. We should check epid. The case reported by syzbot: https://lore.kernel.org/linux-usb/6ac55b05a1c05...@google.com BUG: KASAN: use-after-free in htc_process_conn_rsp

[PATCH AUTOSEL 4.9 30/50] ath9k_htc: Silence undersized packet warnings

2020-06-08 Thread Sasha Levin
From: Masashi Honma [ Upstream commit 450edd2805982d14ed79733a82927d2857b27cac ] Some devices like TP-Link TL-WN722N produces this kind of messages frequently. kernel: ath: phy0: Short RX data len, dropping (dlen: 4) This warning is useful for developers to recognize that the device (Wi-Fi

Re: [PATCH] irqchip/gic-v3-its: Don't try to move a disabled irq

2020-06-08 Thread Thomas Gleixner
Ben, Benjamin Herrenschmidt writes: > On Mon, 2020-06-08 at 15:48 +0200, Thomas Gleixner wrote: >> >if (cpu != its_dev->event_map.col_map[id]) { >> >target_col = _dev->its->collections[cpu]; >> > - its_send_movi(its_dev, target_col, id); >> > + >> > + /* If the

[PATCH AUTOSEL 4.19 086/106] btrfs: qgroup: mark qgroup inconsistent if we're inherting snapshot to a new qgroup

2020-06-08 Thread Sasha Levin
From: Qu Wenruo [ Upstream commit cbab8ade585a18c4334b085564d9d046e01a3f70 ] [BUG] For the following operation, qgroup is guaranteed to be screwed up due to snapshot adding to a new qgroup: # mkfs.btrfs -f $dev # mount $dev $mnt # btrfs qgroup en $mnt # btrfs subv create $mnt/src #

[PATCH AUTOSEL 4.9 45/50] staging: greybus: sdio: Respect the cmd->busy_timeout from the mmc core

2020-06-08 Thread Sasha Levin
From: Ulf Hansson [ Upstream commit a389087ee9f195fcf2f31cd771e9ec5f02c16650 ] Using a fixed 1s timeout for all commands is a bit problematic. For some commands it means waiting longer than needed for the timeout to expire, which may not a big issue, but still. For other commands, like for an

[PATCH AUTOSEL 4.14 65/72] mmc: via-sdmmc: Respect the cmd->busy_timeout from the mmc core

2020-06-08 Thread Sasha Levin
From: Ulf Hansson [ Upstream commit 966244ccd2919e28f2a77f204cd1c109cad8 ] Using a fixed 1s timeout for all commands (and data transfers) is a bit problematic. For some commands it means waiting longer than needed for the timer to expire, which may not a big issue, but still. For other

[PATCH AUTOSEL 4.14 68/72] spi: dw: Return any value retrieved from the dma_transfer callback

2020-06-08 Thread Sasha Levin
From: Serge Semin [ Upstream commit f0410bbf7d0fb80149e3b17d11d31f5b5197873e ] DW APB SSI DMA-part of the driver may need to perform the requested SPI-transfer synchronously. In that case the dma_transfer() callback will return 0 as a marker of the SPI transfer being finished so the SPI core

[PATCH AUTOSEL 4.19 103/106] platform/x86: intel-vbtn: Only blacklist SW_TABLET_MODE on the 9 / "Laptop" chasis-type

2020-06-08 Thread Sasha Levin
From: Hans de Goede [ Upstream commit cfae58ed681c5fe0185db843013ecc71cd265ebf ] The HP Stream x360 11-p000nd no longer report SW_TABLET_MODE state / events with recent kernels. This model reports a chassis-type of 10 / "Notebook" which is not on the recently introduced chassis-type whitelist

[PATCH AUTOSEL 4.19 092/106] xfs: gut error handling in xfs_trans_unreserve_and_mod_sb()

2020-06-08 Thread Sasha Levin
From: Dave Chinner [ Upstream commit dc3ffbb14060c943469d5e12900db3a60bc3fa64 ] xfs: gut error handling in xfs_trans_unreserve_and_mod_sb() From: Dave Chinner The error handling in xfs_trans_unreserve_and_mod_sb() is largely incorrect - rolling back the changes in the transaction if only one

[PATCH AUTOSEL 4.14 66/72] ixgbe: fix signed-integer-overflow warning

2020-06-08 Thread Sasha Levin
From: Xie XiuQi [ Upstream commit 3b70683fc4d68f5d915d9dc7e5ba72c732c7315c ] ubsan report this warning, fix it by adding a unsigned suffix. UBSAN: signed-integer-overflow in drivers/net/ethernet/intel/ixgbe/ixgbe_common.c:2246:26 65535 * 65537 cannot be represented in type 'int' CPU: 21 PID: 7

[PATCH AUTOSEL 4.19 091/106] bcache: fix refcount underflow in bcache_device_free()

2020-06-08 Thread Sasha Levin
From: Coly Li [ Upstream commit 86da9f736740eba602389908574dfbb0f517baa5 ] The problematic code piece in bcache_device_free() is, 785 static void bcache_device_free(struct bcache_device *d) 786 { 787 struct gendisk *disk = d->disk; [snipped] 799 if (disk) { 800 if

[PATCH AUTOSEL 4.4 07/37] clocksource: dw_apb_timer_of: Fix missing clockevent timers

2020-06-08 Thread Sasha Levin
From: Serge Semin [ Upstream commit 6d2e16a3181bafb77b535095c39ad1c8b9558c8c ] Commit 100214889973 ("clocksource: dw_apb_timer_of: use clocksource_of_init") replaced a publicly available driver initialization method with one called by the timer_probe() method available after CLKSRC_OF. In

[PATCH AUTOSEL 4.9 11/50] btrfs: do not ignore error from btrfs_next_leaf() when inserting checksums

2020-06-08 Thread Sasha Levin
From: Filipe Manana [ Upstream commit 7e4a3f7ed5d54926ec671bbb13e171cfe179cc50 ] We are currently treating any non-zero return value from btrfs_next_leaf() the same way, by going to the code that inserts a new checksum item in the tree. However if btrfs_next_leaf() returns an error (a value <

[PATCH AUTOSEL 4.14 47/72] kgdb: Fix spurious true from in_dbg_master()

2020-06-08 Thread Sasha Levin
From: Daniel Thompson [ Upstream commit 3fec4aecb311995189217e64d725cfe84a568de3 ] Currently there is a small window where a badly timed migration could cause in_dbg_master() to spuriously return true. Specifically if we migrate to a new core after reading the processor id and the previous core

[PATCH AUTOSEL 4.14 43/72] ath9k_htc: Silence undersized packet warnings

2020-06-08 Thread Sasha Levin
From: Masashi Honma [ Upstream commit 450edd2805982d14ed79733a82927d2857b27cac ] Some devices like TP-Link TL-WN722N produces this kind of messages frequently. kernel: ath: phy0: Short RX data len, dropping (dlen: 4) This warning is useful for developers to recognize that the device (Wi-Fi

[PATCH AUTOSEL 4.14 21/72] net: vmxnet3: fix possible buffer overflow caused by bad DMA value in vmxnet3_get_rss()

2020-06-08 Thread Sasha Levin
From: Jia-Ju Bai [ Upstream commit 3e1c6846b9e108740ef8a37be80314053f5dd52a ] The value adapter->rss_conf is stored in DMA memory, and it is assigned to rssConf, so rssConf->indTableSize can be modified at anytime by malicious hardware. Because rssConf->indTableSize is assigned to n, buffer

[PATCH AUTOSEL 4.14 41/72] net: allwinner: Fix use correct return type for ndo_start_xmit()

2020-06-08 Thread Sasha Levin
From: Yunjian Wang [ Upstream commit 09f6c44aaae0f1bdb8b983d7762676d5018c53bc ] The method ndo_start_xmit() returns a value of type netdev_tx_t. Fix the ndo function to use the correct type. And emac_start_xmit() can leak one skb if 'channel' == 3. Signed-off-by: Yunjian Wang Signed-off-by:

[PATCH AUTOSEL 4.14 07/72] spi: pxa2xx: Apply CS clk quirk to BXT

2020-06-08 Thread Sasha Levin
From: Evan Green [ Upstream commit 6eefaee4f2d366a389da0eb95e524ba82bf358c4 ] With a couple allies at Intel, and much badgering, I got confirmation from Intel that at least BXT suffers from the same SPI chip-select issue as Cannonlake (and beyond). The issue being that after going through

[PATCH AUTOSEL 4.14 49/72] wcn36xx: Fix error handling path in 'wcn36xx_probe()'

2020-06-08 Thread Sasha Levin
From: Christophe JAILLET [ Upstream commit a86308fc534edeceaf64670c691e17485436a4f4 ] In case of error, 'qcom_wcnss_open_channel()' must be undone by a call to 'rpmsg_destroy_ept()', as already done in the remove function. Fixes: 5052de8deff5 ("soc: qcom: smd: Transition client drivers from

[PATCH AUTOSEL 4.14 29/72] audit: fix a net reference leak in audit_send_reply()

2020-06-08 Thread Sasha Levin
From: Paul Moore [ Upstream commit a48b284b403a4a073d8beb72d2bb33e54df67fb6 ] If audit_send_reply() fails when trying to create a new thread to send the reply it also fails to cleanup properly, leaking a reference to a net structure. This patch fixes the error path and makes a handful of other

[PATCH AUTOSEL 4.14 03/72] drm: bridge: adv7511: Extend list of audio sample rates

2020-06-08 Thread Sasha Levin
From: Bogdan Togorean [ Upstream commit b97b6a1f6e14a25d1e1ca2a46c5fa3e2ca374e22 ] ADV7511 support sample rates up to 192kHz. CTS and N parameters should be computed accordingly so this commit extend the list up to maximum supported sample rate. Signed-off-by: Bogdan Togorean Reviewed-by:

[PATCH AUTOSEL 4.14 35/72] net: bcmgenet: set Rx mode before starting netif

2020-06-08 Thread Sasha Levin
From: Doug Berger [ Upstream commit 72f96347628e73dbb61b307f18dd19293cc6792a ] This commit explicitly calls the bcmgenet_set_rx_mode() function when the network interface is started. This function is normally called by ndo_set_rx_mode when the flags are changed, but apparently not when the

[PATCH AUTOSEL 4.4 36/37] cpuidle: Fix three reference count leaks

2020-06-08 Thread Sasha Levin
From: Qiushi Wu [ Upstream commit c343bf1ba5efcbf2266a1fe3baefec9cc82f867f ] kobject_init_and_add() takes reference even when it fails. If this function returns an error, kobject_put() must be called to properly clean up the memory associated with the object. Previous commit "b8eb718348b8"

Re: [PATCH v2 2/3] platform/x86: dell-wmi: add new keymap type 0x0012

2020-06-08 Thread Pali Rohár
On Monday 08 June 2020 19:05:29 Y Paritcher wrote: > These are events with extended data. The extended data is > currently ignored as userspace does not have a way to deal > it. > > Ignore event with a type of 0x0012 and a code of 0xe035, as > the keyboard controller takes care of Fn lock events

[PATCH AUTOSEL 4.4 33/37] xfs: gut error handling in xfs_trans_unreserve_and_mod_sb()

2020-06-08 Thread Sasha Levin
From: Dave Chinner [ Upstream commit dc3ffbb14060c943469d5e12900db3a60bc3fa64 ] xfs: gut error handling in xfs_trans_unreserve_and_mod_sb() From: Dave Chinner The error handling in xfs_trans_unreserve_and_mod_sb() is largely incorrect - rolling back the changes in the transaction if only one

[PATCH AUTOSEL 4.4 17/37] netfilter: nft_nat: return EOPNOTSUPP if type or flags are not supported

2020-06-08 Thread Sasha Levin
From: Pablo Neira Ayuso [ Upstream commit 0d7c83463fdf7841350f37960a7abadd3e650b41 ] Instead of EINVAL which should be used for malformed netlink messages. Fixes: eb31628e37a0 ("netfilter: nf_tables: Add support for IPv6 NAT") Signed-off-by: Pablo Neira Ayuso Signed-off-by: Sasha Levin ---

[PATCH AUTOSEL 4.4 34/37] ixgbe: fix signed-integer-overflow warning

2020-06-08 Thread Sasha Levin
From: Xie XiuQi [ Upstream commit 3b70683fc4d68f5d915d9dc7e5ba72c732c7315c ] ubsan report this warning, fix it by adding a unsigned suffix. UBSAN: signed-integer-overflow in drivers/net/ethernet/intel/ixgbe/ixgbe_common.c:2246:26 65535 * 65537 cannot be represented in type 'int' CPU: 21 PID: 7

Re: Forest Bond ,Greg Kroah-Hartman ,de...@driverdev.osuosl.org,linux-kernel@vger.kernel.org

2020-06-08 Thread Joe Perches
On Mon, 2020-06-08 at 22:58 +, Rodolfo C Villordo wrote: > On Mon, Jun 08, 2020 at 01:41:11AM -0700, Joe Perches wrote: > > On Mon, 2020-06-08 at 07:59 +0200, Julia Lawall wrote: > > > On Mon, 8 Jun 2020, Al Viro wrote: > > > > > > > On Sun, Jun 07, 2020 at 10:41:56PM +, Rodolfo C.

[PATCH AUTOSEL 4.4 11/37] staging: android: ion: use vmap instead of vm_map_ram

2020-06-08 Thread Sasha Levin
From: Christoph Hellwig [ Upstream commit 5bf9917452112694b2c774465ee4dbe441c84b77 ] vm_map_ram can keep mappings around after the vm_unmap_ram. Using that with non-PAGE_KERNEL mappings can lead to all kinds of aliasing issues. Signed-off-by: Christoph Hellwig Signed-off-by: Andrew Morton

[PATCH AUTOSEL 4.4 23/37] mips: cm: Fix an invalid error code of INTVN_*_ERR

2020-06-08 Thread Sasha Levin
From: Serge Semin [ Upstream commit 8a0efb8b101665a843205eab3d67ab09cb2d9a8d ] Commit 3885c2b463f6 ("MIPS: CM: Add support for reporting CM cache errors") adds cm2_causes[] array with map of error type ID and pointers to the short description string. There is a mistake in the table, since

[PATCH AUTOSEL 4.4 10/37] net: vmxnet3: fix possible buffer overflow caused by bad DMA value in vmxnet3_get_rss()

2020-06-08 Thread Sasha Levin
From: Jia-Ju Bai [ Upstream commit 3e1c6846b9e108740ef8a37be80314053f5dd52a ] The value adapter->rss_conf is stored in DMA memory, and it is assigned to rssConf, so rssConf->indTableSize can be modified at anytime by malicious hardware. Because rssConf->indTableSize is assigned to n, buffer

[PATCH AUTOSEL 4.4 25/37] md: don't flush workqueue unconditionally in md_open

2020-06-08 Thread Sasha Levin
From: Guoqing Jiang [ Upstream commit f6766ff6afff70e2aaf39e1511e16d471de7c3ae ] We need to check mddev->del_work before flush workqueu since the purpose of flush is to ensure the previous md is disappeared. Otherwise the similar deadlock appeared if LOCKDEP is enabled, it is due to md_open

[PATCH AUTOSEL 4.4 12/37] ath9k: Fix use-after-free Read in ath9k_wmi_ctrl_rx

2020-06-08 Thread Sasha Levin
From: Qiujun Huang [ Upstream commit abeaa85054ff8cfe8b99aafc5c70ea067e5d0908 ] Free wmi later after cmd urb has been killed, as urb cb will access wmi. the case reported by syzbot: https://lore.kernel.org/linux-usb/0002fc05a1d61...@google.com BUG: KASAN: use-after-free in

[PATCH AUTOSEL 4.4 20/37] net: allwinner: Fix use correct return type for ndo_start_xmit()

2020-06-08 Thread Sasha Levin
From: Yunjian Wang [ Upstream commit 09f6c44aaae0f1bdb8b983d7762676d5018c53bc ] The method ndo_start_xmit() returns a value of type netdev_tx_t. Fix the ndo function to use the correct type. And emac_start_xmit() can leak one skb if 'channel' == 3. Signed-off-by: Yunjian Wang Signed-off-by:

[PATCH AUTOSEL 4.9 37/50] x86/boot: Correct relocation destination on old linkers

2020-06-08 Thread Sasha Levin
From: Arvind Sankar [ Upstream commit 5214028dd89e49ba27007c3ee475279e584261f0 ] For the 32-bit kernel, as described in 6d92bc9d483a ("x86/build: Build compressed x86 kernels as PIE"), pre-2.26 binutils generates R_386_32 relocations in PIE mode. Since the startup code does not perform

[PATCH AUTOSEL 4.9 36/50] mwifiex: Fix memory corruption in dump_station

2020-06-08 Thread Sasha Levin
From: Pali Rohár [ Upstream commit 3aa42bae9c4d1641aeb36f1a8585cd1d506cf471 ] The mwifiex_cfg80211_dump_station() uses static variable for iterating over a linked list of all associated stations (when the driver is in UAP role). This has a race condition if .dump_station is called in parallel

[PATCH AUTOSEL 4.9 46/50] ixgbe: fix signed-integer-overflow warning

2020-06-08 Thread Sasha Levin
From: Xie XiuQi [ Upstream commit 3b70683fc4d68f5d915d9dc7e5ba72c732c7315c ] ubsan report this warning, fix it by adding a unsigned suffix. UBSAN: signed-integer-overflow in drivers/net/ethernet/intel/ixgbe/ixgbe_common.c:2246:26 65535 * 65537 cannot be represented in type 'int' CPU: 21 PID: 7

[PATCH AUTOSEL 4.9 47/50] mmc: sdhci-esdhc-imx: fix the mask for tuning start point

2020-06-08 Thread Sasha Levin
From: Haibo Chen [ Upstream commit 1194be8c949b8190b2882ad8335a5d98aa50c735 ] According the RM, the bit[6~0] of register ESDHC_TUNING_CTRL is TUNING_START_TAP, bit[7] of this register is to disable the command CRC check for standard tuning. So fix it here. Fixes: d87fc9663688 ("mmc:

[PATCH AUTOSEL 4.4 08/37] btrfs: do not ignore error from btrfs_next_leaf() when inserting checksums

2020-06-08 Thread Sasha Levin
From: Filipe Manana [ Upstream commit 7e4a3f7ed5d54926ec671bbb13e171cfe179cc50 ] We are currently treating any non-zero return value from btrfs_next_leaf() the same way, by going to the code that inserts a new checksum item in the tree. However if btrfs_next_leaf() returns an error (a value <

[PATCH AUTOSEL 4.9 49/50] cpuidle: Fix three reference count leaks

2020-06-08 Thread Sasha Levin
From: Qiushi Wu [ Upstream commit c343bf1ba5efcbf2266a1fe3baefec9cc82f867f ] kobject_init_and_add() takes reference even when it fails. If this function returns an error, kobject_put() must be called to properly clean up the memory associated with the object. Previous commit "b8eb718348b8"

[PATCH AUTOSEL 4.9 50/50] vxlan: Avoid infinite loop when suppressing NS messages with invalid options

2020-06-08 Thread Sasha Levin
From: Ido Schimmel [ Upstream commit 8066e6b449e050675df48e7c4b16c29f00507ff0 ] When proxy mode is enabled the vxlan device might reply to Neighbor Solicitation (NS) messages on behalf of remote hosts. In case the NS message includes the "Source link-layer address" option [1], the vxlan device

[PATCH AUTOSEL 4.9 15/50] staging: android: ion: use vmap instead of vm_map_ram

2020-06-08 Thread Sasha Levin
From: Christoph Hellwig [ Upstream commit 5bf9917452112694b2c774465ee4dbe441c84b77 ] vm_map_ram can keep mappings around after the vm_unmap_ram. Using that with non-PAGE_KERNEL mappings can lead to all kinds of aliasing issues. Signed-off-by: Christoph Hellwig Signed-off-by: Andrew Morton

[PATCH AUTOSEL 4.9 32/50] mips: cm: Fix an invalid error code of INTVN_*_ERR

2020-06-08 Thread Sasha Levin
From: Serge Semin [ Upstream commit 8a0efb8b101665a843205eab3d67ab09cb2d9a8d ] Commit 3885c2b463f6 ("MIPS: CM: Add support for reporting CM cache errors") adds cm2_causes[] array with map of error type ID and pointers to the short description string. There is a mistake in the table, since

[PATCH AUTOSEL 4.9 12/50] ARM: 8978/1: mm: make act_mm() respect THREAD_SIZE

2020-06-08 Thread Sasha Levin
From: Linus Walleij [ Upstream commit e1de94380af588bdf6ad6f0cc1f75004c35bc096 ] Recent work with KASan exposed the folling hard-coded bitmask in arch/arm/mm/proc-macros.S: bic rd, sp, #8128 bic rd, rd, #63 This forms the bitmask 0x1FFF that is coinciding with (PAGE_SIZE <<

[PATCH AUTOSEL 4.9 31/50] MIPS: Truncate link address into 32bit for 32bit kernel

2020-06-08 Thread Sasha Levin
From: Jiaxun Yang [ Upstream commit ff487d41036035376e47972c7c522490b839ab37 ] LLD failed to link vmlinux with 64bit load address for 32bit ELF while bfd will strip 64bit address into 32bit silently. To fix LLD build, we should truncate load address provided by platform into 32bit for 32bit

[PATCH AUTOSEL 4.9 07/50] Bluetooth: Add SCO fallback for invalid LMP parameters error

2020-06-08 Thread Sasha Levin
From: Hsin-Yu Chao [ Upstream commit 56b5453a86203a44726f523b4133c1feca49ce7c ] Bluetooth PTS test case HFP/AG/ACC/BI-12-I accepts SCO connection with invalid parameter at the first SCO request expecting AG to attempt another SCO request with the use of "safe settings" for given codec, base on

[PATCH AUTOSEL 4.9 16/50] ath9k: Fix use-after-free Read in ath9k_wmi_ctrl_rx

2020-06-08 Thread Sasha Levin
From: Qiujun Huang [ Upstream commit abeaa85054ff8cfe8b99aafc5c70ea067e5d0908 ] Free wmi later after cmd urb has been killed, as urb cb will access wmi. the case reported by syzbot: https://lore.kernel.org/linux-usb/0002fc05a1d61...@google.com BUG: KASAN: use-after-free in

[PATCH AUTOSEL 4.9 27/50] net: lpc-enet: fix error return code in lpc_mii_init()

2020-06-08 Thread Sasha Levin
From: Wei Yongjun [ Upstream commit 88ec7cb22ddde725ed4ce15991f0bd9dd817fd85 ] Fix to return a negative error code from the error handling case instead of 0, as done elsewhere in this function. Fixes: b7370112f519 ("lpc32xx: Added ethernet driver") Signed-off-by: Wei Yongjun Acked-by:

[PATCH AUTOSEL 4.9 02/50] ath9k: Fix use-after-free Write in ath9k_htc_rx_msg

2020-06-08 Thread Sasha Levin
From: Qiujun Huang [ Upstream commit e4ff08a4d727146bb6717a39a8d399d834654345 ] Write out of slab bounds. We should check epid. The case reported by syzbot: https://lore.kernel.org/linux-usb/6ac55b05a1c05...@google.com BUG: KASAN: use-after-free in htc_process_conn_rsp

[PATCH AUTOSEL 4.9 24/50] lib/mpi: Fix 64-bit MIPS build with Clang

2020-06-08 Thread Sasha Levin
From: Nathan Chancellor [ Upstream commit 18f1ca46858eac22437819937ae44aa9a8f9f2fa ] When building 64r6_defconfig with CONFIG_MIPS32_O32 disabled and CONFIG_CRYPTO_RSA enabled: lib/mpi/generic_mpih-mul1.c:37:24: error: invalid use of a cast in a inline asm context requiring an l-value: remove

[PATCH AUTOSEL 4.9 21/50] media: platform: fcp: Set appropriate DMA parameters

2020-06-08 Thread Sasha Levin
From: Kieran Bingham [ Upstream commit dd844fb8e50b12e65bbdc5746c9876c6735500df ] Enabling CONFIG_DMA_API_DEBUG=y and CONFIG_DMA_API_DEBUG_SG=y will enable extra validation on DMA operations ensuring that the size restraints are met. When using the FCP in conjunction with the VSP1/DU, and

[PATCH AUTOSEL 4.9 04/50] objtool: Ignore empty alternatives

2020-06-08 Thread Sasha Levin
From: Julien Thierry [ Upstream commit 7170cf47d16f1ba29eca07fd818870b7af0a93a5 ] The .alternatives section can contain entries with no original instructions. Objtool will currently crash when handling such an entry. Just skip that entry, but still give a warning to discourage useless entries.

[PATCH AUTOSEL 4.9 26/50] exit: Move preemption fixup up, move blocking operations down

2020-06-08 Thread Sasha Levin
From: Jann Horn [ Upstream commit 586b58cac8b4683eb58a1446fbc399de18974e40 ] With CONFIG_DEBUG_ATOMIC_SLEEP=y and CONFIG_CGROUPS=y, kernel oopses in non-preemptible context look untidy; after the main oops, the kernel prints a "sleeping function called from invalid context" report because

[PATCH AUTOSEL 4.9 05/50] net: ena: fix error returning in ena_com_get_hash_function()

2020-06-08 Thread Sasha Levin
From: Arthur Kiyanovski [ Upstream commit e9a1de378dd46375f9abfd8de1e6f59ee114a793 ] In case the "func" parameter is NULL we now return "-EINVAL". This shouldn't happen in general, but when it does happen, this is the proper way to handle it. We also check func for NULL in the beginning of the

[PATCH AUTOSEL 4.9 03/50] media: si2157: Better check for running tuner in init

2020-06-08 Thread Sasha Levin
From: Brad Love [ Upstream commit e955f959ac52e145f27ff2be9078b646d0352af0 ] Getting the Xtal trim property to check if running is less error prone. Reset if_frequency if state is unknown. Replaces the previous "garbage check". Signed-off-by: Brad Love Signed-off-by: Sean Young

[PATCH AUTOSEL 4.14 67/72] mmc: sdhci-esdhc-imx: fix the mask for tuning start point

2020-06-08 Thread Sasha Levin
From: Haibo Chen [ Upstream commit 1194be8c949b8190b2882ad8335a5d98aa50c735 ] According the RM, the bit[6~0] of register ESDHC_TUNING_CTRL is TUNING_START_TAP, bit[7] of this register is to disable the command CRC check for standard tuning. So fix it here. Fixes: d87fc9663688 ("mmc:

[PATCH AUTOSEL 4.14 42/72] powerpc/spufs: fix copy_to_user while atomic

2020-06-08 Thread Sasha Levin
From: Jeremy Kerr [ Upstream commit 88413a6bfbbe2f648df399b62f85c934460b7a4d ] Currently, we may perform a copy_to_user (through simple_read_from_buffer()) while holding a context's register_lock, while accessing the context save area. This change uses a temporary buffer for the context save

[PATCH AUTOSEL 4.14 57/72] x86/mm: Stop printing BRK addresses

2020-06-08 Thread Sasha Levin
From: Arvind Sankar [ Upstream commit 67d631b7c05eff955ccff4139327f0f92a5117e5 ] This currently leaks kernel physical addresses into userspace. Signed-off-by: Arvind Sankar Signed-off-by: Borislav Petkov Acked-by: Kees Cook Acked-by: Dave Hansen Link:

[PATCH AUTOSEL 4.14 46/72] mips: cm: Fix an invalid error code of INTVN_*_ERR

2020-06-08 Thread Sasha Levin
From: Serge Semin [ Upstream commit 8a0efb8b101665a843205eab3d67ab09cb2d9a8d ] Commit 3885c2b463f6 ("MIPS: CM: Add support for reporting CM cache errors") adds cm2_causes[] array with map of error type ID and pointers to the short description string. There is a mistake in the table, since

[PATCH AUTOSEL 4.14 40/72] media: cec: silence shift wrapping warning in __cec_s_log_addrs()

2020-06-08 Thread Sasha Levin
From: Dan Carpenter [ Upstream commit 3b5af3171e2d5a73ae6f04965ed653d039904eb6 ] The log_addrs->log_addr_type[i] value is a u8 which is controlled by the user and comes from the ioctl. If it's over 31 then that results in undefined behavior (shift wrapping) and that leads to a Smatch static

[PATCH AUTOSEL 4.14 48/72] nvme: refine the Qemu Identify CNS quirk

2020-06-08 Thread Sasha Levin
From: Christoph Hellwig [ Upstream commit b9a5c3d4c34d8bd9fd75f7f28d18a57cb68da237 ] Add a helper to check if we can use Identify CNS values > 1, and refine the Qemu quirk to not apply to reported versions larger than 1.1, as the Qemu implementation had been fixed by then. Signed-off-by:

[PATCH AUTOSEL 4.14 36/72] lib/mpi: Fix 64-bit MIPS build with Clang

2020-06-08 Thread Sasha Levin
From: Nathan Chancellor [ Upstream commit 18f1ca46858eac22437819937ae44aa9a8f9f2fa ] When building 64r6_defconfig with CONFIG_MIPS32_O32 disabled and CONFIG_CRYPTO_RSA enabled: lib/mpi/generic_mpih-mul1.c:37:24: error: invalid use of a cast in a inline asm context requiring an l-value: remove

[PATCH AUTOSEL 4.14 54/72] x86/boot: Correct relocation destination on old linkers

2020-06-08 Thread Sasha Levin
From: Arvind Sankar [ Upstream commit 5214028dd89e49ba27007c3ee475279e584261f0 ] For the 32-bit kernel, as described in 6d92bc9d483a ("x86/build: Build compressed x86 kernels as PIE"), pre-2.26 binutils generates R_386_32 relocations in PIE mode. Since the startup code does not perform

[PATCH AUTOSEL 4.14 53/72] mwifiex: Fix memory corruption in dump_station

2020-06-08 Thread Sasha Levin
From: Pali Rohár [ Upstream commit 3aa42bae9c4d1641aeb36f1a8585cd1d506cf471 ] The mwifiex_cfg80211_dump_station() uses static variable for iterating over a linked list of all associated stations (when the driver is in UAP role). This has a race condition if .dump_station is called in parallel

[PATCH AUTOSEL 4.14 30/72] media: dvb: return -EREMOTEIO on i2c transfer failure.

2020-06-08 Thread Sasha Levin
From: Colin Ian King [ Upstream commit 96f3a9392799dd0f6472648a7366622ffd0989f3 ] Currently when i2c transfers fail the error return -EREMOTEIO is assigned to err but then later overwritten when the tuner attach call is made. Fix this by returning early with the error return code -EREMOTEIO on

[PATCH AUTOSEL 4.14 51/72] md: don't flush workqueue unconditionally in md_open

2020-06-08 Thread Sasha Levin
From: Guoqing Jiang [ Upstream commit f6766ff6afff70e2aaf39e1511e16d471de7c3ae ] We need to check mddev->del_work before flush workqueu since the purpose of flush is to ensure the previous md is disappeared. Otherwise the similar deadlock appeared if LOCKDEP is enabled, it is due to md_open

[PATCH AUTOSEL 4.14 33/72] audit: fix a net reference leak in audit_list_rules_send()

2020-06-08 Thread Sasha Levin
From: Paul Moore [ Upstream commit 3054d06719079388a543de6adb812638675ad8f5 ] If audit_list_rules_send() fails when trying to create a new thread to send the rules it also fails to cleanup properly, leaking a reference to a net structure. This patch fixes the error patch and renames

[PATCH AUTOSEL 4.14 23/72] ath9k: Fix use-after-free Read in ath9k_wmi_ctrl_rx

2020-06-08 Thread Sasha Levin
From: Qiujun Huang [ Upstream commit abeaa85054ff8cfe8b99aafc5c70ea067e5d0908 ] Free wmi later after cmd urb has been killed, as urb cb will access wmi. the case reported by syzbot: https://lore.kernel.org/linux-usb/0002fc05a1d61...@google.com BUG: KASAN: use-after-free in

[PATCH AUTOSEL 4.14 16/72] clocksource: dw_apb_timer_of: Fix missing clockevent timers

2020-06-08 Thread Sasha Levin
From: Serge Semin [ Upstream commit 6d2e16a3181bafb77b535095c39ad1c8b9558c8c ] Commit 100214889973 ("clocksource: dw_apb_timer_of: use clocksource_of_init") replaced a publicly available driver initialization method with one called by the timer_probe() method available after CLKSRC_OF. In

[PATCH AUTOSEL 4.19 096/106] mmc: via-sdmmc: Respect the cmd->busy_timeout from the mmc core

2020-06-08 Thread Sasha Levin
From: Ulf Hansson [ Upstream commit 966244ccd2919e28f2a77f204cd1c109cad8 ] Using a fixed 1s timeout for all commands (and data transfers) is a bit problematic. For some commands it means waiting longer than needed for the timer to expire, which may not a big issue, but still. For other

[PATCH AUTOSEL 4.14 09/72] spi: dw: Zero DMA Tx and Rx configurations on stack

2020-06-08 Thread Sasha Levin
From: Andy Shevchenko [ Upstream commit 3cb97e223d277f84171cc4ccecab31e08b2ee7b5 ] Some DMA controller drivers do not tolerate non-zero values in the DMA configuration structures. Zero them to avoid issues with such DMA controller drivers. Even despite above this is a good practice per se.

[PATCH AUTOSEL 4.19 095/106] staging: greybus: sdio: Respect the cmd->busy_timeout from the mmc core

2020-06-08 Thread Sasha Levin
From: Ulf Hansson [ Upstream commit a389087ee9f195fcf2f31cd771e9ec5f02c16650 ] Using a fixed 1s timeout for all commands is a bit problematic. For some commands it means waiting longer than needed for the timeout to expire, which may not a big issue, but still. For other commands, like for an

Re: [PATCH v2 1/3] platform/x86: dell-wmi: add new backlight events

2020-06-08 Thread Pali Rohár
On Monday 08 June 2020 19:05:28 Y Paritcher wrote: > Add events with a type of 0x0010 and a code of 0x57 / 0x58, > this silences the following messages being logged on a > Dell Inspiron 5593: > > dell_wmi: Unknown key with type 0x0010 and code 0x0057 pressed > dell_wmi: Unknown key with type

[PATCH AUTOSEL 4.14 17/72] btrfs: do not ignore error from btrfs_next_leaf() when inserting checksums

2020-06-08 Thread Sasha Levin
From: Filipe Manana [ Upstream commit 7e4a3f7ed5d54926ec671bbb13e171cfe179cc50 ] We are currently treating any non-zero return value from btrfs_next_leaf() the same way, by going to the code that inserts a new checksum item in the tree. However if btrfs_next_leaf() returns an error (a value <

[PATCH AUTOSEL 4.19 097/106] ixgbe: fix signed-integer-overflow warning

2020-06-08 Thread Sasha Levin
From: Xie XiuQi [ Upstream commit 3b70683fc4d68f5d915d9dc7e5ba72c732c7315c ] ubsan report this warning, fix it by adding a unsigned suffix. UBSAN: signed-integer-overflow in drivers/net/ethernet/intel/ixgbe/ixgbe_common.c:2246:26 65535 * 65537 cannot be represented in type 'int' CPU: 21 PID: 7

[PATCH AUTOSEL 4.14 18/72] ARM: 8978/1: mm: make act_mm() respect THREAD_SIZE

2020-06-08 Thread Sasha Levin
From: Linus Walleij [ Upstream commit e1de94380af588bdf6ad6f0cc1f75004c35bc096 ] Recent work with KASan exposed the folling hard-coded bitmask in arch/arm/mm/proc-macros.S: bic rd, sp, #8128 bic rd, rd, #63 This forms the bitmask 0x1FFF that is coinciding with (PAGE_SIZE <<

[PATCH AUTOSEL 4.14 08/72] net: ena: fix error returning in ena_com_get_hash_function()

2020-06-08 Thread Sasha Levin
From: Arthur Kiyanovski [ Upstream commit e9a1de378dd46375f9abfd8de1e6f59ee114a793 ] In case the "func" parameter is NULL we now return "-EINVAL". This shouldn't happen in general, but when it does happen, this is the proper way to handle it. We also check func for NULL in the beginning of the

[PATCH AUTOSEL 4.14 02/72] ath9k: Fix use-after-free Write in ath9k_htc_rx_msg

2020-06-08 Thread Sasha Levin
From: Qiujun Huang [ Upstream commit e4ff08a4d727146bb6717a39a8d399d834654345 ] Write out of slab bounds. We should check epid. The case reported by syzbot: https://lore.kernel.org/linux-usb/6ac55b05a1c05...@google.com BUG: KASAN: use-after-free in htc_process_conn_rsp

[PATCH AUTOSEL 4.19 105/106] net_failover: fixed rollback in net_failover_open()

2020-06-08 Thread Sasha Levin
From: Vasily Averin [ Upstream commit e8224bfe77293494626f6eec1884fee7b87d0ced ] found by smatch: drivers/net/net_failover.c:65 net_failover_open() error: we previously assumed 'primary_dev' could be null (see line 43) Fixes: cfc80d9a1163 ("net: Introduce net_failover driver") Signed-off-by:

[PATCH AUTOSEL 4.19 100/106] cpuidle: Fix three reference count leaks

2020-06-08 Thread Sasha Levin
From: Qiushi Wu [ Upstream commit c343bf1ba5efcbf2266a1fe3baefec9cc82f867f ] kobject_init_and_add() takes reference even when it fails. If this function returns an error, kobject_put() must be called to properly clean up the memory associated with the object. Previous commit "b8eb718348b8"

[PATCH AUTOSEL 4.19 106/106] string.h: fix incompatibility between FORTIFY_SOURCE and KASAN

2020-06-08 Thread Sasha Levin
From: Daniel Axtens [ Upstream commit 47227d27e2fcb01a9e8f5958d8997cf47a820afc ] The memcmp KASAN self-test fails on a kernel with both KASAN and FORTIFY_SOURCE. When FORTIFY_SOURCE is on, a number of functions are replaced with fortified versions, which attempt to check the sizes of the

[PATCH AUTOSEL 4.19 099/106] spi: dw: Return any value retrieved from the dma_transfer callback

2020-06-08 Thread Sasha Levin
From: Serge Semin [ Upstream commit f0410bbf7d0fb80149e3b17d11d31f5b5197873e ] DW APB SSI DMA-part of the driver may need to perform the requested SPI-transfer synchronously. In that case the dma_transfer() callback will return 0 as a marker of the SPI transfer being finished so the SPI core

[PATCH AUTOSEL 4.19 087/106] net: ethernet: fec: move GPR register offset and bit into DT

2020-06-08 Thread Sasha Levin
From: Fugang Duan [ Upstream commit 8a448bf832af537d26aa557d183a16943dce4510 ] The commit da722186f654 (net: fec: set GPR bit on suspend by DT configuration) set the GPR reigster offset and bit in driver for wake on lan feature. But it introduces two issues here: - one SOC has two instances,

[PATCH AUTOSEL 4.19 085/106] m68k: mac: Don't call via_flush_cache() on Mac IIfx

2020-06-08 Thread Sasha Levin
From: Finn Thain [ Upstream commit bcc44f6b74106b31f0b0408b70305a40360d63b7 ] There is no VIA2 chip on the Mac IIfx, so don't call via_flush_cache(). This avoids a boot crash which appeared in v5.4. printk: console [ttyS0] enabled printk: bootconsole [debug0] disabled printk: bootconsole

[PATCH AUTOSEL 4.19 090/106] MIPS: Fix IRQ tracing when call handle_fpe() and handle_msa_fpe()

2020-06-08 Thread Sasha Levin
From: YuanJunQing [ Upstream commit 31e1b3efa802f97a17628dde280006c4cee4ce5e ] Register "a1" is unsaved in this function, when CONFIG_TRACE_IRQFLAGS is enabled, the TRACE_IRQS_OFF macro will call trace_hardirqs_off(), and this may change register "a1". The changed register "a1" as argument

[PATCH AUTOSEL 4.19 068/106] ath10k: Remove msdu from idr when management pkt send fails

2020-06-08 Thread Sasha Levin
From: Rakesh Pillai [ Upstream commit c730c477176ad4af86d9aae4d360a7ad840b073a ] Currently when the sending of any management pkt via wmi command fails, the packet is being unmapped freed in the error handling. But the idr entry added, which is used to track these packet is not getting removed.

[PATCH AUTOSEL 4.19 082/106] crypto: stm32/crc32 - fix run-time self test issue.

2020-06-08 Thread Sasha Levin
From: Nicolas Toromanoff [ Upstream commit a8cc3128bf2c01c4d448fe17149e87132113b445 ] Fix wrong crc32 initialisation value: "alg: shash: stm32_crc32 test failed (wrong result) on test vector 0, cfg="init+update+final aligned buffer" cra_name="crc32c" expects an init value of 0X,

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