Merge tag 'ti-driver-soc-for-v7.3' of https://git.kernel.org/pub/scm/linux/kernel/git/ti/linux into soc/drivers

TI SoC driver updates for v7.3

Minor bug fixes and cleanups across TI SoC and firmware drivers:

- firmware: ti_sci: Fix a resource leak by undoing list publication when
  device populate fails, ensuring proper cleanup on error paths
- soc: ti: knav_qmss: Remove debugfs file on teardown to avoid stale
  entries and potential use-after-free scenarios
- soc: ti: wkup_m3_ipc: Remove redundant dev_err() call to avoid
  duplicate error reporting

* tag 'ti-driver-soc-for-v7.3' of https://git.kernel.org/pub/scm/linux/kernel/git/ti/linux:
  soc: ti: wkup_m3_ipc: Remove redundant dev_err()
  soc: ti: knav_qmss: Remove debugfs file on teardown
  firmware: ti_sci: Undo list publication on populate failure

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
This commit is contained in:
Arnd Bergmann
2026-08-10 09:48:27 +02:00
4 changed files with 11 additions and 5 deletions

View File

@@ -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;

View File

@@ -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;
};

View File

@@ -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);

View File

@@ -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;