[PATCH 5.4 18/43] net: DCB: Validate DCB_ATTR_DCB_BUFFER argument

2020-09-25 Thread Greg Kroah-Hartman
From: Petr Machata [ Upstream commit 297e77e53eadb332d5062913447b104a772dc33b ] The parameter passed via DCB_ATTR_DCB_BUFFER is a struct dcbnl_buffer. The field prio2buffer is an array of IEEE_8021Q_MAX_PRIORITIES bytes, where each value is a number of a buffer to direct that priority's traffic

[PATCH 5.8 36/56] net: lantiq: use netif_tx_napi_add() for TX NAPI

2020-09-25 Thread Greg Kroah-Hartman
From: Hauke Mehrtens [ Upstream commit 74c7b80e222b58d3cea731d31e2a31a77fea8345 ] netif_tx_napi_add() should be used for NAPI in the TX direction instead of the netif_napi_add() function. Signed-off-by: Hauke Mehrtens Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman --- driv

[PATCH 5.4 35/43] net: lantiq: use netif_tx_napi_add() for TX NAPI

2020-09-25 Thread Greg Kroah-Hartman
From: Hauke Mehrtens [ Upstream commit 74c7b80e222b58d3cea731d31e2a31a77fea8345 ] netif_tx_napi_add() should be used for NAPI in the TX direction instead of the netif_napi_add() function. Signed-off-by: Hauke Mehrtens Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman --- driv

[PATCH 5.4 17/43] net: bridge: br_vlan_get_pvid_rcu() should dereference the VLAN group under RCU

2020-09-25 Thread Greg Kroah-Hartman
From: Vladimir Oltean [ Upstream commit 99f62a746066fa436aa15d4606a538569540db08 ] When calling the RCU brother of br_vlan_get_pvid(), lockdep warns: = WARNING: suspicious RCU usage 5.9.0-rc3-01631-g13c17acb8e38-dirty #814 Not tainted - ne

[PATCH 5.8 51/56] net: dsa: microchip: ksz8795: really set the correct number of ports

2020-09-25 Thread Greg Kroah-Hartman
From: Matthias Schiffer [ Upstream commit fd944dc24336922656a48f4608bfb41abdcdc4aa ] The KSZ9477 and KSZ8795 use the port_cnt field differently: For the KSZ9477, it includes the CPU port(s), while for the KSZ8795, it doesn't. It would be a good cleanup to make the handling of both drivers match

[PATCH 5.8 42/56] net: add __must_check to skb_put_padto()

2020-09-25 Thread Greg Kroah-Hartman
From: Eric Dumazet [ Upstream commit 4a009cb04aeca0de60b73f37b102573354214b52 ] skb_put_padto() and __skb_put_padto() callers must check return values or risk use-after-free. Signed-off-by: Eric Dumazet Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman --- include/linux/skbuf

[PATCH 4.19 21/37] net: qrtr: check skb_put_padto() return value

2020-09-25 Thread Greg Kroah-Hartman
From: Eric Dumazet [ Upstream commit 3ca1a42a52ca4b4f02061683851692ad65fefac8 ] If skb_put_padto() returns an error, skb has been freed. Better not touch it anymore, as reported by syzbot [1] Note to qrtr maintainers : this suggests qrtr_sendmsg() should adjust sock_alloc_send_skb() second para

[PATCH 4.19 14/37] nfp: use correct define to return NONE fec

2020-09-25 Thread Greg Kroah-Hartman
From: Jakub Kicinski [ Upstream commit 5f6857e808a8bd078296575b417c4b9d160b9779 ] struct ethtool_fecparam carries bitmasks not bit numbers. We want to return 1 (NONE), not 0. Fixes: 0d0870938337 ("nfp: implement ethtool FEC mode settings") Signed-off-by: Jakub Kicinski Reviewed-by: Simon Horma

[PATCH 4.19 26/37] Documentation/llvm: add documentation on building w/ Clang/LLVM

2020-09-25 Thread Greg Kroah-Hartman
From: Nick Desaulniers commit fcf1b6a35c16ac500fa908a4022238e5d666eabf upstream. added to kbuild documentation. Provides more official info on building kernels with Clang and LLVM than our wiki. Suggested-by: Kees Cook Reviewed-by: Kees Cook Reviewed-by: Nathan Chancellor Reviewed-by: Sedat

[PATCH 4.19 12/37] net: ipv6: fix kconfig dependency warning for IPV6_SEG6_HMAC

2020-09-25 Thread Greg Kroah-Hartman
From: Necip Fazil Yildiran [ Upstream commit db7cd91a4be15e1485d6b58c6afc8761c59c4efb ] When IPV6_SEG6_HMAC is enabled and CRYPTO is disabled, it results in the following Kbuild warning: WARNING: unmet direct dependencies detected for CRYPTO_HMAC Depends on [n]: CRYPTO [=n] Selected by [y]:

[PATCH 5.4 14/43] ipv4: Initialize flowi4_multipath_hash in data path

2020-09-25 Thread Greg Kroah-Hartman
From: David Ahern [ Upstream commit 1869e226a7b3ef75b4f70ede2f1b7229f7157fa4 ] flowi4_multipath_hash was added by the commit referenced below for tunnels. Unfortunately, the patch did not initialize the new field for several fast path lookups that do not initialize the entire flow struct to 0. F

[PATCH 5.4 41/43] net: add __must_check to skb_put_padto()

2020-09-25 Thread Greg Kroah-Hartman
From: Eric Dumazet [ Upstream commit 4a009cb04aeca0de60b73f37b102573354214b52 ] skb_put_padto() and __skb_put_padto() callers must check return values or risk use-after-free. Signed-off-by: Eric Dumazet Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman --- include/linux/skbuf

[PATCH 4.19 20/37] net: phy: Avoid NPD upon phy_detach() when driver is unbound

