1. 15 Oct, 2023 3 commits
  2. 14 Oct, 2023 9 commits
  3. 13 Oct, 2023 20 commits
  4. 12 Oct, 2023 8 commits
    • Dmitry Torokhov's avatar
      Revert "Input: psmouse - add delay when deactivating for SMBus mode" · b3572639
      Dmitry Torokhov authored
      This reverts commit 92e24e0e.
      
      While the patch itself is correct, it uncovered an issue with fallback
      to PS/2 mode, where we were leaving psmouse->fast_reconnect handler set
      to psmouse_smbus_reconnect(), which caused crashes.
      
      While discussing various approaches to fix the issue it was noted that
      this patch ass undesired delay in the "fast" resume path of PS/2 device,
      and it would be better to actually use "reset_delay" option defined in
      struct rmi_device_platform_data and have RMI code handle it for SMBus
      transport as well. So this patch is being reverted to deal with crashes
      and a better solution will be merged shortly.
      Reported-by: default avatarThorsten Leemhuis <linux@leemhuis.info>
      Closes: https://lore.kernel.org/all/ca0109fa-c64b-43c1-a651-75b294d750a1@leemhuis.info/Signed-off-by: default avatarDmitry Torokhov <dmitry.torokhov@gmail.com>
      b3572639
    • Linus Torvalds's avatar
      Merge tag 'net-6.6-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net · e8c127b0
      Linus Torvalds authored
      Pull networking fixes from Paolo Abeni:
       "Including fixes from CAN and BPF.
      
        We have a regression in TC currently under investigation, otherwise
        the things that stand off most are probably the TCP and AF_PACKET
        fixes, with both issues coming from 6.5.
      
        Previous releases - regressions:
      
         - af_packet: fix fortified memcpy() without flex array.
      
         - tcp: fix crashes trying to free half-baked MTU probes
      
         - xdp: fix zero-size allocation warning in xskq_create()
      
         - can: sja1000: always restart the tx queue after an overrun
      
         - eth: mlx5e: again mutually exclude RX-FCS and RX-port-timestamp
      
         - eth: nfp: avoid rmmod nfp crash issues
      
         - eth: octeontx2-pf: fix page pool frag allocation warning
      
        Previous releases - always broken:
      
         - mctp: perform route lookups under a RCU read-side lock
      
         - bpf: s390: fix clobbering the caller's backchain in the trampoline
      
         - phy: lynx-28g: cancel the CDR check work item on the remove path
      
         - dsa: qca8k: fix qca8k driver for Turris 1.x
      
         - eth: ravb: fix use-after-free issue in ravb_tx_timeout_work()
      
         - eth: ixgbe: fix crash with empty VF macvlan list"
      
      * tag 'net-6.6-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (54 commits)
        rswitch: Fix imbalance phy_power_off() calling
        rswitch: Fix renesas_eth_sw_remove() implementation
        octeontx2-pf: Fix page pool frag allocation warning
        nfc: nci: assert requested protocol is valid
        af_packet: Fix fortified memcpy() without flex array.
        net: tcp: fix crashes trying to free half-baked MTU probes
        net/smc: Fix pos miscalculation in statistics
        nfp: flower: avoid rmmod nfp crash issues
        net: usb: dm9601: fix uninitialized variable use in dm9601_mdio_read
        ethtool: Fix mod state of verbose no_mask bitset
        net: nfc: fix races in nfc_llcp_sock_get() and nfc_llcp_sock_get_sn()
        mctp: perform route lookups under a RCU read-side lock
        net: skbuff: fix kernel-doc typos
        s390/bpf: Fix unwinding past the trampoline
        s390/bpf: Fix clobbering the caller's backchain in the trampoline
        net/mlx5e: Again mutually exclude RX-FCS and RX-port-timestamp
        net/smc: Fix dependency of SMC on ISM
        ixgbe: fix crash with empty VF macvlan list
        net/mlx5e: macsec: use update_pn flag instead of PN comparation
        net: phy: mscc: macsec: reject PN update requests
        ...
      e8c127b0
    • Lucy Mielke's avatar
      workqueue: fix -Wformat-truncation in create_worker · 5d9c7a1e
      Lucy Mielke authored
      Compiling with W=1 emitted the following warning
      (Compiler: gcc (x86-64, ver. 13.2.1, .config: result of make allyesconfig,
      "Treat warnings as errors" turned off):
      
      kernel/workqueue.c:2188:54: warning: ‘%d’ directive output may be
      	truncated writing between 1 and 10 bytes into a region of size
      	between 5 and 14 [-Wformat-truncation=]
      kernel/workqueue.c:2188:50: note: directive argument in the range
      	[0, 2147483647]
      kernel/workqueue.c:2188:17: note: ‘snprintf’ output between 4 and 23 bytes
      	into a destination of size 16
      
      setting "id_buf" to size 23 will silence the warning, since GCC
      determines snprintf's output to be max. 23 bytes in line 2188.
      
      Please let me know if there are any mistakes in my patch!
      Signed-off-by: default avatarLucy Mielke <lucymielke@icloud.com>
      Signed-off-by: default avatarTejun Heo <tj@kernel.org>
      5d9c7a1e
    • Waiman Long's avatar
      workqueue: Override implicit ordered attribute in workqueue_apply_unbound_cpumask() · ca10d851
      Waiman Long authored
      Commit 5c0338c6 ("workqueue: restore WQ_UNBOUND/max_active==1
      to be ordered") enabled implicit ordered attribute to be added to
      WQ_UNBOUND workqueues with max_active of 1. This prevented the changing
      of attributes to these workqueues leading to fix commit 0a94efb5
      ("workqueue: implicit ordered attribute should be overridable").
      
      However, workqueue_apply_unbound_cpumask() was not updated at that time.
      So sysfs changes to wq_unbound_cpumask has no effect on WQ_UNBOUND
      workqueues with implicit ordered attribute. Since not all WQ_UNBOUND
      workqueues are visible on sysfs, we are not able to make all the
      necessary cpumask changes even if we iterates all the workqueue cpumasks
      in sysfs and changing them one by one.
      
      Fix this problem by applying the corresponding change made
      to apply_workqueue_attrs_locked() in the fix commit to
      workqueue_apply_unbound_cpumask().
      
      Fixes: 5c0338c6 ("workqueue: restore WQ_UNBOUND/max_active==1 to be ordered")
      Signed-off-by: default avatarWaiman Long <longman@redhat.com>
      Signed-off-by: default avatarTejun Heo <tj@kernel.org>
      ca10d851
    • Linus Torvalds's avatar
      Merge tag 'soc-fixes-6.6-2' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc · 9a5a1494
      Linus Torvalds authored
      Pull ARM SoC fixes from Arnd Bergmann:
       "AngeloGioacchino Del Regno is stepping in as co-maintainer for the
        MediaTek SoC platform and starts by sending some dts fixes for the
        mt8195 platform that had been pending for a while.
      
        On the ixp4xx platform, Krzysztof Halasa steps down as co-maintainer,
        reflecting that Linus Walleij has been handling this on his own for
        the past few years.
      
        Generic RISC-V kernels are now marked as incompatible with the RZ/Five
        platform that requires custom hacks both for managing its DMA bounce
        buffers and for addressing low virtual memory.
      
       Finally, there is one bugfix for the AMDTEE firmware driver to prevent
       a use-after-free bug"
      
      * tag 'soc-fixes-6.6-2' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc:
        IXP4xx MAINTAINERS entries
        arm64: dts: mediatek: mt8195: Set DSU PMU status to fail
        arm64: dts: mediatek: fix t-phy unit name
        arm64: dts: mediatek: mt8195-demo: update and reorder reserved memory regions
        arm64: dts: mediatek: mt8195-demo: fix the memory size to 8GB
        MAINTAINERS: Add Angelo as MediaTek SoC co-maintainer
        soc: renesas: Make ARCH_R9A07G043 (riscv version) depend on NONPORTABLE
        tee: amdtee: fix use-after-free vulnerability in amdtee_close_session
      9a5a1494
    • Alexandre Ghiti's avatar
      drivers: perf: Fix panic in riscv SBI mmap support · 3fec3233
      Alexandre Ghiti authored
      The following panic can happen when mmap is called before the pmu add
      callback which sets the hardware counter index: this happens for example
      with the following command `perf record --no-bpf-event -n kill`.
      
      [   99.461486] CPU: 1 PID: 1259 Comm: perf Tainted: G            E      6.6.0-rc4ubuntu-defconfig #2
      [   99.461669] Hardware name: riscv-virtio,qemu (DT)
      [   99.461748] epc : pmu_sbi_set_scounteren+0x42/0x44
      [   99.462337]  ra : smp_call_function_many_cond+0x126/0x5b0
      [   99.462369] epc : ffffffff809f9d24 ra : ffffffff800f93e0 sp : ff60000082153aa0
      [   99.462407]  gp : ffffffff82395c98 tp : ff6000009a218040 t0 : ff6000009ab3a4f0
      [   99.462425]  t1 : 0000000000000004 t2 : 0000000000000100 s0 : ff60000082153ab0
      [   99.462459]  s1 : 0000000000000000 a0 : ff60000098869528 a1 : 0000000000000000
      [   99.462473]  a2 : 000000000000001f a3 : 0000000000f00000 a4 : fffffffffffffff8
      [   99.462488]  a5 : 00000000000000cc a6 : 0000000000000000 a7 : 0000000000735049
      [   99.462502]  s2 : 0000000000000001 s3 : ffffffff809f9ce2 s4 : ff60000098869528
      [   99.462516]  s5 : 0000000000000002 s6 : 0000000000000004 s7 : 0000000000000001
      [   99.462530]  s8 : ff600003fec98bc0 s9 : ffffffff826c5890 s10: ff600003fecfcde0
      [   99.462544]  s11: ff600003fec98bc0 t3 : ffffffff819e2558 t4 : ff1c000004623840
      [   99.462557]  t5 : 0000000000000901 t6 : ff6000008feeb890
      [   99.462570] status: 0000000200000100 badaddr: 0000000000000000 cause: 0000000000000003
      [   99.462658] [<ffffffff809f9d24>] pmu_sbi_set_scounteren+0x42/0x44
      [   99.462979] Code: 1060 4785 97bb 00d7 8fd9 9073 1067 6422 0141 8082 (9002) 0013
      [   99.463335] Kernel BUG [#2]
      
      To circumvent this, try to enable userspace access to the hardware counter
      when it is selected in addition to when the event is mapped. And vice-versa
      when the event is stopped/unmapped.
      
      Fixes: cc4c07c8 ("drivers: perf: Implement perf event mmap support in the SBI backend")
      Signed-off-by: default avatarAlexandre Ghiti <alexghiti@rivosinc.com>
      Link: https://lore.kernel.org/r/20231006082010.11963-1-alexghiti@rivosinc.com
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarPalmer Dabbelt <palmer@rivosinc.com>
      3fec3233
    • Alexandre Ghiti's avatar
      riscv: Fix ftrace syscall handling which are now prefixed with __riscv_ · a87e7d3e
      Alexandre Ghiti authored
      ftrace creates entries for each syscall in the tracefs but has failed
      since commit 08d0ce30 ("riscv: Implement syscall wrappers") which
      prefixes all riscv syscalls with __riscv_.
      
      So fix this by implementing arch_syscall_match_sym_name() which allows us
      to ignore this prefix.
      
      And also ignore compat syscalls like x86/arm64 by implementing
      arch_trace_is_compat_syscall().
      
      Fixes: 08d0ce30 ("riscv: Implement syscall wrappers")
      Signed-off-by: default avatarAlexandre Ghiti <alexghiti@rivosinc.com>
      Reviewed-by: default avatarSami Tolvanen <samitolvanen@google.com>
      Acked-by: default avatarMasami Hiramatsu (Google) <mhiramat@kernel.org>
      Tested-by: default avatarBjörn Töpel <bjorn@rivosinc.com>
      Link: https://lore.kernel.org/r/20231003182407.32198-1-alexghiti@rivosinc.com
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarPalmer Dabbelt <palmer@rivosinc.com>
      a87e7d3e
    • Linus Torvalds's avatar
      Merge tag 'pmdomain-v6.6-rc1-2' of git://git.kernel.org/pub/scm/linux/kernel/git/ulfh/linux-pm · 9b1ad4ba
      Linus Torvalds authored
      Pull pmdomain fix from Ulf Hansson:
      
       - imx: scu-pd: Correct the DMA2 channel
      
      * tag 'pmdomain-v6.6-rc1-2' of git://git.kernel.org/pub/scm/linux/kernel/git/ulfh/linux-pm:
        pmdomain: imx: scu-pd: correct DMA2 channel
      9b1ad4ba