summaryrefslogtreecommitdiffstats
path: root/drivers/misc/cxl/debugfs.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/misc/cxl/debugfs.c')
-rw-r--r--drivers/misc/cxl/debugfs.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/misc/cxl/debugfs.c b/drivers/misc/cxl/debugfs.c
index 18df6f44af2a..5751899e0c17 100644
--- a/drivers/misc/cxl/debugfs.c
+++ b/drivers/misc/cxl/debugfs.c
@@ -118,6 +118,10 @@ void cxl_debugfs_afu_remove(struct cxl_afu *afu)
int __init cxl_debugfs_init(void)
{
struct dentry *ent;
+
+ if (!cpu_has_feature(CPU_FTR_HVMODE))
+ return 0;
+
ent = debugfs_create_dir("cxl", NULL);
if (IS_ERR(ent))
return PTR_ERR(ent);