summaryrefslogtreecommitdiff
path: root/drivers/pci/ide.c
diff options
context:
space:
mode:
authorDan Williams <dan.j.williams@intel.com>2025-10-31 14:29:01 -0700
committerDan Williams <dan.j.williams@intel.com>2025-11-03 19:27:41 -0800
commita4438f06b1db15ce3d831ce82b8767665638aa2a (patch)
tree7707930e5b32ac2299e9dad0a9f6f640a0a92a48 /drivers/pci/ide.c
parent9ddaf9c3ed007cd03c1335fb40920ad76f72a3d5 (diff)
PCI/TSM: Report active IDE streams
Given that the platform TSM owns IDE Stream ID allocation, report the active streams via the TSM class device. Establish a symlink from the class device to the PCI endpoint device consuming the stream, named by the Stream ID. Acked-by: Bjorn Helgaas <bhelgaas@google.com> Reviewed-by: Jonathan Cameron <jonathan.cameron@huawei.com> Reviewed-by: Alexey Kardashevskiy <aik@amd.com> Link: https://patch.msgid.link/20251031212902.2256310-10-dan.j.williams@intel.com Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Diffstat (limited to 'drivers/pci/ide.c')
-rw-r--r--drivers/pci/ide.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/pci/ide.c b/drivers/pci/ide.c
index 4ae3872589fc..da5b1acccbb4 100644
--- a/drivers/pci/ide.c
+++ b/drivers/pci/ide.c
@@ -11,6 +11,7 @@
#include <linux/pci_regs.h>
#include <linux/slab.h>
#include <linux/sysfs.h>
+#include <linux/tsm.h>
#include "pci.h"
@@ -261,6 +262,9 @@ void pci_ide_stream_release(struct pci_ide *ide)
if (ide->partner[PCI_IDE_EP].enable)
pci_ide_stream_disable(pdev, ide);
+ if (ide->tsm_dev)
+ tsm_ide_stream_unregister(ide);
+
if (ide->partner[PCI_IDE_RP].setup)
pci_ide_stream_teardown(rp, ide);