From f52ddaf5e771c753663a719834848fde92b219f8 Mon Sep 17 00:00:00 2001 From: Pengpeng Hou Date: Tue, 16 Jun 2026 08:47:41 +0800 Subject: [PATCH 1/3] firmware: ti_sci: Undo list publication on populate failure ti_sci_probe() publishes the controller on the global ti_sci_list before creating child devices. If of_platform_populate() fails after creating some children, the probe error path leaves the children around and leaves the failed controller visible through ti_sci_get_handle(). Depopulate any children created by the failed populate call and remove the controller from the global list before returning the probe error. Signed-off-by: Pengpeng Hou Link: https://patch.msgid.link/20260616004741.1726-1-pengpeng@iscas.ac.cn Signed-off-by: Nishanth Menon --- drivers/firmware/ti_sci.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/firmware/ti_sci.c b/drivers/firmware/ti_sci.c index 590a464403c5..cc747ab0237f 100644 --- a/drivers/firmware/ti_sci.c +++ b/drivers/firmware/ti_sci.c @@ -4225,6 +4225,10 @@ static int ti_sci_probe(struct platform_device *pdev) ret = of_platform_populate(dev->of_node, NULL, NULL, dev); if (ret) { dev_err(dev, "platform_populate failed %pe\n", ERR_PTR(ret)); + of_platform_depopulate(dev); + mutex_lock(&ti_sci_list_mutex); + list_del(&info->node); + mutex_unlock(&ti_sci_list_mutex); goto out; } return 0; From 3c817862759913097f11467ed4ed2bbf974dabaf Mon Sep 17 00:00:00 2001 From: Pengpeng Hou Date: Mon, 6 Jul 2026 22:47:06 +0800 Subject: [PATCH 2/3] soc: ti: knav_qmss: Remove debugfs file on teardown knav_queue_probe() creates the global qmss debugfs file whose show callback reads the global knav_qdev state. knav_queue_remove() tears down the queue manager resources but leaves the debugfs file published. Save the debugfs dentry in struct knav_device and remove it during teardown before the resources used by the show callback are released. While touching the debugfs_create_file() call, spell the unchanged read- only file mode as 0444. Fixes: 41f93af900a2 ("soc: ti: add Keystone Navigator QMSS driver") Signed-off-by: Pengpeng Hou Link: https://patch.msgid.link/20260706144706.96313-1-pengpeng@iscas.ac.cn Signed-off-by: Nishanth Menon --- drivers/soc/ti/knav_qmss.h | 1 + drivers/soc/ti/knav_qmss_queue.c | 7 +++++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/drivers/soc/ti/knav_qmss.h b/drivers/soc/ti/knav_qmss.h index 037dc1b36645..8a624fbda84a 100644 --- a/drivers/soc/ti/knav_qmss.h +++ b/drivers/soc/ti/knav_qmss.h @@ -304,6 +304,7 @@ struct knav_device { struct list_head pools; struct list_head pdsps; struct list_head qmgrs; + struct dentry *debugfs_file; enum qmss_version version; }; diff --git a/drivers/soc/ti/knav_qmss_queue.c b/drivers/soc/ti/knav_qmss_queue.c index 7410b63af0e6..3e4041454f69 100644 --- a/drivers/soc/ti/knav_qmss_queue.c +++ b/drivers/soc/ti/knav_qmss_queue.c @@ -1849,8 +1849,9 @@ static int knav_queue_probe(struct platform_device *pdev) goto err; } - debugfs_create_file("qmss", S_IFREG | S_IRUGO, NULL, NULL, - &knav_queue_debug_fops); + knav_qdev->debugfs_file = + debugfs_create_file("qmss", 0444, NULL, NULL, + &knav_queue_debug_fops); device_ready = true; return 0; @@ -1868,6 +1869,8 @@ static void knav_queue_remove(struct platform_device *pdev) struct knav_device *kdev = platform_get_drvdata(pdev); device_ready = false; + debugfs_remove(kdev->debugfs_file); + kdev->debugfs_file = NULL; knav_queue_stop_pdsps(kdev); knav_queue_free_regions(kdev); knav_free_queue_ranges(kdev); From dce7afe3efe485a99200a59dc78738539cbd133f Mon Sep 17 00:00:00 2001 From: Pan Chuang Date: Mon, 20 Jul 2026 17:59:12 +0800 Subject: [PATCH 3/3] soc: ti: wkup_m3_ipc: Remove redundant dev_err() Since commit 55b48e23f5c4 ("genirq/devres: Add error handling in devm_request_*_irq()"), devm_request_irq() automatically logs detailed error messages on failure. Remove the now-redundant driver-specific dev_err() calls. Signed-off-by: Pan Chuang Reviewed-by: Hari Prasath Gujulan Elango Link: https://patch.msgid.link/20260720095920.542801-7-panchuang@vivo.com Signed-off-by: Nishanth Menon --- drivers/soc/ti/wkup_m3_ipc.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/soc/ti/wkup_m3_ipc.c b/drivers/soc/ti/wkup_m3_ipc.c index 5845fc652adc..f8640cdc2a21 100644 --- a/drivers/soc/ti/wkup_m3_ipc.c +++ b/drivers/soc/ti/wkup_m3_ipc.c @@ -630,10 +630,8 @@ static int wkup_m3_ipc_probe(struct platform_device *pdev) ret = devm_request_irq(dev, irq, wkup_m3_txev_handler, 0, "wkup_m3_txev", m3_ipc); - if (ret) { - dev_err(dev, "request_irq failed\n"); + if (ret) return ret; - } m3_ipc->mbox_client.dev = dev; m3_ipc->mbox_client.tx_done = NULL;