Skip to content

Commit be5c528

Browse files
Cui Chaodavejiang
authored andcommitted
cxl: Adjust the startup priority of cxl_pmem to be higher than that of cxl_acpi
During the cxl_acpi probe process, it checks whether the cxl_nvb device and driver have been attached. Currently, the startup priority of the cxl_pmem driver is lower than that of the cxl_acpi driver. At this point, the cxl_nvb driver has not yet been registered on the cxl_bus, causing the attachment check to fail. This results in a failure to add the root nvdimm bridge, leading to a cxl_acpi probe failure and ultimately affecting the subsequent loading of cxl drivers. As a consequence, only one mem device object exists on the cxl_bus, while the cxl_port device objects and decoder device objects are missing. The solution is to raise the startup priority of cxl_pmem to be higher than that of cxl_acpi, ensuring that the cxl_pmem driver is registered before the aforementioned attachment check occurs. Co-developed-by: Wang Yinfeng <[email protected]> Signed-off-by: Wang Yinfeng <[email protected]> Signed-off-by: Cui Chao <[email protected]> Fixes: e7e222a ("cxl: Move devm_cxl_add_nvdimm_bridge() to cxl_pmem.ko") Reviewed-by: Dan Williams <[email protected]> Link: https://patch.msgid.link/[email protected] Signed-off-by: Dave Jiang <[email protected]>
1 parent 9a6a209 commit be5c528

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

drivers/cxl/pmem.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -554,7 +554,7 @@ static __exit void cxl_pmem_exit(void)
554554

555555
MODULE_DESCRIPTION("CXL PMEM: Persistent Memory Support");
556556
MODULE_LICENSE("GPL v2");
557-
module_init(cxl_pmem_init);
557+
subsys_initcall(cxl_pmem_init);
558558
module_exit(cxl_pmem_exit);
559559
MODULE_IMPORT_NS("CXL");
560560
MODULE_ALIAS_CXL(CXL_DEVICE_NVDIMM_BRIDGE);

0 commit comments

Comments
 (0)