1. 24 Nov, 2022 6 commits
    • Steven Rostedt (Google)'s avatar
      tracing: Add trace_trigger kernel command line option · a01fdc89
      Steven Rostedt (Google) authored
      Allow triggers to be enabled at kernel boot up. For example:
      
        trace_trigger="sched_switch.stacktrace if prev_state == 2"
      
      The above will enable the stacktrace trigger on top of the sched_switch
      event and only trigger if its prev_state is 2 (TASK_UNINTERRUPTIBLE). Then
      at boot up, a stacktrace will trigger and be recorded in the tracing ring
      buffer every time the sched_switch happens where the previous state is
      TASK_INTERRUPTIBLE.
      
      Another useful trigger would be "traceoff" which can stop tracing on an
      event if a field of the event matches a certain value defined by the
      filter ("if" statement).
      
      Link: https://lore.kernel.org/linux-trace-kernel/20221020210056.0d8d0a5b@gandalf.local.homeSigned-off-by: default avatarSteven Rostedt (Google) <rostedt@goodmis.org>
      a01fdc89
    • Steven Rostedt (Google)'s avatar
      tracing: Add __cpumask to denote a trace event field that is a cpumask_t · 8230f27b
      Steven Rostedt (Google) authored
      The trace events have a __bitmask field that can be used for anything
      that requires bitmasks. Although currently it is only used for CPU
      masks, it could be used in the future for any type of bitmasks.
      
      There is some user space tooling that wants to know if a field is a CPU
      mask and not just some random unsigned long bitmask. Introduce
      "__cpumask()" helper functions that work the same as the current
      __bitmask() helpers but displays in the format file:
      
        field:__data_loc cpumask_t *[] mask;    offset:36;      size:4; signed:0;
      
      Instead of:
      
        field:__data_loc unsigned long[] mask;  offset:32;      size:4; signed:0;
      
      The main difference is the type. Instead of "unsigned long" it is
      "cpumask_t *". Note, this type field needs to be a real type in the
      __dynamic_array() logic that both __cpumask and__bitmask use, but the
      comparison field requires it to be a scalar type whereas cpumask_t is a
      structure (non-scalar). But everything works when making it a pointer.
      
      Valentin added changes to remove the need of passing in "nr_bits" and the
      __cpumask will always use nr_cpumask_bits as its size.
      
      Link: https://lkml.kernel.org/r/20221014080456.1d32b989@rorschach.local.homeRequested-by: default avatarValentin Schneider <vschneid@redhat.com>
      Reviewed-by: default avatarValentin Schneider <vschneid@redhat.com>
      Signed-off-by: default avatarValentin Schneider <vschneid@redhat.com>
      Signed-off-by: default avatarSteven Rostedt (Google) <rostedt@goodmis.org>
      8230f27b
    • Zheng Yejian's avatar
      ftrace: Clean comments related to FTRACE_OPS_FL_PER_CPU · 78a01feb
      Zheng Yejian authored
      Commit b3a88803 ("ftrace: Kill FTRACE_OPS_FL_PER_CPU") didn't
      completely remove the comments related to FTRACE_OPS_FL_PER_CPU.
      
      Link: https://lkml.kernel.org/r/20221025153923.1995973-1-zhengyejian1@huawei.com
      
      Fixes: b3a88803 ("ftrace: Kill FTRACE_OPS_FL_PER_CPU")
      Signed-off-by: default avatarZheng Yejian <zhengyejian1@huawei.com>
      Signed-off-by: default avatarSteven Rostedt (Google) <rostedt@goodmis.org>
      78a01feb
    • Steven Rostedt (Google)'s avatar
      tracing: Free buffers when a used dynamic event is removed · 4313e5a6
      Steven Rostedt (Google) authored
      After 65536 dynamic events have been added and removed, the "type" field
      of the event then uses the first type number that is available (not
      currently used by other events). A type number is the identifier of the
      binary blobs in the tracing ring buffer (known as events) to map them to
      logic that can parse the binary blob.
      
      The issue is that if a dynamic event (like a kprobe event) is traced and
      is in the ring buffer, and then that event is removed (because it is
      dynamic, which means it can be created and destroyed), if another dynamic
      event is created that has the same number that new event's logic on
      parsing the binary blob will be used.
      
      To show how this can be an issue, the following can crash the kernel:
      
       # cd /sys/kernel/tracing
       # for i in `seq 65536`; do
           echo 'p:kprobes/foo do_sys_openat2 $arg1:u32' > kprobe_events
       # done
      
      For every iteration of the above, the writing to the kprobe_events will
      remove the old event and create a new one (with the same format) and
      increase the type number to the next available on until the type number
      reaches over 65535 which is the max number for the 16 bit type. After it
      reaches that number, the logic to allocate a new number simply looks for
      the next available number. When an dynamic event is removed, that number
      is then available to be reused by the next dynamic event created. That is,
      once the above reaches the max number, the number assigned to the event in
      that loop will remain the same.
      
      Now that means deleting one dynamic event and created another will reuse
      the previous events type number. This is where bad things can happen.
      After the above loop finishes, the kprobes/foo event which reads the
      do_sys_openat2 function call's first parameter as an integer.
      
       # echo 1 > kprobes/foo/enable
       # cat /etc/passwd > /dev/null
       # cat trace
                   cat-2211    [005] ....  2007.849603: foo: (do_sys_openat2+0x0/0x130) arg1=4294967196
                   cat-2211    [005] ....  2007.849620: foo: (do_sys_openat2+0x0/0x130) arg1=4294967196
                   cat-2211    [005] ....  2007.849838: foo: (do_sys_openat2+0x0/0x130) arg1=4294967196
                   cat-2211    [005] ....  2007.849880: foo: (do_sys_openat2+0x0/0x130) arg1=4294967196
       # echo 0 > kprobes/foo/enable
      
      Now if we delete the kprobe and create a new one that reads a string:
      
       # echo 'p:kprobes/foo do_sys_openat2 +0($arg2):string' > kprobe_events
      
      And now we can the trace:
      
       # cat trace
              sendmail-1942    [002] .....   530.136320: foo: (do_sys_openat2+0x0/0x240) arg1=             cat-2046    [004] .....   530.930817: foo: (do_sys_openat2+0x0/0x240) arg1="������������������������������������������������������������������������������������������������"
                   cat-2046    [004] .....   530.930961: foo: (do_sys_openat2+0x0/0x240) arg1="������������������������������������������������������������������������������������������������"
                   cat-2046    [004] .....   530.934278: foo: (do_sys_openat2+0x0/0x240) arg1="������������������������������������������������������������������������������������������������"
                   cat-2046    [004] .....   530.934563: foo: (do_sys_openat2+0x0/0x240) arg1="������������������������������������������������������������������������������������������������"
                  bash-1515    [007] .....   534.299093: foo: (do_sys_openat2+0x0/0x240) arg1="kkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk���������@��4Z����;Y�����U
      
      And dmesg has:
      
      ==================================================================
      BUG: KASAN: use-after-free in string+0xd4/0x1c0
      Read of size 1 at addr ffff88805fdbbfa0 by task cat/2049
      
       CPU: 0 PID: 2049 Comm: cat Not tainted 6.1.0-rc6-test+ #641
       Hardware name: Hewlett-Packard HP Compaq Pro 6300 SFF/339A, BIOS K01 v03.03 07/14/2016
       Call Trace:
        <TASK>
        dump_stack_lvl+0x5b/0x77
        print_report+0x17f/0x47b
        kasan_report+0xad/0x130
        string+0xd4/0x1c0
        vsnprintf+0x500/0x840
        seq_buf_vprintf+0x62/0xc0
        trace_seq_printf+0x10e/0x1e0
        print_type_string+0x90/0xa0
        print_kprobe_event+0x16b/0x290
        print_trace_line+0x451/0x8e0
        s_show+0x72/0x1f0
        seq_read_iter+0x58e/0x750
        seq_read+0x115/0x160
        vfs_read+0x11d/0x460
        ksys_read+0xa9/0x130
        do_syscall_64+0x3a/0x90
        entry_SYSCALL_64_after_hwframe+0x63/0xcd
       RIP: 0033:0x7fc2e972ade2
       Code: c0 e9 b2 fe ff ff 50 48 8d 3d b2 3f 0a 00 e8 05 f0 01 00 0f 1f 44 00 00 f3 0f 1e fa 64 8b 04 25 18 00 00 00 85 c0 75 10 0f 05 <48> 3d 00 f0 ff ff 77 56 c3 0f 1f 44 00 00 48 83 ec 28 48 89 54 24
       RSP: 002b:00007ffc64e687c8 EFLAGS: 00000246 ORIG_RAX: 0000000000000000
       RAX: ffffffffffffffda RBX: 0000000000020000 RCX: 00007fc2e972ade2
       RDX: 0000000000020000 RSI: 00007fc2e980d000 RDI: 0000000000000003
       RBP: 00007fc2e980d000 R08: 00007fc2e980c010 R09: 0000000000000000
       R10: 0000000000000022 R11: 0000000000000246 R12: 0000000000020f00
       R13: 0000000000000003 R14: 0000000000020000 R15: 0000000000020000
        </TASK>
      
       The buggy address belongs to the physical page:
       page:ffffea00017f6ec0 refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x5fdbb
       flags: 0xfffffc0000000(node=0|zone=1|lastcpupid=0x1fffff)
       raw: 000fffffc0000000 0000000000000000 ffffea00017f6ec8 0000000000000000
       raw: 0000000000000000 0000000000000000 00000000ffffffff 0000000000000000
       page dumped because: kasan: bad access detected
      
       Memory state around the buggy address:
        ffff88805fdbbe80: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
        ffff88805fdbbf00: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
       >ffff88805fdbbf80: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
                                      ^
        ffff88805fdbc000: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
        ffff88805fdbc080: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
       ==================================================================
      
      This was found when Zheng Yejian sent a patch to convert the event type
      number assignment to use IDA, which gives the next available number, and
      this bug showed up in the fuzz testing by Yujie Liu and the kernel test
      robot. But after further analysis, I found that this behavior is the same
      as when the event type numbers go past the 16bit max (and the above shows
      that).
      
      As modules have a similar issue, but is dealt with by setting a
      "WAS_ENABLED" flag when a module event is enabled, and when the module is
      freed, if any of its events were enabled, the ring buffer that holds that
      event is also cleared, to prevent reading stale events. The same can be
      done for dynamic events.
      
      If any dynamic event that is being removed was enabled, then make sure the
      buffers they were enabled in are now cleared.
      
      Link: https://lkml.kernel.org/r/20221123171434.545706e3@gandalf.local.home
      Link: https://lore.kernel.org/all/20221110020319.1259291-1-zhengyejian1@huawei.com/
      
      Cc: stable@vger.kernel.org
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Depends-on: e18eb878 ("tracing: Add tracing_reset_all_online_cpus_unlocked() function")
      Depends-on: 5448d44c ("tracing: Add unified dynamic event framework")
      Depends-on: 6212dd29 ("tracing/kprobes: Use dyn_event framework for kprobe events")
      Depends-on: 065e63f9 ("tracing: Only have rmmod clear buffers that its events were active in")
      Depends-on: 575380da ("tracing: Only clear trace buffer on module unload if event was traced")
      Fixes: 77b44d1b ("tracing/kprobes: Rename Kprobe-tracer to kprobe-event")
      Reported-by: default avatarZheng Yejian <zhengyejian1@huawei.com>
      Reported-by: default avatarYujie Liu <yujie.liu@intel.com>
      Reported-by: default avatarkernel test robot <yujie.liu@intel.com>
      Acked-by: default avatarMasami Hiramatsu (Google) <mhiramat@kernel.org>
      Signed-off-by: default avatarSteven Rostedt (Google) <rostedt@goodmis.org>
      4313e5a6
    • Steven Rostedt (Google)'s avatar
      tracing: Add tracing_reset_all_online_cpus_unlocked() function · e18eb878
      Steven Rostedt (Google) authored
      Currently the tracing_reset_all_online_cpus() requires the
      trace_types_lock held. But only one caller of this function actually has
      that lock held before calling it, and the other just takes the lock so
      that it can call it. More users of this function is needed where the lock
      is not held.
      
      Add a tracing_reset_all_online_cpus_unlocked() function for the one use
      case that calls it without being held, and also add a lockdep_assert to
      make sure it is held when called.
      
      Then have tracing_reset_all_online_cpus() take the lock internally, such
      that callers do not need to worry about taking it.
      
      Link: https://lkml.kernel.org/r/20221123192741.658273220@goodmis.org
      
      Cc: Masami Hiramatsu <mhiramat@kernel.org>
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Cc: Zheng Yejian <zhengyejian1@huawei.com>
      Signed-off-by: default avatarSteven Rostedt (Google) <rostedt@goodmis.org>
      e18eb878
    • Steven Rostedt (Google)'s avatar
      tracing: Fix race where histograms can be called before the event · ef38c79a
      Steven Rostedt (Google) authored
      commit 94eedf3d ("tracing: Fix race where eprobes can be called before
      the event") fixed an issue where if an event is soft disabled, and the
      trigger is being added, there's a small window where the event sees that
      there's a trigger but does not see that it requires reading the event yet,
      and then calls the trigger with the record == NULL.
      
      This could be solved with adding memory barriers in the hot path, or to
      make sure that all the triggers requiring a record check for NULL. The
      latter was chosen.
      
      Commit 94eedf3d set the eprobe trigger handle to check for NULL, but
      the same needs to be done with histograms.
      
      Link: https://lore.kernel.org/linux-trace-kernel/20221118211809.701d40c0f8a757b0df3c025a@kernel.org/
      Link: https://lore.kernel.org/linux-trace-kernel/20221123164323.03450c3a@gandalf.local.home
      
      Cc: Tom Zanussi <zanussi@kernel.org>
      Cc: stable@vger.kernel.org
      Fixes: 7491e2c4 ("tracing: Add a probe that attaches to trace events")
      Reported-by: default avatarMasami Hiramatsu (Google) <mhiramat@kernel.org>
      Acked-by: default avatarMasami Hiramatsu (Google) <mhiramat@kernel.org>
      Signed-off-by: default avatarSteven Rostedt (Google) <rostedt@goodmis.org>
      ef38c79a
  2. 22 Nov, 2022 3 commits
  3. 21 Nov, 2022 1 commit
  4. 20 Nov, 2022 8 commits
  5. 19 Nov, 2022 8 commits
  6. 18 Nov, 2022 14 commits
    • Chen Jun's avatar
      Input: i8042 - fix leaking of platform device on module removal · 81cd7e84
      Chen Jun authored
      Avoid resetting the module-wide i8042_platform_device pointer in
      i8042_probe() or i8042_remove(), so that the device can be properly
      destroyed by i8042_exit() on module unload.
      
      Fixes: 9222ba68 ("Input: i8042 - add deferred probe support")
      Signed-off-by: default avatarChen Jun <chenjun102@huawei.com>
      Link: https://lore.kernel.org/r/20221109034148.23821-1-chenjun102@huawei.comSigned-off-by: default avatarDmitry Torokhov <dmitry.torokhov@gmail.com>
      81cd7e84
    • Linus Torvalds's avatar
      Merge tag 'io_uring-6.1-2022-11-18' of git://git.kernel.dk/linux · a66e4cbf
      Linus Torvalds authored
      Pull io_uring fixes from Jens Axboe:
       "This is mostly fixing issues around the poll rework, but also two
        tweaks for the multishot handling for accept and receive.
      
        All stable material"
      
      * tag 'io_uring-6.1-2022-11-18' of git://git.kernel.dk/linux:
        io_uring: disallow self-propelled ring polling
        io_uring: fix multishot recv request leaks
        io_uring: fix multishot accept request leaks
        io_uring: fix tw losing poll events
        io_uring: update res mask in io_poll_check_events
      a66e4cbf
    • Linus Torvalds's avatar
      Merge tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux · 23a60a03
      Linus Torvalds authored
      Pull arm64 fixes from Catalin Marinas:
      
       - Fix a build error with CONFIG_CFI_CLANG + CONFIG_FTRACE when
         CONFIG_FUNCTION_GRAPH_TRACER is not enabled.
      
       - Fix a BUG_ON triggered by the page table checker due to incorrect
         file_map_count for non-leaf pmd/pud (the arm64
         pmd_user_accessible_page() not checking whether it's a leaf entry).
      
      * tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux:
        arm64/mm: fix incorrect file_map_count for non-leaf pmd/pud
        arm64: ftrace: Define ftrace_stub_graph only with FUNCTION_GRAPH_TRACER
      23a60a03
    • Linus Torvalds's avatar
      Merge tag 'block-6.1-2022-11-18' of git://git.kernel.dk/linux · f4408c3d
      Linus Torvalds authored
      Pull block fixes from Jens Axboe:
      
       - NVMe pull request via Christoph:
            - Two more bogus nid quirks (Bean Huo, Tiago Dias Ferreira)
            - Memory leak fix in nvmet (Sagi Grimberg)
      
       - Regression fix for block cgroups pinning the wrong blkcg, causing
         leaks of cgroups and blkcgs (Chris)
      
       - UAF fix for drbd setup error handling (Dan)
      
       - Fix DMA alignment propagation in DM (Keith)
      
      * tag 'block-6.1-2022-11-18' of git://git.kernel.dk/linux:
        dm-log-writes: set dma_alignment limit in io_hints
        dm-integrity: set dma_alignment limit in io_hints
        block: make blk_set_default_limits() private
        dm-crypt: provide dma_alignment limit in io_hints
        block: make dma_alignment a stacking queue_limit
        nvmet: fix a memory leak in nvmet_auth_set_key
        nvme-pci: add NVME_QUIRK_BOGUS_NID for Netac NV7000
        drbd: use after free in drbd_create_device()
        nvme-pci: add NVME_QUIRK_BOGUS_NID for Micron Nitro
        blk-cgroup: properly pin the parent in blkcg_css_online
      f4408c3d
    • Linus Torvalds's avatar
      Merge tag 'drm-fixes-2022-11-19' of git://anongit.freedesktop.org/drm/drm · b5bf1d8a
      Linus Torvalds authored
      Pull drm fixes from Dave Airlie:
       "I guess the main question is are things settling down, and I'd say
        kinda, these are all pretty small fixes, nothing big stands out
        really, just seems to be quite a few of them.
      
        Mostly amdgpu and core fixes, with some i915, tegra, vc4, panel bits.
      
        core:
         - Fix potential memory leak in drm_dev_init()
         - Fix potential null-ptr-deref in drm_vblank_destroy_worker()
         - Revert hiding unregistered connectors from userspace, as it breaks
           on DP-MST
         - Add workaround for DP++ dual mode adaptors that don't support i2c
           subaddressing
      
        i915:
         - Fix uaf with lmem_userfault_list handling
      
        amdgpu:
         - gang submit fixes
         - Fix a possible memory leak in ganng submit error path
         - DP tunneling fixes
         - DCN 3.1 page flip fix
         - DCN 3.2.x fixes
         - DCN 3.1.4 fixes
         - Don't expose degamma on hardware that doesn't support it
         - BACO fixes for SMU 11.x
         - BACO fixes for SMU 13.x
         - Virtual display fix for devices with no display hardware
      
        amdkfd:
         - Memory limit regression fix
      
        tegra:
         - tegra20 GART fix
      
        vc4:
         - Fix error handling in vc4_atomic_commit_tail()
      
        lima:
         - Set lima's clkname corrrectly when regulator is missing
      
        panel:
         - Set bpc for logictechno panels"
      
      * tag 'drm-fixes-2022-11-19' of git://anongit.freedesktop.org/drm/drm: (28 commits)
        gpu: host1x: Avoid trying to use GART on Tegra20
        drm/display: Don't assume dual mode adaptors support i2c sub-addressing
        drm/amd/pm: fix SMU13 runpm hang due to unintentional workaround
        drm/amd/pm: enable runpm support over BACO for SMU13.0.7
        drm/amd/pm: enable runpm support over BACO for SMU13.0.0
        drm/amdgpu: there is no vbios fb on devices with no display hw (v2)
        drm/amdkfd: Fix a memory limit issue
        drm/amdgpu: disable BACO support on more cards
        drm/amd/display: don't enable DRM CRTC degamma property for DCE
        drm/amd/display: Set max for prefetch lines on dcn32
        drm/amd/display: use uclk pstate latency for fw assisted mclk validation dcn32
        drm/amd/display: Fix prefetch calculations for dcn32
        drm/amd/display: Fix optc2_configure warning on dcn314
        drm/amd/display: Fix calculation for cursor CAB allocation
        Revert "drm: hide unregistered connectors from GETCONNECTOR IOCTL"
        drm/amd/display: Support parsing VRAM info v3.0 from VBIOS
        drm/amd/display: Fix invalid DPIA AUX reply causing system hang
        drm/amdgpu: Add psp_13_0_10_ta firmware to modinfo
        drm/amd/display: Add HUBP surface flip interrupt handler
        drm/amd/display: Fix access timeout to DPIA AUX at boot time
        ...
      b5bf1d8a
    • Linus Torvalds's avatar
      Merge tag 's390-6.1-5' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux · ab290ead
      Linus Torvalds authored
      Pull s390 fixes from Alexander Gordeev:
      
       - Fix deadlock in discontiguous saved segments (DCSS) block device
         driver. When adding a disk and scanning partitions the scan would not
         break out early without a missed flag.
      
       - Avoid using global register variable for current_stack_pointer due to
         an old bug in gcc versions prior to gcc-8.4. Due to this bug a broken
         code is generated, which leads to stack corruptions.
      
      * tag 's390-6.1-5' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux:
        s390: avoid using global register for current_stack_pointer
        s390/dcssblk: fix deadlock when adding a DCSS
      ab290ead
    • Linus Torvalds's avatar
      Merge tag 'for-6.1/dm-fixes-2' of... · 5556a78c
      Linus Torvalds authored
      Merge tag 'for-6.1/dm-fixes-2' of git://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm
      
      Pull device mapper fixes from Mike Snitzer:
      
       - Fix misbehavior if list_versions DM ioctl races with module loading
      
       - Fix missing decrement of no_sleep_enabled if dm_bufio_client_create
         failed
      
       - Allow DM integrity devices to be activated in read-only mode
      
      * tag 'for-6.1/dm-fixes-2' of git://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm:
        dm integrity: clear the journal on suspend
        dm integrity: flush the journal on suspend
        dm bufio: Fix missing decrement of no_sleep_enabled if dm_bufio_client_create failed
        dm ioctl: fix misbehavior if list_versions races with module loading
      5556a78c
    • Dave Airlie's avatar
      Merge tag 'drm/tegra/for-6.1-rc6' of https://gitlab.freedesktop.org/drm/tegra into drm-fixes · b1010b93
      Dave Airlie authored
      drm/tegra: Fixes for v6.1-rc6
      
      This contains a single fix that avoids using the GART on Tegra20 because
      it doesn't work well with the way the Tegra DRM driver tries to use it.
      Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
      
      From: Thierry Reding <thierry.reding@gmail.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20221118121614.3511110-1-thierry.reding@gmail.com
      b1010b93
    • Linus Torvalds's avatar
      Merge tag 'usb-6.1-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb · 950a9f56
      Linus Torvalds authored
      Pull USB driver fixes from Greg KH:
       "Here are a number of USB driver fixes and new device ids for 6.1-rc6.
        Included in here are:
      
         - new usb-serial device ids
      
         - dwc3 driver fixes for reported problems
      
         - cdns3 driver fixes
      
         - new USB device quirks
      
         - typec driver fixes
      
         - extcon USB typec driver fix
      
        All of these have been in linux-next with no reported issues"
      
      * tag 'usb-6.1-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb:
        USB: serial: option: add u-blox LARA-L6 modem
        USB: serial: option: add u-blox LARA-R6 00B modem
        USB: serial: option: remove old LARA-R6 PID
        USB: serial: option: add Fibocom FM160 0x0111 composition
        usb: add NO_LPM quirk for Realforce 87U Keyboard
        usb: cdns3: host: fix endless superspeed hub port reset
        usb: chipidea: fix deadlock in ci_otg_del_timer
        usb: dwc3: Do not get extcon device when usb-role-switch is used
        usb: typec: tipd: Prevent uninitialized event{1,2} in IRQ handler
        usb: typec: mux: Enter safe mode only when pins need to be reconfigured
        extcon: usbc-tusb320: Call the Type-C IRQ handler only if a port is registered
        Revert "usb: dwc3: disable USB core PHY management"
        usb: dwc3: gadget: Return -ESHUTDOWN on ep disable
        USB: bcma: Make GPIO explicitly optional
        USB: serial: option: add Sierra Wireless EM9191
      950a9f56
    • Linus Torvalds's avatar
      Merge tag 'staging-6.1-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging · 12fe29ee
      Linus Torvalds authored
      Pull staging driver fix from Greg KH:
       "Here is a single staging driver fix for 6.1-rc6.
      
        It resolves a bogus signed character test as pointed out, and fixed
        by, Jason in the rtl8192e driver
      
        It has been in linux-next for a few weeks now with no reported
        problems"
      
      * tag 'staging-6.1-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging:
        staging: rtl8192e: remove bogus ssid character sign test
      12fe29ee
    • Liu Shixin's avatar
      arm64/mm: fix incorrect file_map_count for non-leaf pmd/pud · 5b47348f
      Liu Shixin authored
      The page table check trigger BUG_ON() unexpectedly when collapse hugepage:
      
       ------------[ cut here ]------------
       kernel BUG at mm/page_table_check.c:82!
       Internal error: Oops - BUG: 00000000f2000800 [#1] SMP
       Dumping ftrace buffer:
          (ftrace buffer empty)
       Modules linked in:
       CPU: 6 PID: 68 Comm: khugepaged Not tainted 6.1.0-rc3+ #750
       Hardware name: linux,dummy-virt (DT)
       pstate: 60000005 (nZCv daif -PAN -UAO -TCO -DIT -SSBS BTYPE=--)
       pc : page_table_check_clear.isra.0+0x258/0x3f0
       lr : page_table_check_clear.isra.0+0x240/0x3f0
      [...]
       Call trace:
        page_table_check_clear.isra.0+0x258/0x3f0
        __page_table_check_pmd_clear+0xbc/0x108
        pmdp_collapse_flush+0xb0/0x160
        collapse_huge_page+0xa08/0x1080
        hpage_collapse_scan_pmd+0xf30/0x1590
        khugepaged_scan_mm_slot.constprop.0+0x52c/0xac8
        khugepaged+0x338/0x518
        kthread+0x278/0x2f8
        ret_from_fork+0x10/0x20
      [...]
      
      Since pmd_user_accessible_page() doesn't check if a pmd is leaf, it
      decrease file_map_count for a non-leaf pmd comes from collapse_huge_page().
      and so trigger BUG_ON() unexpectedly.
      
      Fix this problem by using pmd_leaf() insteal of pmd_present() in
      pmd_user_accessible_page(). Moreover, use pud_leaf() for
      pud_user_accessible_page() too.
      
      Fixes: 42b25471 ("arm64/mm: enable ARCH_SUPPORTS_PAGE_TABLE_CHECK")
      Reported-by: default avatarDenys Vlasenko <dvlasenk@redhat.com>
      Signed-off-by: default avatarLiu Shixin <liushixin2@huawei.com>
      Reviewed-by: default avatarDavid Hildenbrand <david@redhat.com>
      Acked-by: default avatarPasha Tatashin <pasha.tatashin@soleen.com>
      Reviewed-by: default avatarKefeng Wang <wangkefeng.wang@huawei.com>
      Acked-by: default avatarWill Deacon <will@kernel.org>
      Link: https://lore.kernel.org/r/20221117075602.2904324-2-liushixin2@huawei.comSigned-off-by: default avatarCatalin Marinas <catalin.marinas@arm.com>
      5b47348f
    • Linus Torvalds's avatar
      Merge tag 'tty-6.1-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty · 09389357
      Linus Torvalds authored
      Pull tty/serial driver fixes from Greg KH:
       "Here are a number of small tty and serial driver fixes for 6.1-rc6.
        They all resolve reported problems:
      
         - kernel doc build problems with the -rc1 serial driver documentation
           update
      
         - n_gsm reported problems
      
         - imx serial driver missing callback
      
         - lots of tiny 8250 driver fixes for reported issues.
      
        All of these have been in linux-next for over a week with no reported
        problems"
      
      * tag 'tty-6.1-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty:
        docs/driver-api/miscellaneous: Remove kernel-doc of serial_core.c
        serial: 8250: Flush DMA Rx on RLSI
        serial: 8250_lpss: Use 16B DMA burst with Elkhart Lake
        serial: 8250_lpss: Configure DMA also w/o DMA filter
        serial: 8250: Fall back to non-DMA Rx if IIR_RDI occurs
        tty: n_gsm: fix sleep-in-atomic-context bug in gsm_control_send
        Revert "tty: n_gsm: replace kicktimer with delayed_work"
        Revert "tty: n_gsm: avoid call of sleeping functions from atomic context"
        serial: imx: Add missing .thaw_noirq hook
        tty: serial: fsl_lpuart: don't break the on-going transfer when global reset
        serial: 8250: omap: Flush PM QOS work on remove
        serial: 8250: omap: Fix unpaired pm_runtime_put_sync() in omap8250_remove()
        serial: 8250_omap: remove wait loop from Errata i202 workaround
        serial: 8250: omap: Fix missing PM runtime calls for omap8250_set_mctrl()
        serial: 8250: 8250_omap: Avoid RS485 RTS glitch on ->set_termios()
      09389357
    • Linus Torvalds's avatar
      Merge tag 'driver-core-6.1-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core · 63c8c0d7
      Linus Torvalds authored
      Pull driver core fixes from Greg KH:
       "Here are two small driver core fixes for 6.1-rc6:
      
         - utsname fix, this one should already be in your tree as it came
           from a different tree earlier.
      
         - kernfs bugfix for a much reported syzbot report that seems to keep
           getting triggered.
      
        Both of these have been in linux-next for a while with no reported
        issues"
      
      * tag 'driver-core-6.1-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core:
        kernfs: Fix spurious lockdep warning in kernfs_find_and_get_node_by_id()
        kernel/utsname_sysctl.c: Add missing enum uts_proc value
      63c8c0d7
    • Linus Torvalds's avatar
      Merge tag 'char-misc-6.1-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc · 1f63d1a1
      Linus Torvalds authored
      Pull char/misc driver fixes from Greg KH:
       "Here are some small char/misc and other driver fixes for 6.1-rc6 to
        resolve some reported problems. Included in here are:
      
         - iio driver fixes
      
         - binder driver fix
      
         - nvmem driver fix
      
         - vme_vmci information leak fix
      
         - parport fix
      
         - slimbus configuration fix
      
         - coreboot firmware bugfix
      
         - speakup build fix and crash fix
      
        All of these have been in linux-next for a while with no reported
        issues"
      
      * tag 'char-misc-6.1-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc: (22 commits)
        firmware: coreboot: Register bus in module init
        nvmem: u-boot-env: fix crc32_data_offset on redundant u-boot-env
        slimbus: qcom-ngd: Fix build error when CONFIG_SLIM_QCOM_NGD_CTRL=y && CONFIG_QCOM_RPROC_COMMON=m
        docs: update mediator contact information in CoC doc
        slimbus: stream: correct presence rate frequencies
        nvmem: lan9662-otp: Fix compatible string
        binder: validate alloc->mm in ->mmap() handler
        parport_pc: Avoid FIFO port location truncation
        siox: fix possible memory leak in siox_device_add()
        misc/vmw_vmci: fix an infoleak in vmci_host_do_receive_datagram()
        speakup: replace utils' u_char with unsigned char
        speakup: fix a segfault caused by switching consoles
        tools: iio: iio_generic_buffer: Fix read size
        iio: imu: bno055: uninitialized variable bug in bno055_trigger_handler()
        iio: adc: at91_adc: fix possible memory leak in at91_adc_allocate_trigger()
        iio: adc: mp2629: fix potential array out of bound access
        iio: adc: mp2629: fix wrong comparison of channel
        iio: pressure: ms5611: changed hardcoded SPI speed to value limited
        iio: pressure: ms5611: fixed value compensation bug
        iio: accel: bma400: Ensure VDDIO is enable defore reading the chip ID.
        ...
      1f63d1a1