Merge branch 'pci/endpoint/core'

- Fix configfs epf_group removal, which incorrectly did a list_del() on a
  list head, not a list entry (Damien Le Moal)

* pci/endpoint/core:
  PCI: endpoint: Fix configfs group removal on driver teardown
  PCI: endpoint: Fix configfs group list head handling
This commit is contained in:
Bjorn Helgaas
2025-07-31 16:11:45 -05:00
2 changed files with 2 additions and 1 deletions
+1
View File
@@ -691,6 +691,7 @@ void pci_ep_cfs_remove_epf_group(struct config_group *group)
if (IS_ERR_OR_NULL(group))
return;
list_del(&group->group_entry);
configfs_unregister_default_group(group);
}
EXPORT_SYMBOL(pci_ep_cfs_remove_epf_group);
+1 -1
View File
@@ -338,7 +338,7 @@ static void pci_epf_remove_cfs(struct pci_epf_driver *driver)
mutex_lock(&pci_epf_mutex);
list_for_each_entry_safe(group, tmp, &driver->epf_group, group_entry)
pci_ep_cfs_remove_epf_group(group);
list_del(&driver->epf_group);
WARN_ON(!list_empty(&driver->epf_group));
mutex_unlock(&pci_epf_mutex);
}