From 2b2fa660b06910e0d2dea375b1f2ff5c0979c547 Mon Sep 17 00:00:00 2001 From: Steven Wang Date: Mon, 2 Sep 2019 17:59:56 +0800 Subject: [PATCH] [Code coverage]: Fix the issue of function code coverage in device.c. It was reported in the code coverage report that Z_SYSCALL_HANDLER() was not called by other code, if we run "sanitycheck -p qemu_x86 --coverage -T tests/kernel/device/". The root cause is that we include "errno.h", which includes "include/generated/syscalls/device.h". It causes that the declare of device_get_binding() in "include/generated/syscalls/device.h" is marked as "has been called", rather than Z_SYSCALL_HANDLER() in device.c. So I remove "#include ", which is useless in device.c. Also, "#include " is removed for the same reason. Signed-off-by: Steven Wang --- kernel/device.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/kernel/device.c b/kernel/device.c index af517698b29..a7fa6aa1681 100644 --- a/kernel/device.c +++ b/kernel/device.c @@ -4,10 +4,8 @@ * SPDX-License-Identifier: Apache-2.0 */ -#include #include #include -#include #include #include