]> git.ipfire.org Git - thirdparty/kernel/linux.git/log
thirdparty/kernel/linux.git
4 weeks agospi: spi-qpic-snand: simplify bad block marker duplication
Gabor Juhos [Fri, 11 Jul 2025 16:32:52 +0000 (18:32 +0200)] 
spi: spi-qpic-snand: simplify bad block marker duplication

Due to the expectations of the SPINAND code, the driver duplicates
the bad block markers during raw OOB reads.

It has been implemented by using two if statements, and due to the
opposite conditions one of conditional codepaths always runs. Since
the effect of both codepaths is the same, remove the if statements
and use a single line solution instead.

Also add a note about why the duplication is required.

No functional changes intended.

Signed-off-by: Gabor Juhos <j4g8y7@gmail.com>
Link: https://patch.msgid.link/20250711-qpic-snand-simplify-bbm-copy-v1-1-dd2608325f72@gmail.com
Signed-off-by: Mark Brown <broonie@kernel.org>
4 weeks agospi: spi-qpic-snand: don't hardcode ECC steps
Gabor Juhos [Wed, 23 Jul 2025 08:06:43 +0000 (10:06 +0200)] 
spi: spi-qpic-snand: don't hardcode ECC steps

NAND devices with different page sizes requires different number
of ECC steps, yet the qcom_spi_ecc_init_ctx_pipelined() function
sets 4 steps in 'ecc_cfg' unconditionally.

The correct number of the steps is calculated earlier in the
function already, so use that instead of the hardcoded value.

Fixes: 7304d1909080 ("spi: spi-qpic: add driver for QCOM SPI NAND flash Interface")
Signed-off-by: Gabor Juhos <j4g8y7@gmail.com>
Link: https://patch.msgid.link/20250723-qpic-snand-fix-steps-v1-1-d800695dde4c@gmail.com
Signed-off-by: Mark Brown <broonie@kernel.org>
4 weeks agoASoC: mediatek: common: fix device and OF node leak
Johan Hovold [Tue, 22 Jul 2025 09:25:42 +0000 (11:25 +0200)] 
ASoC: mediatek: common: fix device and OF node leak

Make sure to drop the references to the accdet OF node and platform
device taken by of_parse_phandle() and of_find_device_by_node() after
looking up the sound component during probe.

Fixes: cf536e2622e2 ("ASoC: mediatek: common: Handle mediatek,accdet property")
Cc: stable@vger.kernel.org # 6.15
Cc: Nícolas F. R. A. Prado <nfraprado@collabora.com>
Signed-off-by: Johan Hovold <johan@kernel.org>
Link: https://patch.msgid.link/20250722092542.32754-1-johan@kernel.org
Signed-off-by: Mark Brown <broonie@kernel.org>
4 weeks agoiommu/vt-d: Fix UAF on sva unbind with pending IOPFs
Lu Baolu [Wed, 23 Jul 2025 07:20:45 +0000 (15:20 +0800)] 
iommu/vt-d: Fix UAF on sva unbind with pending IOPFs

