From: Dan Williams <[email protected]> Replace IS_ENABLED(CONFIG_CXL_REGION) with IS_ENABLED(CONFIG_DEV_DAX_CXL) so that dax_hmem only defers Soft Reserved ranges when CXL DAX support is enabled. This makes the coordination between dax_hmem and the CXL stack more precise and prevents deferral in unrelated CXL configurations.
Signed-off-by: Dan Williams <[email protected]> Signed-off-by: Smita Koralahalli <[email protected]> --- drivers/dax/hmem/hmem.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/dax/hmem/hmem.c b/drivers/dax/hmem/hmem.c index 02e79c7adf75..c2c110b194e5 100644 --- a/drivers/dax/hmem/hmem.c +++ b/drivers/dax/hmem/hmem.c @@ -66,7 +66,7 @@ static int hmem_register_device(struct device *host, int target_nid, long id; int rc; - if (IS_ENABLED(CONFIG_CXL_REGION) && + if (IS_ENABLED(CONFIG_DEV_DAX_CXL) && region_intersects(res->start, resource_size(res), IORESOURCE_MEM, IORES_DESC_CXL) != REGION_DISJOINT) { dev_dbg(host, "deferring range to CXL: %pr\n", res); -- 2.17.1

