sdm: Skip demura license checking in trusted VM
There is no feature license factory in trusted VM. The
change skips demura license checking in SDM.
Change-Id: If891bb57aeabac2a04be55bd43e17543b7ae615d
diff --git a/sdm/libs/core/display_builtin.cpp b/sdm/libs/core/display_builtin.cpp
index 5f5cf38..a93ea8e 100644
--- a/sdm/libs/core/display_builtin.cpp
+++ b/sdm/libs/core/display_builtin.cpp
@@ -733,7 +733,10 @@
panel_id_ = panel_id;
DLOGI("panel_id 0x%lx", panel_id_);
-#ifndef SDM_UNIT_TESTING
+#if defined SDM_UNIT_TESTING || defined TRUSTED_VM
+ demura_allowed = true;
+ demuratn_allowed = true;
+#else
if (!feature_license_factory_) {
DLOGI("Feature license factory is not available");
return kErrorNone;
@@ -790,9 +793,6 @@
return kErrorUndefined;
}
demuratn_allowed = *allowed;
-#else
- demura_allowed = true;
- demuratn_allowed = true;
#endif
DLOGI("Demura enable allowed %d, Anti-aging enable allowed %d", demura_allowed, demuratn_allowed);