1. 30 Jul, 2023 5 commits
    • Linus Torvalds's avatar
      Merge tag 'locking_urgent_for_v6.5_rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · c959e900
      Linus Torvalds authored
      Pull locking fix from Borislav Petkov:
      
       - Fix a rtmutex race condition resulting from sharing of the sort key
         between the lock waiters and the PI chain tree (->pi_waiters) of a
         task by giving each tree their own sort key
      
      * tag 'locking_urgent_for_v6.5_rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        locking/rtmutex: Fix task->pi_waiters integrity
      c959e900
    • Linus Torvalds's avatar
      Merge tag 'x86_urgent_for_v6.5_rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · d410b62e
      Linus Torvalds authored
      Pull x86 fixes from Borislav Petkov:
      
       - AMD's automatic IBRS doesn't enable cross-thread branch target
         injection protection (STIBP) for user processes. Enable STIBP on such
         systems.
      
       - Do not delete (but put the ref instead) of AMD MCE error thresholding
         sysfs kobjects when destroying them in order not to delete the kernfs
         pointer prematurely
      
       - Restore annotation in ret_from_fork_asm() in order to fix kthread
         stack unwinding from being marked as unreliable and thus breaking
         livepatching
      
      * tag 'x86_urgent_for_v6.5_rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        x86/cpu: Enable STIBP on AMD if Automatic IBRS is enabled
        x86/MCE/AMD: Decrement threshold_bank refcount when removing threshold blocks
        x86: Fix kthread unwind
      d410b62e
    • Linus Torvalds's avatar
      Merge tag 'irq_urgent_for_v6.5_rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · eb9fe179
      Linus Torvalds authored
      Pull irq fixes from Borislav Petkov:
      
       - Work around an erratum on GIC700, where a race between a CPU handling
         a wake-up interrupt, a change of affinity, and another CPU going to
         sleep can result in a lack of wake-up event on the next interrupt
      
       - Fix the locking required on a VPE for GICv4
      
       - Enable Rockchip 3588001 erratum workaround for RK3588S
      
       - Fix the irq-bcm6345-l1 assumtions of the boot CPU always be the first
         CPU in the system
      
      * tag 'irq_urgent_for_v6.5_rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        irqchip/gic-v3: Workaround for GIC-700 erratum 2941627
        irqchip/gic-v3: Enable Rockchip 3588001 erratum workaround for RK3588S
        irqchip/gic-v4.1: Properly lock VPEs when doing a directLPI invalidation
        irq-bcm6345-l1: Do not assume a fixed block to cpu mapping
      eb9fe179
    • Linus Torvalds's avatar
      Merge tag '6.5-rc3-smb3-client-fixes' of git://git.samba.org/sfrench/cifs-2.6 · d31e3792
      Linus Torvalds authored
      Pull smb client fixes from Steve French:
       "Four small SMB3 client fixes:
      
         - two reconnect fixes (to address the case where non-default
           iocharset gets incorrectly overridden at reconnect with the
           default charset)
      
         - fix for NTLMSSP_AUTH request setting a flag incorrectly)
      
         - Add missing check for invalid tlink (tree connection) in ioctl"
      
      * tag '6.5-rc3-smb3-client-fixes' of git://git.samba.org/sfrench/cifs-2.6:
        cifs: add missing return value check for cifs_sb_tlink
        smb3: do not set NTLMSSP_VERSION flag for negotiate not auth request
        cifs: fix charset issue in reconnection
        fs/nls: make load_nls() take a const parameter
      d31e3792
    • Linus Torvalds's avatar
      Merge tag 'trace-v6.5-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/trace/linux-trace · b88e123c
      Linus Torvalds authored
      Pull tracing fixes from Steven Rostedt:
      
       - Fix to /sys/kernel/tracing/per_cpu/cpu*/stats read and entries.
      
         If a resize shrinks the buffer it clears the read count to notify
         readers that they need to reset. But the read count is also used for
         accounting and this causes the numbers to be off. Instead, create a
         separate variable to use to notify readers to reset.
      
       - Fix the ref counts of the "soft disable" mode. The wrong value was
         used for testing if soft disable mode should be enabled or disable,
         but instead, just change the logic to do the enable and disable in
         place when the SOFT_MODE is set or cleared.
      
       - Several kernel-doc fixes
      
       - Removal of unused external declarations
      
      * tag 'trace-v6.5-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/trace/linux-trace:
        tracing: Fix warning in trace_buffered_event_disable()
        ftrace: Remove unused extern declarations
        tracing: Fix kernel-doc warnings in trace_seq.c
        tracing: Fix kernel-doc warnings in trace_events_trigger.c
        tracing/synthetic: Fix kernel-doc warnings in trace_events_synth.c
        ring-buffer: Fix kernel-doc warnings in ring_buffer.c
        ring-buffer: Fix wrong stat of cpu_buffer->read
      b88e123c
  2. 29 Jul, 2023 9 commits
    • Sven Joachim's avatar
      arch/*/configs/*defconfig: Replace AUTOFS4_FS by AUTOFS_FS · 1f2190d6
      Sven Joachim authored
      Commit a2225d93 ("autofs: remove left-over autofs4 stubs")
      promised the removal of the fs/autofs/Kconfig fragment for AUTOFS4_FS
      within a couple of releases, but five years later this still has not
      happened yet, and AUTOFS4_FS is still enabled in 63 defconfigs.
      
      Get rid of it mechanically:
      
         git grep -l CONFIG_AUTOFS4_FS -- '*defconfig' |
             xargs sed -i 's/AUTOFS4_FS/AUTOFS_FS/'
      
      Also just remove the AUTOFS4_FS config option stub.  Anybody who hasn't
      regenerated their config file in the last five years will need to just
      get the new name right when they do.
      Signed-off-by: default avatarSven Joachim <svenjoac@gmx.de>
      Acked-by: default avatarIan Kent <raven@themaw.net>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      1f2190d6
    • Linus Torvalds's avatar
      Merge tag 'loongarch-fixes-6.5-1' of... · 12214540
      Linus Torvalds authored
      Merge tag 'loongarch-fixes-6.5-1' of git://git.kernel.org/pub/scm/linux/kernel/git/chenhuacai/linux-loongson
      
      Pull LoongArch fixes from Huacai Chen:
       "Some bug fixes for build system, builtin cmdline handling, bpf and
        {copy, clear}_user, together with a trivial cleanup"
      
      * tag 'loongarch-fixes-6.5-1' of git://git.kernel.org/pub/scm/linux/kernel/git/chenhuacai/linux-loongson:
        LoongArch: Cleanup __builtin_constant_p() checking for cpu_has_*
        LoongArch: BPF: Fix check condition to call lu32id in move_imm()
        LoongArch: BPF: Enable bpf_probe_read{, str}() on LoongArch
        LoongArch: Fix return value underflow in exception path
        LoongArch: Fix CMDLINE_EXTEND and CMDLINE_BOOTLOADER handling
        LoongArch: Fix module relocation error with binutils 2.41
        LoongArch: Only fiddle with CHECKFLAGS if `need-compiler'
      12214540
    • Linus Torvalds's avatar
      Merge tag 'ata-6.5-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/dlemoal/libata · ffabf7c7
      Linus Torvalds authored
      Pull ata fixes from Damien Le Moal:
      
       - Fix error message output in the pata_arasan_cf driver (Minjie)
      
       - Fix invalid error return in the pata_octeon_cf driver initialization
         (Yingliang)
      
       - Fix a compilation warning due to a missing static function
         declaration in the pata_ns87415 driver (Arnd)
      
       - Fix the condition evaluating when to fetch sense data for successful
         completions, which should be done only when command duration limits
         are being used (Niklas)
      
      * tag 'ata-6.5-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/dlemoal/libata:
        ata: libata-core: fix when to fetch sense data for successful commands
        ata: pata_ns87415: mark ns87560_tf_read static
        ata: pata_octeon_cf: fix error return code in octeon_cf_probe()
        ata: pata_arasan_cf: Use dev_err_probe() instead dev_err() in data_xfer()
      ffabf7c7
    • Zheng Yejian's avatar
      tracing: Fix warning in trace_buffered_event_disable() · dea49978
      Zheng Yejian authored
      Warning happened in trace_buffered_event_disable() at
        WARN_ON_ONCE(!trace_buffered_event_ref)
      
        Call Trace:
         ? __warn+0xa5/0x1b0
         ? trace_buffered_event_disable+0x189/0x1b0
         __ftrace_event_enable_disable+0x19e/0x3e0
         free_probe_data+0x3b/0xa0
         unregister_ftrace_function_probe_func+0x6b8/0x800
         event_enable_func+0x2f0/0x3d0
         ftrace_process_regex.isra.0+0x12d/0x1b0
         ftrace_filter_write+0xe6/0x140
         vfs_write+0x1c9/0x6f0
         [...]
      
      The cause of the warning is in __ftrace_event_enable_disable(),
      trace_buffered_event_enable() was called once while
      trace_buffered_event_disable() was called twice.
      Reproduction script show as below, for analysis, see the comments:
       ```
       #!/bin/bash
      
       cd /sys/kernel/tracing/
      
       # 1. Register a 'disable_event' command, then:
       #    1) SOFT_DISABLED_BIT was set;
       #    2) trace_buffered_event_enable() was called first time;
       echo 'cmdline_proc_show:disable_event:initcall:initcall_finish' > \
           set_ftrace_filter
      
       # 2. Enable the event registered, then:
       #    1) SOFT_DISABLED_BIT was cleared;
       #    2) trace_buffered_event_disable() was called first time;
       echo 1 > events/initcall/initcall_finish/enable
      
       # 3. Try to call into cmdline_proc_show(), then SOFT_DISABLED_BIT was
       #    set again!!!
       cat /proc/cmdline
      
       # 4. Unregister the 'disable_event' command, then:
       #    1) SOFT_DISABLED_BIT was cleared again;
       #    2) trace_buffered_event_disable() was called second time!!!
       echo '!cmdline_proc_show:disable_event:initcall:initcall_finish' > \
           set_ftrace_filter
       ```
      
      To fix it, IIUC, we can change to call trace_buffered_event_enable() at
      fist time soft-mode enabled, and call trace_buffered_event_disable() at
      last time soft-mode disabled.
      
      Link: https://lore.kernel.org/linux-trace-kernel/20230726095804.920457-1-zhengyejian1@huawei.com
      
      Cc: <mhiramat@kernel.org>
      Fixes: 0fc1b09f ("tracing: Use temp buffer when filtering events")
      Signed-off-by: default avatarZheng Yejian <zhengyejian1@huawei.com>
      Signed-off-by: default avatarSteven Rostedt (Google) <rostedt@goodmis.org>
      dea49978
    • Linus Torvalds's avatar
      Merge tag 'mm-hotfixes-stable-2023-07-28-15-52' of... · 122e7943
      Linus Torvalds authored
      Merge tag 'mm-hotfixes-stable-2023-07-28-15-52' of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm
      
      Pull hotfixes from Andrew Morton:
       "11 hotfixes. Five are cc:stable and the remainder address post-6.4
        issues or aren't considered serious enough to justify backporting"
      
      * tag 'mm-hotfixes-stable-2023-07-28-15-52' of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm:
        mm/memory-failure: fix hardware poison check in unpoison_memory()
        proc/vmcore: fix signedness bug in read_from_oldmem()
        mailmap: update remaining active codeaurora.org email addresses
        mm: lock VMA in dup_anon_vma() before setting ->anon_vma
        mm: fix memory ordering for mm_lock_seq and vm_lock_seq
        scripts/spelling.txt: remove 'thead' as a typo
        mm/pagewalk: fix EFI_PGT_DUMP of espfix area
        shmem: minor fixes to splice-read implementation
        tmpfs: fix Documentation of noswap and huge mount options
        Revert "um: Use swap() to make code cleaner"
        mm/damon/core-test: initialise context before test in damon_test_set_attrs()
      122e7943
    • Linus Torvalds's avatar
      Merge tag 'thermal-6.5-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm · 20d3f241
      Linus Torvalds authored
      Pull thermal control fixes from Rafael Wysocki:
       "Constify thermal_zone_device_register() parameters, which was omitted
        by mistake, and fix a double free on thermal zone unregistration in
        the generic DT thermal driver (Ahmad Fatoum)"
      
      * tag 'thermal-6.5-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm:
        thermal: of: fix double-free on unregistration
        thermal: core: constify params in thermal_zone_device_register
      20d3f241
    • Linus Torvalds's avatar
      Merge tag 'pm-6.5-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm · 3632f421
      Linus Torvalds authored
      Pull power management fixes from Rafael Wysocki:
       "Fix the arming of wakeup IRQs in the generic wakeup IRQ code
        (wakeirq), drop unused functions from it and fix up a driver using it
        and trying to work around the IRQ arming issue in a questionable way
        (Johan Hovold)"
      
      * tag 'pm-6.5-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm:
        serial: qcom-geni: drop bogus runtime pm state update
        PM: sleep: wakeirq: drop unused enable helpers
        PM: sleep: wakeirq: fix wake irq arming
      3632f421
    • Linus Torvalds's avatar
      Merge tag 'hwmon-for-v6.5-rc4' of... · 2f4effd8
      Linus Torvalds authored
      Merge tag 'hwmon-for-v6.5-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging
      
      Pull hwmon fixes from Guenter Roeck:
      
       - k10temp: Display negative temperatures for industrial processors
      
       - pmbus core: Fix deadlock, NULL pointer dereference, and chip enable
         detection
      
       - nct7802: Do not display PECI1 temperature if disabled
      
       - nct6775: Fix IN scaling factors and feature detection for
         NCT6798/6799
      
       - oxp-sensors: Fix race condition during device attribute creation
      
       - aquacomputer_d5next: Fix incorrect PWM value readout
      
      * tag 'hwmon-for-v6.5-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging:
        hwmon: (k10temp) Enable AMD3255 Proc to show negative temperature
        hwmon: (pmbus_core) Fix Deadlock in pmbus_regulator_get_status
        hwmon: (pmbus_core) Fix NULL pointer dereference
        hwmon: (pmbus_core) Fix pmbus_is_enabled()
        hwmon: (nct7802) Fix for temp6 (PECI1) processed even if PECI1 disabled
        hwmon: (nct6775) Fix IN scaling factors for 6798/6799
        hwmon: (oxp-sensors) Move tt_toggle attribute to dev_groups
        hwmon: (aquacomputer_d5next) Fix incorrect PWM value readout
        hwmon: (nct6775) Fix register for nct6799
      2f4effd8
    • YueHaibing's avatar
      ftrace: Remove unused extern declarations · 800959e6
      YueHaibing authored
      commit 6a9c981b ("ftrace: Remove unused function ftrace_arch_read_dyn_info()")
      left ftrace_arch_read_dyn_info() extern declaration.
      And commit 1d74f2a0 ("ftrace: remove ftrace_ip_converted()")
      leave ftrace_ip_converted() declaration.
      
      Link: https://lore.kernel.org/linux-trace-kernel/20230725134808.9716-1-yuehaibing@huawei.com
      
      Cc: <mhiramat@kernel.org>
      Cc: <mark.rutland@arm.com>
      Signed-off-by: default avatarYueHaibing <yuehaibing@huawei.com>
      Signed-off-by: default avatarSteven Rostedt (Google) <rostedt@goodmis.org>
      800959e6
  3. 28 Jul, 2023 26 commits