2020-09-25 Thread Greg Kroah-Hartman
From: Florian Fainelli [ Upstream commit c2b727df7caa33876e7066bde090f40001b6d643 ] If we have unbound the PHY driver prior to calling phy_detach() (often via phy_disconnect()) then we can cause a NULL pointer de-reference accessing the driver owner member. The steps to reproduce are: echo unim

[PATCH 5.4 13/43] ip: fix tos reflection in ack and reset packets

2020-09-25 Thread Greg Kroah-Hartman
From: Wei Wang [ Upstream commit ba9e04a7ddf4f22a10e05bf9403db6b97743c7bf ] Currently, in tcp_v4_reqsk_send_ack() and tcp_v4_send_reset(), we echo the TOS value of the received packets in the response. However, we do not want to echo the lower 2 ECN bits in accordance with RFC 3168 6.1.5 robustn

[PATCH 4.19 16/37] tipc: fix shutdown() of connection oriented socket

2020-09-25 Thread Greg Kroah-Hartman
From: Tetsuo Handa [ Upstream commit a4b5cc9e10803ecba64a7d54c0f47e4564b4a980 ] I confirmed that the problem fixed by commit 2a63866c8b51a3f7 ("tipc: fix shutdown() of connectionless socket") also applies to stream socket. -- #include #include #include int main(int argc, char *argv[

[PATCH 4.19 17/37] tipc: use skb_unshare() instead in tipc_buf_append()

2020-09-25 Thread Greg Kroah-Hartman
From: Xin Long [ Upstream commit ff48b6222e65ebdba5a403ef1deba6214e749193 ] In tipc_buf_append() it may change skb's frag_list, and it causes problems when this skb is cloned. skb_unclone() doesn't really make this skb's flag_list available to change. Shuang Li has reported an use-after-free is

[PATCH 4.19 02/37] KVM: fix memory leak in kvm_io_bus_unregister_dev()

2020-09-25 Thread Greg Kroah-Hartman
From: Rustam Kovhaev [ Upstream commit f65886606c2d3b562716de030706dfe1bea4ed5e ] when kmalloc() fails in kvm_io_bus_unregister_dev(), before removing the bus, we should iterate over all other devices linked to it and call kvm_iodevice_destructor() for them Fixes: 90db10434b16 ("KVM: kvm_io_bus

[PATCH 5.4 36/43] net: lantiq: Use napi_complete_done()

2020-09-25 Thread Greg Kroah-Hartman
From: Hauke Mehrtens [ Upstream commit c582a7fea9dad4d309437d1a7e22e6d2cb380e2e ] Use napi_complete_done() and activate the interrupts when this function returns true. This way the generic NAPI code can take care of activating the interrupts. Signed-off-by: Hauke Mehrtens Signed-off-by: David

[PATCH 4.19 07/37] hdlc_ppp: add range checks in ppp_cp_parse_cr()

2020-09-25 Thread Greg Kroah-Hartman
From: Dan Carpenter [ Upstream commit 66d42ed8b25b64eb63111a2b8582c5afc8bf1105 ] There are a couple bugs here: 1) If opt[1] is zero then this results in a forever loop. If the value is less than 2 then it is invalid. 2) It assumes that "len" is more than sizeof(valid_accm) or 6 which can

[PATCH 4.19 22/37] net: add __must_check to skb_put_padto()

2020-09-25 Thread Greg Kroah-Hartman
From: Eric Dumazet [ Upstream commit 4a009cb04aeca0de60b73f37b102573354214b52 ] skb_put_padto() and __skb_put_padto() callers must check return values or risk use-after-free. Signed-off-by: Eric Dumazet Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman --- include/linux/skbuf

[PATCH 4.19 03/37] kprobes: fix kill kprobe which has been marked as gone

2020-09-25 Thread Greg Kroah-Hartman
From: Muchun Song [ Upstream commit b0399092ccebd9feef68d4ceb8d6219a8c0caa05 ] If a kprobe is marked as gone, we should not kill it again. Otherwise, we can disarm the kprobe more than once. In that case, the statistics of kprobe_ftrace_enabled can unbalance which can lead to that kprobe do no

[PATCH 5.4 38/43] net: phy: Avoid NPD upon phy_detach() when driver is unbound

2020-09-25 Thread Greg Kroah-Hartman
From: Florian Fainelli [ Upstream commit c2b727df7caa33876e7066bde090f40001b6d643 ] If we have unbound the PHY driver prior to calling phy_detach() (often via phy_disconnect()) then we can cause a NULL pointer de-reference accessing the driver owner member. The steps to reproduce are: echo unim

[PATCH 4.19 13/37] net: sch_generic: aviod concurrent reset and enqueue op for lockless qdisc

2020-09-25 Thread Greg Kroah-Hartman
From: Yunsheng Lin [ Upstream commit 2fb541c862c987d02dfdf28f1545016deecfa0d5 ] Currently there is concurrent reset and enqueue operation for the same lockless qdisc when there is no lock to synchronize the q->enqueue() in __dev_xmit_skb() with the qdisc reset operation in qdisc_deactivate() cal

[PATCH 4.19 11/37] net: dsa: rtl8366: Properly clear member config

2020-09-25 Thread Greg Kroah-Hartman
From: Linus Walleij [ Upstream commit 4ddcaf1ebb5e4e99240f29d531ee69d4244fe416 ] When removing a port from a VLAN we are just erasing the member config for the VLAN, which is wrong: other ports can be using it. Just mask off the port and only zero out the rest of the member config once ports us

[PATCH 4.19 15/37] tipc: Fix memory leak in tipc_group_create_member()

2020-09-25 Thread Greg Kroah-Hartman
From: Peilin Ye [ Upstream commit bb3a420d47ab00d7e1e5083286cab15235a96680 ] tipc_group_add_to_tree() returns silently if `key` matches `nkey` of an existing node, causing tipc_group_create_member() to leak memory. Let tipc_group_add_to_tree() return an error in such a case, so that tipc_group_c