Commit 17fce9d2336d ("iommu/vt-d: Put iopf enablement in domain attach
path") disables IOPF on device by removing the device from its IOMMU's
IOPF queue when the last IOPF-capable domain is detached from the device.
Unfortunately, it did this in a wrong place where there are still pending
IOPFs. As a result, a use-after-free error is potentially triggered and
eventually a kernel panic with a kernel trace similar to the following:

 refcount_t: underflow; use-after-free.
 WARNING: CPU: 3 PID: 313 at lib/refcount.c:28 refcount_warn_saturate+0xd8/0xe0
 Workqueue: iopf_queue/dmar0-iopfq iommu_sva_handle_iopf
 Call Trace:
   <TASK>
   iopf_free_group+0xe/0x20
   process_one_work+0x197/0x3d0
   worker_thread+0x23a/0x350
   ? rescuer_thread+0x4a0/0x4a0
   kthread+0xf8/0x230
   ? finish_task_switch.isra.0+0x81/0x260
   ? kthreads_online_cpu+0x110/0x110
   ? kthreads_online_cpu+0x110/0x110
   ret_from_fork+0x13b/0x170
   ? kthreads_online_cpu+0x110/0x110
   ret_from_fork_asm+0x11/0x20
   </TASK>
  ---[ end trace 0000000000000000 ]---

The intel_pasid_tear_down_entry() function is responsible for blocking
hardware from generating new page faults and flushing all in-flight
ones. Therefore, moving iopf_for_domain_remove() after this function
should resolve this.

Fixes: 17fce9d2336d ("iommu/vt-d: Put iopf enablement in domain attach path")
Reported-by: Ethan Milon <ethan.milon@eviden.com>
Closes: https://lore.kernel.org/r/e8b37f3e-8539-40d4-8993-43a1f3ffe5aa@eviden.com
Suggested-by: Ethan Milon <ethan.milon@eviden.com>
Signed-off-by: Lu Baolu <baolu.lu@linux.intel.com>
Link: https://lore.kernel.org/r/20250723072045.1853328-1-baolu.lu@linux.intel.com
Signed-off-by: Will Deacon <will@kernel.org>
4 weeks agoafs: Set vllist to NULL if addr parsing fails
Edward Adam Davis [Mon, 21 Jul 2025 14:26:51 +0000 (15:26 +0100)] 
afs: Set vllist to NULL if addr parsing fails

syzbot reported a bug in in afs_put_vlserverlist.

  kAFS: bad VL server IP address
  BUG: unable to handle page fault for address: fffffffffffffffa
  ...
  Oops: Oops: 0002 [#1] SMP KASAN PTI
  ...
  RIP: 0010:refcount_dec_and_test include/linux/refcount.h:450 [inline]
  RIP: 0010:afs_put_vlserverlist+0x3a/0x220 fs/afs/vl_list.c:67
  ...
  Call Trace:
   <TASK>
   afs_alloc_cell fs/afs/cell.c:218 [inline]
   afs_lookup_cell+0x12a5/0x1680 fs/afs/cell.c:264
   afs_cell_init+0x17a/0x380 fs/afs/cell.c:386
   afs_proc_rootcell_write+0x21f/0x290 fs/afs/proc.c:247
   proc_simple_write+0x114/0x1b0 fs/proc/generic.c:825
   pde_write fs/proc/inode.c:330 [inline]
   proc_reg_write+0x23d/0x330 fs/proc/inode.c:342
   vfs_write+0x25c/0x1180 fs/read_write.c:682
   ksys_write+0x12a/0x240 fs/read_write.c:736
   do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
   do_syscall_64+0xcd/0x260 arch/x86/entry/syscall_64.c:94
   entry_SYSCALL_64_after_hwframe+0x77/0x7f

Because afs_parse_text_addrs() parses incorrectly, its return value -EINVAL
is assigned to vllist, which results in -EINVAL being used as the vllist
address when afs_put_vlserverlist() is executed.

Set the vllist value to NULL when a parsing error occurs to avoid this
issue.

Fixes: e2c2cb8ef07a ("afs: Simplify cell record handling")
Reported-by: syzbot+5c042fbab0b292c98fc6@syzkaller.appspotmail.com
Closes: https://syzkaller.appspot.com/bug?extid=5c042fbab0b292c98fc6
Tested-by: syzbot+5c042fbab0b292c98fc6@syzkaller.appspotmail.com
Signed-off-by: Edward Adam Davis <eadavis@qq.com>
Signed-off-by: David Howells <dhowells@redhat.com>
Link: https://lore.kernel.org/4119365.1753108011@warthog.procyon.org.uk
cc: Marc Dionne <marc.dionne@auristor.com>
cc: linux-afs@lists.infradead.org
cc: linux-fsdevel@vger.kernel.org
Signed-off-by: Christian Brauner <brauner@kernel.org>
4 weeks agoafs: Fix check for NULL terminator
Leo Stone [Mon, 21 Jul 2025 14:29:12 +0000 (15:29 +0100)] 
afs: Fix check for NULL terminator

Add a missing check for reaching the end of the string while attempting
to split a command.

Fixes: f94f70d39cc2 ("afs: Provide a way to configure address priorities")
Reported-by: syzbot+7741f872f3c53385a2e2@syzkaller.appspotmail.com
Closes: https://syzkaller.appspot.com/bug?extid=7741f872f3c53385a2e2
Signed-off-by: Leo Stone <leocstone@gmail.com>
Signed-off-by: David Howells <dhowells@redhat.com>
Link: https://lore.kernel.org/4119428.1753108152@warthog.procyon.org.uk
Acked-by: David Howells <dhowells@redhat.com>
cc: Marc Dionne <marc.dionne@auristor.com>
cc: linux-afs@lists.infradead.org
cc: linux-fsdevel@vger.kernel.org
Signed-off-by: Christian Brauner <brauner@kernel.org>
4 weeks agoRISC-V: KVM: add SBI extension reset callback
Clément Léger [Fri, 23 May 2025 10:19:29 +0000 (12:19 +0200)] 
RISC-V: KVM: add SBI extension reset callback

Currently, only the STA extension needed a reset function but that's
going to be the case for FWFT as well. Add a reset callback that can
be implemented by SBI extensions.

Signed-off-by: Clément Léger <cleger@rivosinc.com>
Reviewed-by: Andrew Jones <ajones@ventanamicro.com>
Reviewed-by: Atish Patra <atishp@rivosinc.com>
Link: https://lore.kernel.org/r/20250523101932.1594077-13-cleger@rivosinc.com
Signed-off-by: Anup Patel <anup@brainfault.org>
4 weeks agoRISC-V: KVM: add SBI extension init()/deinit() functions
Clément Léger [Fri, 23 May 2025 10:19:28 +0000 (12:19 +0200)] 
RISC-V: KVM: add SBI extension init()/deinit() functions

The FWFT SBI extension will need to dynamically allocate memory and do
init time specific initialization. Add an init/deinit callbacks that
allows to do so.

Signed-off-by: Clément Léger <cleger@rivosinc.com>
Reviewed-by: Andrew Jones <ajones@ventanamicro.com>
Reviewed-by: Atish Patra <atishp@rivosinc.com>
Link: https://lore.kernel.org/r/20250523101932.1594077-12-cleger@rivosinc.com
Signed-off-by: Anup Patel <anup@brainfault.org>
4 weeks agodt-bindings: dma: qcom,gpi: document the Milos GPI DMA Engine
Luca Weiss [Sun, 13 Jul 2025 08:05:31 +0000 (10:05 +0200)] 
dt-bindings: dma: qcom,gpi: document the Milos GPI DMA Engine

Document the GPI DMA Engine on the Milos SoC.

Signed-off-by: Luca Weiss <luca.weiss@fairphone.com>
Acked-by: Rob Herring (Arm) <robh@kernel.org>
Link: https://lore.kernel.org/r/20250713-sm7635-fp6-initial-v2-9-e8f9a789505b@fairphone.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
4 weeks agopinctrl: mediatek: Add pinctrl driver for mt8189
Cathy Xu [Fri, 11 Jul 2025 09:44:59 +0000 (17:44 +0800)] 
pinctrl: mediatek: Add pinctrl driver for mt8189

Add pinctrl driver support for MediaTek Soc mt8189.

Signed-off-by: Cathy Xu <ot_cathy.xu@mediatek.com>
Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Link: https://lore.kernel.org/20250711094513.17073-4-ot_cathy.xu@mediatek.com
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
4 weeks agodt-bindings: pinctrl: mediatek: Add support for mt8189
Cathy Xu [Fri, 11 Jul 2025 09:44:57 +0000 (17:44 +0800)] 
dt-bindings: pinctrl: mediatek: Add support for mt8189

Add the new binding document for pinctrl on MediaTek mt8189.

Signed-off-by: Cathy Xu <ot_cathy.xu@mediatek.com>
Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Reviewed-by: Rob Herring (Arm) <robh@kernel.org>
Link: https://lore.kernel.org/20250711094513.17073-2-ot_cathy.xu@mediatek.com
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
4 weeks agopinctrl: aspeed-g6: Add PCIe RC PERST pin group
Jacky Chou [Tue, 15 Jul 2025 03:43:17 +0000 (11:43 +0800)] 
pinctrl: aspeed-g6: Add PCIe RC PERST pin group

The PCIe RC PERST uses SSPRST# as PERST#  and enable this pin
to output.

Signed-off-by: Jacky Chou <jacky_chou@aspeedtech.com>
Acked-by: Linus Walleij <linus.walleij@linaro.org>
Link: https://lore.kernel.org/20250715034320.2553837-8-jacky_chou@aspeedtech.com
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
4 weeks agoxen/netfront: Fix TX response spurious interrupts
Anthoine Bourgeois [Mon, 21 Jul 2025 09:34:54 +0000 (09:34 +0000)] 
xen/netfront: Fix TX response spurious interrupts

We found at Vates that there are lot of spurious interrupts when
benchmarking the xen-net PV driver frontend. This issue appeared with a
patch that addresses security issue XSA-391 (b27d47950e48 "xen/netfront:
harden netfront against event channel storms"). On an iperf benchmark,
spurious interrupts can represent up to 50% of the interrupts.

Spurious interrupts are interrupts that are rised for nothing, there is
no work to do. This appends because the function that handles the
interrupts ("xennet_tx_buf_gc") is also called at the end of the request
path to garbage collect the responses received during the transmission
load.

The request path is doing the work that the interrupt handler should
have done otherwise. This is particurary true when there is more than
one vcpu and get worse linearly with the number of vcpu/queue.

Moreover, this problem is amplifyed by the penalty imposed by a spurious
interrupt. When an interrupt is found spurious the interrupt chip will
delay the EOI to slowdown the backend. This delay will allow more
responses to be handled by the request path and then there will be more
chance the next interrupt will not find any work to do, creating a new
spurious interrupt.

This causes performance issue. The solution here is to remove the calls
from the request path and let the interrupt handler do the processing of
the responses. This approch removes most of the spurious interrupts
(<0.05%) and also has the benefit of freeing up cycles in the request
path, allowing it to process more work, which improves performance
compared to masking the spurious interrupt one way or another.

This optimization changes a part of the code that is present since the
net frontend driver was upstreamed. There is no similar pattern in the
other xen PV drivers. Since the first commit of xen-netfront is a blob
that doesn't explain all the design choices I can only guess why this
specific mecanism was here. This could have been introduce to compensate
a slow backend at the time (maybe the backend was fixed or optimize
later) or a small queue. In 18 years, both frontend and backend gain lot
of features and optimizations that could have obsolete the feature of
reaping completions from the TX path.

Some vif throughput performance figures from a 8 vCPUs, 4GB of RAM HVM
guest(s):

Without this patch on the :
vm -> dom0: 4.5Gb/s
vm -> vm:   7.0Gb/s

Without XSA-391 patch (revert of b27d47950e48):
vm -> dom0: 8.3Gb/s
vm -> vm:   8.7Gb/s

With XSA-391 and this patch:
vm -> dom0: 11.5Gb/s
vm -> vm:   12.6Gb/s

v2:
- add revewed and tested by tags
- resend with the maintainers in the recipients list

v3:
- remove Fixes tag but keep the commit ref in the explanation
- add a paragraph on why this code was here

Signed-off-by: Anthoine Bourgeois <anthoine.bourgeois@vates.tech>
Reviewed-by: Juergen Gross <jgross@suse.com>
Tested-by: Elliott Mitchell <ehem+xen@m5p.com>
Signed-off-by: Juergen Gross <jgross@suse.com>
Message-ID: <20250721093316.23560-1-anthoine.bourgeois@vates.tech>

4 weeks agowifi: iwlwifi: Revert "wifi: iwlwifi: remove support of several iwl_ppag_table_cmd...
Miri Korenblit [Wed, 23 Jul 2025 06:45:15 +0000 (09:45 +0300)] 
wifi: iwlwifi: Revert "wifi: iwlwifi: remove support of several iwl_ppag_table_cmd versions"

It turns out that version 6 is still needed.
This change will be brought back once the FW that supports version 6 will no
longer be supported.

This reverts commit 24bc49d158c7 ("wifi: iwlwifi: remove support of several
iwl_ppag_table_cmd versions")

Link: https://patch.msgid.link/20250723064515.2084903-2-miriam.rachel.korenblit@intel.com
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
4 weeks agowifi: iwlwifi: check validity of the FW API range
Miri Korenblit [Wed, 23 Jul 2025 06:45:14 +0000 (09:45 +0300)] 
wifi: iwlwifi: check validity of the FW API range

We assume that iwl_mac_cfg and iwl_rf_cfg instances has either
both ucode_api_min and ucode_api_max set, or neither.
Validate this assumption with a Kunit test.

Reviewed-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Link: https://patch.msgid.link/20250723094230.66502f3f4345.I661f347d3bb29994d8b2ec1d3f31f3383422d68a@changeid
4 weeks agowifi: iwlwifi: don't export symbols that we shouldn't
Miri Korenblit [Wed, 23 Jul 2025 06:45:13 +0000 (09:45 +0300)] 
wifi: iwlwifi: don't export symbols that we shouldn't

Functions that are not called from the opmodes shouldn't be exported.

Reviewed-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Link: https://patch.msgid.link/20250723094230.97b80d0d00b3.Ib8abe63c9b25ef1e4ae1bc167cb23fe34bb3682a@changeid
4 weeks agowifi: iwlwifi: mld: use spec link id and not FW link id
Miri Korenblit [Wed, 23 Jul 2025 06:45:12 +0000 (09:45 +0300)] 
wifi: iwlwifi: mld: use spec link id and not FW link id

In missed beacon handling, we compare the FW link id to the
bss_param_ch_cnt_link_id, which is a spec link id. Fix it.

Reviewed-by: Somashekhar Puttagangaiah <somashekhar.puttagangaiah@intel.com>
Reviewed-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Link: https://patch.msgid.link/20250723094230.2104f8cac836.I25ed77c2b87bde82a9153e2aa26e09b8a42f6ee3@changeid
4 weeks agowifi: iwlwifi: mld: decode EOF bit for AMPDUs
Benjamin Berg [Wed, 23 Jul 2025 06:45:11 +0000 (09:45 +0300)] 
wifi: iwlwifi: mld: decode EOF bit for AMPDUs

Only the EOF bit handling for single frames was ported to the MLD
driver. The code to handle AMPDUs correctly was forgotten. Add it back
so that the bit is reported in the radiotap headers again.

Fixes: d1e879ec600f ("wifi: iwlwifi: add iwlmld sub-driver")
Signed-off-by: Benjamin Berg <benjamin.berg@intel.com>
Reviewed-by: Daniel Gabay <daniel.gabay@intel.com>
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Link: https://patch.msgid.link/20250723094230.195be86372d5.I4db4abf348f7b6dfc75f869770dd77655a204bc7@changeid
4 weeks agowifi: iwlwifi: Remove support for rx OMI bandwidth reduction
Miri Korenblit [Wed, 23 Jul 2025 06:45:10 +0000 (09:45 +0300)] 
wifi: iwlwifi: Remove support for rx OMI bandwidth reduction

This feature turns out to have an issue: it can take up to 8 seconds to
detect high throughput scenarios and to leave RX OMI bandwidth
reduction. This leads to throughput degradation.
Until the issues are fixed, remove the RX OMI implementation.

Reviewed-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Link: https://patch.msgid.link/20250723094230.a9ccfe210516.Ic87bc7709a6761f593e88f1488a41442c68c1686@changeid
4 weeks agowifi: iwlwifi: stop supporting iwl_omi_send_status_notif ver 1
Miri Korenblit [Wed, 23 Jul 2025 06:45:09 +0000 (09:45 +0300)] 
wifi: iwlwifi: stop supporting iwl_omi_send_status_notif ver 1

This version doesn't provide the sta id, so we need to look it up -
assuming that no other sta exists, since one of the conditions of
entering OMI is not having P2P/TDLS.

But when we leave OMI, because of the P2P/TDLS activation, the P2P/TDLS
sta can already exist while we receive the notification from the FW.
This causes an error log which is incorrect.

Since OMI is only supported in SC, which is not shipped yet, no one will
use a FW with the old version.
Remove support for it.

Reviewed-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Link: https://patch.msgid.link/20250723094230.b716b9cebaa7.I2a1cc4be441dbbb5566a9a3d2d330d956ff3ed38@changeid
4 weeks agowifi: iwlwifi: remove SC2F firmware support
Miri Korenblit [Wed, 23 Jul 2025 06:45:08 +0000 (09:45 +0300)] 
wifi: iwlwifi: remove SC2F firmware support

The only difference between SC2 and SC2F is that they use a different
FSEQ image.
The firmware of SC2 implements the logic of selecting the right FSEQ
image to load, so there is no need for SC2F firmware image.
Stop loading it, and load SC2 image instead.

Reviewed-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Link: https://patch.msgid.link/20250723094230.bf0ec63e49a9.Iffa0a982f90a179566d85c60ccd3dbfc50e293ef@changeid
4 weeks agowifi: iwlwifi: mvm: Remove NAN support
Ilan Peer [Wed, 23 Jul 2025 06:45:07 +0000 (09:45 +0300)] 
wifi: iwlwifi: mvm: Remove NAN support

NAN is not officially supported on any of the MVM devices so there
is no need to maintain it.

Signed-off-by: Ilan Peer <ilan.peer@intel.com>
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Link: https://patch.msgid.link/20250723094230.b327adbf35c0.I0357e383ab5df72d8b87e0dee10609a6946865b6@changeid
4 weeks agowifi: iwlwifi: mld: avoid outdated reorder buffer head_sn
Avraham Stern [Wed, 23 Jul 2025 06:45:06 +0000 (09:45 +0300)] 
wifi: iwlwifi: mld: avoid outdated reorder buffer head_sn

If no frames are received on a queue for a while, the reorder buffer
head_sn may be an old one. When the next frame that is received on
that queue and buffered is a subframe of an AMSDU but not the last
subframe, it will not update the buffer's head_sn. When the frame
release notification arrives, it will not release the buffered frame
because it will look like the notification's NSSN is lower than the
buffer's head_sn (because of a wraparound).
Fix it by updating the head_sn when the first frame is buffered.

Signed-off-by: Avraham Stern <avraham.stern@intel.com>
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Link: https://patch.msgid.link/20250723094230.e1f62a9a603c.I7b57a481122074b1f40d39cd31db2e5262668eb2@changeid
4 weeks agowifi: iwlwifi: mvm: avoid outdated reorder buffer head_sn
Avraham Stern [Wed, 23 Jul 2025 06:45:05 +0000 (09:45 +0300)] 
wifi: iwlwifi: mvm: avoid outdated reorder buffer head_sn

If no frames are received on a queue for a while, the reorder buffer
head_sn may be an old one. When the next frame that is received on
that queue and buffered is a subframe of an AMSDU but not the last
subframe, it will not update the buffer's head_sn. When the frame
release notification arrives, it will not release the buffered frame
because it will look like the notification's NSSN is lower than the
buffer's head_sn (because of a wraparound).
Fix it by updating the head_sn when the first frame is buffered.

Signed-off-by: Avraham Stern <avraham.stern@intel.com>
Reviewed-by: Daniel Gabay <daniel.gabay@intel.com>
Reviewed-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Link: https://patch.msgid.link/20250723094230.795ec0cb8817.I9ec9a3508e7935e8d1833ea3e086066fdefee644@changeid
4 weeks agowifi: iwlwifi: disable certain features for fips_enabled
Johannes Berg [Wed, 23 Jul 2025 06:45:04 +0000 (09:45 +0300)] 
wifi: iwlwifi: disable certain features for fips_enabled

When fips_enabled is set, keys will not be given to the
hardware by mac80211 since the hardware isn't certified.
In this case, various features cannot work correctly as
the firmware needs to handle frames, but it then cannot
since no keys are available.

Disable features:
 - WoWLAN since no keys etc.
 - MFP since some frames need to be handled in firmware
 - EHT/6GHz since MFP is required

Also restrict A-MSDU size since A-MSDUs cannot be split
up by hardware and thus need to fit into the RX buffers
in one piece.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Link: https://patch.msgid.link/20250723094230.329fade58a27.I0be27dd329643cc5fdf79a8c8b8f6d2e6fb5c175@changeid
4 weeks agowifi: iwlwifi: mld: support channel survey collection for ACS scans
Benjamin Berg [Wed, 23 Jul 2025 06:45:03 +0000 (09:45 +0300)] 
wifi: iwlwifi: mld: support channel survey collection for ACS scans

The firmware is able to collect channel statistics when doing passive
scans. Enable the flag when doing a passive scan on an AP interface and
collect the survey information.

Signed-off-by: Benjamin Berg <benjamin.berg@intel.com>
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Link: https://patch.msgid.link/20250723094230.a659ef1b1fd8.I24a9a0383327c231f36be170968bc7bac801f9f2@changeid
4 weeks agowifi: iwlwifi: mld: disable RX aggregation if requested
Miri Korenblit [Wed, 23 Jul 2025 06:45:02 +0000 (09:45 +0300)] 
wifi: iwlwifi: mld: disable RX aggregation if requested

The user can request to disable RX aggregations via the module parameter
enable_11n.
Honor this request and reject addba.

Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Link: https://patch.msgid.link/20250723094230.40746586ade7.Ibf5877df76ea2f1eee614166b3194843fd9898cd@changeid
4 weeks agoarm64/gcs: task_gcs_el0_enable() should use passed task
Jeremy Linton [Sat, 19 Jul 2025 04:37:33 +0000 (23:37 -0500)] 
arm64/gcs: task_gcs_el0_enable() should use passed task

Mark Rutland noticed that the task parameter is ignored and
'current' is being used instead. Since this is usually
what its passed, it hasn't yet been causing problems but likely
will as the code gets more testing.

But, once this is fixed, it creates a new bug in copy_thread_gcs()
since the gcs_el_mode isn't yet set for the task before its being
checked. Move gcs_alloc_thread_stack() after the new task's
gcs_el0_mode initialization to avoid this.

Fixes: fc84bc5378a8 ("arm64/gcs: Context switch GCS state for EL0")
Signed-off-by: Jeremy Linton <jeremy.linton@arm.com>
Reviewed-by: Mark Brown <broonie@kernel.org>
Link: https://lore.kernel.org/r/20250719043740.4548-2-jeremy.linton@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
4 weeks agodt-bindings: net: wireless: rt2800: add SOC Wifi
Rosen Penev [Tue, 22 Jul 2025 21:28:56 +0000 (14:28 -0700)] 
dt-bindings: net: wireless: rt2800: add SOC Wifi

Add device-tree bindings for the RT2800 SOC wifi device found in older
Ralink/Mediatek devices.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Link: https://patch.msgid.link/20250722212856.11343-8-rosenp@gmail.com
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
4 weeks agoMIPS: dts: ralink: mt7620a: add wifi
Rosen Penev [Tue, 22 Jul 2025 21:28:55 +0000 (14:28 -0700)] 
MIPS: dts: ralink: mt7620a: add wifi

MT7620A devices all contain a wifi device as part of the SOC. Add it
here to get it working.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Reviewed-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Link: https://patch.msgid.link/20250722212856.11343-7-rosenp@gmail.com
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
4 weeks agowifi: rt2x00: soc: modernize probe
Rosen Penev [Tue, 22 Jul 2025 21:28:54 +0000 (14:28 -0700)] 
wifi: rt2x00: soc: modernize probe

Remove a bunch of static memory management functions and simplify with
devm.

Also move allocation before ieee80211_alloc_hw to get rid of goto
statements and clarify the error handling a bit more.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Acked-by: Stanislaw Gruszka <stf_xl@wp.pl>
Reviewed-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Link: https://patch.msgid.link/20250722212856.11343-6-rosenp@gmail.com
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
4 weeks agowifi: rt2800: move 2x00soc to 2800soc
Rosen Penev [Tue, 22 Jul 2025 21:28:53 +0000 (14:28 -0700)] 
wifi: rt2800: move 2x00soc to 2800soc

This driver was written with multiple SOC platforms in mind. However
since Ralink was aquired by Mediatek, it only effectively got used by
older platforms. As such, we can slim down the driver slightly by moving
all of rt2x00soc to rt2800soc in order to benefit from inlining.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Acked-by: Stanislaw Gruszka <stf_xl@wp.pl>
Reviewed-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Link: https://patch.msgid.link/20250722212856.11343-5-rosenp@gmail.com
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
4 weeks agowifi: rt2800soc: allow loading from OF
Rosen Penev [Tue, 22 Jul 2025 21:28:52 +0000 (14:28 -0700)] 
wifi: rt2800soc: allow loading from OF

Add a single binding to help the already present dts files load the
driver. More are possible but there doesn't seem to be a significant
difference between them to justify this.

Use wifi name per dtschema requirements.

Added OF dependency to SOC CONFIG as adding of_match_table without OF
being present makes no sense.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Reviewed-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Acked-by: Stanislaw Gruszka <stf_xl@wp.pl>
Link: https://patch.msgid.link/20250722212856.11343-4-rosenp@gmail.com
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
4 weeks agowifi: rt2x00: remove mod_name from platform_driver
Rosen Penev [Tue, 22 Jul 2025 21:28:51 +0000 (14:28 -0700)] 
wifi: rt2x00: remove mod_name from platform_driver

mod_name is a legacy debugging feature with no real modern use. An
analysis of the underlying MIPS setup code reveals it to also be unused.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Reviewed-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Acked-by: Stanislaw Gruszka <stf_xl@wp.pl>
Link: https://patch.msgid.link/20250722212856.11343-3-rosenp@gmail.com
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
4 weeks agowifi: rt2x00: add COMPILE_TEST
Rosen Penev [Tue, 22 Jul 2025 21:28:50 +0000 (14:28 -0700)] 
wifi: rt2x00: add COMPILE_TEST

While this driver is for a specific arch, there is nothing preventing it
from being compiled on other platforms.

Allows the various bots to test compilation and complain if a patch is
bad.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Acked-by: Stanislaw Gruszka <stf_xl@wp.pl>
Reviewed-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Link: https://patch.msgid.link/20250722212856.11343-2-rosenp@gmail.com
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
4 weeks agowifi: mac80211: fix WARN_ON for monitor mode on some devices
Johannes Berg [Wed, 23 Jul 2025 07:14:19 +0000 (09:14 +0200)] 
wifi: mac80211: fix WARN_ON for monitor mode on some devices

On devices without WANT_MONITOR_VIF (and probably without
channel context support) we get a WARN_ON for changing the
per-link setting of a monitor interface.

Since we already skip AP_VLAN interfaces and MONITOR with
WANT_MONITOR_VIF and/or NO_VIRTUAL_MONITOR should update
the settings, catch this in the link change code instead
of the warning.

Reported-by: Martin Kaistra <martin.kaistra@linutronix.de>
Link: https://lore.kernel.org/r/a9de62a0-28f1-4981-84df-253489da74ed@linutronix.de/
Fixes: c4382d5ca1af ("wifi: mac80211: update the right link for tx power")
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
4 weeks agowifi: brcmfmac: cyw: Fix __counted_by to be LE variant
Kees Cook [Mon, 21 Jul 2025 18:18:14 +0000 (11:18 -0700)] 
wifi: brcmfmac: cyw: Fix __counted_by to be LE variant

In brcmf_cyw_mgmt_tx() the "len" counter of the struct
brcmf_mf_params_le::data flexible array is stored as little-endian via
cpu_to_le16() so the __counted_by_le() variant must be used:

struct brcmf_mf_params_le *mf_params;
...
mf_params_len = offsetof(struct brcmf_mf_params_le, data) +
(len - DOT11_MGMT_HDR_LEN);
mf_params = kzalloc(mf_params_len, GFP_KERNEL);
...
        mf_params->len = cpu_to_le16(len - DOT11_MGMT_HDR_LEN);

Fixes: 66f909308a7c ("wifi: brcmfmac: cyw: support external SAE authentication in station mode")
Signed-off-by: Kees Cook <kees@kernel.org>
Reviewed-by: Gustavo A. R. Silva <gustavoars@kernel.org>
Acked-by: Arend van Spriel <arend.vanspriel@broadcom.com>>
Link: https://patch.msgid.link/20250721181810.work.575-kees@kernel.org
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
4 weeks agoMAINTAINERS: add missing files to slab section
Lorenzo Stoakes [Tue, 22 Jul 2025 17:59:01 +0000 (18:59 +0100)] 
MAINTAINERS: add missing files to slab section

The failslab implementation implements fault injection for slab allocations
so seems best suited to the slab section.

The mempool implementation uses slab in the backend, so that seems best
suited here also.

Signed-off-by: Lorenzo Stoakes <lorenzo.stoakes@oracle.com>
Signed-off-by: Vlastimil Babka <vbabka@suse.cz>
4 weeks agopmdomain: qcom: rpmhpd: Add Glymur RPMh Power Domains
Kamal Wadhwa [Wed, 16 Jul 2025 15:27:58 +0000 (20:57 +0530)] 
pmdomain: qcom: rpmhpd: Add Glymur RPMh Power Domains

Add RPMh Power Domains support for the Glymur platform.

Signed-off-by: Kamal Wadhwa <kamal.wadhwa@oss.qualcomm.com>
Signed-off-by: Pankaj Patil <pankaj.patil@oss.qualcomm.com>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Reviewed-by: Abel Vesa <abel.vesa@linaro.org>
Link: https://lore.kernel.org/r/20250716152758.4079467-3-pankaj.patil@oss.qualcomm.com
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
4 weeks agopmdomain: Merge branch dt into next
Ulf Hansson [Wed, 23 Jul 2025 10:10:42 +0000 (12:10 +0200)] 
pmdomain: Merge branch dt into next

Merge the immutable branch dt into next, to allow the DT bindings to be
tested together with changes that are targeted for v6.17.

Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
4 weeks agodt-bindings: power: rpmpd: Add Glymur power domains
Kamal Wadhwa [Wed, 16 Jul 2025 15:27:57 +0000 (20:57 +0530)] 
dt-bindings: power: rpmpd: Add Glymur power domains

Add the compatibles for the rpmpd power domains on glymur
boards

Signed-off-by: Kamal Wadhwa <kamal.wadhwa@oss.qualcomm.com>
Signed-off-by: Pankaj Patil <pankaj.patil@oss.qualcomm.com>
Acked-by: Rob Herring (Arm) <robh@kernel.org>
Link: https://lore.kernel.org/r/20250716152758.4079467-2-pankaj.patil@oss.qualcomm.com
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
4 weeks agodocs: Downgrade arm64 & riscv from titles to comment
Joel Granados [Tue, 1 Jul 2025 08:39:27 +0000 (10:39 +0200)] 
docs: Downgrade arm64 & riscv from titles to comment

Remove the title string ("====") from under arm64 & riscv and move them
to a commment under the perf_user_access sysctl. They are explanations,
*not* sysctls themselves

This effectively removes these two strings from appearing as not
implemented when the check-sysctl-docs script is run

Signed-off-by: Joel Granados <joel.granados@kernel.org>
4 weeks agodocs: Replace spaces with tabs in check-sysctl-docs
Joel Granados [Tue, 1 Jul 2025 08:19:09 +0000 (10:19 +0200)] 
docs: Replace spaces with tabs in check-sysctl-docs

Remove the combination of spaces and tabs in favor of just tabs.

Signed-off-by: Joel Granados <joel.granados@kernel.org>
4 weeks agodocs: Remove colon from ctltable title in vm.rst
Joel Granados [Tue, 1 Jul 2025 08:07:46 +0000 (10:07 +0200)] 
docs: Remove colon from ctltable title in vm.rst

Removing them solves an issue where they were incorrectly considered as
not implemented by the check-sysctl-docs script

Signed-off-by: Joel Granados <joel.granados@kernel.org>
4 weeks agodocs: Add awk section for ucount sysctl entries
Joel Granados [Tue, 1 Jul 2025 08:07:04 +0000 (10:07 +0200)] 
docs: Add awk section for ucount sysctl entries

Adjust the sysctl table detection to include the macro pattern used for
the ucount ctl_tables. This prevents falsly assigning them as
non-documented ctl_tables

Signed-off-by: Joel Granados <joel.granados@kernel.org>
4 weeks agodocs: Use skiplist when checking sysctl admin-guide
Joel Granados [Tue, 1 Jul 2025 07:55:39 +0000 (09:55 +0200)] 
docs: Use skiplist when checking sysctl admin-guide

Use a skiplist to "skip" the titles in the guide documentation
(Documentation/admin-guide/sysctl/*) that are not sysctls. This will
give a more accurate account of what sysctl are miss-documented.

Signed-off-by: Joel Granados <joel.granados@kernel.org>
4 weeks agodocs: nixify check-sysctl-docs
Joel Granados [Tue, 1 Jul 2025 07:51:57 +0000 (09:51 +0200)] 
docs: nixify check-sysctl-docs

Use "#!/usr/bin/env -S gawk -f" instead of "#!/bin/gawk". Needed for
testing in nix environments as they only provide /usr/bin/env at the
standard location.

Signed-off-by: Joel Granados <joel.granados@kernel.org>
4 weeks agosysctl: rename kern_table -> sysctl_subsys_table
Joel Granados [Fri, 27 Jun 2025 08:12:40 +0000 (10:12 +0200)] 
sysctl: rename kern_table -> sysctl_subsys_table

Renamed sysctl table from kern_table to sysctl_subsys_table and grouped
the two arch specific ctls to the end of the array.

This is part of a greater effort to move ctl tables into their
respective subsystems which will reduce the merge conflicts in
kernel/sysctl.c.

Signed-off-by: Joel Granados <joel.granados@kernel.org>
4 weeks agokernel/sys.c: Move overflow{uid,gid} sysctl into kernel/sys.c
Joel Granados [Fri, 27 Jun 2025 08:00:51 +0000 (10:00 +0200)] 
kernel/sys.c: Move overflow{uid,gid} sysctl into kernel/sys.c

Moved ctl_tables elements for overflowuid and overflowgid into in
kernel/sys.c. Create a register function that keeps them under "kernel"
and run it after core with postcore_initcall.

This is part of a greater effort to move ctl tables into their
respective subsystems which will reduce the merge conflicts in
kernel/sysctl.c.

Signed-off-by: Joel Granados <joel.granados@kernel.org>
4 weeks agouevent: mv uevent_helper into kobject_uevent.c
Joel Granados [Fri, 27 Jun 2025 07:29:56 +0000 (09:29 +0200)] 
uevent: mv uevent_helper into kobject_uevent.c

Move both uevent_helper table into lib/kobject_uevent.c. Place the
registration early in the initcall order with postcore_initcall.

This is part of a greater effort to move ctl tables into their
respective subsystems which will reduce the merge conflicts in
kernel/sysctl.c.

Signed-off-by: Joel Granados <joel.granados@kernel.org>
4 weeks agosysctl: Removed unused variable
Joel Granados [Fri, 27 Jun 2025 07:00:05 +0000 (09:00 +0200)] 
sysctl: Removed unused variable

Remove unaligned_dump_stack from sysctl.h; it is no longer used or
defined.

Signed-off-by: Joel Granados <joel.granados@kernel.org>
4 weeks agosysctl: Nixify sysctl.sh
Joel Granados [Thu, 26 Jun 2025 12:48:08 +0000 (14:48 +0200)] 
sysctl: Nixify sysctl.sh

Use "#!/usr/bin/env bash" instead of "#!/bin/bash". Needed for testing
in nix environments as they only provide /usr/bin/env at the standard
location.

Signed-off-by: Joel Granados <joel.granados@kernel.org>
4 weeks agoslab: Update MAINTAINERS entry
Matthew Wilcox (Oracle) [Wed, 11 Jun 2025 15:59:14 +0000 (16:59 +0100)] 
slab: Update MAINTAINERS entry

Add the two Documentation files to the maintainers entry.  Simplify the
match for header files now that there is only slab.h.  Move Vlastimil
to the top of the list of maintainers since he's the one doing the pull
requests.  Change David & Christoph's roles to Reviewer.  Expand the
pattern for files in mm/ so that somebody searching for 'slub' will
find it.

Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Acked-by: Harry Yoo <harry.yoo@oracle.com>
Acked-by: David Rientjes <rientjes@google.com>
Link: https://patch.msgid.link/20250611155916.2579160-12-willy@infradead.org
Signed-off-by: Vlastimil Babka <vbabka@suse.cz>
4 weeks agomemcg_slabinfo: Fix use of PG_slab
Matthew Wilcox (Oracle) [Wed, 11 Jun 2025 15:59:13 +0000 (16:59 +0100)] 
memcg_slabinfo: Fix use of PG_slab

Check PGTY_slab instead of PG_slab.

Fixes: 4ffca5a96678 (mm: support only one page_type per page)
Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Tested-by: Roman Gushchin <roman.gushchin@linux.dev>
Reviewed-by: Roman Gushchin <roman.gushchin@linux.dev>
Reviewed-by: Harry Yoo <harry.yoo@oracle.com>
Link: https://patch.msgid.link/20250611155916.2579160-11-willy@infradead.org
Signed-off-by: Vlastimil Babka <vbabka@suse.cz>
4 weeks agokfence: Remove mention of PG_slab
Matthew Wilcox (Oracle) [Wed, 11 Jun 2025 15:59:12 +0000 (16:59 +0100)] 
kfence: Remove mention of PG_slab

Improve the documentation slightly, assuming I understood it correctly.

Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Acked-by: Harry Yoo <harry.yoo@oracle.com>
Link: https://patch.msgid.link/20250611155916.2579160-10-willy@infradead.org
Signed-off-by: Vlastimil Babka <vbabka@suse.cz>
4 weeks agosysctl: Remove superfluous includes from kernel/sysctl.c
Joel Granados [Mon, 5 May 2025 08:53:28 +0000 (10:53 +0200)] 
sysctl: Remove superfluous includes from kernel/sysctl.c

Remove the following headers from the include list in sysctl.c.

* These are removed as the related variables are no longer there.
  ===================   ====================
  Include               Related Var
  ===================   ====================
  linux/kmod.h          usermodehelper
  asm/nmi.h             nmi_watchdoc_enabled
  asm/io.h              io_delay_type
  linux/pid.h           pid_max_{,min,max}
  linux/sched/sysctl.h  sysctl_{sched_*,numa_*,timer_*}
  linux/mount.h         sysctl_mount_max
  linux/reboot.h        poweroff_cmd
  linux/ratelimit.h     {,printk_}ratelimit_state
  linux/printk.h        kptr_restrict
  linux/security.h      CONFIG_SECURITY_CAPABILITIES
  linux/net.h           net_table
  linux/key.h           key_sysctls
  linux/nvs_fs.h        acpi_video_flags
  linux/acpi.h          acpi_video_flags
  linux/fs.h            proc_nr_files

* These are no longer needed as intermediate includes
  ==============
  Include
  ==============
  linux/filter.h
  linux/binfmts.h

Reviewed-by: Kees Cook <kees@kernel.org>
Reviewed-by: Luis Chamberlain <mcgrof@kernel.org>
Signed-off-by: Joel Granados <joel.granados@kernel.org>
4 weeks agosysctl: Remove (very) old file changelog
Joel Granados [Mon, 5 May 2025 11:42:27 +0000 (13:42 +0200)] 
sysctl: Remove (very) old file changelog

These comments are older than 2003 and therefore do not bare any
relevance on the current state of the sysctl.c file. Remove them as they
confuse more than clarify.

Reviewed-by: Luis Chamberlain <mcgrof@kernel.org>
Reviewed-by: Kees Cook <kees@kernel.org>
Signed-off-by: Joel Granados <joel.granados@kernel.org>
4 weeks agosysctl: Move sysctl_panic_on_stackoverflow to kernel/panic.c
Joel Granados [Thu, 8 May 2025 19:35:27 +0000 (21:35 +0200)] 
sysctl: Move sysctl_panic_on_stackoverflow to kernel/panic.c

This is part of a greater effort to move ctl tables into their
respective subsystems which will reduce the merge conflicts in
kernel/sysctl.c.

Reviewed-by: Kees Cook <kees@kernel.org>
Signed-off-by: Joel Granados <joel.granados@kernel.org>
4 weeks agosysctl: move cad_pid into kernel/pid.c
Joel Granados [Mon, 5 May 2025 19:47:47 +0000 (21:47 +0200)] 
sysctl: move cad_pid into kernel/pid.c

Move cad_pid as well as supporting function proc_do_cad_pid into
kernel/pic.c. Replaced call to __do_proc_dointvec with proc_dointvec
inside proc_do_cad_pid which requires the copy of the ctl_table to
handle the temp value.

This is part of a greater effort to move ctl tables into their
respective subsystems which will reduce the merge conflicts in
kernel/sysctl.c.

Reviewed-by: Luis Chamberlain <mcgrof@kernel.org>
Reviewed-by: Kees Cook <kees@kernel.org>
Signed-off-by: Joel Granados <joel.granados@kernel.org>
4 weeks agosysctl: Move tainted ctl_table into kernel/panic.c
Joel Granados [Mon, 5 May 2025 19:20:07 +0000 (21:20 +0200)] 
sysctl: Move tainted ctl_table into kernel/panic.c

Move the ctl_table with the "tainted" proc_name into kernel/panic.c.
With it moves the proc_tainted helper function.

This is part of a greater effort to move ctl tables into their
respective subsystems which will reduce the merge conflicts in
kernel/sysctl.c.

Reviewed-by: Luis Chamberlain <mcgrof@kernel.org>
Reviewed-by: Kees Cook <kees@kernel.org>
Signed-off-by: Joel Granados <joel.granados@kernel.org>
4 weeks agoInput: sysrq: mv sysrq into drivers/tty/sysrq.c
Joel Granados [Fri, 2 May 2025 20:47:06 +0000 (22:47 +0200)] 
Input: sysrq: mv sysrq into drivers/tty/sysrq.c

Move both sysrq ctl_table and supported sysrq_sysctl_handler helper
function into drivers/tty/sysrq.c. Replaced the __do_proc_dointvec in
helper function with do_proc_dointvec_minmax as the former is local to
kernel/sysctl.c. Here we use the minmax version of do_proc_dointvec
because do_proc_dointvec is static and calling do_proc_dointvec_minmax
with a NULL min and max is the same as calling do_proc_dointvec.

This is part of a greater effort to move ctl tables into their
respective subsystems which will reduce the merge conflicts in
kernel/sysctl.c.

Reviewed-by: Kees Cook <kees@kernel.org>
Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Joel Granados <joel.granados@kernel.org>
4 weeks agofork: mv threads-max into kernel/fork.c
Joel Granados [Fri, 2 May 2025 20:27:38 +0000 (22:27 +0200)] 
fork: mv threads-max into kernel/fork.c

make sysctl_max_threads static as it no longer needs to be exported into
sysctl.c.

This is part of a greater effort to move ctl tables into their
respective subsystems which will reduce the merge conflicts in
kernel/sysctl.c.

Reviewed-by: Luis Chamberlain <mcgrof@kernel.org>
Reviewed-by: Kees Cook <kees@kernel.org>
Signed-off-by: Joel Granados <joel.granados@kernel.org>
4 weeks agoparisc/power: Move soft-power into power.c
Joel Granados [Fri, 2 May 2025 13:32:17 +0000 (15:32 +0200)] 
parisc/power: Move soft-power into power.c

Move the soft-power ctl table into parisc/power.c. As a consequence the
pwrsw_enabled var is made static.

This is part of a greater effort to move ctl tables into their
respective subsystems which will reduce the merge conflicts in
kernel/sysctl.c.

Reviewed-by: Luis Chamberlain <mcgrof@kernel.org>
Reviewed-by: Kees Cook <kees@kernel.org>
Signed-off-by: Joel Granados <joel.granados@kernel.org>
4 weeks agomm: move randomize_va_space into memory.c
Joel Granados [Wed, 30 Apr 2025 12:42:13 +0000 (14:42 +0200)] 
mm: move randomize_va_space into memory.c

Move the randomize_va_space variable together with all its sysctl table
elements into memory.c. Register it to the "kernel" directory by
adding it to the subsys initialization calls

This is part of a greater effort to move ctl tables into their
respective subsystems which will reduce the merge conflicts in
kernel/sysctl.c.

Reviewed-by: Luis Chamberlain <mcgrof@kernel.org>
Reviewed-by: Kees Cook <kees@kernel.org>
Signed-off-by: Joel Granados <joel.granados@kernel.org>
4 weeks agorcu: Move rcu_stall related sysctls into rcu/tree_stall.h
Joel Granados [Wed, 30 Apr 2025 12:07:33 +0000 (14:07 +0200)] 
rcu: Move rcu_stall related sysctls into rcu/tree_stall.h

Move sysctl_panic_on_rcu_stall and sysctl_max_rcu_stall_to_panic into
the kernel/rcu subdirectory. Make these static in tree_stall.h and
removed them as extern from panic.h as their scope is now confined into
one file.

This is part of a greater effort to move ctl tables into their
respective subsystems which will reduce the merge conflicts in
kernel/sysctl.c.

Reviewed-by: Luis Chamberlain <mcgrof@kernel.org>
Reviewed-by: Joel Fernandes <joelagnelf@nvidia.com>
Reviewed-by: Kees Cook <kees@kernel.org>
Signed-off-by: Joel Granados <joel.granados@kernel.org>
4 weeks agolocking/rtmutex: Move max_lock_depth into rtmutex.c
Joel Granados [Tue, 29 Apr 2025 13:12:17 +0000 (15:12 +0200)] 
locking/rtmutex: Move max_lock_depth into rtmutex.c

Move the max_lock_depth sysctl table element into rtmutex_api.c. Removed
the rtmutex.h include from sysctl.c. Chose to move into rtmutex_api.c
to avoid multiple registrations every time rtmutex.c is included in other
files.

This is part of a greater effort to move ctl tables into their
respective subsystems which will reduce the merge conflicts in
kernel/sysctl.c.

Signed-off-by: Joel Granados <joel.granados@kernel.org>
4 weeks agomodule: Move modprobe_path and modules_disabled ctl_tables into the module subsys
Joel Granados [Tue, 29 Apr 2025 12:30:00 +0000 (14:30 +0200)] 
module: Move modprobe_path and modules_disabled ctl_tables into the module subsys

Move module sysctl (modprobe_path and modules_disabled) out of sysctl.c
and into the modules subsystem. Make modules_disabled static as it no
longer needs to be exported. Remove module.h from the includes in sysctl
as it no longer uses any module exported variables.

This is part of a greater effort to move ctl tables into their
respective subsystems which will reduce the merge conflicts in
kernel/sysctl.c.

Reviewed-by: Luis Chamberlain <mcgrof@kernel.org>
Reviewed-by: Petr Pavlu <petr.pavlu@suse.com>
Signed-off-by: Joel Granados <joel.granados@kernel.org>
4 weeks agodt-bindings: leds: ncp5623: Add 0x39 as a valid I2C address
Fabio Estevam [Thu, 3 Jul 2025 14:46:44 +0000 (11:46 -0300)] 
dt-bindings: leds: ncp5623: Add 0x39 as a valid I2C address

The NCP5623C variant has the I2C address at 0x39 according its datasheet:

https://www.mouser.com/datasheet/2/308/NCP5623C-D-64591.pdf

Make 0x39 a valid I2C address in the dt-binding.

Signed-off-by: Fabio Estevam <festevam@gmail.com>
Acked-by: "Rob Herring (Arm)" <robh@kernel.org>
Link: https://lore.kernel.org/r/20250703144644.2878253-1-festevam@gmail.com
Signed-off-by: Lee Jones <lee@kernel.org>
4 weeks agogpio: cadence: Remove duplicated include in gpio-cadence.c
Yang Li [Wed, 23 Jul 2025 06:46:08 +0000 (14:46 +0800)] 
gpio: cadence: Remove duplicated include in gpio-cadence.c

The header files linux/gpio/driver.h is included twice in gpio-cadence.c,
so one inclusion of each can be removed.

Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Closes: https://bugzilla.openanolis.cn/show_bug.cgi?id=22931
Signed-off-by: Yang Li <yang.lee@linux.alibaba.com>
Link: https://lore.kernel.org/r/20250723064608.2178024-1-yang.lee@linux.alibaba.com
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
4 weeks agoRDMA/mana_ib: add support of multiple ports
Konstantin Taranov [Tue, 22 Jul 2025 08:55:15 +0000 (01:55 -0700)] 
RDMA/mana_ib: add support of multiple ports

If the HW indicates support of multiple ports for rdma, create an IB device
with a port per netdev in the ethernet mana driver.

CM is only available on port 1, but RC QPs are supported on all
ports.

Signed-off-by: Konstantin Taranov <kotaranov@microsoft.com>
Link: https://patch.msgid.link/1753174515-23634-1-git-send-email-kotaranov@linux.microsoft.com
Signed-off-by: Leon Romanovsky <leon@kernel.org>
4 weeks agogpio: tps65219: Add support for TI TPS65214 PMIC
Shree Ramamoorthy [Tue, 22 Jul 2025 18:16:09 +0000 (13:16 -0500)] 
gpio: tps65219: Add support for TI TPS65214 PMIC

Add support for the TI TPS65214 PMIC with the addition of an id_table,
separate TPS65214 template_chip, and device-specific _change_direction
functions.

- Use platform_get_device_id() to assign dev-specific information.
- Use different change_direction() functions since TPS65214's GPIO
  configuration bits are changeable during device operation through bit
  GPIO_CONFIG in GENERAL_CONFIG register.
- Remove MODULE_ALIAS since it is now generated by MODULE_DEVICE_TABLE.

Reviewed-by: Jonathan Cormier <jcormier@criticallink.com>
Tested-by: Jonathan Cormier <jcormier@criticallink.com>
Signed-off-by: Shree Ramamoorthy <s-ramamoorthy@ti.com>
Link: https://lore.kernel.org/r/20250722181609.1541739-3-s-ramamoorthy@ti.com
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
4 weeks agogpio: tps65219: Update _IDX & _OFFSET macro prefix
Shree Ramamoorthy [Tue, 22 Jul 2025 18:16:08 +0000 (13:16 -0500)] 
gpio: tps65219: Update _IDX & _OFFSET macro prefix

TPS65215 and TPS65219 are overlapping PMIC devices. While their regulator
features differe, the GPIO features are the same. In the TPS65219 MFD
driver, the 2 PMICs share the same "tps65219-gpio" compatible string to
limit support for TPS65215 in this GPIO driver to comments.

The TPS6521X_GPIO0_IDX and TPS6521X_GPIO0_OFFSET macro name prefixes are
updated to indicate these macros apply to both PMICs.

Reviewed-by: Roger Quadros <rogerq@kernel.org>
Acked-by: Linus Walleij <linus.walleij@linaro.org>
Reviewed-by: Jonathan Cormier <jcormier@criticallink.com>
Signed-off-by: Shree Ramamoorthy <s-ramamoorthy@ti.com>
Link: https://lore.kernel.org/r/20250722181609.1541739-2-s-ramamoorthy@ti.com
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
4 weeks agoRDMA/mlx5: Refactor optional counters steering code
Patrisious Haddad [Sun, 20 Jul 2025 09:37:24 +0000 (12:37 +0300)] 
RDMA/mlx5: Refactor optional counters steering code

Currently there isn't a clear layer separation between the counters and
the steering code, whereas the steering code is doing redundant access
to the counter struct.

Separate the fs.c and counters.c, where fs code won't access or be
aware of counter structs but only the objects it needs.

As a result, move mlx5_rdma_counter struct from the header file to be
an internal struct for the counters file only.

Signed-off-by: Patrisious Haddad <phaddad@nvidia.com>
Reviewed-by: Edward Srouji <edwards@nvidia.com>
Link: https://patch.msgid.link/9854d1fdb140e4a6552b7a2fd1a028cfe488a935.1753004208.git.leon@kernel.org
Signed-off-by: Leon Romanovsky <leon@kernel.org>
4 weeks agokcsan: test: Initialize dummy variable
Marco Elver [Tue, 22 Jul 2025 18:19:17 +0000 (20:19 +0200)] 
kcsan: test: Initialize dummy variable

Newer compiler versions rightfully point out:

 kernel/kcsan/kcsan_test.c:591:41: error: variable 'dummy' is
 uninitialized when passed as a const pointer argument here
 [-Werror,-Wuninitialized-const-pointer]
   591 |         KCSAN_EXPECT_READ_BARRIER(atomic_read(&dummy), false);
       |                                                ^~~~~
 1 error generated.

Although this particular test does not care about the value stored in
the dummy atomic variable, let's silence the warning.

Link: https://lkml.kernel.org/r/CA+G9fYu8JY=k-r0hnBRSkQQrFJ1Bz+ShdXNwC1TNeMt0eXaxeA@mail.gmail.com
Fixes: 8bc32b348178 ("kcsan: test: Add test cases for memory barrier instrumentation")
Reported-by: Linux Kernel Functional Testing <lkft@linaro.org>
Reviewed-by: Alexander Potapenko <glider@google.com>
Signed-off-by: Marco Elver <elver@google.com>
5 weeks agoMerge tag 'v6.17-rockchip-arm32-1' of https://git.kernel.org/pub/scm/linux/kernel...
Arnd Bergmann [Wed, 23 Jul 2025 05:51:03 +0000 (07:51 +0200)] 
Merge tag 'v6.17-rockchip-arm32-1' of https://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip into soc/arm

Fix for seldom hangs when bringing up arm32 cpu cores.

* tag 'v6.17-rockchip-arm32-1' of https://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip:
  ARM: rockchip: fix kernel hang during smp initialization

Link: https://lore.kernel.org/r/12434765.CDJkKcVGEf@phil
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
5 weeks agoRDMA/mlx5: Add DMAH support for reg_user_mr/reg_user_dmabuf_mr
Yishai Hadas [Thu, 17 Jul 2025 12:17:32 +0000 (15:17 +0300)] 
RDMA/mlx5: Add DMAH support for reg_user_mr/reg_user_dmabuf_mr

As part of this enhancement, allow the creation of an MKEY associated
with a DMA handle.

Additional notes:

MKEYs with TPH (i.e. TLP Processing Hints) attributes are currently not
UMR-capable unless explicitly enabled by firmware or hardware.
Therefore, to maintain such MKEYs in the MR cache, the TPH fields have
been added to the rb_key structure, with a dedicated hash bucket.

The ability to bypass the kernel verbs flow and create an MKEY with TPH
attributes using DEVX has been restricted. TPH must follow the standard
InfiniBand flow, where a DMAH is created with the appropriate security
checks and management mechanisms in place.

DMA handles are currently not supported in conjunction with On-Demand
Paging (ODP).

Re-registration of memory regions originally created with TPH attributes
is currently not supported.

Signed-off-by: Yishai Hadas <yishaih@nvidia.com>
Reviewed-by: Edward Srouji <edwards@nvidia.com>
Link: https://patch.msgid.link/1c485651cf8417694ddebb80446c5093d5a791a9.1752752567.git.leon@kernel.org
Signed-off-by: Leon Romanovsky <leon@kernel.org>
5 weeks agoIB: Extend UVERBS_METHOD_REG_MR to get DMAH
Yishai Hadas [Thu, 17 Jul 2025 12:17:31 +0000 (15:17 +0300)] 
IB: Extend UVERBS_METHOD_REG_MR to get DMAH

Extend UVERBS_METHOD_REG_MR to get DMAH and pass it to all drivers.

It will be used in mlx5 driver as part of the next patch from the
series.

Signed-off-by: Yishai Hadas <yishaih@nvidia.com>
Reviewed-by: Edward Srouji <edwards@nvidia.com>
Link: https://patch.msgid.link/2ae1e628c0675db81f092cc00d3ad6fbf6139405.1752752567.git.leon@kernel.org
Signed-off-by: Leon Romanovsky <leon@kernel.org>
5 weeks agoRDMA/mlx5: Add DMAH object support
Yishai Hadas [Thu, 17 Jul 2025 12:17:30 +0000 (15:17 +0300)] 
RDMA/mlx5: Add DMAH object support

This patch introduces support for allocating and deallocating the DMAH
object.

Further details:
----------------
The DMAH API is exposed to upper layers only if the underlying device
supports TPH.

It uses the mlx5_core steering tag (ST) APIs to get a steering tag index
based on the provided input.

The obtained index is stored in the device-specific mlx5_dmah structure
for future use.

Upcoming patches in the series will integrate the allocated DMAH into
the memory region (MR) registration process.

Signed-off-by: Yishai Hadas <yishaih@nvidia.com>
Reviewed-by: Edward Srouji <edwards@nvidia.com>
Link: https://patch.msgid.link/778550776799d82edb4d05da249a1cff00160b50.1752752567.git.leon@kernel.org
Signed-off-by: Leon Romanovsky <leon@kernel.org>
5 weeks agoRDMA/core: Introduce a DMAH object and its alloc/free APIs
Yishai Hadas [Thu, 17 Jul 2025 12:17:29 +0000 (15:17 +0300)] 
RDMA/core: Introduce a DMAH object and its alloc/free APIs

Introduce a new DMA handle (DMAH) object along with its corresponding
allocation and deallocation APIs.

This DMAH object encapsulates attributes intended for use in DMA
transactions.

While its initial purpose is to support TPH functionality, it is
designed to be extensible for future features such as DMA PCI multipath,
PCI UIO configurations, PCI traffic class selection, and more.

Further details:
----------------
We ensure that a caller requesting a DMA handle for a specific CPU ID is
permitted to be scheduled on it. This prevent a potential security issue
where a non privilege user may trigger DMA operations toward a CPU that
it's not allowed to run on.

We manage reference counting for the DMAH object and its consumers
(e.g., memory regions) as will be detailed in subsequent patches in the
series.

Signed-off-by: Yishai Hadas <yishaih@nvidia.com>
Reviewed-by: Edward Srouji <edwards@nvidia.com>
Link: https://patch.msgid.link/2cad097e849597e49d6b61e6865dba878257f371.1752752567.git.leon@kernel.org
Signed-off-by: Leon Romanovsky <leon@kernel.org>
5 weeks agoIB/core: Add UVERBS_METHOD_REG_MR on the MR object
Yishai Hadas [Thu, 17 Jul 2025 12:17:28 +0000 (15:17 +0300)] 
IB/core: Add UVERBS_METHOD_REG_MR on the MR object

This new method enables us to use a single ioctl from user space which
supports the below variants of reg_mr [1].

The method will be extended in the next patches from the series with an
extra attribute to let us pass DMA handle to be used as part of the
registration.

[1] ibv_reg_mr(), ibv_reg_mr_iova(), ibv_reg_mr_iova2(),
ibv_reg_dmabuf_mr().

Signed-off-by: Yishai Hadas <yishaih@nvidia.com>
Reviewed-by: Edward Srouji <edwards@nvidia.com>
Link: https://patch.msgid.link/5a3822ceef084efe967c9752e89c58d8250337c7.1752752567.git.leon@kernel.org
Signed-off-by: Leon Romanovsky <leon@kernel.org>
5 weeks agoRDMA support for DMA handle
Leon Romanovsky [Wed, 23 Jul 2025 05:38:56 +0000 (01:38 -0400)] 
RDMA support for DMA handle

From Yishai:

This patch series introduces a new DMA Handle (DMAH) object, along with
corresponding APIs for its allocation and deallocation.

The DMAH object encapsulates attributes relevant for DMA transactions.

While initially intended to support TLP Processing Hints (TPH) [1], the
design is extensible to accommodate future features such as PCI
multipath for DMA, PCI UIO configurations, traffic class selection, and
more.

Additionally, we introduce a new ioctl method on the MR object:
UVERBS_METHOD_REG_MR.

This method consolidates multiple reg_mr variants under a single
user-space ioctl interface, supporting: ibv_reg_mr(), ibv_reg_mr_iova(),
ibv_reg_mr_iova2() and ibv_reg_dmabuf_mr(). It also enables passing a
DMA handle as part of the registration process.

Throughout the patch series, the following DMAH-related stuff can also
be observed in the IB layer:

- Association with a CPU ID and its memory type, for use with Steering
  Tags [2].

- Inclusion of Processing Hints (PH) data for TPH functionality [3].

- Enforces security by ensuring that only tasks allowed to run on a
  given CPU may request a DMA handle for it.

- Reference counting for DMAH life cycle management and safe usage
  across memory regions.

mlx5 driver implementation:
--------------------------
The series includes implementation of the above functionality in the
mlx5 driver.

In mlx5_core:
- Enables TPH over PCIe when both firmware and OS support it.

- Manages Steering Tags and corresponding indices by writing tag values
  to the PCI configuration space.

- Exposes APIs to upper layers (e.g., mlx5_ib) to enable the PCIe TPH
  functionality.

In mlx5_ib:
- Adds full support for DMAH operations.

- Utilizes mlx5_core's Steering Tag APIs to derive tag indices from
  input.

- Stores the resulting index in a mlx5_dmah structure for use during
  MKEY creation with a DMA handle.

- Adds support for allowing MKEYs to be created in conjunction with DMA
  handles.

Additional details are provided in the commit messages.

[1] Background, from PCIe specification 6.2.
TLP Processing Hints (TPH)
--------------------------
TLP Processing Hints is an optional feature that provides hints in
Request TLP headers to facilitate optimized processing of Requests that
target Memory Space.  These Processing Hints enable the system hardware
(e.g., the Root Complex and/ or Endpoints) to optimize platform
resources such as system and memory interconnect on a per TLP basis.
Steering Tags are system-specific values used to identify a processing
resource that a Requester explicitly targets. System software discovers
and identifies TPH capabilities to determine the Steering Tag allocation
for each Function that supports TPH

[2] Steering Tags
Functions that intend to target a TLP towards a specific processing
resource such as a host processor or system cache hierarchy require
topological information of the target cache (e.g., which host cache).
Steering Tags are system-specific values that provide information about
the host or cache structure in the system cache hierarchy. These values
are used to associate processing elements within the platform with the
processing of Requests.

[3] Processing Hints
The Requester provides hints to the Root Complex or other targets about
the intended use of data and data structures by the host and/or device.
The hints are provided by the Requester, which has knowledge of upcoming
Request patterns, and which the Completer would not be able to deduce
autonomously (with good accuracy)

Yishai

Signed-off-by: Leon Romanovsky <leon@kernel.org>
* mlx5-next:
  net/mlx5: Add support for device steering tag
  net/mlx5: Expose IFC bits for TPH
  PCI/TPH: Expose pcie_tph_get_st_table_size()
  net/mlx5: Expose cable_length field in PFCC register
  net/mlx5: Add IFC bits and enums for buf_ownership
  net/mlx5: Add IFC bits to support RSS for IPSec offload
  net/mlx5: IFC updates for disabled host PF
  net/mlx5: Expose disciplined_fr_counter through HCA capabilities in mlx5_ifc

5 weeks agonet/mlx5: Add support for device steering tag
Yishai Hadas [Thu, 17 Jul 2025 12:17:27 +0000 (15:17 +0300)] 
net/mlx5: Add support for device steering tag

Background, from PCIe specification 6.2.

TLP Processing Hints (TPH)
--------------------------
TLP Processing Hints is an optional feature that provides hints in
Request TLP headers to facilitate optimized processing of Requests that
target Memory Space. These Processing Hints enable the system hardware
(e.g., the Root Complex and/or Endpoints) to optimize platform
resources such as system and memory interconnect on a per TLP basis.
Steering Tags are system-specific values used to identify a processing
resource that a Requester explicitly targets. System software discovers
and identifies TPH capabilities to determine the Steering Tag allocation
for each Function that supports TPH.

This patch adds steering tag support for mlx5 based NICs by:

- Enabling the TPH functionality over PCI if both FW and OS support it.
- Managing steering tags and their matching steering indexes by
  writing a ST to an ST index over the PCI configuration space.
- Exposing APIs to upper layers (e.g.,mlx5_ib) to allow usage of
  the PCI TPH infrastructure.

Further details:
- Upon probing of a device, the feature will be enabled based
  on both capability detection and OS support.

- It will retrieve the appropriate ST for a given CPU ID and memory
  type using the pcie_tph_get_cpu_st() API.

- It will track available ST indices according to the configuration
  space table size (expected to be 63 entries), reserving index 0 to
  indicate non-TPH use.

- It will assign a free ST index with a ST using the
  pcie_tph_set_st_entry() API.

- It will reuse the same index for identical (CPU ID + memory type)
  combinations by maintaining a reference count per entry.

- It will expose APIs to upper layers (e.g., mlx5_ib) to allow usage of
  the PCI TPH infrastructure.

- SF will use its parent PF stuff.

Signed-off-by: Yishai Hadas <yishaih@nvidia.com>
Link: https://patch.msgid.link/de1ae7398e9e34eacd8c10845683df44fc9e32f8.1752752567.git.leon@kernel.org
Signed-off-by: Leon Romanovsky <leon@kernel.org>
5 weeks agonet/mlx5: Expose IFC bits for TPH
Yishai Hadas [Thu, 17 Jul 2025 12:17:26 +0000 (15:17 +0300)] 
net/mlx5: Expose IFC bits for TPH

Expose IFC bits for the TPH functionality.

Signed-off-by: Yishai Hadas <yishaih@nvidia.com>
Reviewed-by: Edward Srouji <edwards@nvidia.com>
Reviewed-by: Moshe Shemesh <moshe@nvidia.com>
Link: https://patch.msgid.link/38ea3a0d56551364214e8edf359c9c77c9a3b71b.1752752567.git.leon@kernel.org
Signed-off-by: Leon Romanovsky <leon@kernel.org>
5 weeks agoPCI/TPH: Expose pcie_tph_get_st_table_size()
Yishai Hadas [Thu, 17 Jul 2025 12:17:25 +0000 (15:17 +0300)] 
PCI/TPH: Expose pcie_tph_get_st_table_size()

Expose pcie_tph_get_st_table_size() to be used by drivers as will be
done in the next patch from the series.

Signed-off-by: Yishai Hadas <yishaih@nvidia.com>
Acked-by: Bjorn Helgaas <bhelgaas@google.com>
Link: https://patch.msgid.link/9ae851e0ee42cc56d2a30276e116b65091030ceb.1752752567.git.leon@kernel.org
Signed-off-by: Leon Romanovsky <leon@kernel.org>
5 weeks agodt-bindings: display: sprd,sharkl3-dsi-host: Fix missing clocks constraints
Krzysztof Kozlowski [Sun, 20 Jul 2025 12:30:05 +0000 (14:30 +0200)] 
dt-bindings: display: sprd,sharkl3-dsi-host: Fix missing clocks constraints

'minItems' alone does not impose upper bound, unlike 'maxItems' which
implies lower bound.  Add missing clock constraint so the list will have
exact number of items (clocks).

Fixes: 2295bbd35edb ("dt-bindings: display: add Unisoc's mipi dsi controller bindings")
Cc: stable@vger.kernel.org
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Link: https://lore.kernel.org/r/20250720123003.37662-4-krzysztof.kozlowski@linaro.org
Signed-off-by: Rob Herring (Arm) <robh@kernel.org>
5 weeks agodt-bindings: display: sprd,sharkl3-dpu: Fix missing clocks constraints
Krzysztof Kozlowski [Sun, 20 Jul 2025 12:30:04 +0000 (14:30 +0200)] 
dt-bindings: display: sprd,sharkl3-dpu: Fix missing clocks constraints

'minItems' alone does not impose upper bound, unlike 'maxItems' which
implies lower bound.  Add missing clock constraint so the list will have
exact number of items (clocks).

Fixes: 8cae15c60cf0 ("dt-bindings: display: add Unisoc's dpu bindings")
Cc: stable@vger.kernel.org
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Link: https://lore.kernel.org/r/20250720123003.37662-3-krzysztof.kozlowski@linaro.org
Signed-off-by: Rob Herring (Arm) <robh@kernel.org>
5 weeks agodt-bindings: display: imx: convert fsl,dcu.txt to yaml format
Frank Li [Mon, 16 Jun 2025 18:24:38 +0000 (14:24 -0400)] 
dt-bindings: display: imx: convert fsl,dcu.txt to yaml format

Convert fsl,dcu.txt to yaml format.

Additional changes:
- remove label in example.
- change node to display-controller in example.
- use 32bit address in example.
- add interrupts property.

Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Frank Li <Frank.Li@nxp.com>
Reviewed-by: Stefan Agner <stefan@agner.ch>
Link: https://lore.kernel.org/r/20250616182439.1989840-1-Frank.Li@nxp.com
Signed-off-by: Rob Herring (Arm) <robh@kernel.org>
5 weeks agodt-bindings: timer: via,vt8500-timer: Convert to YAML
Alexey Charkov [Wed, 21 May 2025 13:00:09 +0000 (17:00 +0400)] 
dt-bindings: timer: via,vt8500-timer: Convert to YAML

Rewrite the textual description for the VIA/WonderMedia timer
as YAML schema.

The IP can generate up to four interrupts from four respective match
registers, so reflect that in the schema.

Reviewed-by: Rob Herring (Arm) <robh@kernel.org>
Signed-off-by: Alexey Charkov <alchark@gmail.com>
Link: https://lore.kernel.org/r/20250521-vt8500-timer-updates-v5-1-7e4bd11df72e@gmail.com
Signed-off-by: Rob Herring (Arm) <robh@kernel.org>
5 weeks agodt-bindings: net: Convert Marvell Armada NETA and BM to DT schema
Rob Herring (Arm) [Wed, 2 Jul 2025 22:26:24 +0000 (17:26 -0500)] 
dt-bindings: net: Convert Marvell Armada NETA and BM to DT schema

Convert Marvell Armada NETA Ethernet Controller and Buffer Manager
bindings to schema. It is a straight forward conversion.

Link: https://lore.kernel.org/r/20250702222626.2761199-1-robh@kernel.org
Signed-off-by: Rob Herring (Arm) <robh@kernel.org>
5 weeks agoplatform/chrome: cros_ec_typec: Check ec platform device pointer
Tomasz Michalec [Tue, 22 Jul 2025 13:28:26 +0000 (15:28 +0200)] 
platform/chrome: cros_ec_typec: Check ec platform device pointer

It is possible that parent device for cros_ec_typec device is already
available, but ec pointer in parent driver data isn't populated yet. It
may happen when cros_typec_probe is running in parallel with
cros_ec_register. This leads to NULL pointer dereference when
cros_typec_probe tries to get driver data from typec->ec->ec->dev.

Check if typec->ec->ec is set before using it in cros_typec_probe.

Signed-off-by: Tomasz Michalec <tmichalec@google.com>
Link: https://lore.kernel.org/r/20250722132826.707087-1-tmichalec@google.com
Signed-off-by: Tzung-Bi Shih <tzungbi@kernel.org>
5 weeks agoplatform/chrome: cros_ec: Unregister notifier in cros_ec_unregister()
Tzung-Bi Shih [Tue, 22 Jul 2025 12:05:13 +0000 (12:05 +0000)] 
platform/chrome: cros_ec: Unregister notifier in cros_ec_unregister()

The blocking notifier is registered in cros_ec_register(); however, it
isn't unregistered in cros_ec_unregister().

Fix it.

Fixes: 42cd0ab476e2 ("platform/chrome: cros_ec: Query EC protocol version if EC transitions between RO/RW")
Cc: stable@vger.kernel.org
Reviewed-by: Benson Leung <bleung@chromium.org>
Link: https://lore.kernel.org/r/20250722120513.234031-1-tzungbi@kernel.org
Signed-off-by: Tzung-Bi Shih <tzungbi@kernel.org>
5 weeks agoarm64: defconfig: Enable rudimentary Sophgo SG2000 support
Alexander Sverdlin [Thu, 12 Jun 2025 13:28:14 +0000 (15:28 +0200)] 
arm64: defconfig: Enable rudimentary Sophgo SG2000 support

Enable ARCH_SOPHGO, pinctrl (built-in, required to boot), ADC as module.
This defconfig is able to boot from SD card on Milk-V Duo Module 01
evalboard.

Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Reviewed-by: Inochi Amaoto <inochiama@gmail.com>
Signed-off-by: Alexander Sverdlin <alexander.sverdlin@gmail.com>
Link: https://lore.kernel.org/r/20250612132844.767216-7-alexander.sverdlin@gmail.com
Signed-off-by: Inochi Amaoto <inochiama@gmail.com>
Signed-off-by: Chen Wang <unicorn_wang@outlook.com>
Signed-off-by: Chen Wang <wangchen20@iscas.ac.cn>
5 weeks agoarm64: Add SOPHGO SOC family Kconfig support
Alexander Sverdlin [Thu, 12 Jun 2025 13:28:13 +0000 (15:28 +0200)] 
arm64: Add SOPHGO SOC family Kconfig support

First user will be Aarch64 core within SG2000 SoC.

Reviewed-by: Chen Wang <unicorn_wang@outlook.com>
Reviewed-by: Inochi Amaoto <inochiama@gmail.com>
Signed-off-by: Alexander Sverdlin <alexander.sverdlin@gmail.com>
Link: https://lore.kernel.org/r/20250612132844.767216-6-alexander.sverdlin@gmail.com
Signed-off-by: Inochi Amaoto <inochiama@gmail.com>
Signed-off-by: Chen Wang <unicorn_wang@outlook.com>
Signed-off-by: Chen Wang <wangchen20@iscas.ac.cn>
5 weeks agoarm64: dts: sophgo: Add Duo Module 01 Evaluation Board
Alexander Sverdlin [Thu, 12 Jun 2025 13:28:12 +0000 (15:28 +0200)] 
arm64: dts: sophgo: Add Duo Module 01 Evaluation Board

Duo Module 01 Evaluation Board contains Sophgo Duo Module 01
SMD SoM, Ethernet+USB switch, microSD slot, etc...
Add only support for UART0 (console) and microSD slot.

Signed-off-by: Alexander Sverdlin <alexander.sverdlin@gmail.com>
Reviewed-by: Inochi Amaoto <inochiama@gmail.com>
Link: https://lore.kernel.org/r/20250612132844.767216-5-alexander.sverdlin@gmail.com
Signed-off-by: Inochi Amaoto <inochiama@gmail.com>
Signed-off-by: Chen Wang <unicorn_wang@outlook.com>
Signed-off-by: Chen Wang <wangchen20@iscas.ac.cn>
5 weeks agoarm64: dts: sophgo: Add Duo Module 01
Alexander Sverdlin [Thu, 12 Jun 2025 13:28:11 +0000 (15:28 +0200)] 
arm64: dts: sophgo: Add Duo Module 01

The Duo Module 01 is a compact module with integrated SG2000,
WI-FI6/BTDM5.4, and eMMC.
Add only support for UART and SDHCI.

Signed-off-by: Alexander Sverdlin <alexander.sverdlin@gmail.com>
Reviewed-by: Inochi Amaoto <inochiama@gmail.com>
Link: https://lore.kernel.org/r/20250612132844.767216-4-alexander.sverdlin@gmail.com
Signed-off-by: Inochi Amaoto <inochiama@gmail.com>
Signed-off-by: Chen Wang <unicorn_wang@outlook.com>
Signed-off-by: Chen Wang <wangchen20@iscas.ac.cn>
5 weeks agoarm64: dts: sophgo: Add initial SG2000 SoC device tree
Alexander Sverdlin [Thu, 12 Jun 2025 13:28:10 +0000 (15:28 +0200)] 
arm64: dts: sophgo: Add initial SG2000 SoC device tree

Add initial device tree for the SG2000 SoC by SOPHGO (from ARM64 PoV).

Reviewed-by: Inochi Amaoto <inochiama@gmail.com>
Signed-off-by: Alexander Sverdlin <alexander.sverdlin@gmail.com>
Link: https://lore.kernel.org/r/20250612132844.767216-3-alexander.sverdlin@gmail.com
Signed-off-by: Inochi Amaoto <inochiama@gmail.com>
Signed-off-by: Chen Wang <unicorn_wang@outlook.com>
Signed-off-by: Chen Wang <wangchen20@iscas.ac.cn>
5 weeks agoriscv: dts: sophgo: fix mdio node name for CV180X
Inochi Amaoto [Tue, 15 Jul 2025 22:13:48 +0000 (06:13 +0800)] 
riscv: dts: sophgo: fix mdio node name for CV180X

As the mdio multipledxer is marked as mdio device, the check complains
the mdio bus number exceed the maximum.

Change the node name to mdio-mux to remove the following warnings:
mdio@3009800 (mdio-mux-mmioreg): mdio@80:reg:0:0: 128 is greater than
the maximum of 31

Fixes: b7945143bc33 ("riscv: dts: sophgo: Add mdio multiplexer device for cv18xx")
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202507140738.XRjv3G8i-lkp@intel.com/
Closes: https://lore.kernel.org/oe-kbuild-all/202507121830.POx2KDVi-lkp@intel.com/
Reviewed-by: Alexander Sverdlin <alexander.sverdlin@gmail.com>
Link: https://lore.kernel.org/r/20250715221349.11034-1-inochiama@gmail.com
Signed-off-by: Inochi Amaoto <inochiama@gmail.com>
Signed-off-by: Chen Wang <unicorn_wang@outlook.com>
Signed-off-by: Chen Wang <wangchen20@iscas.ac.cn>
5 weeks agoriscv: dts: sophgo: sophgo-srd3-10: reserve uart0 device
Inochi Amaoto [Thu, 3 Jul 2025 00:40:23 +0000 (08:40 +0800)] 
riscv: dts: sophgo: sophgo-srd3-10: reserve uart0 device

As the uart0 is already occupied by the firmware, reserve it
to avoid this port is used by mistake.

Tested-by: Han Gao <rabenda.cn@gmail.com>
Reviewed-by: Chen Wang <wangchen20@iscas.ac.cn>
Link: https://lore.kernel.org/r/20250703004024.85221-1-inochiama@gmail.com
Signed-off-by: Inochi Amaoto <inochiama@gmail.com>
Signed-off-by: Chen Wang <unicorn_wang@outlook.com>
Signed-off-by: Chen Wang <wangchen20@iscas.ac.cn>
5 weeks agoriscv: dts: sophgo: add Sophgo SG2042_EVB_V2.0 board device tree
Han Gao [Sat, 5 Jul 2025 07:39:56 +0000 (15:39 +0800)] 
riscv: dts: sophgo: add Sophgo SG2042_EVB_V2.0 board device tree

Sophgo SG2042_EVB_V2.0 [1] is a prototype development board based on SG2042

Currently supports serial port, sdcard/emmc, pwm, fan speed control.

Link: https://github.com/sophgo/sophgo-hardware/tree/master/SG2042/SG2042-x4-EVB
Signed-off-by: Han Gao <rabenda.cn@gmail.com>
Reviewed-by: Nutty Liu <liujingqi@lanxincomputing.com>
Reviewed-by: Chen Wang <unicorn_wang@outlook.com>
Link: https://lore.kernel.org/r/c1b6ccdc69af0c1457fc1486a6bc8a1e83671537.1751700954.git.rabenda.cn@gmail.com
Signed-off-by: Inochi Amaoto <inochiama@gmail.com>
Signed-off-by: Chen Wang <unicorn_wang@outlook.com>
Signed-off-by: Chen Wang <wangchen20@iscas.ac.cn>
5 weeks agoriscv: dts: sophgo: add Sophgo SG2042_EVB_V1.X board device tree
Han Gao [Sat, 5 Jul 2025 07:39:55 +0000 (15:39 +0800)] 
riscv: dts: sophgo: add Sophgo SG2042_EVB_V1.X board device tree

Sophgo SG2042_EVB_V1.X [1] is a prototype development board based on SG2042

Currently supports serial port, sdcard/emmc, pwm, fan speed control.

Link: https://github.com/sophgo/sophgo-hardware/tree/master/SG2042/SG2042-x8-EVB
Signed-off-by: Han Gao <rabenda.cn@gmail.com>
Reviewed-by: Nutty Liu <liujingqi@lanxincomputing.com>
Reviewed-by: Chen Wang <unicorn_wang@outlook.com>
Link: https://lore.kernel.org/r/27091134ce1f8a6541a349afc324d6f7402ea606.1751700954.git.rabenda.cn@gmail.com
Signed-off-by: Inochi Amaoto <inochiama@gmail.com>
Signed-off-by: Chen Wang <unicorn_wang@outlook.com>
Signed-off-by: Chen Wang <wangchen20@iscas.ac.cn>