1. 27 Mar, 2024 10 commits
    • Jakub Kicinski's avatar
      Merge tag 'wireless-2024-03-27' of git://git.kernel.org/pub/scm/linux/kernel/git/wireless/wireless · 56d2f48e
      Jakub Kicinski authored
      Kalle Valo says:
      
      ====================
      wireless fixes for v6.9-rc2
      
      The first fixes for v6.9. Ping-Ke Shih now maintains a separate tree
      for Realtek drivers, document that in the MAINTAINERS. Plenty of fixes
      for both to stack and iwlwifi. Our kunit tests were working only on um
      architecture but that's fixed now.
      
      * tag 'wireless-2024-03-27' of git://git.kernel.org/pub/scm/linux/kernel/git/wireless/wireless: (21 commits)
        MAINTAINERS: wifi: mwifiex: add Francesco as reviewer
        kunit: fix wireless test dependencies
        wifi: iwlwifi: mvm: include link ID when releasing frames
        wifi: iwlwifi: mvm: handle debugfs names more carefully
        wifi: iwlwifi: mvm: guard against invalid STA ID on removal
        wifi: iwlwifi: read txq->read_ptr under lock
        wifi: iwlwifi: fw: don't always use FW dump trig
        wifi: iwlwifi: mvm: rfi: fix potential response leaks
        wifi: mac80211: correctly set active links upon TTLM
        wifi: iwlwifi: mvm: Configure the link mapping for non-MLD FW
        wifi: iwlwifi: mvm: consider having one active link
        wifi: iwlwifi: mvm: pick the version of SESSION_PROTECTION_NOTIF
        wifi: mac80211: fix prep_connection error path
        wifi: cfg80211: fix rdev_dump_mpp() arguments order
        wifi: iwlwifi: mvm: disable MLO for the time being
        wifi: cfg80211: add a flag to disable wireless extensions
        wifi: mac80211: fix ieee80211_bss_*_flags kernel-doc
        wifi: mac80211: check/clear fast rx for non-4addr sta VLAN changes
        wifi: mac80211: fix mlme_link_id_dbg()
        MAINTAINERS: wifi: add git tree for Realtek WiFi drivers
        ...
      ====================
      
      Link: https://lore.kernel.org/r/20240327191346.1A1EAC433C7@smtp.kernel.orgSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      56d2f48e
    • Jakub Kicinski's avatar
      selftests: netdevsim: set test timeout to 10 minutes · afbf75e8
      Jakub Kicinski authored
      The longest running netdevsim test, nexthop.sh, currently takes
      5 min to finish. Around 260s to be exact, and 310s on a debug kernel.
      The default timeout in selftest is 45sec, so we need an explicit
      config. Give ourselves some headroom and use 10min.
      
      Commit under Fixes isn't really to "blame" but prior to that
      netdevsim tests weren't integrated with kselftest infra
      so blaming the tests themselves doesn't seem right, either.
      
      Fixes: 8ff25dac ("netdevsim: add Makefile for selftests")
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      Reviewed-by: default avatarSimon Horman <horms@kernel.org>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      afbf75e8
    • Herve Codina's avatar
      net: wan: framer: Add missing static inline qualifiers · ea2c0928
      Herve Codina authored
      Compilation with CONFIG_GENERIC_FRAMER disabled lead to the following
      warnings:
        framer.h:184:16: warning: no previous prototype for function 'framer_get' [-Wmissing-prototypes]
        184 | struct framer *framer_get(struct device *dev, const char *con_id)
        framer.h:184:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
        184 | struct framer *framer_get(struct device *dev, const char *con_id)
        framer.h:189:6: warning: no previous prototype for function 'framer_put' [-Wmissing-prototypes]
        189 | void framer_put(struct device *dev, struct framer *framer)
        framer.h:189:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
        189 | void framer_put(struct device *dev, struct framer *framer)
      
      Add missing 'static inline' qualifiers for these functions.
      Reported-by: default avatarkernel test robot <lkp@intel.com>
      Closes: https://lore.kernel.org/oe-kbuild-all/202403241110.hfJqeJRu-lkp@intel.com/
      Fixes: 82c944d0 ("net: wan: Add framer framework support")
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarHerve Codina <herve.codina@bootlin.com>
      Reviewed-by: default avatarAndy Shevchenko <andriy.shevchenko@linux.intel.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      ea2c0928
    • Jakub Kicinski's avatar
      Merge branch '100GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/tnguy/net-queue · c4d2d23d
      Jakub Kicinski authored
      Tony Nguyen says:
      
      ====================
      Intel Wired LAN Driver Updates 2024-03-25 (ice, ixgbe, igc)
      
      This series contains updates to ice, ixgbe, and igc drivers.
      
      Steven fixes incorrect casting of bitmap type for ice driver.
      
      Jesse fixes memory corruption issue with suspend flow on ice.
      
      Przemek adds GFP_ATOMIC flag to avoid sleeping in IRQ context for ixgbe.
      
      Kurt Kanzenbach removes no longer valid comment on igc.
      
      * '100GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/tnguy/net-queue:
        igc: Remove stale comment about Tx timestamping
        ixgbe: avoid sleeping allocation in ixgbe_ipsec_vf_add_sa()
        ice: fix memory corruption bug with suspend and rebuild
        ice: Refactor FW data type and fix bitmap casting issue
      ====================
      
      Link: https://lore.kernel.org/r/20240325200659.993749-1-anthony.l.nguyen@intel.comSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      c4d2d23d
    • David Thompson's avatar
      mlxbf_gige: call request_irq() after NAPI initialized · f7442a63
      David Thompson authored
      The mlxbf_gige driver encounters a NULL pointer exception in
      mlxbf_gige_open() when kdump is enabled.  The sequence to reproduce
      the exception is as follows:
      a) enable kdump
      b) trigger kdump via "echo c > /proc/sysrq-trigger"
      c) kdump kernel executes
      d) kdump kernel loads mlxbf_gige module
      e) the mlxbf_gige module runs its open() as the
         the "oob_net0" interface is brought up
      f) mlxbf_gige module will experience an exception
         during its open(), something like:
      
           Unable to handle kernel NULL pointer dereference at virtual address 0000000000000000
           Mem abort info:
             ESR = 0x0000000086000004
             EC = 0x21: IABT (current EL), IL = 32 bits
             SET = 0, FnV = 0
             EA = 0, S1PTW = 0
             FSC = 0x04: level 0 translation fault
           user pgtable: 4k pages, 48-bit VAs, pgdp=00000000e29a4000
           [0000000000000000] pgd=0000000000000000, p4d=0000000000000000
           Internal error: Oops: 0000000086000004 [#1] SMP
           CPU: 0 PID: 812 Comm: NetworkManager Tainted: G           OE     5.15.0-1035-bluefield #37-Ubuntu
           Hardware name: https://www.mellanox.com BlueField-3 SmartNIC Main Card/BlueField-3 SmartNIC Main Card, BIOS 4.6.0.13024 Jan 19 2024
           pstate: 80400009 (Nzcv daif +PAN -UAO -TCO -DIT -SSBS BTYPE=--)
           pc : 0x0
           lr : __napi_poll+0x40/0x230
           sp : ffff800008003e00
           x29: ffff800008003e00 x28: 0000000000000000 x27: 00000000ffffffff
           x26: ffff000066027238 x25: ffff00007cedec00 x24: ffff800008003ec8
           x23: 000000000000012c x22: ffff800008003eb7 x21: 0000000000000000
           x20: 0000000000000001 x19: ffff000066027238 x18: 0000000000000000
           x17: ffff578fcb450000 x16: ffffa870b083c7c0 x15: 0000aaab010441d0
           x14: 0000000000000001 x13: 00726f7272655f65 x12: 6769675f6662786c
           x11: 0000000000000000 x10: 0000000000000000 x9 : ffffa870b0842398
           x8 : 0000000000000004 x7 : fe5a48b9069706ea x6 : 17fdb11fc84ae0d2
           x5 : d94a82549d594f35 x4 : 0000000000000000 x3 : 0000000000400100
           x2 : 0000000000000000 x1 : 0000000000000000 x0 : ffff000066027238
           Call trace:
            0x0
            net_rx_action+0x178/0x360
            __do_softirq+0x15c/0x428
            __irq_exit_rcu+0xac/0xec
            irq_exit+0x18/0x2c
            handle_domain_irq+0x6c/0xa0
            gic_handle_irq+0xec/0x1b0
            call_on_irq_stack+0x20/0x2c
            do_interrupt_handler+0x5c/0x70
            el1_interrupt+0x30/0x50
            el1h_64_irq_handler+0x18/0x2c
            el1h_64_irq+0x7c/0x80
            __setup_irq+0x4c0/0x950
            request_threaded_irq+0xf4/0x1bc
            mlxbf_gige_request_irqs+0x68/0x110 [mlxbf_gige]
            mlxbf_gige_open+0x5c/0x170 [mlxbf_gige]
            __dev_open+0x100/0x220
            __dev_change_flags+0x16c/0x1f0
            dev_change_flags+0x2c/0x70
            do_setlink+0x220/0xa40
            __rtnl_newlink+0x56c/0x8a0
            rtnl_newlink+0x58/0x84
            rtnetlink_rcv_msg+0x138/0x3c4
            netlink_rcv_skb+0x64/0x130
            rtnetlink_rcv+0x20/0x30
            netlink_unicast+0x2ec/0x360
            netlink_sendmsg+0x278/0x490
            __sock_sendmsg+0x5c/0x6c
            ____sys_sendmsg+0x290/0x2d4
            ___sys_sendmsg+0x84/0xd0
            __sys_sendmsg+0x70/0xd0
            __arm64_sys_sendmsg+0x2c/0x40
            invoke_syscall+0x78/0x100
            el0_svc_common.constprop.0+0x54/0x184
            do_el0_svc+0x30/0xac
            el0_svc+0x48/0x160
            el0t_64_sync_handler+0xa4/0x12c
            el0t_64_sync+0x1a4/0x1a8
           Code: bad PC value
           ---[ end trace 7d1c3f3bf9d81885 ]---
           Kernel panic - not syncing: Oops: Fatal exception in interrupt
           Kernel Offset: 0x2870a7a00000 from 0xffff800008000000
           PHYS_OFFSET: 0x80000000
           CPU features: 0x0,000005c1,a3332a5a
           Memory Limit: none
           ---[ end Kernel panic - not syncing: Oops: Fatal exception in interrupt ]---
      
      The exception happens because there is a pending RX interrupt before the
      call to request_irq(RX IRQ) executes.  Then, the RX IRQ handler fires
      immediately after this request_irq() completes. The RX IRQ handler runs
      "napi_schedule()" before NAPI is fully initialized via "netif_napi_add()"
      and "napi_enable()", both which happen later in the open() logic.
      
      The logic in mlxbf_gige_open() must fully initialize NAPI before any calls
      to request_irq() execute.
      
      Fixes: f92e1869 ("Add Mellanox BlueField Gigabit Ethernet driver")
      Signed-off-by: default avatarDavid Thompson <davthompson@nvidia.com>
      Reviewed-by: default avatarAsmaa Mnebhi <asmaa@nvidia.com>
      Link: https://lore.kernel.org/r/20240325183627.7641-1-davthompson@nvidia.comSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      f7442a63
    • Jakub Kicinski's avatar
      Merge branch 'tls-recvmsg-fixes' · 646fc4bd
      Jakub Kicinski authored
      Sabrina Dubroca says:
      
      ====================
      tls: recvmsg fixes
      
      The first two fixes are again related to async decrypt. The last one
      is unrelated but I stumbled upon it while reading the code.
      ====================
      
      Link: https://lore.kernel.org/r/cover.1711120964.git.sd@queasysnail.netSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      646fc4bd
    • Sabrina Dubroca's avatar
      tls: get psock ref after taking rxlock to avoid leak · 417e91e8
      Sabrina Dubroca authored
      At the start of tls_sw_recvmsg, we take a reference on the psock, and
      then call tls_rx_reader_lock. If that fails, we return directly
      without releasing the reference.
      
      Instead of adding a new label, just take the reference after locking
      has succeeded, since we don't need it before.
      
      Fixes: 4cbc325e ("tls: rx: allow only one reader at a time")
      Signed-off-by: default avatarSabrina Dubroca <sd@queasysnail.net>
      Reviewed-by: default avatarSimon Horman <horms@kernel.org>
      Link: https://lore.kernel.org/r/fe2ade22d030051ce4c3638704ed58b67d0df643.1711120964.git.sd@queasysnail.netSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      417e91e8
    • Sabrina Dubroca's avatar
      selftests: tls: add test with a partially invalid iov · dc54b813
      Sabrina Dubroca authored
      Make sure that we don't return more bytes than we actually received if
      the userspace buffer was bogus. We expect to receive at least the rest
      of rec1, and possibly some of rec2 (currently, we don't, but that
      would be ok).
      Signed-off-by: default avatarSabrina Dubroca <sd@queasysnail.net>
      Reviewed-by: default avatarSimon Horman <horms@kernel.org>
      Link: https://lore.kernel.org/r/720e61b3d3eab40af198a58ce2cd1ee019f0ceb1.1711120964.git.sd@queasysnail.netSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      dc54b813
    • Sabrina Dubroca's avatar
      tls: adjust recv return with async crypto and failed copy to userspace · 85eef9a4
      Sabrina Dubroca authored
      process_rx_list may not copy as many bytes as we want to the userspace
      buffer, for example in case we hit an EFAULT during the copy. If this
      happens, we should only count the bytes that were actually copied,
      which may be 0.
      
      Subtracting async_copy_bytes is correct in both peek and !peek cases,
      because decrypted == async_copy_bytes + peeked for the peek case: peek
      is always !ZC, and we can go through either the sync or async path. In
      the async case, we add chunk to both decrypted and
      async_copy_bytes. In the sync case, we add chunk to both decrypted and
      peeked. I missed that in commit 6caaf104 ("tls: fix peeking with
      sync+async decryption").
      
      Fixes: 4d42cd6b ("tls: rx: fix return value for async crypto")
      Signed-off-by: default avatarSabrina Dubroca <sd@queasysnail.net>
      Reviewed-by: default avatarSimon Horman <horms@kernel.org>
      Link: https://lore.kernel.org/r/1b5a1eaab3c088a9dd5d9f1059ceecd7afe888d1.1711120964.git.sd@queasysnail.netSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      85eef9a4
    • Sabrina Dubroca's avatar
      tls: recv: process_rx_list shouldn't use an offset with kvec · 7608a971
      Sabrina Dubroca authored
      Only MSG_PEEK needs to copy from an offset during the final
      process_rx_list call, because the bytes we copied at the beginning of
      tls_sw_recvmsg were left on the rx_list. In the KVEC case, we removed
      data from the rx_list as we were copying it, so there's no need to use
      an offset, just like in the normal case.
      
      Fixes: 692d7b5d ("tls: Fix recvmsg() to be able to peek across multiple records")
      Signed-off-by: default avatarSabrina Dubroca <sd@queasysnail.net>
      Reviewed-by: default avatarSimon Horman <horms@kernel.org>
      Link: https://lore.kernel.org/r/e5487514f828e0347d2b92ca40002c62b58af73d.1711120964.git.sd@queasysnail.netSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      7608a971
  2. 26 Mar, 2024 15 commits
  3. 25 Mar, 2024 15 commits