[PATCH 4.19 32/37] kbuild: replace AS=clang with LLVM_IAS=1

2020-09-25 Thread Greg Kroah-Hartman
From: Masahiro Yamada commit 7e20e47c70f810d678d02941fa3c671209c4ca97 upstream. The 'AS' variable is unused for building the kernel. Only the remaining usage is to turn on the integrated assembler. A boolean flag is a better fit for this purpose. AS=clang was added for experts. So, I replaced i

[PATCH 4.19 04/37] mm/thp: fix __split_huge_pmd_locked() for migration PMD

2020-09-25 Thread Greg Kroah-Hartman
From: Ralph Campbell [ Upstream commit ec0abae6dcdf7ef88607c869bf35a4b63ce1b370 ] A migrating transparent huge page has to already be unmapped. Otherwise, the page could be modified while it is being copied to a new page and data could be lost. The function __split_huge_pmd() checks for a PMD

[PATCH 5.4 39/43] net: phy: Do not warn in phy_stop() on PHY_DOWN

2020-09-25 Thread Greg Kroah-Hartman
From: Florian Fainelli [ Upstream commit 5116a8ade333b6c2e180782139c9c516a437b21c ] When phy_is_started() was added to catch incorrect PHY states, phy_stop() would not be qualified against PHY_DOWN. It is possible to reach that state when the PHY driver has been unbound and the network device is

[PATCH 4.19 31/37] kbuild: remove AS variable

2020-09-25 Thread Greg Kroah-Hartman
From: Masahiro Yamada commit aa824e0c962b532d5073cbb41b2efcd6f5e72bae upstream. As commit 5ef872636ca7 ("kbuild: get rid of misleading $(AS) from documents") noted, we rarely use $(AS) directly in the kernel build. Now that the only/last user of $(AS) in drivers/net/wan/Makefile was converted t

[PATCH 4.19 33/37] kbuild: support LLVM=1 to switch the default tools to Clang/LLVM

2020-09-25 Thread Greg Kroah-Hartman
From: Masahiro Yamada commit a0d1c951ef08ed24f35129267e3595d86f57f5d3 upstream. As Documentation/kbuild/llvm.rst implies, building the kernel with a full set of LLVM tools gets very verbose and unwieldy. Provide a single switch LLVM=1 to use Clang and LLVM tools instead of GCC and Binutils. You

[PATCH 4.19 23/37] ipv4: Update exception handling for multipath routes via same device

2020-09-25 Thread Greg Kroah-Hartman
From: David Ahern [ Upstream commit 2fbc6e89b2f1403189e624cabaf73e189c5e50c6 ] Kfir reported that pmtu exceptions are not created properly for deployments where multipath routes use the same device. After some digging I see 2 compounding problems: 1. ip_route_output_key_hash_rcu is updating the

[PATCH 4.19 27/37] Documentation/llvm: fix the name of llvm-size

2020-09-25 Thread Greg Kroah-Hartman
From: Fangrui Song commit 0f44fbc162b737ff6251ae248184390ae2279fee upstream. The tool is called llvm-size, not llvm-objsize. Fixes: fcf1b6a35c16 ("Documentation/llvm: add documentation on building w/ Clang/LLVM") Signed-off-by: Fangrui Song Reviewed-by: Nick Desaulniers Reviewed-by: Nathan C

[PATCH 4.19 25/37] kbuild: add OBJSIZE variable for the size tool

2020-09-25 Thread Greg Kroah-Hartman
From: Vasily Gorbik commit 7bac98707f65b93bf994ef4e99b1eb9e7dbb9c32 upstream. Define and export OBJSIZE variable for "size" tool from binutils to be used in architecture specific Makefiles (naming the variable just "SIZE" would be too risky). In particular this tool is useful to perform checks t

[PATCH 4.19 34/37] mm: memcg: fix memcg reclaim soft lockup

2020-09-25 Thread Greg Kroah-Hartman
From: Xunlei Pang commit e3336cab2579012b1e72b5265adf98e2d6e244ad upstream. We've met softlockup with "CONFIG_PREEMPT_NONE=y", when the target memcg doesn't have any reclaimable memory. It can be easily reproduced as below: watchdog: BUG: soft lockup - CPU#0 stuck for 111s![memcg_test:2204]

[PATCH 4.19 09/37] ipv6: avoid lockdep issue in fib6_del()

2020-09-25 Thread Greg Kroah-Hartman
From: Eric Dumazet [ Upstream commit 843d926b003ea692468c8cc5bea1f9f58dfa8c75 ] syzbot reported twice a lockdep issue in fib6_del() [1] which I think is caused by net->ipv6.fib6_null_entry having a NULL fib6_table pointer. fib6_del() already checks for fib6_null_entry special case, we only need

[PATCH 4.19 37/37] serial: 8250: Avoid error message on reprobe

2020-09-25 Thread Greg Kroah-Hartman
From: Lukas Wunner commit e0a851fe6b9b619527bd928aa93caaddd003f70c upstream. If the call to uart_add_one_port() in serial8250_register_8250_port() fails, a half-initialized entry in the serial_8250ports[] array is left behind. A subsequent reprobe of the same serial port causes that entry to be

[PATCH 4.19 30/37] x86/boot: kbuild: allow readelf executable to be specified

2020-09-25 Thread Greg Kroah-Hartman
From: Dmitry Golovin commit eefb8c124fd969e9a174ff2bedff86aa305a7438 upstream. Introduce a new READELF variable to top-level Makefile, so the name of readelf binary can be specified. Before this change the name of the binary was hardcoded to "$(CROSS_COMPILE)readelf" which might not be present

[PATCH 4.19 35/37] tcp_bbr: refactor bbr_target_cwnd() for general inflight provisioning

