]> www.infradead.org Git - users/mchehab/rasdaemon.git/commitdiff
Makefile: only enable rbtree if needed
authorMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Mon, 18 Nov 2024 13:35:28 +0000 (14:35 +0100)
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Mon, 18 Nov 2024 13:40:04 +0000 (14:40 +0100)
Don't enable rbtree and ras-page-isolation code unconditionally.
Only enable it if PFA is compiled.

Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Makefile.am
configure.ac

index a64a1c92aea6aaa88da2e6bb16068cf519d45ba4..440d36dabed9a43efdf0a5683b93544df6439777 100644 (file)
@@ -69,7 +69,9 @@ endif
 if WITH_HISI_NS_DECODE
    rasdaemon_SOURCES += non-standard-hisi_hip08.c non-standard-hisilicon.c
 endif
-rasdaemon_SOURCES += rbtree.c ras-page-isolation.c
+if WITH_PFA
+   rasdaemon_SOURCES += rbtree.c ras-page-isolation.c
+endif
 if WITH_AMP_NS_DECODE
    rasdaemon_SOURCES += non-standard-ampere.c
 endif
index 3668672ce89944932fa95aba04285b0ac48fe996..a30f661dc3f630d60a629073a313e67369248fa5 100644 (file)
@@ -192,6 +192,8 @@ AS_IF([test "x$enable_memory_row_ce_pfa" = "xyes" || test "x$enable_all" == "xye
 AM_CONDITIONAL([WITH_MEMORY_ROW_CE_PFA], [test x$enable_memory_row_ce_pfa = xyes || test x$enable_all == xyes])
 AM_COND_IF([WITH_MEMORY_ROW_CE_PFA], [USE_MEMORY_ROW_CE_PFA="yes"], [USE_MEMORY_ROW_CE_PFA="no"])
 
+AM_CONDITIONAL([WITH_PFA], [test x$USE_MEMORY_CE_PFA = xyes || test x$USE_MEMORY_ROW_CE_PFA = xyes])
+
 AC_ARG_ENABLE([amp_ns_decode],
     AS_HELP_STRING([--enable-amp-ns-decode], [enable AMP_NS_DECODE events (currently experimental)]))