From c87ec4ff8035edf5a195bdbf286ae4d910d3499b Mon Sep 17 00:00:00 2001 From: Sasha Levin Date: Thu, 27 Nov 2025 07:25:16 -0500 Subject: [PATCH] Fixes for all trees Signed-off-by: Sasha Levin --- ...ix-uac2-clock-source-at-terminal-par.patch | 47 +++++ ...netcp-standardize-knav_dma_open_chan.patch | 168 ++++++++++++++++++ queue-5.10/series | 2 + ...ix-uac2-clock-source-at-terminal-par.patch | 47 +++++ ...netcp-standardize-knav_dma_open_chan.patch | 168 ++++++++++++++++++ queue-5.15/series | 3 + ...x-incorrcet-short-option-in-usage-te.patch | 43 +++++ ...ix-uac2-clock-source-at-terminal-par.patch | 47 +++++ ...netcp-standardize-knav_dma_open_chan.patch | 168 ++++++++++++++++++ queue-5.4/series | 2 + ...ix-uac2-clock-source-at-terminal-par.patch | 47 +++++ ...netcp-standardize-knav_dma_open_chan.patch | 168 ++++++++++++++++++ queue-6.1/series | 3 + ...x-incorrcet-short-option-in-usage-te.patch | 43 +++++ ...ix-uac2-clock-source-at-terminal-par.patch | 47 +++++ ...pu-page-fault-after-hibernation-on-p.patch | 65 +++++++ ...netcp-standardize-knav_dma_open_chan.patch | 168 ++++++++++++++++++ queue-6.12/series | 4 + ...x-incorrcet-short-option-in-usage-te.patch | 43 +++++ ...ix-uac2-clock-source-at-terminal-par.patch | 47 +++++ ...flag-btrfs_inode_copy_everything-whe.patch | 83 +++++++++ ...pu-page-fault-after-hibernation-on-p.patch | 65 +++++++ ...netcp-standardize-knav_dma_open_chan.patch | 168 ++++++++++++++++++ ...m-fix-ufs-ocp-issue-during-ufs-power.patch | 85 +++++++++ queue-6.17/series | 6 + ...x-incorrcet-short-option-in-usage-te.patch | 43 +++++ ...ix-uac2-clock-source-at-terminal-par.patch | 47 +++++ ...netcp-standardize-knav_dma_open_chan.patch | 168 ++++++++++++++++++ queue-6.6/series | 3 + ...x-incorrcet-short-option-in-usage-te.patch | 43 +++++ 30 files changed, 2041 insertions(+) create mode 100644 queue-5.10/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch create mode 100644 queue-5.10/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch create mode 100644 queue-5.15/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch create mode 100644 queue-5.15/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch create mode 100644 queue-5.15/tracing-tools-fix-incorrcet-short-option-in-usage-te.patch create mode 100644 queue-5.4/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch create mode 100644 queue-5.4/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch create mode 100644 queue-6.1/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch create mode 100644 queue-6.1/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch create mode 100644 queue-6.1/tracing-tools-fix-incorrcet-short-option-in-usage-te.patch create mode 100644 queue-6.12/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch create mode 100644 queue-6.12/drm-amdgpu-fix-gpu-page-fault-after-hibernation-on-p.patch create mode 100644 queue-6.12/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch create mode 100644 queue-6.12/tracing-tools-fix-incorrcet-short-option-in-usage-te.patch create mode 100644 queue-6.17/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch create mode 100644 queue-6.17/btrfs-set-inode-flag-btrfs_inode_copy_everything-whe.patch create mode 100644 queue-6.17/drm-amdgpu-fix-gpu-page-fault-after-hibernation-on-p.patch create mode 100644 queue-6.17/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch create mode 100644 queue-6.17/scsi-ufs-ufs-qcom-fix-ufs-ocp-issue-during-ufs-power.patch create mode 100644 queue-6.17/tracing-tools-fix-incorrcet-short-option-in-usage-te.patch create mode 100644 queue-6.6/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch create mode 100644 queue-6.6/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch create mode 100644 queue-6.6/tracing-tools-fix-incorrcet-short-option-in-usage-te.patch diff --git a/queue-5.10/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch b/queue-5.10/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch new file mode 100644 index 0000000000..7512d1fbba --- /dev/null +++ b/queue-5.10/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch @@ -0,0 +1,47 @@ +From 66f8f74e4bdbff4457fd6157c8c2d1afd8f89b0e Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Tue, 25 Nov 2025 15:41:49 +0100 +Subject: ALSA: usb-audio: fix uac2 clock source at terminal parser +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +From: René Rebe + +[ Upstream commit d26e9f669cc0a6a85cf17180c09a6686db9f4002 ] + +Since 8b3a087f7f65 ("ALSA: usb-audio: Unify virtual type units type to +UAC3 values") usb-audio is using UAC3_CLOCK_SOURCE instead of +bDescriptorSubtype, later refactored with e0ccdef9265 ("ALSA: usb-audio: +Clean up check_input_term()") into parse_term_uac2_clock_source(). + +This breaks the clock source selection for at least my +1397:0003 BEHRINGER International GmbH FCA610 Pro. + +Fix by using UAC2_CLOCK_SOURCE in parse_term_uac2_clock_source(). + +Fixes: 8b3a087f7f65 ("ALSA: usb-audio: Unify virtual type units type to UAC3 values") +Signed-off-by: René Rebe +Link: https://patch.msgid.link/20251125.154149.1121389544970412061.rene@exactco.de +Signed-off-by: Takashi Iwai +Signed-off-by: Sasha Levin +--- + sound/usb/mixer.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/sound/usb/mixer.c b/sound/usb/mixer.c +index 6b9a472ea43cb..949b171377267 100644 +--- a/sound/usb/mixer.c ++++ b/sound/usb/mixer.c +@@ -925,7 +925,7 @@ static int parse_term_uac2_clock_source(struct mixer_build *state, + { + struct uac_clock_source_descriptor *d = p1; + +- term->type = UAC3_CLOCK_SOURCE << 16; /* virtual type */ ++ term->type = UAC2_CLOCK_SOURCE << 16; /* virtual type */ + term->id = id; + term->name = d->iClockSource; + return 0; +-- +2.51.0 + diff --git a/queue-5.10/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch b/queue-5.10/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch new file mode 100644 index 0000000000..2c251c31dd --- /dev/null +++ b/queue-5.10/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch @@ -0,0 +1,168 @@ +From ebcc35cfb2aba43499b187f57967ebaa31bdf134 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Mon, 3 Nov 2025 10:28:11 -0600 +Subject: net: ethernet: ti: netcp: Standardize knav_dma_open_channel to return + NULL on error + +From: Nishanth Menon + +[ Upstream commit 90a88306eb874fe4bbdd860e6c9787f5bbc588b5 ] + +Make knav_dma_open_channel consistently return NULL on error instead +of ERR_PTR. Currently the header include/linux/soc/ti/knav_dma.h +returns NULL when the driver is disabled, but the driver +implementation does not even return NULL or ERR_PTR on failure, +causing inconsistency in the users. This results in a crash in +netcp_free_navigator_resources as followed (trimmed): + +Unhandled fault: alignment exception (0x221) at 0xfffffff2 +[fffffff2] *pgd=80000800207003, *pmd=82ffda003, *pte=00000000 +Internal error: : 221 [#1] SMP ARM +Modules linked in: +CPU: 0 UID: 0 PID: 1 Comm: swapper/0 Not tainted 6.17.0-rc7 #1 NONE +Hardware name: Keystone +PC is at knav_dma_close_channel+0x30/0x19c +LR is at netcp_free_navigator_resources+0x2c/0x28c + +[... TRIM...] + +Call trace: + knav_dma_close_channel from netcp_free_navigator_resources+0x2c/0x28c + netcp_free_navigator_resources from netcp_ndo_open+0x430/0x46c + netcp_ndo_open from __dev_open+0x114/0x29c + __dev_open from __dev_change_flags+0x190/0x208 + __dev_change_flags from netif_change_flags+0x1c/0x58 + netif_change_flags from dev_change_flags+0x38/0xa0 + dev_change_flags from ip_auto_config+0x2c4/0x11f0 + ip_auto_config from do_one_initcall+0x58/0x200 + do_one_initcall from kernel_init_freeable+0x1cc/0x238 + kernel_init_freeable from kernel_init+0x1c/0x12c + kernel_init from ret_from_fork+0x14/0x38 +[... TRIM...] + +Standardize the error handling by making the function return NULL on +all error conditions. The API is used in just the netcp_core.c so the +impact is limited. + +Note, this change, in effect reverts commit 5b6cb43b4d62 ("net: +ethernet: ti: netcp_core: return error while dma channel open issue"), +but provides a less error prone implementation. + +Suggested-by: Simon Horman +Suggested-by: Jacob Keller +Signed-off-by: Nishanth Menon +Reviewed-by: Jacob Keller +Link: https://patch.msgid.link/20251103162811.3730055-1-nm@ti.com +Signed-off-by: Jakub Kicinski +Signed-off-by: Sasha Levin +--- + drivers/net/ethernet/ti/netcp_core.c | 10 +++++----- + drivers/soc/ti/knav_dma.c | 14 +++++++------- + 2 files changed, 12 insertions(+), 12 deletions(-) + +diff --git a/drivers/net/ethernet/ti/netcp_core.c b/drivers/net/ethernet/ti/netcp_core.c +index f145abb77a497..77dd20431c447 100644 +--- a/drivers/net/ethernet/ti/netcp_core.c ++++ b/drivers/net/ethernet/ti/netcp_core.c +@@ -1339,10 +1339,10 @@ int netcp_txpipe_open(struct netcp_tx_pipe *tx_pipe) + + tx_pipe->dma_channel = knav_dma_open_channel(dev, + tx_pipe->dma_chan_name, &config); +- if (IS_ERR(tx_pipe->dma_channel)) { ++ if (!tx_pipe->dma_channel) { + dev_err(dev, "failed opening tx chan(%s)\n", + tx_pipe->dma_chan_name); +- ret = PTR_ERR(tx_pipe->dma_channel); ++ ret = -EINVAL; + goto err; + } + +@@ -1360,7 +1360,7 @@ int netcp_txpipe_open(struct netcp_tx_pipe *tx_pipe) + return 0; + + err: +- if (!IS_ERR_OR_NULL(tx_pipe->dma_channel)) ++ if (tx_pipe->dma_channel) + knav_dma_close_channel(tx_pipe->dma_channel); + tx_pipe->dma_channel = NULL; + return ret; +@@ -1679,10 +1679,10 @@ static int netcp_setup_navigator_resources(struct net_device *ndev) + + netcp->rx_channel = knav_dma_open_channel(netcp->netcp_device->device, + netcp->dma_chan_name, &config); +- if (IS_ERR(netcp->rx_channel)) { ++ if (!netcp->rx_channel) { + dev_err(netcp->ndev_dev, "failed opening rx chan(%s\n", + netcp->dma_chan_name); +- ret = PTR_ERR(netcp->rx_channel); ++ ret = -EINVAL; + goto fail; + } + +diff --git a/drivers/soc/ti/knav_dma.c b/drivers/soc/ti/knav_dma.c +index 56597f6ea666a..a677e874de543 100644 +--- a/drivers/soc/ti/knav_dma.c ++++ b/drivers/soc/ti/knav_dma.c +@@ -410,7 +410,7 @@ static int of_channel_match_helper(struct device_node *np, const char *name, + * @name: slave channel name + * @config: dma configuration parameters + * +- * Returns pointer to appropriate DMA channel on success or error. ++ * Return: Pointer to appropriate DMA channel on success or NULL on error. + */ + void *knav_dma_open_channel(struct device *dev, const char *name, + struct knav_dma_cfg *config) +@@ -423,13 +423,13 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + + if (!kdev) { + pr_err("keystone-navigator-dma driver not registered\n"); +- return (void *)-EINVAL; ++ return NULL; + } + + chan_num = of_channel_match_helper(dev->of_node, name, &instance); + if (chan_num < 0) { + dev_err(kdev->dev, "No DMA instance with name %s\n", name); +- return (void *)-EINVAL; ++ return NULL; + } + + dev_dbg(kdev->dev, "initializing %s channel %d from DMA %s\n", +@@ -440,7 +440,7 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + if (config->direction != DMA_MEM_TO_DEV && + config->direction != DMA_DEV_TO_MEM) { + dev_err(kdev->dev, "bad direction\n"); +- return (void *)-EINVAL; ++ return NULL; + } + + /* Look for correct dma instance */ +@@ -452,7 +452,7 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + } + if (!found) { + dev_err(kdev->dev, "No DMA instance with name %s\n", instance); +- return (void *)-EINVAL; ++ return NULL; + } + + /* Look for correct dma channel from dma instance */ +@@ -473,14 +473,14 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + if (!found) { + dev_err(kdev->dev, "channel %d is not in DMA %s\n", + chan_num, instance); +- return (void *)-EINVAL; ++ return NULL; + } + + if (atomic_read(&chan->ref_count) >= 1) { + if (!check_config(chan, config)) { + dev_err(kdev->dev, "channel %d config miss-match\n", + chan_num); +- return (void *)-EINVAL; ++ return NULL; + } + } + +-- +2.51.0 + diff --git a/queue-5.10/series b/queue-5.10/series index 60f6d285d2..c13a107660 100644 --- a/queue-5.10/series +++ b/queue-5.10/series @@ -233,3 +233,5 @@ net-tls-cancel-rx-async-resync-request-on-rcd_delta-.patch kconfig-mconf-initialize-the-default-locale-at-start.patch kconfig-nconf-initialize-the-default-locale-at-start.patch mm-mm_init-fix-hash-table-order-logging-in-alloc_lar.patch +alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch +net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch diff --git a/queue-5.15/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch b/queue-5.15/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch new file mode 100644 index 0000000000..79e7c3ded4 --- /dev/null +++ b/queue-5.15/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch @@ -0,0 +1,47 @@ +From 4ebac835388b24bd8cf7e4a080047c003b67658b Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Tue, 25 Nov 2025 15:41:49 +0100 +Subject: ALSA: usb-audio: fix uac2 clock source at terminal parser +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +From: René Rebe + +[ Upstream commit d26e9f669cc0a6a85cf17180c09a6686db9f4002 ] + +Since 8b3a087f7f65 ("ALSA: usb-audio: Unify virtual type units type to +UAC3 values") usb-audio is using UAC3_CLOCK_SOURCE instead of +bDescriptorSubtype, later refactored with e0ccdef9265 ("ALSA: usb-audio: +Clean up check_input_term()") into parse_term_uac2_clock_source(). + +This breaks the clock source selection for at least my +1397:0003 BEHRINGER International GmbH FCA610 Pro. + +Fix by using UAC2_CLOCK_SOURCE in parse_term_uac2_clock_source(). + +Fixes: 8b3a087f7f65 ("ALSA: usb-audio: Unify virtual type units type to UAC3 values") +Signed-off-by: René Rebe +Link: https://patch.msgid.link/20251125.154149.1121389544970412061.rene@exactco.de +Signed-off-by: Takashi Iwai +Signed-off-by: Sasha Levin +--- + sound/usb/mixer.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/sound/usb/mixer.c b/sound/usb/mixer.c +index de80240d9ed58..5cc97982ab82e 100644 +--- a/sound/usb/mixer.c ++++ b/sound/usb/mixer.c +@@ -931,7 +931,7 @@ static int parse_term_uac2_clock_source(struct mixer_build *state, + { + struct uac_clock_source_descriptor *d = p1; + +- term->type = UAC3_CLOCK_SOURCE << 16; /* virtual type */ ++ term->type = UAC2_CLOCK_SOURCE << 16; /* virtual type */ + term->id = id; + term->name = d->iClockSource; + return 0; +-- +2.51.0 + diff --git a/queue-5.15/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch b/queue-5.15/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch new file mode 100644 index 0000000000..c8d39874c9 --- /dev/null +++ b/queue-5.15/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch @@ -0,0 +1,168 @@ +From dbd400746e605a4387a8afafea8a7eb2ad2d4207 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Mon, 3 Nov 2025 10:28:11 -0600 +Subject: net: ethernet: ti: netcp: Standardize knav_dma_open_channel to return + NULL on error + +From: Nishanth Menon + +[ Upstream commit 90a88306eb874fe4bbdd860e6c9787f5bbc588b5 ] + +Make knav_dma_open_channel consistently return NULL on error instead +of ERR_PTR. Currently the header include/linux/soc/ti/knav_dma.h +returns NULL when the driver is disabled, but the driver +implementation does not even return NULL or ERR_PTR on failure, +causing inconsistency in the users. This results in a crash in +netcp_free_navigator_resources as followed (trimmed): + +Unhandled fault: alignment exception (0x221) at 0xfffffff2 +[fffffff2] *pgd=80000800207003, *pmd=82ffda003, *pte=00000000 +Internal error: : 221 [#1] SMP ARM +Modules linked in: +CPU: 0 UID: 0 PID: 1 Comm: swapper/0 Not tainted 6.17.0-rc7 #1 NONE +Hardware name: Keystone +PC is at knav_dma_close_channel+0x30/0x19c +LR is at netcp_free_navigator_resources+0x2c/0x28c + +[... TRIM...] + +Call trace: + knav_dma_close_channel from netcp_free_navigator_resources+0x2c/0x28c + netcp_free_navigator_resources from netcp_ndo_open+0x430/0x46c + netcp_ndo_open from __dev_open+0x114/0x29c + __dev_open from __dev_change_flags+0x190/0x208 + __dev_change_flags from netif_change_flags+0x1c/0x58 + netif_change_flags from dev_change_flags+0x38/0xa0 + dev_change_flags from ip_auto_config+0x2c4/0x11f0 + ip_auto_config from do_one_initcall+0x58/0x200 + do_one_initcall from kernel_init_freeable+0x1cc/0x238 + kernel_init_freeable from kernel_init+0x1c/0x12c + kernel_init from ret_from_fork+0x14/0x38 +[... TRIM...] + +Standardize the error handling by making the function return NULL on +all error conditions. The API is used in just the netcp_core.c so the +impact is limited. + +Note, this change, in effect reverts commit 5b6cb43b4d62 ("net: +ethernet: ti: netcp_core: return error while dma channel open issue"), +but provides a less error prone implementation. + +Suggested-by: Simon Horman +Suggested-by: Jacob Keller +Signed-off-by: Nishanth Menon +Reviewed-by: Jacob Keller +Link: https://patch.msgid.link/20251103162811.3730055-1-nm@ti.com +Signed-off-by: Jakub Kicinski +Signed-off-by: Sasha Levin +--- + drivers/net/ethernet/ti/netcp_core.c | 10 +++++----- + drivers/soc/ti/knav_dma.c | 14 +++++++------- + 2 files changed, 12 insertions(+), 12 deletions(-) + +diff --git a/drivers/net/ethernet/ti/netcp_core.c b/drivers/net/ethernet/ti/netcp_core.c +index 2f00be789a8a9..08c6cb16532e5 100644 +--- a/drivers/net/ethernet/ti/netcp_core.c ++++ b/drivers/net/ethernet/ti/netcp_core.c +@@ -1338,10 +1338,10 @@ int netcp_txpipe_open(struct netcp_tx_pipe *tx_pipe) + + tx_pipe->dma_channel = knav_dma_open_channel(dev, + tx_pipe->dma_chan_name, &config); +- if (IS_ERR(tx_pipe->dma_channel)) { ++ if (!tx_pipe->dma_channel) { + dev_err(dev, "failed opening tx chan(%s)\n", + tx_pipe->dma_chan_name); +- ret = PTR_ERR(tx_pipe->dma_channel); ++ ret = -EINVAL; + goto err; + } + +@@ -1359,7 +1359,7 @@ int netcp_txpipe_open(struct netcp_tx_pipe *tx_pipe) + return 0; + + err: +- if (!IS_ERR_OR_NULL(tx_pipe->dma_channel)) ++ if (tx_pipe->dma_channel) + knav_dma_close_channel(tx_pipe->dma_channel); + tx_pipe->dma_channel = NULL; + return ret; +@@ -1678,10 +1678,10 @@ static int netcp_setup_navigator_resources(struct net_device *ndev) + + netcp->rx_channel = knav_dma_open_channel(netcp->netcp_device->device, + netcp->dma_chan_name, &config); +- if (IS_ERR(netcp->rx_channel)) { ++ if (!netcp->rx_channel) { + dev_err(netcp->ndev_dev, "failed opening rx chan(%s\n", + netcp->dma_chan_name); +- ret = PTR_ERR(netcp->rx_channel); ++ ret = -EINVAL; + goto fail; + } + +diff --git a/drivers/soc/ti/knav_dma.c b/drivers/soc/ti/knav_dma.c +index 591d14ebcb112..bbde54b2ce62d 100644 +--- a/drivers/soc/ti/knav_dma.c ++++ b/drivers/soc/ti/knav_dma.c +@@ -410,7 +410,7 @@ static int of_channel_match_helper(struct device_node *np, const char *name, + * @name: slave channel name + * @config: dma configuration parameters + * +- * Returns pointer to appropriate DMA channel on success or error. ++ * Return: Pointer to appropriate DMA channel on success or NULL on error. + */ + void *knav_dma_open_channel(struct device *dev, const char *name, + struct knav_dma_cfg *config) +@@ -423,13 +423,13 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + + if (!kdev) { + pr_err("keystone-navigator-dma driver not registered\n"); +- return (void *)-EINVAL; ++ return NULL; + } + + chan_num = of_channel_match_helper(dev->of_node, name, &instance); + if (chan_num < 0) { + dev_err(kdev->dev, "No DMA instance with name %s\n", name); +- return (void *)-EINVAL; ++ return NULL; + } + + dev_dbg(kdev->dev, "initializing %s channel %d from DMA %s\n", +@@ -440,7 +440,7 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + if (config->direction != DMA_MEM_TO_DEV && + config->direction != DMA_DEV_TO_MEM) { + dev_err(kdev->dev, "bad direction\n"); +- return (void *)-EINVAL; ++ return NULL; + } + + /* Look for correct dma instance */ +@@ -452,7 +452,7 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + } + if (!found) { + dev_err(kdev->dev, "No DMA instance with name %s\n", instance); +- return (void *)-EINVAL; ++ return NULL; + } + + /* Look for correct dma channel from dma instance */ +@@ -473,14 +473,14 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + if (!found) { + dev_err(kdev->dev, "channel %d is not in DMA %s\n", + chan_num, instance); +- return (void *)-EINVAL; ++ return NULL; + } + + if (atomic_read(&chan->ref_count) >= 1) { + if (!check_config(chan, config)) { + dev_err(kdev->dev, "channel %d config miss-match\n", + chan_num); +- return (void *)-EINVAL; ++ return NULL; + } + } + +-- +2.51.0 + diff --git a/queue-5.15/series b/queue-5.15/series index eb98984699..b760837da2 100644 --- a/queue-5.15/series +++ b/queue-5.15/series @@ -308,3 +308,6 @@ kconfig-nconf-initialize-the-default-locale-at-start.patch mm-mm_init-fix-hash-table-order-logging-in-alloc_lar.patch mm-mprotect-use-long-for-page-accountings-and-retval.patch mm-secretmem-fix-use-after-free-race-in-fault-handle.patch +alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch +net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch +tracing-tools-fix-incorrcet-short-option-in-usage-te.patch diff --git a/queue-5.15/tracing-tools-fix-incorrcet-short-option-in-usage-te.patch b/queue-5.15/tracing-tools-fix-incorrcet-short-option-in-usage-te.patch new file mode 100644 index 0000000000..9c5e242ae1 --- /dev/null +++ b/queue-5.15/tracing-tools-fix-incorrcet-short-option-in-usage-te.patch @@ -0,0 +1,43 @@ +From 6cdded98a8837d52b4d2b776866be32e59e3ee80 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Thu, 6 Nov 2025 11:10:40 +0800 +Subject: tracing/tools: Fix incorrcet short option in usage text for --threads + +From: Zhang Chujun + +[ Upstream commit 53afec2c8fb2a562222948cb1c2aac48598578c9 ] + +The help message incorrectly listed '-t' as the short option for +--threads, but the actual getopt_long configuration uses '-e'. +This mismatch can confuse users and lead to incorrect command-line +usage. This patch updates the usage string to correctly show: + "-e, --threads NRTHR" +to match the implementation. + +Note: checkpatch.pl reports a false-positive spelling warning on +'Run', which is intentional. + +Link: https://patch.msgid.link/20251106031040.1869-1-zhangchujun@cmss.chinamobile.com +Signed-off-by: Zhang Chujun +Signed-off-by: Steven Rostedt (Google) +Signed-off-by: Sasha Levin +--- + tools/tracing/latency/latency-collector.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/tools/tracing/latency/latency-collector.c b/tools/tracing/latency/latency-collector.c +index f7ed8084e16ad..ec95b94f80e1f 100644 +--- a/tools/tracing/latency/latency-collector.c ++++ b/tools/tracing/latency/latency-collector.c +@@ -1725,7 +1725,7 @@ static void show_usage(void) + "-n, --notrace\t\tIf latency is detected, do not print out the content of\n" + "\t\t\tthe trace file to standard output\n\n" + +-"-t, --threads NRTHR\tRun NRTHR threads for printing. Default is %d.\n\n" ++"-e, --threads NRTHR\tRun NRTHR threads for printing. Default is %d.\n\n" + + "-r, --random\t\tArbitrarily sleep a certain amount of time, default\n" + "\t\t\t%ld ms, before reading the trace file. The\n" +-- +2.51.0 + diff --git a/queue-5.4/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch b/queue-5.4/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch new file mode 100644 index 0000000000..a32ec5f980 --- /dev/null +++ b/queue-5.4/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch @@ -0,0 +1,47 @@ +From eba2a11a9b8c4711b8a2c6cfb53a9743309b15ff Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Tue, 25 Nov 2025 15:41:49 +0100 +Subject: ALSA: usb-audio: fix uac2 clock source at terminal parser +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +From: René Rebe + +[ Upstream commit d26e9f669cc0a6a85cf17180c09a6686db9f4002 ] + +Since 8b3a087f7f65 ("ALSA: usb-audio: Unify virtual type units type to +UAC3 values") usb-audio is using UAC3_CLOCK_SOURCE instead of +bDescriptorSubtype, later refactored with e0ccdef9265 ("ALSA: usb-audio: +Clean up check_input_term()") into parse_term_uac2_clock_source(). + +This breaks the clock source selection for at least my +1397:0003 BEHRINGER International GmbH FCA610 Pro. + +Fix by using UAC2_CLOCK_SOURCE in parse_term_uac2_clock_source(). + +Fixes: 8b3a087f7f65 ("ALSA: usb-audio: Unify virtual type units type to UAC3 values") +Signed-off-by: René Rebe +Link: https://patch.msgid.link/20251125.154149.1121389544970412061.rene@exactco.de +Signed-off-by: Takashi Iwai +Signed-off-by: Sasha Levin +--- + sound/usb/mixer.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/sound/usb/mixer.c b/sound/usb/mixer.c +index 11a74cc0e94d8..d6dfa2b40067f 100644 +--- a/sound/usb/mixer.c ++++ b/sound/usb/mixer.c +@@ -914,7 +914,7 @@ static int parse_term_uac2_clock_source(struct mixer_build *state, + { + struct uac_clock_source_descriptor *d = p1; + +- term->type = UAC3_CLOCK_SOURCE << 16; /* virtual type */ ++ term->type = UAC2_CLOCK_SOURCE << 16; /* virtual type */ + term->id = id; + term->name = d->iClockSource; + return 0; +-- +2.51.0 + diff --git a/queue-5.4/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch b/queue-5.4/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch new file mode 100644 index 0000000000..3b4a1cd9ff --- /dev/null +++ b/queue-5.4/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch @@ -0,0 +1,168 @@ +From 990698a9ac3cb6792ef3605aa294115402ca80fa Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Mon, 3 Nov 2025 10:28:11 -0600 +Subject: net: ethernet: ti: netcp: Standardize knav_dma_open_channel to return + NULL on error + +From: Nishanth Menon + +[ Upstream commit 90a88306eb874fe4bbdd860e6c9787f5bbc588b5 ] + +Make knav_dma_open_channel consistently return NULL on error instead +of ERR_PTR. Currently the header include/linux/soc/ti/knav_dma.h +returns NULL when the driver is disabled, but the driver +implementation does not even return NULL or ERR_PTR on failure, +causing inconsistency in the users. This results in a crash in +netcp_free_navigator_resources as followed (trimmed): + +Unhandled fault: alignment exception (0x221) at 0xfffffff2 +[fffffff2] *pgd=80000800207003, *pmd=82ffda003, *pte=00000000 +Internal error: : 221 [#1] SMP ARM +Modules linked in: +CPU: 0 UID: 0 PID: 1 Comm: swapper/0 Not tainted 6.17.0-rc7 #1 NONE +Hardware name: Keystone +PC is at knav_dma_close_channel+0x30/0x19c +LR is at netcp_free_navigator_resources+0x2c/0x28c + +[... TRIM...] + +Call trace: + knav_dma_close_channel from netcp_free_navigator_resources+0x2c/0x28c + netcp_free_navigator_resources from netcp_ndo_open+0x430/0x46c + netcp_ndo_open from __dev_open+0x114/0x29c + __dev_open from __dev_change_flags+0x190/0x208 + __dev_change_flags from netif_change_flags+0x1c/0x58 + netif_change_flags from dev_change_flags+0x38/0xa0 + dev_change_flags from ip_auto_config+0x2c4/0x11f0 + ip_auto_config from do_one_initcall+0x58/0x200 + do_one_initcall from kernel_init_freeable+0x1cc/0x238 + kernel_init_freeable from kernel_init+0x1c/0x12c + kernel_init from ret_from_fork+0x14/0x38 +[... TRIM...] + +Standardize the error handling by making the function return NULL on +all error conditions. The API is used in just the netcp_core.c so the +impact is limited. + +Note, this change, in effect reverts commit 5b6cb43b4d62 ("net: +ethernet: ti: netcp_core: return error while dma channel open issue"), +but provides a less error prone implementation. + +Suggested-by: Simon Horman +Suggested-by: Jacob Keller +Signed-off-by: Nishanth Menon +Reviewed-by: Jacob Keller +Link: https://patch.msgid.link/20251103162811.3730055-1-nm@ti.com +Signed-off-by: Jakub Kicinski +Signed-off-by: Sasha Levin +--- + drivers/net/ethernet/ti/netcp_core.c | 10 +++++----- + drivers/soc/ti/knav_dma.c | 14 +++++++------- + 2 files changed, 12 insertions(+), 12 deletions(-) + +diff --git a/drivers/net/ethernet/ti/netcp_core.c b/drivers/net/ethernet/ti/netcp_core.c +index 5dbb4ed1b1328..5c850cc3fae41 100644 +--- a/drivers/net/ethernet/ti/netcp_core.c ++++ b/drivers/net/ethernet/ti/netcp_core.c +@@ -1339,10 +1339,10 @@ int netcp_txpipe_open(struct netcp_tx_pipe *tx_pipe) + + tx_pipe->dma_channel = knav_dma_open_channel(dev, + tx_pipe->dma_chan_name, &config); +- if (IS_ERR(tx_pipe->dma_channel)) { ++ if (!tx_pipe->dma_channel) { + dev_err(dev, "failed opening tx chan(%s)\n", + tx_pipe->dma_chan_name); +- ret = PTR_ERR(tx_pipe->dma_channel); ++ ret = -EINVAL; + goto err; + } + +@@ -1360,7 +1360,7 @@ int netcp_txpipe_open(struct netcp_tx_pipe *tx_pipe) + return 0; + + err: +- if (!IS_ERR_OR_NULL(tx_pipe->dma_channel)) ++ if (tx_pipe->dma_channel) + knav_dma_close_channel(tx_pipe->dma_channel); + tx_pipe->dma_channel = NULL; + return ret; +@@ -1679,10 +1679,10 @@ static int netcp_setup_navigator_resources(struct net_device *ndev) + + netcp->rx_channel = knav_dma_open_channel(netcp->netcp_device->device, + netcp->dma_chan_name, &config); +- if (IS_ERR(netcp->rx_channel)) { ++ if (!netcp->rx_channel) { + dev_err(netcp->ndev_dev, "failed opening rx chan(%s\n", + netcp->dma_chan_name); +- ret = PTR_ERR(netcp->rx_channel); ++ ret = -EINVAL; + goto fail; + } + +diff --git a/drivers/soc/ti/knav_dma.c b/drivers/soc/ti/knav_dma.c +index 981a9014c9c4e..f238ce3d32fbe 100644 +--- a/drivers/soc/ti/knav_dma.c ++++ b/drivers/soc/ti/knav_dma.c +@@ -420,7 +420,7 @@ static int of_channel_match_helper(struct device_node *np, const char *name, + * @name: slave channel name + * @config: dma configuration parameters + * +- * Returns pointer to appropriate DMA channel on success or error. ++ * Return: Pointer to appropriate DMA channel on success or NULL on error. + */ + void *knav_dma_open_channel(struct device *dev, const char *name, + struct knav_dma_cfg *config) +@@ -433,13 +433,13 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + + if (!kdev) { + pr_err("keystone-navigator-dma driver not registered\n"); +- return (void *)-EINVAL; ++ return NULL; + } + + chan_num = of_channel_match_helper(dev->of_node, name, &instance); + if (chan_num < 0) { + dev_err(kdev->dev, "No DMA instance with name %s\n", name); +- return (void *)-EINVAL; ++ return NULL; + } + + dev_dbg(kdev->dev, "initializing %s channel %d from DMA %s\n", +@@ -450,7 +450,7 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + if (config->direction != DMA_MEM_TO_DEV && + config->direction != DMA_DEV_TO_MEM) { + dev_err(kdev->dev, "bad direction\n"); +- return (void *)-EINVAL; ++ return NULL; + } + + /* Look for correct dma instance */ +@@ -462,7 +462,7 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + } + if (!found) { + dev_err(kdev->dev, "No DMA instance with name %s\n", instance); +- return (void *)-EINVAL; ++ return NULL; + } + + /* Look for correct dma channel from dma instance */ +@@ -483,14 +483,14 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + if (!found) { + dev_err(kdev->dev, "channel %d is not in DMA %s\n", + chan_num, instance); +- return (void *)-EINVAL; ++ return NULL; + } + + if (atomic_read(&chan->ref_count) >= 1) { + if (!check_config(chan, config)) { + dev_err(kdev->dev, "channel %d config miss-match\n", + chan_num); +- return (void *)-EINVAL; ++ return NULL; + } + } + +-- +2.51.0 + diff --git a/queue-5.4/series b/queue-5.4/series index 57d0a1726f..f0f23b4d40 100644 --- a/queue-5.4/series +++ b/queue-5.4/series @@ -170,3 +170,5 @@ vsock-ignore-signal-timeout-on-connect-if-already-es.patch kconfig-mconf-initialize-the-default-locale-at-start.patch kconfig-nconf-initialize-the-default-locale-at-start.patch mm-page_alloc-fix-hash-table-order-logging-in-alloc_.patch +alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch +net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch diff --git a/queue-6.1/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch b/queue-6.1/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch new file mode 100644 index 0000000000..1493ac7084 --- /dev/null +++ b/queue-6.1/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch @@ -0,0 +1,47 @@ +From 617aa1d681825e98809ffc8fe7c33da73c4db37a Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Tue, 25 Nov 2025 15:41:49 +0100 +Subject: ALSA: usb-audio: fix uac2 clock source at terminal parser +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +From: René Rebe + +[ Upstream commit d26e9f669cc0a6a85cf17180c09a6686db9f4002 ] + +Since 8b3a087f7f65 ("ALSA: usb-audio: Unify virtual type units type to +UAC3 values") usb-audio is using UAC3_CLOCK_SOURCE instead of +bDescriptorSubtype, later refactored with e0ccdef9265 ("ALSA: usb-audio: +Clean up check_input_term()") into parse_term_uac2_clock_source(). + +This breaks the clock source selection for at least my +1397:0003 BEHRINGER International GmbH FCA610 Pro. + +Fix by using UAC2_CLOCK_SOURCE in parse_term_uac2_clock_source(). + +Fixes: 8b3a087f7f65 ("ALSA: usb-audio: Unify virtual type units type to UAC3 values") +Signed-off-by: René Rebe +Link: https://patch.msgid.link/20251125.154149.1121389544970412061.rene@exactco.de +Signed-off-by: Takashi Iwai +Signed-off-by: Sasha Levin +--- + sound/usb/mixer.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/sound/usb/mixer.c b/sound/usb/mixer.c +index 9b34004e67131..1540e9f1c2e3f 100644 +--- a/sound/usb/mixer.c ++++ b/sound/usb/mixer.c +@@ -930,7 +930,7 @@ static int parse_term_uac2_clock_source(struct mixer_build *state, + { + struct uac_clock_source_descriptor *d = p1; + +- term->type = UAC3_CLOCK_SOURCE << 16; /* virtual type */ ++ term->type = UAC2_CLOCK_SOURCE << 16; /* virtual type */ + term->id = id; + term->name = d->iClockSource; + return 0; +-- +2.51.0 + diff --git a/queue-6.1/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch b/queue-6.1/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch new file mode 100644 index 0000000000..c7a2e2b396 --- /dev/null +++ b/queue-6.1/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch @@ -0,0 +1,168 @@ +From fa94da4d4ccb9d01a93b6848ba8b9e1be3a85300 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Mon, 3 Nov 2025 10:28:11 -0600 +Subject: net: ethernet: ti: netcp: Standardize knav_dma_open_channel to return + NULL on error + +From: Nishanth Menon + +[ Upstream commit 90a88306eb874fe4bbdd860e6c9787f5bbc588b5 ] + +Make knav_dma_open_channel consistently return NULL on error instead +of ERR_PTR. Currently the header include/linux/soc/ti/knav_dma.h +returns NULL when the driver is disabled, but the driver +implementation does not even return NULL or ERR_PTR on failure, +causing inconsistency in the users. This results in a crash in +netcp_free_navigator_resources as followed (trimmed): + +Unhandled fault: alignment exception (0x221) at 0xfffffff2 +[fffffff2] *pgd=80000800207003, *pmd=82ffda003, *pte=00000000 +Internal error: : 221 [#1] SMP ARM +Modules linked in: +CPU: 0 UID: 0 PID: 1 Comm: swapper/0 Not tainted 6.17.0-rc7 #1 NONE +Hardware name: Keystone +PC is at knav_dma_close_channel+0x30/0x19c +LR is at netcp_free_navigator_resources+0x2c/0x28c + +[... TRIM...] + +Call trace: + knav_dma_close_channel from netcp_free_navigator_resources+0x2c/0x28c + netcp_free_navigator_resources from netcp_ndo_open+0x430/0x46c + netcp_ndo_open from __dev_open+0x114/0x29c + __dev_open from __dev_change_flags+0x190/0x208 + __dev_change_flags from netif_change_flags+0x1c/0x58 + netif_change_flags from dev_change_flags+0x38/0xa0 + dev_change_flags from ip_auto_config+0x2c4/0x11f0 + ip_auto_config from do_one_initcall+0x58/0x200 + do_one_initcall from kernel_init_freeable+0x1cc/0x238 + kernel_init_freeable from kernel_init+0x1c/0x12c + kernel_init from ret_from_fork+0x14/0x38 +[... TRIM...] + +Standardize the error handling by making the function return NULL on +all error conditions. The API is used in just the netcp_core.c so the +impact is limited. + +Note, this change, in effect reverts commit 5b6cb43b4d62 ("net: +ethernet: ti: netcp_core: return error while dma channel open issue"), +but provides a less error prone implementation. + +Suggested-by: Simon Horman +Suggested-by: Jacob Keller +Signed-off-by: Nishanth Menon +Reviewed-by: Jacob Keller +Link: https://patch.msgid.link/20251103162811.3730055-1-nm@ti.com +Signed-off-by: Jakub Kicinski +Signed-off-by: Sasha Levin +--- + drivers/net/ethernet/ti/netcp_core.c | 10 +++++----- + drivers/soc/ti/knav_dma.c | 14 +++++++------- + 2 files changed, 12 insertions(+), 12 deletions(-) + +diff --git a/drivers/net/ethernet/ti/netcp_core.c b/drivers/net/ethernet/ti/netcp_core.c +index 9eb9eaff4dc90..6c0c9b795c8fe 100644 +--- a/drivers/net/ethernet/ti/netcp_core.c ++++ b/drivers/net/ethernet/ti/netcp_core.c +@@ -1338,10 +1338,10 @@ int netcp_txpipe_open(struct netcp_tx_pipe *tx_pipe) + + tx_pipe->dma_channel = knav_dma_open_channel(dev, + tx_pipe->dma_chan_name, &config); +- if (IS_ERR(tx_pipe->dma_channel)) { ++ if (!tx_pipe->dma_channel) { + dev_err(dev, "failed opening tx chan(%s)\n", + tx_pipe->dma_chan_name); +- ret = PTR_ERR(tx_pipe->dma_channel); ++ ret = -EINVAL; + goto err; + } + +@@ -1359,7 +1359,7 @@ int netcp_txpipe_open(struct netcp_tx_pipe *tx_pipe) + return 0; + + err: +- if (!IS_ERR_OR_NULL(tx_pipe->dma_channel)) ++ if (tx_pipe->dma_channel) + knav_dma_close_channel(tx_pipe->dma_channel); + tx_pipe->dma_channel = NULL; + return ret; +@@ -1678,10 +1678,10 @@ static int netcp_setup_navigator_resources(struct net_device *ndev) + + netcp->rx_channel = knav_dma_open_channel(netcp->netcp_device->device, + netcp->dma_chan_name, &config); +- if (IS_ERR(netcp->rx_channel)) { ++ if (!netcp->rx_channel) { + dev_err(netcp->ndev_dev, "failed opening rx chan(%s\n", + netcp->dma_chan_name); +- ret = PTR_ERR(netcp->rx_channel); ++ ret = -EINVAL; + goto fail; + } + +diff --git a/drivers/soc/ti/knav_dma.c b/drivers/soc/ti/knav_dma.c +index 84afebd355bef..10014ffca829a 100644 +--- a/drivers/soc/ti/knav_dma.c ++++ b/drivers/soc/ti/knav_dma.c +@@ -402,7 +402,7 @@ static int of_channel_match_helper(struct device_node *np, const char *name, + * @name: slave channel name + * @config: dma configuration parameters + * +- * Returns pointer to appropriate DMA channel on success or error. ++ * Return: Pointer to appropriate DMA channel on success or NULL on error. + */ + void *knav_dma_open_channel(struct device *dev, const char *name, + struct knav_dma_cfg *config) +@@ -414,13 +414,13 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + + if (!kdev) { + pr_err("keystone-navigator-dma driver not registered\n"); +- return (void *)-EINVAL; ++ return NULL; + } + + chan_num = of_channel_match_helper(dev->of_node, name, &instance); + if (chan_num < 0) { + dev_err(kdev->dev, "No DMA instance with name %s\n", name); +- return (void *)-EINVAL; ++ return NULL; + } + + dev_dbg(kdev->dev, "initializing %s channel %d from DMA %s\n", +@@ -431,7 +431,7 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + if (config->direction != DMA_MEM_TO_DEV && + config->direction != DMA_DEV_TO_MEM) { + dev_err(kdev->dev, "bad direction\n"); +- return (void *)-EINVAL; ++ return NULL; + } + + /* Look for correct dma instance */ +@@ -443,7 +443,7 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + } + if (!dma) { + dev_err(kdev->dev, "No DMA instance with name %s\n", instance); +- return (void *)-EINVAL; ++ return NULL; + } + + /* Look for correct dma channel from dma instance */ +@@ -463,14 +463,14 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + if (!chan) { + dev_err(kdev->dev, "channel %d is not in DMA %s\n", + chan_num, instance); +- return (void *)-EINVAL; ++ return NULL; + } + + if (atomic_read(&chan->ref_count) >= 1) { + if (!check_config(chan, config)) { + dev_err(kdev->dev, "channel %d config miss-match\n", + chan_num); +- return (void *)-EINVAL; ++ return NULL; + } + } + +-- +2.51.0 + diff --git a/queue-6.1/series b/queue-6.1/series index 116c765d18..e5598c4471 100644 --- a/queue-6.1/series +++ b/queue-6.1/series @@ -473,3 +473,6 @@ kconfig-mconf-initialize-the-default-locale-at-start.patch kconfig-nconf-initialize-the-default-locale-at-start.patch mm-secretmem-fix-use-after-free-race-in-fault-handle.patch mm-mm_init-fix-hash-table-order-logging-in-alloc_lar.patch +alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch +net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch +tracing-tools-fix-incorrcet-short-option-in-usage-te.patch diff --git a/queue-6.1/tracing-tools-fix-incorrcet-short-option-in-usage-te.patch b/queue-6.1/tracing-tools-fix-incorrcet-short-option-in-usage-te.patch new file mode 100644 index 0000000000..8f520e1699 --- /dev/null +++ b/queue-6.1/tracing-tools-fix-incorrcet-short-option-in-usage-te.patch @@ -0,0 +1,43 @@ +From 5fff56f6007ba6d78731a29bab19d6055753726d Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Thu, 6 Nov 2025 11:10:40 +0800 +Subject: tracing/tools: Fix incorrcet short option in usage text for --threads + +From: Zhang Chujun + +[ Upstream commit 53afec2c8fb2a562222948cb1c2aac48598578c9 ] + +The help message incorrectly listed '-t' as the short option for +--threads, but the actual getopt_long configuration uses '-e'. +This mismatch can confuse users and lead to incorrect command-line +usage. This patch updates the usage string to correctly show: + "-e, --threads NRTHR" +to match the implementation. + +Note: checkpatch.pl reports a false-positive spelling warning on +'Run', which is intentional. + +Link: https://patch.msgid.link/20251106031040.1869-1-zhangchujun@cmss.chinamobile.com +Signed-off-by: Zhang Chujun +Signed-off-by: Steven Rostedt (Google) +Signed-off-by: Sasha Levin +--- + tools/tracing/latency/latency-collector.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/tools/tracing/latency/latency-collector.c b/tools/tracing/latency/latency-collector.c +index f7ed8084e16ad..ec95b94f80e1f 100644 +--- a/tools/tracing/latency/latency-collector.c ++++ b/tools/tracing/latency/latency-collector.c +@@ -1725,7 +1725,7 @@ static void show_usage(void) + "-n, --notrace\t\tIf latency is detected, do not print out the content of\n" + "\t\t\tthe trace file to standard output\n\n" + +-"-t, --threads NRTHR\tRun NRTHR threads for printing. Default is %d.\n\n" ++"-e, --threads NRTHR\tRun NRTHR threads for printing. Default is %d.\n\n" + + "-r, --random\t\tArbitrarily sleep a certain amount of time, default\n" + "\t\t\t%ld ms, before reading the trace file. The\n" +-- +2.51.0 + diff --git a/queue-6.12/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch b/queue-6.12/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch new file mode 100644 index 0000000000..023cddf53d --- /dev/null +++ b/queue-6.12/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch @@ -0,0 +1,47 @@ +From 9de9c0c63bfa095da450bb5518a0814a56baa45e Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Tue, 25 Nov 2025 15:41:49 +0100 +Subject: ALSA: usb-audio: fix uac2 clock source at terminal parser +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +From: René Rebe + +[ Upstream commit d26e9f669cc0a6a85cf17180c09a6686db9f4002 ] + +Since 8b3a087f7f65 ("ALSA: usb-audio: Unify virtual type units type to +UAC3 values") usb-audio is using UAC3_CLOCK_SOURCE instead of +bDescriptorSubtype, later refactored with e0ccdef9265 ("ALSA: usb-audio: +Clean up check_input_term()") into parse_term_uac2_clock_source(). + +This breaks the clock source selection for at least my +1397:0003 BEHRINGER International GmbH FCA610 Pro. + +Fix by using UAC2_CLOCK_SOURCE in parse_term_uac2_clock_source(). + +Fixes: 8b3a087f7f65 ("ALSA: usb-audio: Unify virtual type units type to UAC3 values") +Signed-off-by: René Rebe +Link: https://patch.msgid.link/20251125.154149.1121389544970412061.rene@exactco.de +Signed-off-by: Takashi Iwai +Signed-off-by: Sasha Levin +--- + sound/usb/mixer.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/sound/usb/mixer.c b/sound/usb/mixer.c +index 4853336f0e6b5..7307e29c60b75 100644 +--- a/sound/usb/mixer.c ++++ b/sound/usb/mixer.c +@@ -930,7 +930,7 @@ static int parse_term_uac2_clock_source(struct mixer_build *state, + { + struct uac_clock_source_descriptor *d = p1; + +- term->type = UAC3_CLOCK_SOURCE << 16; /* virtual type */ ++ term->type = UAC2_CLOCK_SOURCE << 16; /* virtual type */ + term->id = id; + term->name = d->iClockSource; + return 0; +-- +2.51.0 + diff --git a/queue-6.12/drm-amdgpu-fix-gpu-page-fault-after-hibernation-on-p.patch b/queue-6.12/drm-amdgpu-fix-gpu-page-fault-after-hibernation-on-p.patch new file mode 100644 index 0000000000..c2edcb2eb4 --- /dev/null +++ b/queue-6.12/drm-amdgpu-fix-gpu-page-fault-after-hibernation-on-p.patch @@ -0,0 +1,65 @@ +From 36c1990cf5d866c729153406fe30c590bf6462a5 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Wed, 5 Nov 2025 03:04:08 +0000 +Subject: drm/amdgpu: fix gpu page fault after hibernation on PF passthrough + +From: Samuel Zhang + +[ Upstream commit eb6e7f520d6efa4d4ebf1671455abe4a681f7a05 ] + +On PF passthrough environment, after hibernate and then resume, coralgemm +will cause gpu page fault. + +Mode1 reset happens during hibernate, but partition mode is not restored +on resume, register mmCP_HYP_XCP_CTL and mmCP_PSP_XCP_CTL is not right +after resume. When CP access the MQD BO, wrong stride size is used, +this will cause out of bound access on the MQD BO, resulting page fault. + +The fix is to ensure gfx_v9_4_3_switch_compute_partition() is called +when resume from a hibernation. +KFD resume is called separately during a reset recovery or resume from +suspend sequence. Hence it's not required to be called as part of +partition switch. + +Signed-off-by: Samuel Zhang +Reviewed-by: Lijo Lazar +Signed-off-by: Alex Deucher +(cherry picked from commit 5d1b32cfe4a676fe552416cb5ae847b215463a1a) +Signed-off-by: Sasha Levin +--- + drivers/gpu/drm/amd/amdgpu/aqua_vanjaram.c | 3 ++- + drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c | 4 +++- + 2 files changed, 5 insertions(+), 2 deletions(-) + +diff --git a/drivers/gpu/drm/amd/amdgpu/aqua_vanjaram.c b/drivers/gpu/drm/amd/amdgpu/aqua_vanjaram.c +index ccfd2a4b4acc8..9c89e234c7869 100644 +--- a/drivers/gpu/drm/amd/amdgpu/aqua_vanjaram.c ++++ b/drivers/gpu/drm/amd/amdgpu/aqua_vanjaram.c +@@ -555,7 +555,8 @@ static int aqua_vanjaram_switch_partition_mode(struct amdgpu_xcp_mgr *xcp_mgr, + return -EINVAL; + } + +- if (adev->kfd.init_complete && !amdgpu_in_reset(adev)) ++ if (adev->kfd.init_complete && !amdgpu_in_reset(adev) && ++ !adev->in_suspend) + flags |= AMDGPU_XCP_OPS_KFD; + + if (flags & AMDGPU_XCP_OPS_KFD) { +diff --git a/drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c b/drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c +index f27ccb8f3c8c5..26c2d8d9e2463 100644 +--- a/drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c ++++ b/drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c +@@ -2297,7 +2297,9 @@ static int gfx_v9_4_3_cp_resume(struct amdgpu_device *adev) + r = amdgpu_xcp_init(adev->xcp_mgr, num_xcp, mode); + + } else { +- if (amdgpu_xcp_query_partition_mode(adev->xcp_mgr, ++ if (adev->in_suspend) ++ amdgpu_xcp_restore_partition_mode(adev->xcp_mgr); ++ else if (amdgpu_xcp_query_partition_mode(adev->xcp_mgr, + AMDGPU_XCP_FL_NONE) == + AMDGPU_UNKNOWN_COMPUTE_PARTITION_MODE) + r = amdgpu_xcp_switch_partition_mode( +-- +2.51.0 + diff --git a/queue-6.12/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch b/queue-6.12/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch new file mode 100644 index 0000000000..c51d94a2f0 --- /dev/null +++ b/queue-6.12/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch @@ -0,0 +1,168 @@ +From 09ddf192899184225976ad473ed9b16a27ed997f Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Mon, 3 Nov 2025 10:28:11 -0600 +Subject: net: ethernet: ti: netcp: Standardize knav_dma_open_channel to return + NULL on error + +From: Nishanth Menon + +[ Upstream commit 90a88306eb874fe4bbdd860e6c9787f5bbc588b5 ] + +Make knav_dma_open_channel consistently return NULL on error instead +of ERR_PTR. Currently the header include/linux/soc/ti/knav_dma.h +returns NULL when the driver is disabled, but the driver +implementation does not even return NULL or ERR_PTR on failure, +causing inconsistency in the users. This results in a crash in +netcp_free_navigator_resources as followed (trimmed): + +Unhandled fault: alignment exception (0x221) at 0xfffffff2 +[fffffff2] *pgd=80000800207003, *pmd=82ffda003, *pte=00000000 +Internal error: : 221 [#1] SMP ARM +Modules linked in: +CPU: 0 UID: 0 PID: 1 Comm: swapper/0 Not tainted 6.17.0-rc7 #1 NONE +Hardware name: Keystone +PC is at knav_dma_close_channel+0x30/0x19c +LR is at netcp_free_navigator_resources+0x2c/0x28c + +[... TRIM...] + +Call trace: + knav_dma_close_channel from netcp_free_navigator_resources+0x2c/0x28c + netcp_free_navigator_resources from netcp_ndo_open+0x430/0x46c + netcp_ndo_open from __dev_open+0x114/0x29c + __dev_open from __dev_change_flags+0x190/0x208 + __dev_change_flags from netif_change_flags+0x1c/0x58 + netif_change_flags from dev_change_flags+0x38/0xa0 + dev_change_flags from ip_auto_config+0x2c4/0x11f0 + ip_auto_config from do_one_initcall+0x58/0x200 + do_one_initcall from kernel_init_freeable+0x1cc/0x238 + kernel_init_freeable from kernel_init+0x1c/0x12c + kernel_init from ret_from_fork+0x14/0x38 +[... TRIM...] + +Standardize the error handling by making the function return NULL on +all error conditions. The API is used in just the netcp_core.c so the +impact is limited. + +Note, this change, in effect reverts commit 5b6cb43b4d62 ("net: +ethernet: ti: netcp_core: return error while dma channel open issue"), +but provides a less error prone implementation. + +Suggested-by: Simon Horman +Suggested-by: Jacob Keller +Signed-off-by: Nishanth Menon +Reviewed-by: Jacob Keller +Link: https://patch.msgid.link/20251103162811.3730055-1-nm@ti.com +Signed-off-by: Jakub Kicinski +Signed-off-by: Sasha Levin +--- + drivers/net/ethernet/ti/netcp_core.c | 10 +++++----- + drivers/soc/ti/knav_dma.c | 14 +++++++------- + 2 files changed, 12 insertions(+), 12 deletions(-) + +diff --git a/drivers/net/ethernet/ti/netcp_core.c b/drivers/net/ethernet/ti/netcp_core.c +index 11b90e1da0c63..d07dcffc2517e 100644 +--- a/drivers/net/ethernet/ti/netcp_core.c ++++ b/drivers/net/ethernet/ti/netcp_core.c +@@ -1338,10 +1338,10 @@ int netcp_txpipe_open(struct netcp_tx_pipe *tx_pipe) + + tx_pipe->dma_channel = knav_dma_open_channel(dev, + tx_pipe->dma_chan_name, &config); +- if (IS_ERR(tx_pipe->dma_channel)) { ++ if (!tx_pipe->dma_channel) { + dev_err(dev, "failed opening tx chan(%s)\n", + tx_pipe->dma_chan_name); +- ret = PTR_ERR(tx_pipe->dma_channel); ++ ret = -EINVAL; + goto err; + } + +@@ -1359,7 +1359,7 @@ int netcp_txpipe_open(struct netcp_tx_pipe *tx_pipe) + return 0; + + err: +- if (!IS_ERR_OR_NULL(tx_pipe->dma_channel)) ++ if (tx_pipe->dma_channel) + knav_dma_close_channel(tx_pipe->dma_channel); + tx_pipe->dma_channel = NULL; + return ret; +@@ -1678,10 +1678,10 @@ static int netcp_setup_navigator_resources(struct net_device *ndev) + + netcp->rx_channel = knav_dma_open_channel(netcp->netcp_device->device, + netcp->dma_chan_name, &config); +- if (IS_ERR(netcp->rx_channel)) { ++ if (!netcp->rx_channel) { + dev_err(netcp->ndev_dev, "failed opening rx chan(%s\n", + netcp->dma_chan_name); +- ret = PTR_ERR(netcp->rx_channel); ++ ret = -EINVAL; + goto fail; + } + +diff --git a/drivers/soc/ti/knav_dma.c b/drivers/soc/ti/knav_dma.c +index fb0746d8caad4..c9cf8a90c6d49 100644 +--- a/drivers/soc/ti/knav_dma.c ++++ b/drivers/soc/ti/knav_dma.c +@@ -402,7 +402,7 @@ static int of_channel_match_helper(struct device_node *np, const char *name, + * @name: slave channel name + * @config: dma configuration parameters + * +- * Returns pointer to appropriate DMA channel on success or error. ++ * Return: Pointer to appropriate DMA channel on success or NULL on error. + */ + void *knav_dma_open_channel(struct device *dev, const char *name, + struct knav_dma_cfg *config) +@@ -414,13 +414,13 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + + if (!kdev) { + pr_err("keystone-navigator-dma driver not registered\n"); +- return (void *)-EINVAL; ++ return NULL; + } + + chan_num = of_channel_match_helper(dev->of_node, name, &instance); + if (chan_num < 0) { + dev_err(kdev->dev, "No DMA instance with name %s\n", name); +- return (void *)-EINVAL; ++ return NULL; + } + + dev_dbg(kdev->dev, "initializing %s channel %d from DMA %s\n", +@@ -431,7 +431,7 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + if (config->direction != DMA_MEM_TO_DEV && + config->direction != DMA_DEV_TO_MEM) { + dev_err(kdev->dev, "bad direction\n"); +- return (void *)-EINVAL; ++ return NULL; + } + + /* Look for correct dma instance */ +@@ -443,7 +443,7 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + } + if (!dma) { + dev_err(kdev->dev, "No DMA instance with name %s\n", instance); +- return (void *)-EINVAL; ++ return NULL; + } + + /* Look for correct dma channel from dma instance */ +@@ -463,14 +463,14 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + if (!chan) { + dev_err(kdev->dev, "channel %d is not in DMA %s\n", + chan_num, instance); +- return (void *)-EINVAL; ++ return NULL; + } + + if (atomic_read(&chan->ref_count) >= 1) { + if (!check_config(chan, config)) { + dev_err(kdev->dev, "channel %d config miss-match\n", + chan_num); +- return (void *)-EINVAL; ++ return NULL; + } + } + +-- +2.51.0 + diff --git a/queue-6.12/series b/queue-6.12/series index abae70ebd7..e45dc04207 100644 --- a/queue-6.12/series +++ b/queue-6.12/series @@ -95,3 +95,7 @@ kvm-arm64-make-all-32bit-id-registers-fully-writable.patch revert-rdma-irdma-update-kconfig.patch drm-xe-prevent-bit-overflow-when-handling-invalid-pr.patch s390-mm-fix-__ptep_rdp-inline-assembly.patch +alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch +net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch +tracing-tools-fix-incorrcet-short-option-in-usage-te.patch +drm-amdgpu-fix-gpu-page-fault-after-hibernation-on-p.patch diff --git a/queue-6.12/tracing-tools-fix-incorrcet-short-option-in-usage-te.patch b/queue-6.12/tracing-tools-fix-incorrcet-short-option-in-usage-te.patch new file mode 100644 index 0000000000..1347d333b9 --- /dev/null +++ b/queue-6.12/tracing-tools-fix-incorrcet-short-option-in-usage-te.patch @@ -0,0 +1,43 @@ +From af7a79c271a3ac166ad8f446c4cf8b80c1d35346 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Thu, 6 Nov 2025 11:10:40 +0800 +Subject: tracing/tools: Fix incorrcet short option in usage text for --threads + +From: Zhang Chujun + +[ Upstream commit 53afec2c8fb2a562222948cb1c2aac48598578c9 ] + +The help message incorrectly listed '-t' as the short option for +--threads, but the actual getopt_long configuration uses '-e'. +This mismatch can confuse users and lead to incorrect command-line +usage. This patch updates the usage string to correctly show: + "-e, --threads NRTHR" +to match the implementation. + +Note: checkpatch.pl reports a false-positive spelling warning on +'Run', which is intentional. + +Link: https://patch.msgid.link/20251106031040.1869-1-zhangchujun@cmss.chinamobile.com +Signed-off-by: Zhang Chujun +Signed-off-by: Steven Rostedt (Google) +Signed-off-by: Sasha Levin +--- + tools/tracing/latency/latency-collector.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/tools/tracing/latency/latency-collector.c b/tools/tracing/latency/latency-collector.c +index cf263fe9deaf4..ef97916e3873a 100644 +--- a/tools/tracing/latency/latency-collector.c ++++ b/tools/tracing/latency/latency-collector.c +@@ -1725,7 +1725,7 @@ static void show_usage(void) + "-n, --notrace\t\tIf latency is detected, do not print out the content of\n" + "\t\t\tthe trace file to standard output\n\n" + +-"-t, --threads NRTHR\tRun NRTHR threads for printing. Default is %d.\n\n" ++"-e, --threads NRTHR\tRun NRTHR threads for printing. Default is %d.\n\n" + + "-r, --random\t\tArbitrarily sleep a certain amount of time, default\n" + "\t\t\t%ld ms, before reading the trace file. The\n" +-- +2.51.0 + diff --git a/queue-6.17/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch b/queue-6.17/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch new file mode 100644 index 0000000000..249759bc0f --- /dev/null +++ b/queue-6.17/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch @@ -0,0 +1,47 @@ +From 8436670aca4ea4298bcb639d3b5a663de7c52686 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Tue, 25 Nov 2025 15:41:49 +0100 +Subject: ALSA: usb-audio: fix uac2 clock source at terminal parser +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +From: René Rebe + +[ Upstream commit d26e9f669cc0a6a85cf17180c09a6686db9f4002 ] + +Since 8b3a087f7f65 ("ALSA: usb-audio: Unify virtual type units type to +UAC3 values") usb-audio is using UAC3_CLOCK_SOURCE instead of +bDescriptorSubtype, later refactored with e0ccdef9265 ("ALSA: usb-audio: +Clean up check_input_term()") into parse_term_uac2_clock_source(). + +This breaks the clock source selection for at least my +1397:0003 BEHRINGER International GmbH FCA610 Pro. + +Fix by using UAC2_CLOCK_SOURCE in parse_term_uac2_clock_source(). + +Fixes: 8b3a087f7f65 ("ALSA: usb-audio: Unify virtual type units type to UAC3 values") +Signed-off-by: René Rebe +Link: https://patch.msgid.link/20251125.154149.1121389544970412061.rene@exactco.de +Signed-off-by: Takashi Iwai +Signed-off-by: Sasha Levin +--- + sound/usb/mixer.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/sound/usb/mixer.c b/sound/usb/mixer.c +index f2058eb71fc8d..572ef02074538 100644 +--- a/sound/usb/mixer.c ++++ b/sound/usb/mixer.c +@@ -930,7 +930,7 @@ static int parse_term_uac2_clock_source(struct mixer_build *state, + { + struct uac_clock_source_descriptor *d = p1; + +- term->type = UAC3_CLOCK_SOURCE << 16; /* virtual type */ ++ term->type = UAC2_CLOCK_SOURCE << 16; /* virtual type */ + term->id = id; + term->name = d->iClockSource; + return 0; +-- +2.51.0 + diff --git a/queue-6.17/btrfs-set-inode-flag-btrfs_inode_copy_everything-whe.patch b/queue-6.17/btrfs-set-inode-flag-btrfs_inode_copy_everything-whe.patch new file mode 100644 index 0000000000..7474e43167 --- /dev/null +++ b/queue-6.17/btrfs-set-inode-flag-btrfs_inode_copy_everything-whe.patch @@ -0,0 +1,83 @@ +From 6613df3efbf0285c10c7fbaf359874d8886c8391 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Fri, 24 Oct 2025 12:30:56 +0100 +Subject: btrfs: set inode flag BTRFS_INODE_COPY_EVERYTHING when logging new + name + +From: Filipe Manana + +[ Upstream commit 953902e4fb4c373c81a977f78e40f9f93a79e20f ] + +If we are logging a new name make sure our inode has the runtime flag +BTRFS_INODE_COPY_EVERYTHING set so that at btrfs_log_inode() we will find +new inode refs/extrefs in the subvolume tree and copy them into the log +tree. + +We are currently doing it when adding a new link but we are missing it +when renaming. + +An example where this makes a new name not persisted: + + 1) create symlink with name foo in directory A + 2) fsync directory A, which persists the symlink + 3) rename the symlink from foo to bar + 4) fsync directory A to persist the new symlink name + +Step 4 isn't working correctly as it's not logging the new name and also +leaving the old inode ref in the log tree, so after a power failure the +symlink still has the old name of "foo". This is because when we first +fsync directoy A we log the symlink's inode (as it's a new entry) and at +btrfs_log_inode() we set the log mode to LOG_INODE_ALL and then because +we are using that mode and the inode has the runtime flag +BTRFS_INODE_NEEDS_FULL_SYNC set, we clear that flag as well as the flag +BTRFS_INODE_COPY_EVERYTHING. That means the next time we log the inode, +during the rename through the call to btrfs_log_new_name() (calling +btrfs_log_inode_parent() and then btrfs_log_inode()), we will not search +the subvolume tree for new refs/extrefs and jump directory to the +'log_extents' label. + +Fix this by making sure we set BTRFS_INODE_COPY_EVERYTHING on an inode +when we are about to log a new name. A test case for fstests will follow +soon. + +Reported-by: Vyacheslav Kovalevsky +Link: https://lore.kernel.org/linux-btrfs/ac949c74-90c2-4b9a-b7fd-1ffc5c3175c7@gmail.com/ +Reviewed-by: Boris Burkov +Reviewed-by: Qu Wenruo +Signed-off-by: Filipe Manana +Signed-off-by: David Sterba +Signed-off-by: Sasha Levin +--- + fs/btrfs/inode.c | 1 - + fs/btrfs/tree-log.c | 3 +++ + 2 files changed, 3 insertions(+), 1 deletion(-) + +diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c +index 68b2140c9fdb1..79a68f1871679 100644 +--- a/fs/btrfs/inode.c ++++ b/fs/btrfs/inode.c +@@ -6850,7 +6850,6 @@ static int btrfs_link(struct dentry *old_dentry, struct inode *dir, + BTRFS_I(inode)->dir_index = 0ULL; + inode_inc_iversion(inode); + inode_set_ctime_current(inode); +- set_bit(BTRFS_INODE_COPY_EVERYTHING, &BTRFS_I(inode)->runtime_flags); + + ret = btrfs_add_link(trans, BTRFS_I(dir), BTRFS_I(inode), + &fname.disk_name, 1, index); +diff --git a/fs/btrfs/tree-log.c b/fs/btrfs/tree-log.c +index dc0f3b5778b48..b203d8f2d2aaf 100644 +--- a/fs/btrfs/tree-log.c ++++ b/fs/btrfs/tree-log.c +@@ -7608,6 +7608,9 @@ void btrfs_log_new_name(struct btrfs_trans_handle *trans, + bool log_pinned = false; + int ret; + ++ /* The inode has a new name (ref/extref), so make sure we log it. */ ++ set_bit(BTRFS_INODE_COPY_EVERYTHING, &inode->runtime_flags); ++ + btrfs_init_log_ctx(&ctx, inode); + ctx.logging_new_name = true; + +-- +2.51.0 + diff --git a/queue-6.17/drm-amdgpu-fix-gpu-page-fault-after-hibernation-on-p.patch b/queue-6.17/drm-amdgpu-fix-gpu-page-fault-after-hibernation-on-p.patch new file mode 100644 index 0000000000..d3205f38d9 --- /dev/null +++ b/queue-6.17/drm-amdgpu-fix-gpu-page-fault-after-hibernation-on-p.patch @@ -0,0 +1,65 @@ +From 98b6fde5d7835d680bf7b0fb26f64eb3bdd72836 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Wed, 5 Nov 2025 03:04:08 +0000 +Subject: drm/amdgpu: fix gpu page fault after hibernation on PF passthrough + +From: Samuel Zhang + +[ Upstream commit eb6e7f520d6efa4d4ebf1671455abe4a681f7a05 ] + +On PF passthrough environment, after hibernate and then resume, coralgemm +will cause gpu page fault. + +Mode1 reset happens during hibernate, but partition mode is not restored +on resume, register mmCP_HYP_XCP_CTL and mmCP_PSP_XCP_CTL is not right +after resume. When CP access the MQD BO, wrong stride size is used, +this will cause out of bound access on the MQD BO, resulting page fault. + +The fix is to ensure gfx_v9_4_3_switch_compute_partition() is called +when resume from a hibernation. +KFD resume is called separately during a reset recovery or resume from +suspend sequence. Hence it's not required to be called as part of +partition switch. + +Signed-off-by: Samuel Zhang +Reviewed-by: Lijo Lazar +Signed-off-by: Alex Deucher +(cherry picked from commit 5d1b32cfe4a676fe552416cb5ae847b215463a1a) +Signed-off-by: Sasha Levin +--- + drivers/gpu/drm/amd/amdgpu/aqua_vanjaram.c | 3 ++- + drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c | 4 +++- + 2 files changed, 5 insertions(+), 2 deletions(-) + +diff --git a/drivers/gpu/drm/amd/amdgpu/aqua_vanjaram.c b/drivers/gpu/drm/amd/amdgpu/aqua_vanjaram.c +index 811124ff88a88..f9e2edf5260bc 100644 +--- a/drivers/gpu/drm/amd/amdgpu/aqua_vanjaram.c ++++ b/drivers/gpu/drm/amd/amdgpu/aqua_vanjaram.c +@@ -407,7 +407,8 @@ static int aqua_vanjaram_switch_partition_mode(struct amdgpu_xcp_mgr *xcp_mgr, + return -EINVAL; + } + +- if (adev->kfd.init_complete && !amdgpu_in_reset(adev)) ++ if (adev->kfd.init_complete && !amdgpu_in_reset(adev) && ++ !adev->in_suspend) + flags |= AMDGPU_XCP_OPS_KFD; + + if (flags & AMDGPU_XCP_OPS_KFD) { +diff --git a/drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c b/drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c +index f06bc94cf6e14..9ee7d25bb06cf 100644 +--- a/drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c ++++ b/drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c +@@ -2292,7 +2292,9 @@ static int gfx_v9_4_3_cp_resume(struct amdgpu_device *adev) + r = amdgpu_xcp_init(adev->xcp_mgr, num_xcp, mode); + + } else { +- if (amdgpu_xcp_query_partition_mode(adev->xcp_mgr, ++ if (adev->in_suspend) ++ amdgpu_xcp_restore_partition_mode(adev->xcp_mgr); ++ else if (amdgpu_xcp_query_partition_mode(adev->xcp_mgr, + AMDGPU_XCP_FL_NONE) == + AMDGPU_UNKNOWN_COMPUTE_PARTITION_MODE) + r = amdgpu_xcp_switch_partition_mode( +-- +2.51.0 + diff --git a/queue-6.17/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch b/queue-6.17/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch new file mode 100644 index 0000000000..73e360705d --- /dev/null +++ b/queue-6.17/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch @@ -0,0 +1,168 @@ +From d229937c65f033c95cb374593638ca35a60fa940 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Mon, 3 Nov 2025 10:28:11 -0600 +Subject: net: ethernet: ti: netcp: Standardize knav_dma_open_channel to return + NULL on error + +From: Nishanth Menon + +[ Upstream commit 90a88306eb874fe4bbdd860e6c9787f5bbc588b5 ] + +Make knav_dma_open_channel consistently return NULL on error instead +of ERR_PTR. Currently the header include/linux/soc/ti/knav_dma.h +returns NULL when the driver is disabled, but the driver +implementation does not even return NULL or ERR_PTR on failure, +causing inconsistency in the users. This results in a crash in +netcp_free_navigator_resources as followed (trimmed): + +Unhandled fault: alignment exception (0x221) at 0xfffffff2 +[fffffff2] *pgd=80000800207003, *pmd=82ffda003, *pte=00000000 +Internal error: : 221 [#1] SMP ARM +Modules linked in: +CPU: 0 UID: 0 PID: 1 Comm: swapper/0 Not tainted 6.17.0-rc7 #1 NONE +Hardware name: Keystone +PC is at knav_dma_close_channel+0x30/0x19c +LR is at netcp_free_navigator_resources+0x2c/0x28c + +[... TRIM...] + +Call trace: + knav_dma_close_channel from netcp_free_navigator_resources+0x2c/0x28c + netcp_free_navigator_resources from netcp_ndo_open+0x430/0x46c + netcp_ndo_open from __dev_open+0x114/0x29c + __dev_open from __dev_change_flags+0x190/0x208 + __dev_change_flags from netif_change_flags+0x1c/0x58 + netif_change_flags from dev_change_flags+0x38/0xa0 + dev_change_flags from ip_auto_config+0x2c4/0x11f0 + ip_auto_config from do_one_initcall+0x58/0x200 + do_one_initcall from kernel_init_freeable+0x1cc/0x238 + kernel_init_freeable from kernel_init+0x1c/0x12c + kernel_init from ret_from_fork+0x14/0x38 +[... TRIM...] + +Standardize the error handling by making the function return NULL on +all error conditions. The API is used in just the netcp_core.c so the +impact is limited. + +Note, this change, in effect reverts commit 5b6cb43b4d62 ("net: +ethernet: ti: netcp_core: return error while dma channel open issue"), +but provides a less error prone implementation. + +Suggested-by: Simon Horman +Suggested-by: Jacob Keller +Signed-off-by: Nishanth Menon +Reviewed-by: Jacob Keller +Link: https://patch.msgid.link/20251103162811.3730055-1-nm@ti.com +Signed-off-by: Jakub Kicinski +Signed-off-by: Sasha Levin +--- + drivers/net/ethernet/ti/netcp_core.c | 10 +++++----- + drivers/soc/ti/knav_dma.c | 14 +++++++------- + 2 files changed, 12 insertions(+), 12 deletions(-) + +diff --git a/drivers/net/ethernet/ti/netcp_core.c b/drivers/net/ethernet/ti/netcp_core.c +index 857820657bac5..5ee13db568f08 100644 +--- a/drivers/net/ethernet/ti/netcp_core.c ++++ b/drivers/net/ethernet/ti/netcp_core.c +@@ -1338,10 +1338,10 @@ int netcp_txpipe_open(struct netcp_tx_pipe *tx_pipe) + + tx_pipe->dma_channel = knav_dma_open_channel(dev, + tx_pipe->dma_chan_name, &config); +- if (IS_ERR(tx_pipe->dma_channel)) { ++ if (!tx_pipe->dma_channel) { + dev_err(dev, "failed opening tx chan(%s)\n", + tx_pipe->dma_chan_name); +- ret = PTR_ERR(tx_pipe->dma_channel); ++ ret = -EINVAL; + goto err; + } + +@@ -1359,7 +1359,7 @@ int netcp_txpipe_open(struct netcp_tx_pipe *tx_pipe) + return 0; + + err: +- if (!IS_ERR_OR_NULL(tx_pipe->dma_channel)) ++ if (tx_pipe->dma_channel) + knav_dma_close_channel(tx_pipe->dma_channel); + tx_pipe->dma_channel = NULL; + return ret; +@@ -1678,10 +1678,10 @@ static int netcp_setup_navigator_resources(struct net_device *ndev) + + netcp->rx_channel = knav_dma_open_channel(netcp->netcp_device->device, + netcp->dma_chan_name, &config); +- if (IS_ERR(netcp->rx_channel)) { ++ if (!netcp->rx_channel) { + dev_err(netcp->ndev_dev, "failed opening rx chan(%s\n", + netcp->dma_chan_name); +- ret = PTR_ERR(netcp->rx_channel); ++ ret = -EINVAL; + goto fail; + } + +diff --git a/drivers/soc/ti/knav_dma.c b/drivers/soc/ti/knav_dma.c +index a25ebe6cd5030..553ae7ee20f16 100644 +--- a/drivers/soc/ti/knav_dma.c ++++ b/drivers/soc/ti/knav_dma.c +@@ -402,7 +402,7 @@ static int of_channel_match_helper(struct device_node *np, const char *name, + * @name: slave channel name + * @config: dma configuration parameters + * +- * Returns pointer to appropriate DMA channel on success or error. ++ * Return: Pointer to appropriate DMA channel on success or NULL on error. + */ + void *knav_dma_open_channel(struct device *dev, const char *name, + struct knav_dma_cfg *config) +@@ -414,13 +414,13 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + + if (!kdev) { + pr_err("keystone-navigator-dma driver not registered\n"); +- return (void *)-EINVAL; ++ return NULL; + } + + chan_num = of_channel_match_helper(dev->of_node, name, &instance); + if (chan_num < 0) { + dev_err(kdev->dev, "No DMA instance with name %s\n", name); +- return (void *)-EINVAL; ++ return NULL; + } + + dev_dbg(kdev->dev, "initializing %s channel %d from DMA %s\n", +@@ -431,7 +431,7 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + if (config->direction != DMA_MEM_TO_DEV && + config->direction != DMA_DEV_TO_MEM) { + dev_err(kdev->dev, "bad direction\n"); +- return (void *)-EINVAL; ++ return NULL; + } + + /* Look for correct dma instance */ +@@ -443,7 +443,7 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + } + if (!dma) { + dev_err(kdev->dev, "No DMA instance with name %s\n", instance); +- return (void *)-EINVAL; ++ return NULL; + } + + /* Look for correct dma channel from dma instance */ +@@ -463,14 +463,14 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + if (!chan) { + dev_err(kdev->dev, "channel %d is not in DMA %s\n", + chan_num, instance); +- return (void *)-EINVAL; ++ return NULL; + } + + if (atomic_read(&chan->ref_count) >= 1) { + if (!check_config(chan, config)) { + dev_err(kdev->dev, "channel %d config miss-match\n", + chan_num); +- return (void *)-EINVAL; ++ return NULL; + } + } + +-- +2.51.0 + diff --git a/queue-6.17/scsi-ufs-ufs-qcom-fix-ufs-ocp-issue-during-ufs-power.patch b/queue-6.17/scsi-ufs-ufs-qcom-fix-ufs-ocp-issue-during-ufs-power.patch new file mode 100644 index 0000000000..16d4062022 --- /dev/null +++ b/queue-6.17/scsi-ufs-ufs-qcom-fix-ufs-ocp-issue-during-ufs-power.patch @@ -0,0 +1,85 @@ +From e0052e539a991c64b1c5c3f816cde0fb2ceddb4d Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Sun, 12 Oct 2025 23:08:28 +0530 +Subject: scsi: ufs: ufs-qcom: Fix UFS OCP issue during UFS power down (PC=3) + +From: Nitin Rawat + +[ Upstream commit 5127be409c6c3815c4a7d8f6d88043e44f9b9543 ] + +According to UFS specifications, the power-off sequence for a UFS device +includes: + + - Sending an SSU command with Power_Condition=3 and await a response. + + - Asserting RST_N low. + + - Turning off REF_CLK. + + - Turning off VCC. + + - Turning off VCCQ/VCCQ2. + +As part of ufs shutdown, after the SSU command completion, asserting +hardware reset (HWRST) triggers the device firmware to wake up and +execute its reset routine. This routine initializes hardware blocks and +takes a few milliseconds to complete. During this time, the ICCQ draws a +large current. + +This large ICCQ current may cause issues for the regulator which is +supplying power to UFS, because the turn off request from UFS driver to +the regulator framework will be immediately followed by low power +mode(LPM) request by regulator framework. This is done by framework +because UFS which is the only client is requesting for disable. So if +the rail is still in the process of shutting down while ICCQ exceeds LPM +current thresholds, and LPM mode is activated in hardware during this +state, it may trigger an overcurrent protection (OCP) fault in the +regulator. + +To prevent this, a 10ms delay is added after asserting HWRST. This +allows the reset operation to complete while power rails remain active +and in high-power mode. + +Currently there is no way for Host to query whether the reset is +completed or not and hence this the delay is based on experiments with +Qualcomm UFS controllers across multiple UFS vendors. + +Signed-off-by: Nitin Rawat +Reviewed-by: Manivannan Sadhasivam +Link: https://patch.msgid.link/20251012173828.9880-1-nitin.rawat@oss.qualcomm.com +Signed-off-by: Martin K. Petersen +Signed-off-by: Sasha Levin +--- + drivers/ufs/host/ufs-qcom.c | 15 ++++++++++++++- + 1 file changed, 14 insertions(+), 1 deletion(-) + +diff --git a/drivers/ufs/host/ufs-qcom.c b/drivers/ufs/host/ufs-qcom.c +index 2b6eb377eec07..f14c124c103b3 100644 +--- a/drivers/ufs/host/ufs-qcom.c ++++ b/drivers/ufs/host/ufs-qcom.c +@@ -744,8 +744,21 @@ static int ufs_qcom_suspend(struct ufs_hba *hba, enum ufs_pm_op pm_op, + + + /* reset the connected UFS device during power down */ +- if (ufs_qcom_is_link_off(hba) && host->device_reset) ++ if (ufs_qcom_is_link_off(hba) && host->device_reset) { + ufs_qcom_device_reset_ctrl(hba, true); ++ /* ++ * After sending the SSU command, asserting the rst_n ++ * line causes the device firmware to wake up and ++ * execute its reset routine. ++ * ++ * During this process, the device may draw current ++ * beyond the permissible limit for low-power mode (LPM). ++ * A 10ms delay, based on experimental observations, ++ * allows the UFS device to complete its hardware reset ++ * before transitioning the power rail to LPM. ++ */ ++ usleep_range(10000, 11000); ++ } + + return ufs_qcom_ice_suspend(host); + } +-- +2.51.0 + diff --git a/queue-6.17/series b/queue-6.17/series index 44538cf3e9..d9cac9e775 100644 --- a/queue-6.17/series +++ b/queue-6.17/series @@ -151,3 +151,9 @@ x86-cpu-amd-extend-zen6-model-range.patch kconfig-mconf-initialize-the-default-locale-at-start.patch kconfig-nconf-initialize-the-default-locale-at-start.patch drm-xe-prevent-bit-overflow-when-handling-invalid-pr.patch +alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch +scsi-ufs-ufs-qcom-fix-ufs-ocp-issue-during-ufs-power.patch +net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch +tracing-tools-fix-incorrcet-short-option-in-usage-te.patch +btrfs-set-inode-flag-btrfs_inode_copy_everything-whe.patch +drm-amdgpu-fix-gpu-page-fault-after-hibernation-on-p.patch diff --git a/queue-6.17/tracing-tools-fix-incorrcet-short-option-in-usage-te.patch b/queue-6.17/tracing-tools-fix-incorrcet-short-option-in-usage-te.patch new file mode 100644 index 0000000000..6c6cf744ee --- /dev/null +++ b/queue-6.17/tracing-tools-fix-incorrcet-short-option-in-usage-te.patch @@ -0,0 +1,43 @@ +From 89b1da4d9acf8600f01c6efad367354735e56ee4 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Thu, 6 Nov 2025 11:10:40 +0800 +Subject: tracing/tools: Fix incorrcet short option in usage text for --threads + +From: Zhang Chujun + +[ Upstream commit 53afec2c8fb2a562222948cb1c2aac48598578c9 ] + +The help message incorrectly listed '-t' as the short option for +--threads, but the actual getopt_long configuration uses '-e'. +This mismatch can confuse users and lead to incorrect command-line +usage. This patch updates the usage string to correctly show: + "-e, --threads NRTHR" +to match the implementation. + +Note: checkpatch.pl reports a false-positive spelling warning on +'Run', which is intentional. + +Link: https://patch.msgid.link/20251106031040.1869-1-zhangchujun@cmss.chinamobile.com +Signed-off-by: Zhang Chujun +Signed-off-by: Steven Rostedt (Google) +Signed-off-by: Sasha Levin +--- + tools/tracing/latency/latency-collector.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/tools/tracing/latency/latency-collector.c b/tools/tracing/latency/latency-collector.c +index cf263fe9deaf4..ef97916e3873a 100644 +--- a/tools/tracing/latency/latency-collector.c ++++ b/tools/tracing/latency/latency-collector.c +@@ -1725,7 +1725,7 @@ static void show_usage(void) + "-n, --notrace\t\tIf latency is detected, do not print out the content of\n" + "\t\t\tthe trace file to standard output\n\n" + +-"-t, --threads NRTHR\tRun NRTHR threads for printing. Default is %d.\n\n" ++"-e, --threads NRTHR\tRun NRTHR threads for printing. Default is %d.\n\n" + + "-r, --random\t\tArbitrarily sleep a certain amount of time, default\n" + "\t\t\t%ld ms, before reading the trace file. The\n" +-- +2.51.0 + diff --git a/queue-6.6/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch b/queue-6.6/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch new file mode 100644 index 0000000000..e4ea6cae26 --- /dev/null +++ b/queue-6.6/alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch @@ -0,0 +1,47 @@ +From 9ce2642cddafc82887923d58ae28dcba032a36a3 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Tue, 25 Nov 2025 15:41:49 +0100 +Subject: ALSA: usb-audio: fix uac2 clock source at terminal parser +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +From: René Rebe + +[ Upstream commit d26e9f669cc0a6a85cf17180c09a6686db9f4002 ] + +Since 8b3a087f7f65 ("ALSA: usb-audio: Unify virtual type units type to +UAC3 values") usb-audio is using UAC3_CLOCK_SOURCE instead of +bDescriptorSubtype, later refactored with e0ccdef9265 ("ALSA: usb-audio: +Clean up check_input_term()") into parse_term_uac2_clock_source(). + +This breaks the clock source selection for at least my +1397:0003 BEHRINGER International GmbH FCA610 Pro. + +Fix by using UAC2_CLOCK_SOURCE in parse_term_uac2_clock_source(). + +Fixes: 8b3a087f7f65 ("ALSA: usb-audio: Unify virtual type units type to UAC3 values") +Signed-off-by: René Rebe +Link: https://patch.msgid.link/20251125.154149.1121389544970412061.rene@exactco.de +Signed-off-by: Takashi Iwai +Signed-off-by: Sasha Levin +--- + sound/usb/mixer.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/sound/usb/mixer.c b/sound/usb/mixer.c +index 787cdeddbdf44..e19d962fab870 100644 +--- a/sound/usb/mixer.c ++++ b/sound/usb/mixer.c +@@ -930,7 +930,7 @@ static int parse_term_uac2_clock_source(struct mixer_build *state, + { + struct uac_clock_source_descriptor *d = p1; + +- term->type = UAC3_CLOCK_SOURCE << 16; /* virtual type */ ++ term->type = UAC2_CLOCK_SOURCE << 16; /* virtual type */ + term->id = id; + term->name = d->iClockSource; + return 0; +-- +2.51.0 + diff --git a/queue-6.6/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch b/queue-6.6/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch new file mode 100644 index 0000000000..14ff9e1de2 --- /dev/null +++ b/queue-6.6/net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch @@ -0,0 +1,168 @@ +From 55eec5a3e727d0bacc1fb1ce14d394ea9b3fdb90 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Mon, 3 Nov 2025 10:28:11 -0600 +Subject: net: ethernet: ti: netcp: Standardize knav_dma_open_channel to return + NULL on error + +From: Nishanth Menon + +[ Upstream commit 90a88306eb874fe4bbdd860e6c9787f5bbc588b5 ] + +Make knav_dma_open_channel consistently return NULL on error instead +of ERR_PTR. Currently the header include/linux/soc/ti/knav_dma.h +returns NULL when the driver is disabled, but the driver +implementation does not even return NULL or ERR_PTR on failure, +causing inconsistency in the users. This results in a crash in +netcp_free_navigator_resources as followed (trimmed): + +Unhandled fault: alignment exception (0x221) at 0xfffffff2 +[fffffff2] *pgd=80000800207003, *pmd=82ffda003, *pte=00000000 +Internal error: : 221 [#1] SMP ARM +Modules linked in: +CPU: 0 UID: 0 PID: 1 Comm: swapper/0 Not tainted 6.17.0-rc7 #1 NONE +Hardware name: Keystone +PC is at knav_dma_close_channel+0x30/0x19c +LR is at netcp_free_navigator_resources+0x2c/0x28c + +[... TRIM...] + +Call trace: + knav_dma_close_channel from netcp_free_navigator_resources+0x2c/0x28c + netcp_free_navigator_resources from netcp_ndo_open+0x430/0x46c + netcp_ndo_open from __dev_open+0x114/0x29c + __dev_open from __dev_change_flags+0x190/0x208 + __dev_change_flags from netif_change_flags+0x1c/0x58 + netif_change_flags from dev_change_flags+0x38/0xa0 + dev_change_flags from ip_auto_config+0x2c4/0x11f0 + ip_auto_config from do_one_initcall+0x58/0x200 + do_one_initcall from kernel_init_freeable+0x1cc/0x238 + kernel_init_freeable from kernel_init+0x1c/0x12c + kernel_init from ret_from_fork+0x14/0x38 +[... TRIM...] + +Standardize the error handling by making the function return NULL on +all error conditions. The API is used in just the netcp_core.c so the +impact is limited. + +Note, this change, in effect reverts commit 5b6cb43b4d62 ("net: +ethernet: ti: netcp_core: return error while dma channel open issue"), +but provides a less error prone implementation. + +Suggested-by: Simon Horman +Suggested-by: Jacob Keller +Signed-off-by: Nishanth Menon +Reviewed-by: Jacob Keller +Link: https://patch.msgid.link/20251103162811.3730055-1-nm@ti.com +Signed-off-by: Jakub Kicinski +Signed-off-by: Sasha Levin +--- + drivers/net/ethernet/ti/netcp_core.c | 10 +++++----- + drivers/soc/ti/knav_dma.c | 14 +++++++------- + 2 files changed, 12 insertions(+), 12 deletions(-) + +diff --git a/drivers/net/ethernet/ti/netcp_core.c b/drivers/net/ethernet/ti/netcp_core.c +index d829113c16eee..1c33a9c9ddb5a 100644 +--- a/drivers/net/ethernet/ti/netcp_core.c ++++ b/drivers/net/ethernet/ti/netcp_core.c +@@ -1338,10 +1338,10 @@ int netcp_txpipe_open(struct netcp_tx_pipe *tx_pipe) + + tx_pipe->dma_channel = knav_dma_open_channel(dev, + tx_pipe->dma_chan_name, &config); +- if (IS_ERR(tx_pipe->dma_channel)) { ++ if (!tx_pipe->dma_channel) { + dev_err(dev, "failed opening tx chan(%s)\n", + tx_pipe->dma_chan_name); +- ret = PTR_ERR(tx_pipe->dma_channel); ++ ret = -EINVAL; + goto err; + } + +@@ -1359,7 +1359,7 @@ int netcp_txpipe_open(struct netcp_tx_pipe *tx_pipe) + return 0; + + err: +- if (!IS_ERR_OR_NULL(tx_pipe->dma_channel)) ++ if (tx_pipe->dma_channel) + knav_dma_close_channel(tx_pipe->dma_channel); + tx_pipe->dma_channel = NULL; + return ret; +@@ -1678,10 +1678,10 @@ static int netcp_setup_navigator_resources(struct net_device *ndev) + + netcp->rx_channel = knav_dma_open_channel(netcp->netcp_device->device, + netcp->dma_chan_name, &config); +- if (IS_ERR(netcp->rx_channel)) { ++ if (!netcp->rx_channel) { + dev_err(netcp->ndev_dev, "failed opening rx chan(%s\n", + netcp->dma_chan_name); +- ret = PTR_ERR(netcp->rx_channel); ++ ret = -EINVAL; + goto fail; + } + +diff --git a/drivers/soc/ti/knav_dma.c b/drivers/soc/ti/knav_dma.c +index 0fbc37cd51231..f599eaab3c562 100644 +--- a/drivers/soc/ti/knav_dma.c ++++ b/drivers/soc/ti/knav_dma.c +@@ -402,7 +402,7 @@ static int of_channel_match_helper(struct device_node *np, const char *name, + * @name: slave channel name + * @config: dma configuration parameters + * +- * Returns pointer to appropriate DMA channel on success or error. ++ * Return: Pointer to appropriate DMA channel on success or NULL on error. + */ + void *knav_dma_open_channel(struct device *dev, const char *name, + struct knav_dma_cfg *config) +@@ -414,13 +414,13 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + + if (!kdev) { + pr_err("keystone-navigator-dma driver not registered\n"); +- return (void *)-EINVAL; ++ return NULL; + } + + chan_num = of_channel_match_helper(dev->of_node, name, &instance); + if (chan_num < 0) { + dev_err(kdev->dev, "No DMA instance with name %s\n", name); +- return (void *)-EINVAL; ++ return NULL; + } + + dev_dbg(kdev->dev, "initializing %s channel %d from DMA %s\n", +@@ -431,7 +431,7 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + if (config->direction != DMA_MEM_TO_DEV && + config->direction != DMA_DEV_TO_MEM) { + dev_err(kdev->dev, "bad direction\n"); +- return (void *)-EINVAL; ++ return NULL; + } + + /* Look for correct dma instance */ +@@ -443,7 +443,7 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + } + if (!dma) { + dev_err(kdev->dev, "No DMA instance with name %s\n", instance); +- return (void *)-EINVAL; ++ return NULL; + } + + /* Look for correct dma channel from dma instance */ +@@ -463,14 +463,14 @@ void *knav_dma_open_channel(struct device *dev, const char *name, + if (!chan) { + dev_err(kdev->dev, "channel %d is not in DMA %s\n", + chan_num, instance); +- return (void *)-EINVAL; ++ return NULL; + } + + if (atomic_read(&chan->ref_count) >= 1) { + if (!check_config(chan, config)) { + dev_err(kdev->dev, "channel %d config miss-match\n", + chan_num); +- return (void *)-EINVAL; ++ return NULL; + } + } + +-- +2.51.0 + diff --git a/queue-6.6/series b/queue-6.6/series index 6ae84b9c8b..a167a43c33 100644 --- a/queue-6.6/series +++ b/queue-6.6/series @@ -66,3 +66,6 @@ kconfig-nconf-initialize-the-default-locale-at-start.patch f2fs-compress-change-the-first-parameter-of-page_arr.patch s390-mm-fix-__ptep_rdp-inline-assembly.patch f2fs-compress-fix-uaf-of-f2fs_inode_info-in-f2fs_fre.patch +alsa-usb-audio-fix-uac2-clock-source-at-terminal-par.patch +net-ethernet-ti-netcp-standardize-knav_dma_open_chan.patch +tracing-tools-fix-incorrcet-short-option-in-usage-te.patch diff --git a/queue-6.6/tracing-tools-fix-incorrcet-short-option-in-usage-te.patch b/queue-6.6/tracing-tools-fix-incorrcet-short-option-in-usage-te.patch new file mode 100644 index 0000000000..085058dca5 --- /dev/null +++ b/queue-6.6/tracing-tools-fix-incorrcet-short-option-in-usage-te.patch @@ -0,0 +1,43 @@ +From bc09fd71975bcda5e978e1907b77be066ce2c4be Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Thu, 6 Nov 2025 11:10:40 +0800 +Subject: tracing/tools: Fix incorrcet short option in usage text for --threads + +From: Zhang Chujun + +[ Upstream commit 53afec2c8fb2a562222948cb1c2aac48598578c9 ] + +The help message incorrectly listed '-t' as the short option for +--threads, but the actual getopt_long configuration uses '-e'. +This mismatch can confuse users and lead to incorrect command-line +usage. This patch updates the usage string to correctly show: + "-e, --threads NRTHR" +to match the implementation. + +Note: checkpatch.pl reports a false-positive spelling warning on +'Run', which is intentional. + +Link: https://patch.msgid.link/20251106031040.1869-1-zhangchujun@cmss.chinamobile.com +Signed-off-by: Zhang Chujun +Signed-off-by: Steven Rostedt (Google) +Signed-off-by: Sasha Levin +--- + tools/tracing/latency/latency-collector.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/tools/tracing/latency/latency-collector.c b/tools/tracing/latency/latency-collector.c +index cf263fe9deaf4..ef97916e3873a 100644 +--- a/tools/tracing/latency/latency-collector.c ++++ b/tools/tracing/latency/latency-collector.c +@@ -1725,7 +1725,7 @@ static void show_usage(void) + "-n, --notrace\t\tIf latency is detected, do not print out the content of\n" + "\t\t\tthe trace file to standard output\n\n" + +-"-t, --threads NRTHR\tRun NRTHR threads for printing. Default is %d.\n\n" ++"-e, --threads NRTHR\tRun NRTHR threads for printing. Default is %d.\n\n" + + "-r, --random\t\tArbitrarily sleep a certain amount of time, default\n" + "\t\t\t%ld ms, before reading the trace file. The\n" +-- +2.51.0 + -- 2.47.3