2020-09-25 Thread Greg Kroah-Hartman
From: Priyaranjan Jha commit 232aa8ec3ed979d4716891540c03a806ecab0c37 upstream. Because bbr_target_cwnd() is really a general-purpose BBR helper for computing some volume of inflight data as a function of the estimated BDP, refactor it into following helper functions: - bbr_bdp() - bbr_quantizat

[PATCH 4.19 28/37] net: wan: wanxl: use allow to pass CROSS_COMPILE_M68k for rebuilding firmware

2020-09-25 Thread Greg Kroah-Hartman
From: Masahiro Yamada commit 63b903dfebdea92aa92ad337d8451a6fbfeabf9d upstream. As far as I understood from the Kconfig help text, this build rule is used to rebuild the driver firmware, which runs on an old m68k-based chip. So, you need m68k tools for the firmware rebuild. wanxl.c is a PCI dri

[PATCH 4.19 24/37] MAINTAINERS: add CLANG/LLVM BUILD SUPPORT info

2020-09-25 Thread Greg Kroah-Hartman
From: Nick Desaulniers commit 8708e13c6a0600625eea3aebd027c0715a5d2bb2 upstream. Add keyword support so that our mailing list gets cc'ed for clang/llvm patches. We're pretty active on our mailing list so far as code review. There are numerous Googlers like myself that are paid to support buildi

[PATCH 4.19 10/37] net: DCB: Validate DCB_ATTR_DCB_BUFFER argument

2020-09-25 Thread Greg Kroah-Hartman
From: Petr Machata [ Upstream commit 297e77e53eadb332d5062913447b104a772dc33b ] The parameter passed via DCB_ATTR_DCB_BUFFER is a struct dcbnl_buffer. The field prio2buffer is an array of IEEE_8021Q_MAX_PRIORITIES bytes, where each value is a number of a buffer to direct that priority's traffic

[PATCH 4.19 29/37] net: wan: wanxl: use $(M68KCC) instead of $(M68KAS) for rebuilding firmware

2020-09-25 Thread Greg Kroah-Hartman
From: Masahiro Yamada commit 734f3719d3438f9cc181d674c33ca9762e9148a1 upstream. The firmware source, wanxlfw.S, is currently compiled by the combo of $(CPP) and $(M68KAS). This is not what we usually do for compiling *.S files. In fact, this Makefile is the only user of $(AS) in the kernel build

[PATCH 4.19 36/37] tcp_bbr: adapt cwnd based on ack aggregation estimation

2020-09-25 Thread Greg Kroah-Hartman
From: Priyaranjan Jha commit 78dc70ebaa38aa303274e333be6c98eef87619e2 upstream. Aggregation effects are extremely common with wifi, cellular, and cable modem link technologies, ACK decimation in middleboxes, and LRO and GRO in receiving hosts. The aggregation can happen in either direction, data

[PATCH 4.19 18/37] bnxt_en: return proper error codes in bnxt_show_temp

2020-09-25 Thread Greg Kroah-Hartman
From: Edwin Peer [ Upstream commit d69753fa1ecb3218b56b022722f7a5822735b876 ] Returning "unknown" as a temperature value violates the hwmon interface rules. Appropriate error codes should be returned via device_attribute show instead. These will ultimately be propagated to the user via the file

[PATCH 4.19 08/37] ip: fix tos reflection in ack and reset packets

2020-09-25 Thread Greg Kroah-Hartman
From: Wei Wang [ Upstream commit ba9e04a7ddf4f22a10e05bf9403db6b97743c7bf ] Currently, in tcp_v4_reqsk_send_ack() and tcp_v4_send_reset(), we echo the TOS value of the received packets in the response. However, we do not want to echo the lower 2 ECN bits in accordance with RFC 3168 6.1.5 robustn

[PATCH 4.19 01/37] af_key: pfkey_dump needs parameter validation

2020-09-25 Thread Greg Kroah-Hartman
From: Mark Salyzyn commit 37bd22420f856fcd976989f1d4f1f7ad28e1fcac upstream. In pfkey_dump() dplen and splen can both be specified to access the xfrm_address_t structure out of bounds in__xfrm_state_filter_match() when it calls addr_match() with the indexes. Return EINVAL if either are out of r

[PATCH 4.19 05/37] cxgb4: Fix offset when clearing filter byte counters

