From aeaabf3c1f8ab93464339f38aca8c4c959d1f820 Mon Sep 17 00:00:00 2001 From: Ray Chin Date: Thu, 25 Jan 2024 16:52:18 +0800 Subject: [PATCH] Bypass Live if there is no HW FE nor SW FE. Bug: 321774563 Test: atest VtsHalTvTunerTargetTest on cf_x86_tv-userdebug Change-Id: I801bd81f80e4b15f1e3064ed796951aead087557 --- .../VtsHalTvTunerTestConfigurations.h | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/tv/tuner/aidl/vts/functional/VtsHalTvTunerTestConfigurations.h b/tv/tuner/aidl/vts/functional/VtsHalTvTunerTestConfigurations.h index 5c13ed081a..ff94639466 100644 --- a/tv/tuner/aidl/vts/functional/VtsHalTvTunerTestConfigurations.h +++ b/tv/tuner/aidl/vts/functional/VtsHalTvTunerTestConfigurations.h @@ -731,9 +731,20 @@ inline void determineLive() { if (videoFilterIds.empty() || audioFilterIds.empty() || frontendMap.empty()) { return; } - if (hasSwFe && !hasHwFe && dvrMap.empty()) { - ALOGD("Cannot configure Live. Only software frontends and no dvr connections"); - return; + if (!hasHwFe) { + if (hasSwFe) { + if (dvrMap.empty()) { + ALOGD("Cannot configure Live. Only software frontends and no dvr connections."); + return; + } + // Live is available if there is SW FE and some DVR is attached. + } else { + // We will arrive here because frontendMap won't be empty since + // there will be at least a default frontend declared. But the + // default frontend doesn't count as "hasSwFe". + ALOGD("Cannot configure Live. No frontend declared at all."); + return; + } } ALOGD("Can support live"); live.hasFrontendConnection = true;