From 1186ffc915f9c1a49c6beae6d3e659623f7df81e Mon Sep 17 00:00:00 2001 From: Jeremy Bettis Date: Mon, 1 May 2023 13:46:11 -0600 Subject: utils: Only exclude certain zephyr files When looking for bad lines that have coverage reported, only exclude a few files instead of all of zephyr. Commit a10cb8394d26d9c369eb5bd1c2ab64f0e955a898 caused bad lines in kernel/init.c, and this script could not see them. BRANCH=None BUG=b:272518464 TEST=./util/find_non_exec_lines.py build/zephyr/lcov.info Change-Id: Ic3dfd6783f4a556759be8e43ed97d36454743ab3 Signed-off-by: Jeremy Bettis Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/4496382 Reviewed-by: Simon Glass Auto-Submit: Jeremy Bettis Tested-by: Jeremy Bettis Commit-Queue: Simon Glass --- util/find_non_exec_lines.py | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/util/find_non_exec_lines.py b/util/find_non_exec_lines.py index e88d3f61ff..af5e972c79 100755 --- a/util/find_non_exec_lines.py +++ b/util/find_non_exec_lines.py @@ -36,7 +36,16 @@ def main() -> int: active_name = line[3:] # There are several files in zephyr that have odd coverage # but it seems consistent. - if not "src/third_party/zephyr" in active_name: + if ( + not "src/third_party/zephyr/cmsis/CMSIS/Core/Include/core_cm4.h" + in active_name + and not "src/third_party/zephyr/main/arch/arm/core/aarch32/mpu/arm_mpu.c" + in active_name + and not "src/third_party/zephyr/main/drivers/clock_control/clock_control_mchp_xec.c" + in active_name + and not "src/third_party/zephyr/main/lib/libc/minimal/include/" + in active_name + ): active_file = open( # pylint: disable=R1732 active_name, encoding="utf-8" ) -- cgit v1.2.1