2020-09-25 Thread Greg Kroah-Hartman
From: Ganji Aravind [ Upstream commit 94cc242a067a869c29800aa789d38b7676136e50 ] Pass the correct offset to clear the stale filter hit bytes counter. Otherwise, the counter starts incrementing from the stale information, instead of 0. Fixes: 12b276fbf6e0 ("cxgb4: add support to create hash filt

[PATCH 4.19 00/37] 4.19.148-rc1 review

2020-09-25 Thread Greg Kroah-Hartman
This is the start of the stable review cycle for the 4.19.148 release. There are 37 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 Sun, 27 Sep 2020 12:47:02 +. Anything re

[PATCH 4.19 19/37] bnxt_en: Protect bnxt_set_eee() and bnxt_set_pauseparam() with mutex.

2020-09-25 Thread Greg Kroah-Hartman
From: Michael Chan [ Upstream commit a53906908148d64423398a62c4435efb0d09652c ] All changes related to bp->link_info require the protection of the link_lock mutex. It's not sufficient to rely just on RTNL. Fixes: 163e9ef63641 ("bnxt_en: Fix race when modifying pause settings.") Reviewed-by: Ed

[PATCH 4.19 06/37] geneve: add transport ports in route lookup for geneve

2020-09-25 Thread Greg Kroah-Hartman
From: Mark Gray [ Upstream commit 34beb21594519ce64a55a498c2fe7d567bc1ca20 ] This patch adds transport ports information for route lookup so that IPsec can select Geneve tunnel traffic to do encryption. This is needed for OVS/OVN IPsec with encrypted Geneve tunnels. This can be tested by config

[PATCH 5.4 25/43] nfp: use correct define to return NONE fec

2020-09-25 Thread Greg Kroah-Hartman
From: Jakub Kicinski [ Upstream commit 5f6857e808a8bd078296575b417c4b9d160b9779 ] struct ethtool_fecparam carries bitmasks not bit numbers. We want to return 1 (NONE), not 0. Fixes: 0d0870938337 ("nfp: implement ethtool FEC mode settings") Signed-off-by: Jakub Kicinski Reviewed-by: Simon Horma

[PATCH 5.4 29/43] tipc: use skb_unshare() instead in tipc_buf_append()

2020-09-25 Thread Greg Kroah-Hartman
From: Xin Long [ Upstream commit ff48b6222e65ebdba5a403ef1deba6214e749193 ] In tipc_buf_append() it may change skb's frag_list, and it causes problems when this skb is cloned. skb_unclone() doesn't really make this skb's flag_list available to change. Shuang Li has reported an use-after-free is

[PATCH 5.4 40/43] net: qrtr: check skb_put_padto() return value

2020-09-25 Thread Greg Kroah-Hartman
From: Eric Dumazet [ Upstream commit 3ca1a42a52ca4b4f02061683851692ad65fefac8 ] If skb_put_padto() returns an error, skb has been freed. Better not touch it anymore, as reported by syzbot [1] Note to qrtr maintainers : this suggests qrtr_sendmsg() should adjust sock_alloc_send_skb() second para

[PATCH 5.4 08/43] bnxt_en: Fix NULL ptr dereference crash in bnxt_fw_reset_task()

2020-09-25 Thread Greg Kroah-Hartman
From: Vasundhara Volam [ Upstream commit b16939b59cc00231a75d224fd058d22c9d064976 ] bnxt_fw_reset_task() which runs from a workqueue can race with bnxt_remove_one(). For example, if firmware reset and VF FLR are happening at about the same time. bnxt_remove_one() already cancels the workqueue

[PATCH 5.4 07/43] bnxt_en: Avoid sending firmware messages when AER error is detected.

2020-09-25 Thread Greg Kroah-Hartman
From: Vasundhara Volam [ Upstream commit b340dc680ed48dcc05b56e1ebe1b9535813c3ee0 ] When the driver goes through PCIe AER reset in error state, all firmware messages will timeout because the PCIe bus is no longer accessible. This can lead to AER reset taking many minutes to complete as each fir

[PATCH 5.4 11/43] geneve: add transport ports in route lookup for geneve

2020-09-25 Thread Greg Kroah-Hartman
From: Mark Gray [ Upstream commit 34beb21594519ce64a55a498c2fe7d567bc1ca20 ] This patch adds transport ports information for route lookup so that IPsec can select Geneve tunnel traffic to do encryption. This is needed for OVS/OVN IPsec with encrypted Geneve tunnels. This can be tested by config

[PATCH 5.4 31/43] net/mlx5e: TLS, Do not expose FPGA TLS counter if not supported

2020-09-25 Thread Greg Kroah-Hartman
From: Tariq Toukan [ Upstream commit 8f0bcd19b1da3f264223abea985b9462e85a3718 ] The set of TLS TX global SW counters in mlx5e_tls_sw_stats_desc is updated from all rings by using atomic ops. This set of stats is used only in the FPGA TLS use case, not in the Connect-X TLS one, where regular per-

[PATCH 5.4 37/43] net: lantiq: Disable IRQs only if NAPI gets scheduled

2020-09-25 Thread Greg Kroah-Hartman
From: Hauke Mehrtens [ Upstream commit 9423361da52356cb68642db5b2729b6b85aad330 ] The napi_schedule() call will only schedule the NAPI if it is not already running. To make sure that we do not deactivate interrupts without scheduling NAPI only deactivate the interrupts in case NAPI also gets sch

[PATCH 5.4 42/43] mm: memcg: fix memcg reclaim soft lockup

2020-09-25 Thread Greg Kroah-Hartman
From: Xunlei Pang commit e3336cab2579012b1e72b5265adf98e2d6e244ad upstream. We've met softlockup with "CONFIG_PREEMPT_NONE=y", when the target memcg doesn't have any reclaimable memory. It can be easily reproduced as below: watchdog: BUG: soft lockup - CPU#0 stuck for 111s![memcg_test:2204]

[PATCH 5.4 12/43] hdlc_ppp: add range checks in ppp_cp_parse_cr()

2020-09-25 Thread Greg Kroah-Hartman
From: Dan Carpenter [ Upstream commit 66d42ed8b25b64eb63111a2b8582c5afc8bf1105 ] There are a couple bugs here: 1) If opt[1] is zero then this results in a forever loop. If the value is less than 2 then it is invalid. 2) It assumes that "len" is more than sizeof(valid_accm) or 6 which can

[PATCH 5.4 09/43] cxgb4: fix memory leak during module unload

2020-09-25 Thread Greg Kroah-Hartman
From: Raju Rangoju [ Upstream commit f4a26a9b311d7ff9db461278faf2869d06496ef8 ] Fix the memory leak in mps during module unload path by freeing mps reference entries if the list adpter->mps_ref is not already empty Fixes: 28b3870578ef ("cxgb4: Re-work the logic for mps refcounting") Signed-off-

[PATCH 5.4 05/43] mm/thp: fix __split_huge_pmd_locked() for migration PMD

2020-09-25 Thread Greg Kroah-Hartman
From: Ralph Campbell [ Upstream commit ec0abae6dcdf7ef88607c869bf35a4b63ce1b370 ] A migrating transparent huge page has to already be unmapped. Otherwise, the page could be modified while it is being copied to a new page and data could be lost. The function __split_huge_pmd() checks for a PMD

[PATCH 5.4 43/43] iommu/amd: Use cmpxchg_double() when updating 128-bit IRTE

