Skip to content

Commit a53c28b

Browse files
committed
cxl/acpi: Autoload driver for 'cxl_acpi' test devices
In support of CXL unit tests in the ndctl project, arrange for the cxl_acpi driver to load in response to the registration of cxl_test devices. Reported-by: Dave Jiang <[email protected]> Tested-by: Dave Jiang <[email protected]> Reviewed-by: Vishal Verma <[email protected]> Link: https://lore.kernel.org/r/165853775783.2430596.13637998086505316619.stgit@dwillia2-xfh.jf.intel.com Signed-off-by: Dan Williams <[email protected]>
1 parent 5e42bcb commit a53c28b

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

drivers/cxl/acpi.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -515,12 +515,19 @@ static const struct acpi_device_id cxl_acpi_ids[] = {
515515
};
516516
MODULE_DEVICE_TABLE(acpi, cxl_acpi_ids);
517517

518+
static const struct platform_device_id cxl_test_ids[] = {
519+
{ "cxl_acpi" },
520+
{ },
521+
};
522+
MODULE_DEVICE_TABLE(platform, cxl_test_ids);
523+
518524
static struct platform_driver cxl_acpi_driver = {
519525
.probe = cxl_acpi_probe,
520526
.driver = {
521527
.name = KBUILD_MODNAME,
522528
.acpi_match_table = cxl_acpi_ids,
523529
},
530+
.id_table = cxl_test_ids,
524531
};
525532

526533
module_platform_driver(cxl_acpi_driver);

0 commit comments

Comments
 (0)