Skip to content
  1. Aug 26, 2023
    • Linus Torvalds's avatar
      Merge tag 'pinctrl-v6.5-4' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl · a87eaffb
      Linus Torvalds authored
      Pull pin control fixes from Linus Walleij:
       "Here are some Renesas and AMD driver fixes, the AMD fix affects
        important laptops in the wild so this one is pretty important. It
        seems a bit tough to get this right.
      
         - Fix DT parsing and related locking in the Renesas driver.
      
         - Fix wakeup IRQs in the AMD driver once again. Really tricky this
           one"
      
      * tag 'pinctrl-v6.5-4' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl:
        pinctrl: amd: Mask wake bits on probe again
        pinctrl: renesas: rza2: Add lock around pinctrl_generic{{add,remove}_group,{add,remove}_function}
        pinctrl: renesas: rzv2m: Fix NULL pointer dereference in rzv2m_dt_subnode_to_map()
        pinctrl: renesas: rzg2l: Fix NULL pointer dereference in rzg2l_dt_subnode_to_map()
      a87eaffb
  2. Aug 25, 2023
    • Linus Torvalds's avatar
      Merge tag 'sound-6.5' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound · ced5bf24
      Linus Torvalds authored
      Pull sound fixes from Takashi Iwai:
       "Hopefully the last bits for 6.5. It's slightly higher LOCs than
        wished, but it doesn't look scary.
      
        The biggest change is MAINTAINERS update for TI; it's good to have the
        update before the final release, so that people can contact to the
        right persons for bug reports (which shouldn't happen of course!)
      
        The rest are all device-specific fixes and quirks, most for various
        ASoC platforms"
      
      * tag 'sound-6.5' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound:
        ASoC: amd: yc: Fix a non-functional mic on Lenovo 82SJ
        ALSA: ymfpci: Fix the missing snd_card_free() call at probe error
        ASoC: cs35l41: Correct amp_gain_tlv values
        ASoC: amd: yc: Add VivoBook Pro 15 to quirks list for acp6x
        ASoC: tas2781: fixed register access error when switching to other chips
        ASoC: cs35l56: Add an ACPI match table
        ASoC: cs35l56: Read firmware uuid from a device property instead of _SUB
        ASoC: SOF: ipc4-pcm: fix possible null pointer deference
        MAINTAINERS: Add entries for TEXAS INSTRUMENTS ASoC DRIVERS
      ced5bf24
    • Linus Torvalds's avatar
      Merge tag 'drm-fixes-2023-08-25' of git://anongit.freedesktop.org/drm/drm · beaa71d6
      Linus Torvalds authored
      Pull drm fixes from Dave Airlie:
       "A bit bigger than I'd care for, but it's mostly a single vmwgfx fix
        and a fix for an i915 hotplug probing. Otherwise misc i915, bridge,
        panfrost and dma-buf fixes.
      
        core:
         - add a HPD poll helper
      
        i915:
         - fix regression in i915 polling
         - fix docs build warning
         - fix DG2 idle power consumption
      
        bridge:
         - samsung-dsim: init fix
      
        panfrost:
         - fix speed binning issue
      
        dma-buf:
         - fix recursive lock in fence signal
      
        vmwgfx:
         - fix shader stage validation
         - fix NULL ptr derefs in gem put"
      
      * tag 'drm-fixes-2023-08-25' of git://anongit.freedesktop.org/drm/drm:
        drm/i915: Fix HPD polling, reenabling the output poll work as needed
        drm: Add an HPD poll helper to reschedule the poll work
        drm/vmwgfx: Fix possible invalid drm gem put calls
        drm/vmwgfx: Fix shader stage validation
        dma-buf/sw_sync: Avoid recursive lock during fence signal
        drm/i915: fix Sphinx indentation warning
        drm/i915/dgfx: Enable d3cold at s2idle
        drm/display/dp: Fix the DP DSC Receiver cap size
        drm/panfrost: Skip speed binning on EOPNOTSUPP
        drm: bridge: samsung-dsim: Fix init during host transfer
      beaa71d6
    • Takashi Iwai's avatar
      Merge tag 'asoc-fix-v6.5-rc7-2' of... · 37e44d60
      Takashi Iwai authored
      Merge tag 'asoc-fix-v6.5-rc7-2' of https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linus
      
      ASoC: Quirk for v6.5
      
      One additional fix for v6.5, an additional quirk.  As with the other
      fixes this could wait for the merge window.
      37e44d60
    • Linus Torvalds's avatar
      Merge tag 'trace-v6.5-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/trace/linux-trace · 4f9e7fab
      Linus Torvalds authored
      Pull tracing fixes from Steven Rostedt:
      
       - Fix ring buffer being permanently disabled due to missed
         record_disabled()
      
         Changing the trace cpu mask will disable the ring buffers for the
         CPUs no longer in the mask. But it fails to update the snapshot
         buffer. If a snapshot takes place, the accounting for the ring buffer
         being disabled is corrupted and this can lead to the ring buffer
         being permanently disabled.
      
       - Add test case for snapshot and cpu mask working together
      
       - Fix memleak by the function graph tracer not getting closed properly.
      
         The iterator is used to read the ring buffer. When it opens, it calls
         the open function of a tracer, and when it is closed, it calls the
         close iteration. While a trace is being read, it is still possible to
         change the tracer.
      
         If this happens between the function graph tracer and the wakeup
         tracer (which uses function graph tracing), the tracers are not
         closed properly during when the iterator sees the switch, and the
         wakeup function did not initialize its private pointer to NULL, which
         is used to know if the function graph tracer was the last tracer. It
         could be fooled in thinking it is, but then on exit it does not call
         the close function of the function graph tracer to clean up its data.
      
       - Fix synthetic events on big endian machines, by introducing a union
         that does the conversions properly.
      
       - Fix synthetic events from printing out the number of elements in the
         stacktrace when it shouldn't.
      
       - Fix synthetic events stacktrace to not print a bogus value at the
         end.
      
       - Introduce a pipe_cpumask that prevents the trace_pipe files from
         being opened by more than one task (file descriptor).
      
         There was a race found where if splice is called, the iter->ent could
         become stale and events could be missed. There's no point reading a
         producer/consumer file by more than one task as they will corrupt
         each other anyway. Add a cpumask that keeps track of the per_cpu
         trace_pipe files as well as the global trace_pipe file that prevents
         more than one open of a trace_pipe file that represents the same ring
         buffer. This prevents the race from happening.
      
       - Fix ftrace samples for arm64 to work with older compilers.
      
      * tag 'trace-v6.5-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/trace/linux-trace:
        samples: ftrace: Replace bti assembly with hint for older compiler
        tracing: Introduce pipe_cpumask to avoid race on trace_pipes
        tracing: Fix memleak due to race between current_tracer and trace
        tracing/synthetic: Allocate one additional element for size
        tracing/synthetic: Skip first entry for stack traces
        tracing/synthetic: Use union instead of casts
        selftests/ftrace: Add a basic testcase for snapshot
        tracing: Fix cpu buffers unavailable due to 'record_disabled' missed
      4f9e7fab
    • Linus Torvalds's avatar
      Merge tag 'media/v6.5-4' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media · 14ddccc8
      Linus Torvalds authored
      Pull media fix from Mauro Carvalho Chehab:
       "Fix a potential array out-of-bounds in the mediatek vcodec driver"
      
      * tag 'media/v6.5-4' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media:
        media: vcodec: Fix potential array out-of-bounds in encoder queue_setup
      14ddccc8
    • Dave Airlie's avatar
      Merge tag 'drm-intel-fixes-2023-08-24' of... · 59fe2029
      Dave Airlie authored
      Merge tag 'drm-intel-fixes-2023-08-24' of git://anongit.freedesktop.org/drm/drm-intel
      
       into drm-fixes
      
      - Fix power consumption at s2idle on DG2 (Anshuman)
      - Fix documentation build warning (Jani)
      - Fix Display HPD (Imre)
      
      Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
      
      From: Rodrigo Vivi <rodrigo.vivi@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/ZOdPRFSJpo0ErPX/@intel.com
      59fe2029
    • Linus Torvalds's avatar
      Merge tag 'nfsd-6.5-5' of git://git.kernel.org/pub/scm/linux/kernel/git/cel/linux · f8d6ff44
      Linus Torvalds authored
      Pull nfsd fixes from Chuck Lever:
       "Two last-minute one-liners for v6.5-rc. One got lost in the shuffle,
        and the other was reported just this morning"
      
         - Close race window when handling FREE_STATEID operations
      
         - Fix regression in /proc/fs/nfsd/v4_end_grace introduced in v6.5-rc"
      
      * tag 'nfsd-6.5-5' of git://git.kernel.org/pub/scm/linux/kernel/git/cel/linux:
        NFSD: Fix a thinko introduced by recent trace point changes
        nfsd: Fix race to FREE_STATEID and cl_revoked
      f8d6ff44
    • Linus Torvalds's avatar
      Merge tag 'spi-fix-v6.5-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi · 0de5ec44
      Linus Torvalds authored
      Pull spi fixes from Mark Brown:
       "A couple more small driver specific fixes for v6.5.
      
        The device mode for Cadence had been broken by some recent updates
        done for host mode and large transfers for multi-byte words on stm32
        had been broken by an API update in what I think was a rebasing
        incident"
      
      * tag 'spi-fix-v6.5-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi:
        spi: spi-cadence: Fix data corruption issues in slave mode
        spi: stm32: fix accidential revert to byte-sized transfer splitting
      0de5ec44
    • Dave Airlie's avatar
      Merge tag 'drm-misc-fixes-2023-08-24' of git://anongit.freedesktop.org/drm/drm-misc into drm-fixes · ce22e89e
      Dave Airlie authored
      
      
      A samsung-dsim initialization fix, a devfreq fix for panfrost, a DP DSC
      define fix, a recursive lock fix for dma-buf, a shader validation fix
      and a reference counting fix for vmwgfx
      
      Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
      
      From: Maxime Ripard <mripard@redhat.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/amy26vu5xbeeikswpx7nt6rddwfocdidshrtt2qovipihx5poj@y45p3dtzrloc
      ce22e89e
  3. Aug 24, 2023
    • Linus Torvalds's avatar
      Merge tag 'net-6.5-rc8' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net · b5cc3833
      Linus Torvalds authored
      Pull networking fixes from Paolo Abeni:
       "Including fixes from wifi, can and netfilter.
      
        Fixes to fixes:
      
         - nf_tables:
             - GC transaction race with abort path
             - defer gc run if previous batch is still pending
      
        Previous releases - regressions:
      
         - ipv4: fix data-races around inet->inet_id
      
         - phy: fix deadlocking in phy_error() invocation
      
         - mdio: fix C45 read/write protocol
      
         - ipvlan: fix a reference count leak warning in ipvlan_ns_exit()
      
         - ice: fix NULL pointer deref during VF reset
      
         - i40e: fix potential NULL pointer dereferencing of pf->vf in
           i40e_sync_vsi_filters()
      
         - tg3: use slab_build_skb() when needed
      
         - mtk_eth_soc: fix NULL pointer on hw reset
      
        Previous releases - always broken:
      
         - core: validate veth and vxcan peer ifindexes
      
         - sched: fix a qdisc modification with ambiguous command request
      
         - devlink: add missing unregister linecard notification
      
         - wifi: mac80211: limit reorder_buf_filtered to avoid UBSAN warning
      
         - batman:
            - do not get eth header before batadv_check_management_packet
            - fix batadv_v_ogm_aggr_send memory leak
      
         - bonding: fix macvlan over alb bond support
      
         - mlxsw: set time stamp fields also when its type is MIRROR_UTC"
      
      * tag 'net-6.5-rc8' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (54 commits)
        selftests: bonding: add macvlan over bond testing
        selftest: bond: add new topo bond_topo_2d1c.sh
        bonding: fix macvlan over alb bond support
        rtnetlink: Reject negative ifindexes in RTM_NEWLINK
        netfilter: nf_tables: defer gc run if previous batch is still pending
        netfilter: nf_tables: fix out of memory error handling
        netfilter: nf_tables: use correct lock to protect gc_list
        netfilter: nf_tables: GC transaction race with abort path
        netfilter: nf_tables: flush pending destroy work before netlink notifier
        netfilter: nf_tables: validate all pending tables
        ibmveth: Use dcbf rather than dcbfl
        i40e: fix potential NULL pointer dereferencing of pf->vf i40e_sync_vsi_filters()
        net/sched: fix a qdisc modification with ambiguous command request
        igc: Fix the typo in the PTM Control macro
        batman-adv: Hold rtnl lock during MTU update via netlink
        igb: Avoid starting unnecessary workqueues
        can: raw: add missing refcount for memory leak fix
        can: isotp: fix support for transmission of SF without flow control
        bnx2x: new flag for track HW resource allocation
        sfc: allocate a big enough SKB for loopback selftest packet
        ...
      b5cc3833
    • Chuck Lever's avatar
      NFSD: Fix a thinko introduced by recent trace point changes · 8073a98e
      Chuck Lever authored
      
      
      The fixed commit erroneously removed a call to nfsd_end_grace(),
      which makes calls to write_v4_end_grace() a no-op.
      
      Reported-by: default avatarkernel test robot <oliver.sang@intel.com>
      Closes: https://lore.kernel.org/oe-lkp/202308241229.68396422-oliver.sang@intel.com
      
      
      Fixes: 39d432fc ("NFSD: trace nfsctl operations")
      Reviewed-by: default avatarJeff Layton <jlayton@kernel.org>
      Signed-off-by: default avatarChuck Lever <chuck.lever@oracle.com>
      8073a98e
    • Mario Limonciello's avatar
      ASoC: amd: yc: Fix a non-functional mic on Lenovo 82SJ · c008323f
      Mario Limonciello authored
      
      
      Lenovo 82SJ doesn't have DMIC connected like 82V2 does.  Narrow
      the match down to only cover 82V2.
      
      Reported-by: default avatar <prosenfeld@Yuhsbstudents.org>
      Closes: https://bugzilla.kernel.org/show_bug.cgi?id=217063
      
      
      Fixes: 2232b2dd ("ASoC: amd: yc: Add Lenovo Yoga Slim 7 Pro X to quirks table")
      Signed-off-by: default avatarMario Limonciello <mario.limonciello@amd.com>
      Link: https://lore.kernel.org/r/20230824011149.1395-1-mario.limonciello@amd.com
      
      
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      c008323f
    • Paolo Abeni's avatar
      Merge tag 'nf-23-08-23' of ssh://gitolite.kernel.org/pub/scm/linux/kernel/git/netfilter/nf · 8938fc0c
      Paolo Abeni authored
      Florian Westphal says:
      
      ====================
      netfilter updates for net
      
      This PR contains nf_tables updates for your *net* tree.
      
      First patch fixes table validation, I broke this in 6.4 when tracking
      validation state per table, reported by Pablo, fixup from myself.
      
      Second patch makes sure objects waiting for memory release have been
      released, this was broken in 6.1, patch from Pablo Neira Ayuso.
      
      Patch three is a fix-for-fix from previous PR: In case a transaction
      gets aborted, gc sequence counter needs to be incremented so pending
      gc requests are invalidated, from Pablo.
      
      Same for patch 4: gc list needs to use gc list lock, not destroy lock,
      also from Pablo.
      
      Patch 5 fixes a UaF in a set backend, but this should only occur when
      failslab is enabled for GFP_KERNEL allocations, broken since feature
      was added in 5.6, from myself.
      
      Patch 6 fixes a double-free bug that was also added via previous PR:
      We must not schedule gc work if the previous batch is still queued.
      
      netfilter pull request 2023-08-23
      
      * tag 'nf-23-08-23' of ssh://gitolite.kernel.org/pub/scm/linux/kernel/git/netfilter/nf:
        netfilter: nf_tables: defer gc run if previous batch is still pending
        netfilter: nf_tables: fix out of memory error handling
        netfilter: nf_tables: use correct lock to protect gc_list
        netfilter: nf_tables: GC transaction race with abort path
        netfilter: nf_tables: flush pending destroy work before netlink notifier
        netfilter: nf_tables: validate all pending tables
      ====================
      
      Link: https://lore.kernel.org/r/20230823152711.15279-1-fw@strlen.de
      
      
      Signed-off-by: default avatarPaolo Abeni <pabeni@redhat.com>
      8938fc0c
    • Paolo Abeni's avatar
      Merge branch 'fix-macvlan-over-alb-bond-support' · b251610c
      Paolo Abeni authored
      Hangbin Liu says:
      
      ====================
      fix macvlan over alb bond support
      
      Currently, the macvlan over alb bond is broken after commit
      14af9963 ("bonding: Support macvlans on top of tlb/rlb mode bonds").
      Fix this and add relate tests.
      ====================
      
      Link: https://lore.kernel.org/r/20230823071907.3027782-1-liuhangbin@gmail.com
      
      
      Signed-off-by: default avatarPaolo Abeni <pabeni@redhat.com>
      b251610c
    • Hangbin Liu's avatar
      selftests: bonding: add macvlan over bond testing · 246af950
      Hangbin Liu authored
      
      
      Add a macvlan over bonding test with mode active-backup, balance-tlb
      and balance-alb.
      
      ]# ./bond_macvlan.sh
      TEST: active-backup: IPv4: client->server                           [ OK ]
      TEST: active-backup: IPv6: client->server                           [ OK ]
      TEST: active-backup: IPv4: client->macvlan_1                        [ OK ]
      TEST: active-backup: IPv6: client->macvlan_1                        [ OK ]
      TEST: active-backup: IPv4: client->macvlan_2                        [ OK ]
      TEST: active-backup: IPv6: client->macvlan_2                        [ OK ]
      TEST: active-backup: IPv4: macvlan_1->macvlan_2                     [ OK ]
      TEST: active-backup: IPv6: macvlan_1->macvlan_2                     [ OK ]
      TEST: active-backup: IPv4: server->client                           [ OK ]
      TEST: active-backup: IPv6: server->client                           [ OK ]
      TEST: active-backup: IPv4: macvlan_1->client                        [ OK ]
      TEST: active-backup: IPv6: macvlan_1->client                        [ OK ]
      TEST: active-backup: IPv4: macvlan_2->client                        [ OK ]
      TEST: active-backup: IPv6: macvlan_2->client                        [ OK ]
      TEST: active-backup: IPv4: macvlan_2->macvlan_2                     [ OK ]
      TEST: active-backup: IPv6: macvlan_2->macvlan_2                     [ OK ]
      [...]
      TEST: balance-alb: IPv4: client->server                             [ OK ]
      TEST: balance-alb: IPv6: client->server                             [ OK ]
      TEST: balance-alb: IPv4: client->macvlan_1                          [ OK ]
      TEST: balance-alb: IPv6: client->macvlan_1                          [ OK ]
      TEST: balance-alb: IPv4: client->macvlan_2                          [ OK ]
      TEST: balance-alb: IPv6: client->macvlan_2                          [ OK ]
      TEST: balance-alb: IPv4: macvlan_1->macvlan_2                       [ OK ]
      TEST: balance-alb: IPv6: macvlan_1->macvlan_2                       [ OK ]
      TEST: balance-alb: IPv4: server->client                             [ OK ]
      TEST: balance-alb: IPv6: server->client                             [ OK ]
      TEST: balance-alb: IPv4: macvlan_1->client                          [ OK ]
      TEST: balance-alb: IPv6: macvlan_1->client                          [ OK ]
      TEST: balance-alb: IPv4: macvlan_2->client                          [ OK ]
      TEST: balance-alb: IPv6: macvlan_2->client                          [ OK ]
      TEST: balance-alb: IPv4: macvlan_2->macvlan_2                       [ OK ]
      TEST: balance-alb: IPv6: macvlan_2->macvlan_2                       [ OK ]
      
      Signed-off-by: default avatarHangbin Liu <liuhangbin@gmail.com>
      Acked-by: default avatarJay Vosburgh <jay.vosburgh@canonical.com>
      Signed-off-by: default avatarPaolo Abeni <pabeni@redhat.com>
      246af950
    • Hangbin Liu's avatar
      selftest: bond: add new topo bond_topo_2d1c.sh · 27aa43f8
      Hangbin Liu authored
      
      
      Add a new testing topo bond_topo_2d1c.sh which is used more commonly.
      Make bond_topo_3d1c.sh just source bond_topo_2d1c.sh and add the
      extra link.
      
      Signed-off-by: default avatarHangbin Liu <liuhangbin@gmail.com>
      Acked-by: default avatarJay Vosburgh <jay.vosburgh@canonical.com>
      Signed-off-by: default avatarPaolo Abeni <pabeni@redhat.com>
      27aa43f8
    • Hangbin Liu's avatar
      bonding: fix macvlan over alb bond support · e74216b8
      Hangbin Liu authored
      
      
      The commit 14af9963 ("bonding: Support macvlans on top of tlb/rlb mode
      bonds") aims to enable the use of macvlans on top of rlb bond mode. However,
      the current rlb bond mode only handles ARP packets to update remote neighbor
      entries. This causes an issue when a macvlan is on top of the bond, and
      remote devices send packets to the macvlan using the bond's MAC address
      as the destination. After delivering the packets to the macvlan, the macvlan
      will rejects them as the MAC address is incorrect. Consequently, this commit
      makes macvlan over bond non-functional.
      
      To address this problem, one potential solution is to check for the presence
      of a macvlan port on the bond device using netif_is_macvlan_port(bond->dev)
      and return NULL in the rlb_arp_xmit() function. However, this approach
      doesn't fully resolve the situation when a VLAN exists between the bond and
      macvlan.
      
      So let's just do a partial revert for commit 14af9963 in rlb_arp_xmit().
      As the comment said, Don't modify or load balance ARPs that do not originate
      locally.
      
      Fixes: 14af9963 ("bonding: Support macvlans on top of tlb/rlb mode bonds")
      Reported-by: default avatar <susan.zheng@veritas.com>
      Closes: https://bugzilla.redhat.com/show_bug.cgi?id=2117816
      
      
      Signed-off-by: default avatarHangbin Liu <liuhangbin@gmail.com>
      Acked-by: default avatarJay Vosburgh <jay.vosburgh@canonical.com>
      Signed-off-by: default avatarPaolo Abeni <pabeni@redhat.com>
      e74216b8
    • Ido Schimmel's avatar
      rtnetlink: Reject negative ifindexes in RTM_NEWLINK · 30188bd7
      Ido Schimmel authored
      
      
      Negative ifindexes are illegal, but the kernel does not validate the
      ifindex in the ancillary header of RTM_NEWLINK messages, resulting in
      the kernel generating a warning [1] when such an ifindex is specified.
      
      Fix by rejecting negative ifindexes.
      
      [1]
      WARNING: CPU: 0 PID: 5031 at net/core/dev.c:9593 dev_index_reserve+0x1a2/0x1c0 net/core/dev.c:9593
      [...]
      Call Trace:
       <TASK>
       register_netdevice+0x69a/0x1490 net/core/dev.c:10081
       br_dev_newlink+0x27/0x110 net/bridge/br_netlink.c:1552
       rtnl_newlink_create net/core/rtnetlink.c:3471 [inline]
       __rtnl_newlink+0x115e/0x18c0 net/core/rtnetlink.c:3688
       rtnl_newlink+0x67/0xa0 net/core/rtnetlink.c:3701
       rtnetlink_rcv_msg+0x439/0xd30 net/core/rtnetlink.c:6427
       netlink_rcv_skb+0x16b/0x440 net/netlink/af_netlink.c:2545
       netlink_unicast_kernel net/netlink/af_netlink.c:1342 [inline]
       netlink_unicast+0x536/0x810 net/netlink/af_netlink.c:1368
       netlink_sendmsg+0x93c/0xe40 net/netlink/af_netlink.c:1910
       sock_sendmsg_nosec net/socket.c:728 [inline]
       sock_sendmsg+0xd9/0x180 net/socket.c:751
       ____sys_sendmsg+0x6ac/0x940 net/socket.c:2538
       ___sys_sendmsg+0x135/0x1d0 net/socket.c:2592
       __sys_sendmsg+0x117/0x1e0 net/socket.c:2621
       do_syscall_x64 arch/x86/entry/common.c:50 [inline]
       do_syscall_64+0x38/0xb0 arch/x86/entry/common.c:80
       entry_SYSCALL_64_after_hwframe+0x63/0xcd
      
      Fixes: 38f7b870 ("[RTNETLINK]: Link creation API")
      Reported-by: default avatar <syzbot+5ba06978f34abb058571@syzkaller.appspotmail.com>
      Signed-off-by: default avatarIdo Schimmel <idosch@nvidia.com>
      Reviewed-by: default avatarJiri Pirko <jiri@nvidia.com>
      Reviewed-by: default avatarJakub Kicinski <kuba@kernel.org>
      Link: https://lore.kernel.org/r/20230823064348.2252280-1-idosch@nvidia.com
      
      
      Signed-off-by: default avatarPaolo Abeni <pabeni@redhat.com>
      30188bd7
    • Takashi Iwai's avatar
      Merge tag 'asoc-fix-v6.5-rc7' of... · a4a6eed8
      Takashi Iwai authored
      Merge tag 'asoc-fix-v6.5-rc7' of https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linus
      
      ASoC: Fixes for v6.5
      
      A relatively large but generally not super urgent set of fixes for ASoC,
      including some quirks and a MAINTAINERS update.  There's also an update
      to cs35l56 to change the firmware ABI, there are no current shipping
      systems which use the current interface and the sooner we get the new
      interface in the less likely it is that something will start.
      
      It'd be nice if these landed for v6.5 but not the end of the world if
      they wait till v6.6.
      a4a6eed8
    • Linus Torvalds's avatar
      Merge tag 'acpi-6.5-rc8' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm · 93f5de5f
      Linus Torvalds authored
      Pull ACPI fix from Rafael Wysocki:
       "Make an existing ACPI IRQ override quirk for PCSpecialist Elimina Pro
        16 M work as intended (Hans de Goede)"
      
      * tag 'acpi-6.5-rc8' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm:
        ACPI: resource: Fix IRQ override quirk for PCSpecialist Elimina Pro 16 M
      93f5de5f
    • Imre Deak's avatar
      drm/i915: Fix HPD polling, reenabling the output poll work as needed · 1dcc4374
      Imre Deak authored
      
      
      After the commit in the Fixes: line below, HPD polling stopped working
      on i915, since after that change calling drm_kms_helper_poll_enable()
      doesn't restart drm_mode_config::output_poll_work if the work was
      stopped (no connectors needing polling) and enabling polling for a
      connector (during runtime suspend or detecting an HPD IRQ storm).
      
      After the above change calling drm_kms_helper_poll_enable() is a nop
      after it's been called already and polling for some connectors was
      disabled/re-enabled.
      
      Fix this by calling drm_kms_helper_poll_reschedule() added in the
      previous patch instead, which reschedules the work whenever expected.
      
      Fixes: d33a54e3 ("drm/probe_helper: sort out poll_running vs poll_enabled")
      CC: stable@vger.kernel.org # 6.4+
      Cc: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
      Cc: dri-devel@lists.freedesktop.org
      Reviewed-by: default avatarJouni Högander <jouni.hogander@intel.com>
      Signed-off-by: default avatarImre Deak <imre.deak@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20230822113015.41224-2-imre.deak@intel.com
      
      
      (cherry picked from commit 50452f2f)
      Signed-off-by: default avatarRodrigo Vivi <rodrigo.vivi@intel.com>
      1dcc4374
    • Imre Deak's avatar
      drm: Add an HPD poll helper to reschedule the poll work · a94e7ccf
      Imre Deak authored
      
      
      Add a helper to reschedule drm_mode_config::output_poll_work after
      polling has been enabled for a connector (and needing a reschedule,
      since previously polling was disabled for all connectors and hence
      output_poll_work was not running).
      
      This is needed by the next patch fixing HPD polling on i915.
      
      CC: stable@vger.kernel.org # 6.4+
      Cc: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
      Cc: dri-devel@lists.freedesktop.org
      Reviewed-by: default avatarJouni Högander <jouni.hogander@intel.com>
      Reviewed-by: default avatarDmitry Baryshkov <dmitry.baryshkov@linaro.org>
      Signed-off-by: default avatarImre Deak <imre.deak@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20230822113015.41224-1-imre.deak@intel.com
      
      
      (cherry picked from commit fe2352fd)
      Signed-off-by: default avatarRodrigo Vivi <rodrigo.vivi@intel.com>
      a94e7ccf
    • Zack Rusin's avatar
      drm/vmwgfx: Fix possible invalid drm gem put calls · f9e96bf1
      Zack Rusin authored
      
      
      vmw_bo_unreference sets the input buffer to null on exit, resulting in
      null ptr deref's on the subsequent drm gem put calls.
      
      This went unnoticed because only very old userspace would be exercising
      those paths but it wouldn't be hard to hit on old distros with brand
      new kernels.
      
      Introduce a new function that abstracts unrefing of user bo's to make
      the code cleaner and more explicit.
      
      Signed-off-by: default avatarZack Rusin <zackr@vmware.com>
      Reported-by: default avatarIan Forbes <iforbes@vmware.com>
      Fixes: 9ef8d83e ("drm/vmwgfx: Do not drop the reference to the handle too soon")
      Cc: <stable@vger.kernel.org> # v6.4+
      Reviewed-by: default avatarMaaz <Mombasawala&lt;mombasawalam@vmware.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20230818041301.407636-1-zack@kde.org
      f9e96bf1
    • Zack Rusin's avatar
      drm/vmwgfx: Fix shader stage validation · 14abdfae
      Zack Rusin authored
      
      
      For multiple commands the driver was not correctly validating the shader
      stages resulting in possible kernel oopses. The validation code was only.
      if ever, checking the upper bound on the shader stages but never a lower
      bound (valid shader stages start at 1 not 0).
      
      Fixes kernel oopses ending up in vmw_binding_add, e.g.:
      Oops: 0000 [#1] PREEMPT SMP PTI
      CPU: 1 PID: 2443 Comm: testcase Not tainted 6.3.0-rc4-vmwgfx #1
      Hardware name: VMware, Inc. VMware Virtual Platform/440BX Desktop Reference Platform, BIOS 6.00 11/12/2020
      RIP: 0010:vmw_binding_add+0x4c/0x140 [vmwgfx]
      Code: 7e 30 49 83 ff 0e 0f 87 ea 00 00 00 4b 8d 04 7f 89 d2 89 cb 48 c1 e0 03 4c 8b b0 40 3d 93 c0 48 8b 80 48 3d 93 c0 49 0f af de <48> 03 1c d0 4c 01 e3 49 8>
      RSP: 0018:ffffb8014416b968 EFLAGS: 00010206
      RAX: ffffffffc0933ec0 RBX: 0000000000000000 RCX: 0000000000000000
      RDX: 00000000ffffffff RSI: ffffb8014416b9c0 RDI: ffffb8014316f000
      RBP: ffffb8014416b998 R08: 0000000000000003 R09: 746f6c735f726564
      R10: ffffffffaaf2bda0 R11: 732e676e69646e69 R12: ffffb8014316f000
      R13: ffffb8014416b9c0 R14: 0000000000000040 R15: 0000000000000006
      FS:  00007fba8c0af740(0000) GS:ffff8a1277c80000(0000) knlGS:0000000000000000
      CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
      CR2: 00000007c0933eb8 CR3: 0000000118244001 CR4: 00000000003706e0
      Call Trace:
       <TASK>
       vmw_view_bindings_add+0xf5/0x1b0 [vmwgfx]
       ? ___drm_dbg+0x8a/0xb0 [drm]
       vmw_cmd_dx_set_shader_res+0x8f/0xc0 [vmwgfx]
       vmw_execbuf_process+0x590/0x1360 [vmwgfx]
       vmw_execbuf_ioctl+0x173/0x370 [vmwgfx]
       ? __drm_dev_dbg+0xb4/0xe0 [drm]
       ? __pfx_vmw_execbuf_ioctl+0x10/0x10 [vmwgfx]
       drm_ioctl_kernel+0xbc/0x160 [drm]
       drm_ioctl+0x2d2/0x580 [drm]
       ? __pfx_vmw_execbuf_ioctl+0x10/0x10 [vmwgfx]
       ? do_fault+0x1a6/0x420
       vmw_generic_ioctl+0xbd/0x180 [vmwgfx]
       vmw_unlocked_ioctl+0x19/0x20 [vmwgfx]
       __x64_sys_ioctl+0x96/0xd0
       do_syscall_64+0x5d/0x90
       ? handle_mm_fault+0xe4/0x2f0
       ? debug_smp_processor_id+0x1b/0x30
       ? fpregs_assert_state_consistent+0x2e/0x50
       ? exit_to_user_mode_prepare+0x40/0x180
       ? irqentry_exit_to_user_mode+0xd/0x20
       ? irqentry_exit+0x3f/0x50
       ? exc_page_fault+0x8b/0x180
       entry_SYSCALL_64_after_hwframe+0x72/0xdc
      
      Signed-off-by: default avatarZack Rusin <zackr@vmware.com>
      Cc: security@openanolis.org
      Reported-by: default avatarZiming Zhang <ezrakiez@gmail.com>
      Testcase-found-by: default avatarNiels De Graef <ndegraef@redhat.com>
      Fixes: d80efd5c ("drm/vmwgfx: Initial DX support")
      Cc: <stable@vger.kernel.org> # v4.3+
      Reviewed-by: default avatarMaaz <Mombasawala&lt;mombasawalam@vmware.com>
      Reviewed-by: default avatarMartin Krastev <krastevm@vmware.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20230616190934.54828-1-zack@kde.org
      14abdfae
    • Takashi Iwai's avatar
      ALSA: ymfpci: Fix the missing snd_card_free() call at probe error · 1d0eb614
      Takashi Iwai authored
      
      
      Like a few other drivers, YMFPCI driver needs to clean up with
      snd_card_free() call at an error path of the probe; otherwise the
      other devres resources are released before the card and it results in
      the UAF.
      
      This patch uses the helper for handling the probe error gracefully.
      
      Fixes: f33fc157 ("ALSA: ymfpci: Create card with device-managed snd_devm_card_new()")
      Cc: <stable@vger.kernel.org>
      Reported-and-tested-by: default avatarTakashi Yano <takashi.yano@nifty.ne.jp>
      Closes: https://lore.kernel.org/r/20230823135846.1812-1-takashi.yano@nifty.ne.jp
      Link: https://lore.kernel.org/r/20230823161625.5807-1-tiwai@suse.de
      
      
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      1d0eb614
  4. Aug 23, 2023