2020-09-25 Thread Greg Kroah-Hartman
From: Suravee Suthikulpanit commit e52d58d54a321d4fe9d0ecdabe4f8774449f0d6e upstream. When using 128-bit interrupt-remapping table entry (IRTE) (a.k.a GA mode), current driver disables interrupt remapping when it updates the IRTE so that the upper and lower 64-bit values can be updated safely.

[PATCH 5.4 10/43] cxgb4: Fix offset when clearing filter byte counters

2020-09-25 Thread Greg Kroah-Hartman
From: Ganji Aravind [ Upstream commit 94cc242a067a869c29800aa789d38b7676136e50 ] Pass the correct offset to clear the stale filter hit bytes counter. Otherwise, the counter starts incrementing from the stale information, instead of 0. Fixes: 12b276fbf6e0 ("cxgb4: add support to create hash filt

[PATCH 5.4 34/43] net: lantiq: Wake TX queue again

2020-09-25 Thread Greg Kroah-Hartman
From: Hauke Mehrtens [ Upstream commit dea36631e6f186d4b853af67a4aef2e35cfa8bb7 ] The call to netif_wake_queue() when the TX descriptors were freed was missing. When there are no TX buffers available the TX queue will be stopped, but it was not started again when they are available again, this i

[PATCH 5.4 30/43] net/mlx5e: Enable adding peer miss rules only if merged eswitch is supported

2020-09-25 Thread Greg Kroah-Hartman
From: Maor Dickman [ Upstream commit 6cec0229ab1959259e71e9a5bbe47c04577950b1 ] The cited commit creates peer miss group during switchdev mode initialization in order to handle miss packets correctly while in VF LAG mode. This is done regardless of FW support of such groups which could cause rul

[PATCH 5.4 32/43] bnxt_en: return proper error codes in bnxt_show_temp

2020-09-25 Thread Greg Kroah-Hartman
From: Edwin Peer [ Upstream commit d69753fa1ecb3218b56b022722f7a5822735b876 ] Returning "unknown" as a temperature value violates the hwmon interface rules. Appropriate error codes should be returned via device_attribute show instead. These will ultimately be propagated to the user via the file

[PATCH 5.4 22/43] net/mlx5: Fix FTE cleanup

2020-09-25 Thread Greg Kroah-Hartman
From: Maor Gottlieb [ Upstream commit cefc23554fc259114e78a7b0908aac4610ee18eb ] Currently, when an FTE is allocated, its refcount is decreased to 0 with the purpose it will not be a stand alone steering object and every rule (destination) of the FTE would increase the refcount. When mlx5_cleanu

[PATCH 5.4 28/43] tipc: fix shutdown() of connection oriented socket

2020-09-25 Thread Greg Kroah-Hartman
From: Tetsuo Handa [ Upstream commit a4b5cc9e10803ecba64a7d54c0f47e4564b4a980 ] I confirmed that the problem fixed by commit 2a63866c8b51a3f7 ("tipc: fix shutdown() of connectionless socket") also applies to stream socket. -- #include #include #include int main(int argc, char *argv[

[PATCH 5.4 15/43] ipv4: Update exception handling for multipath routes via same device

2020-09-25 Thread Greg Kroah-Hartman
From: David Ahern [ Upstream commit 2fbc6e89b2f1403189e624cabaf73e189c5e50c6 ] Kfir reported that pmtu exceptions are not created properly for deployments where multipath routes use the same device. After some digging I see 2 compounding problems: 1. ip_route_output_key_hash_rcu is updating the

[PATCH 5.4 00/43] 5.4.68-rc1 review

2020-09-25 Thread Greg Kroah-Hartman
This is the start of the stable review cycle for the 5.4.68 release. There are 43 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 Sun, 27 Sep 2020 12:47:02 +. Anything rece

[PATCH 5.4 16/43] ipv6: avoid lockdep issue in fib6_del()

2020-09-25 Thread Greg Kroah-Hartman
From: Eric Dumazet [ Upstream commit 843d926b003ea692468c8cc5bea1f9f58dfa8c75 ] syzbot reported twice a lockdep issue in fib6_del() [1] which I think is caused by net->ipv6.fib6_null_entry having a NULL fib6_table pointer. fib6_del() already checks for fib6_null_entry special case, we only need

[PATCH 5.4 27/43] tipc: Fix memory leak in tipc_group_create_member()

2020-09-25 Thread Greg Kroah-Hartman
From: Peilin Ye [ Upstream commit bb3a420d47ab00d7e1e5083286cab15235a96680 ] tipc_group_add_to_tree() returns silently if `key` matches `nkey` of an existing node, causing tipc_group_create_member() to leak memory. Let tipc_group_add_to_tree() return an error in such a case, so that tipc_group_c

[PATCH 5.4 21/43] net: ipv6: fix kconfig dependency warning for IPV6_SEG6_HMAC

2020-09-25 Thread Greg Kroah-Hartman
From: Necip Fazil Yildiran [ Upstream commit db7cd91a4be15e1485d6b58c6afc8761c59c4efb ] When IPV6_SEG6_HMAC is enabled and CRYPTO is disabled, it results in the following Kbuild warning: WARNING: unmet direct dependencies detected for CRYPTO_HMAC Depends on [n]: CRYPTO [=n] Selected by [y]:

[PATCH 5.4 33/43] bnxt_en: Protect bnxt_set_eee() and bnxt_set_pauseparam() with mutex.

2020-09-25 Thread Greg Kroah-Hartman
From: Michael Chan [ Upstream commit a53906908148d64423398a62c4435efb0d09652c ] All changes related to bp->link_info require the protection of the link_lock mutex. It's not sufficient to rely just on RTNL. Fixes: 163e9ef63641 ("bnxt_en: Fix race when modifying pause settings.") Reviewed-by: Ed

[PATCH 5.4 24/43] net: sctp: Fix IPv6 ancestor_size calc in sctp_copy_descendant

2020-09-25 Thread Greg Kroah-Hartman
From: Henry Ptasinski [ Upstream commit fe81d9f6182d1160e625894eecb3d7ff0222cac5 ] When calculating ancestor_size with IPv6 enabled, simply using sizeof(struct ipv6_pinfo) doesn't account for extra bytes needed for alignment in the struct sctp6_sock. On x86, there aren't any extra bytes, but on

[PATCH 5.4 19/43] net: dsa: rtl8366: Properly clear member config

2020-09-25 Thread Greg Kroah-Hartman
From: Linus Walleij [ Upstream commit 4ddcaf1ebb5e4e99240f29d531ee69d4244fe416 ] When removing a port from a VLAN we are just erasing the member config for the VLAN, which is wrong: other ports can be using it. Just mask off the port and only zero out the rest of the member config once ports us

[PATCH 5.4 26/43] taprio: Fix allowing too small intervals

2020-09-25 Thread Greg Kroah-Hartman
From: Vinicius Costa Gomes [ Upstream commit b5b73b26b3ca34574124ed7ae9c5ba8391a7f176 ] It's possible that the user specifies an interval that couldn't allow any packet to be transmitted. This also avoids the issue of the hrtimer handler starving the other threads because it's running too often.

[PATCH 5.4 23/43] net: sch_generic: aviod concurrent reset and enqueue op for lockless qdisc

2020-09-25 Thread Greg Kroah-Hartman
From: Yunsheng Lin [ Upstream commit 2fb541c862c987d02dfdf28f1545016deecfa0d5 ] Currently there is concurrent reset and enqueue operation for the same lockless qdisc when there is no lock to synchronize the q->enqueue() in __dev_xmit_skb() with the qdisc reset operation in qdisc_deactivate() cal

[PATCH 5.4 03/43] ibmvnic: add missing parenthesis in do_reset()

2020-09-25 Thread Greg Kroah-Hartman
From: Jakub Kicinski [ Upstream commit 8ae4dff882eb879c17bf46574201bd37fc6bc8b5 ] Indentation and logic clearly show that this code is missing parenthesis. Fixes: 9f1345737790 ("ibmvnic fix NULL tx_pools and rx_tools issue at do_reset") Signed-off-by: Jakub Kicinski Signed-off-by: Sasha Levin

Re: [PATCH v3 24/39] arm64: mte: Add in-kernel MTE helpers

2020-09-25 Thread Catalin Marinas
On Fri, Sep 25, 2020 at 12:28:24PM +0100, Vincenzo Frascino wrote: > On 9/25/20 11:15 AM, Catalin Marinas wrote: > > On Fri, Sep 25, 2020 at 12:50:31AM +0200, Andrey Konovalov wrote: > >> +u8 mte_get_mem_tag(void *addr); > >> +u8 mte_get_random_tag(void); > >> +void *mte_set_mem_tag_range(void *add

[PATCH 5.8 41/56] net: qrtr: check skb_put_padto() return value

2020-09-25 Thread Greg Kroah-Hartman
From: Eric Dumazet [ Upstream commit 3ca1a42a52ca4b4f02061683851692ad65fefac8 ] If skb_put_padto() returns an error, skb has been freed. Better not touch it anymore, as reported by syzbot [1] Note to qrtr maintainers : this suggests qrtr_sendmsg() should adjust sock_alloc_send_skb() second para

[PATCH 5.8 39/56] net: phy: Avoid NPD upon phy_detach() when driver is unbound

2020-09-25 Thread Greg Kroah-Hartman
From: Florian Fainelli [ Upstream commit c2b727df7caa33876e7066bde090f40001b6d643 ] If we have unbound the PHY driver prior to calling phy_detach() (often via phy_disconnect()) then we can cause a NULL pointer de-reference accessing the driver owner member. The steps to reproduce are: echo unim

[PATCH 5.8 50/56] net: dsa: link interfaces with the DSA master to get rid of lockdep warnings

2020-09-25 Thread Greg Kroah-Hartman
From: Vladimir Oltean [ Upstream commit 2f1e8ea726e9020e01e9e2ae29c2d5eb11133032 ] Since commit 845e0ebb4408 ("net: change addr_list_lock back to static key"), cascaded DSA setups (DSA switch port as DSA master for another DSA switch port) are emitting this lockdep warning:

[PATCH 5.8 33/56] bnxt_en: return proper error codes in bnxt_show_temp

2020-09-25 Thread Greg Kroah-Hartman
From: Edwin Peer [ Upstream commit d69753fa1ecb3218b56b022722f7a5822735b876 ] Returning "unknown" as a temperature value violates the hwmon interface rules. Appropriate error codes should be returned via device_attribute show instead. These will ultimately be propagated to the user via the file

[PATCH 5.8 38/56] net: lantiq: Disable IRQs only if NAPI gets scheduled

2020-09-25 Thread Greg Kroah-Hartman
From: Hauke Mehrtens [ Upstream commit 9423361da52356cb68642db5b2729b6b85aad330 ] The napi_schedule() call will only schedule the NAPI if it is not already running. To make sure that we do not deactivate interrupts without scheduling NAPI only deactivate the interrupts in case NAPI also gets sch

[PATCH 5.4 06/43] act_ife: load meta modules before tcf_idr_check_alloc()

2020-09-25 Thread Greg Kroah-Hartman
From: Cong Wang [ Upstream commit cc8e58f8325cdf14b9516b61c384cdfd02a4f408 ] The following deadlock scenario is triggered by syzbot: Thread A: Thread B: tcf_idr_check_alloc() ... populate_metalist() rtnl_unlock() rtnl_lock(

[PATCH 5.8 48/56] hinic: fix rewaking txq after netif_tx_disable

2020-09-25 Thread Greg Kroah-Hartman
From: Luo bin [ Upstream commit a1b80e0143a1b878f8e21d82fd55f3f46f0014be ] When calling hinic_close in hinic_set_channels, all queues are stopped after netif_tx_disable, but some queue may be rewaken in free_tx_poll by mistake while drv is handling tx irq. If one queue is rewaken core may call h

[PATCH 5.8 52/56] net: macb: fix for pause frame receive enable bit

2020-09-25 Thread Greg Kroah-Hartman
From: Parshuram Thombare [ Upstream commit d7739b0b6d15ef9ad5c79424736b8ded5ed3e913 ] PAE bit of NCFGR register, when set, pauses transmission if a non-zero 802.3 classic pause frame is received. Fixes: 7897b071ac3b ("net: macb: convert to phylink") Signed-off-by: Parshuram Thombare Signed-off

[PATCH 5.4 02/43] ibmvnic fix NULL tx_pools and rx_tools issue at do_reset

2020-09-25 Thread Greg Kroah-Hartman
From: Mingming Cao [ Upstream commit 9f13457377907fa253aef560e1a37e1ca4197f9b ] At the time of do_rest, ibmvnic tries to re-initalize the tx_pools and rx_pools to avoid re-allocating the long term buffer. However there is a window inside do_reset that the tx_pools and rx_pools were freed before

[PATCH 5.8 40/56] net: phy: Do not warn in phy_stop() on PHY_DOWN

2020-09-25 Thread Greg Kroah-Hartman
From: Florian Fainelli [ Upstream commit 5116a8ade333b6c2e180782139c9c516a437b21c ] When phy_is_started() was added to catch incorrect PHY states, phy_stop() would not be qualified against PHY_DOWN. It is possible to reach that state when the PHY driver has been unbound and the network device is

Re: [PATCH v2] pinctrl: mediatek: check mtk_is_virt_gpio input parameter

2020-09-25 Thread Hanks Chen
Hi Sean & Linux & Matthias, Please kindly let me know your comments about this fixes patch. Thanks Regards, Hanks On Thu, 2020-08-20 at 19:22 +0800, Hanks Chen wrote: > check mtk_is_virt_gpio input parameter, > virtual gpio need to support eint mode. > > add error handler for the ko case > to

[PATCH 5.4 04/43] kprobes: fix kill kprobe which has been marked as gone

2020-09-25 Thread Greg Kroah-Hartman
From: Muchun Song [ Upstream commit b0399092ccebd9feef68d4ceb8d6219a8c0caa05 ] If a kprobe is marked as gone, we should not kill it again. Otherwise, we can disarm the kprobe more than once. In that case, the statistics of kprobe_ftrace_enabled can unbalance which can lead to that kprobe do no

[PATCH 5.8 56/56] net/mlx5e: Fix endianness when calculating pedit mask first bit

2020-09-25 Thread Greg Kroah-Hartman
From: Maor Dickman [ Upstream commit 82198d8bcdeff01d19215d712aa55031e21bccbc ] The field mask value is provided in network byte order and has to be converted to host byte order before calculating pedit mask first bit. Fixes: 88f30bbcbaaa ("net/mlx5e: Bit sized fields rewrite support") Signed-o

[PATCH 5.8 55/56] net/mlx5e: Use synchronize_rcu to sync with NAPI

2020-09-25 Thread Greg Kroah-Hartman
From: Maxim Mikityanskiy [ Upstream commit 9c25a22dfb00270372224721fed646965420323a ] As described in the previous commit, napi_synchronize doesn't quite fit the purpose when we just need to wait until the currently running NAPI quits. Its implementation waits until NAPI is not running by pollin

[PATCH 5.8 45/56] wireguard: peerlookup: take lock before checking hash in replace operation

2020-09-25 Thread Greg Kroah-Hartman
From: "Jason A. Donenfeld" [ Upstream commit 6147f7b1e90ff09bd52afc8b9206a7fcd133daf7 ] Eric's suggested fix for the previous commit's mentioned race condition was to simply take the table->lock in wg_index_hashtable_replace(). The table->lock of the hash table is supposed to protect the bucket

[PATCH 5.8 11/56] ip: fix tos reflection in ack and reset packets

2020-09-25 Thread Greg Kroah-Hartman
From: Wei Wang [ Upstream commit ba9e04a7ddf4f22a10e05bf9403db6b97743c7bf ] Currently, in tcp_v4_reqsk_send_ack() and tcp_v4_send_reset(), we echo the TOS value of the received packets in the response. However, we do not want to echo the lower 2 ECN bits in accordance with RFC 3168 6.1.5 robustn

[PATCH 5.8 10/56] hinic: bump up the timeout of SET_FUNC_STATE cmd

2020-09-25 Thread Greg Kroah-Hartman
From: Luo bin [ Upstream commit 4e4269ebe7e18038fffacf113e2dd5ded6d49942 ] We free memory regardless of the return value of SET_FUNC_STATE cmd in hinic_close function to avoid memory leak and this cmd may timeout when fw is busy with handling other cmds, so we bump up the timeout of this cmd to

[PATCH 5.8 44/56] wireguard: noise: take lock when removing handshake entry from table

2020-09-25 Thread Greg Kroah-Hartman
From: "Jason A. Donenfeld" [ Upstream commit 9179ba31367bcf481c3c79b5f028c94faad9f30a ] Eric reported that syzkaller found a race of this variety: CPU 1 CPU 2 ---|--- wg_index_hasht

[PATCH 5.8 08/56] geneve: add transport ports in route lookup for geneve

2020-09-25 Thread Greg Kroah-Hartman
From: Mark Gray [ Upstream commit 34beb21594519ce64a55a498c2fe7d567bc1ca20 ] This patch adds transport ports information for route lookup so that IPsec can select Geneve tunnel traffic to do encryption. This is needed for OVS/OVN IPsec with encrypted Geneve tunnels. This can be tested by config

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