From fcf50ed6e7a9cc22477ff1003233cdc756afef02 Mon Sep 17 00:00:00 2001 From: Anas Nashif Date: Tue, 29 Aug 2023 19:32:46 +0000 Subject: [PATCH] kernel: move timeout_q.h to kernel/include This is a private kernel header with private kernel APIs, it should not be exposed in the public zephyr include directory. Once sample remains to be fixed (metairq_dispatch), which currently uses private APIs from that header, it should not be the case. Signed-off-by: Anas Nashif --- kernel/include/ksched.h | 2 +- {include/zephyr => kernel/include}/timeout_q.h | 0 kernel/include/wait_q.h | 2 +- kernel/timeout.c | 2 +- samples/kernel/metairq_dispatch/CMakeLists.txt | 4 ++++ samples/kernel/metairq_dispatch/src/msgdev.c | 2 +- soc/x86/intel_ish/intel_ish5/pm/power.c | 1 - subsys/pm/pm.c | 1 - 8 files changed, 8 insertions(+), 6 deletions(-) rename {include/zephyr => kernel/include}/timeout_q.h (100%) diff --git a/kernel/include/ksched.h b/kernel/include/ksched.h index 0ec1897a2f3..4676a0beca1 100644 --- a/kernel/include/ksched.h +++ b/kernel/include/ksched.h @@ -9,7 +9,7 @@ #include #include -#include +#include #include #include diff --git a/include/zephyr/timeout_q.h b/kernel/include/timeout_q.h similarity index 100% rename from include/zephyr/timeout_q.h rename to kernel/include/timeout_q.h diff --git a/kernel/include/wait_q.h b/kernel/include/wait_q.h index 3edcb77702a..2c8eeefbf25 100644 --- a/kernel/include/wait_q.h +++ b/kernel/include/wait_q.h @@ -13,7 +13,7 @@ #include #include #include -#include +#include #ifdef __cplusplus extern "C" { diff --git a/kernel/timeout.c b/kernel/timeout.c index 1d3149b2afe..339bc65a014 100644 --- a/kernel/timeout.c +++ b/kernel/timeout.c @@ -7,7 +7,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/samples/kernel/metairq_dispatch/CMakeLists.txt b/samples/kernel/metairq_dispatch/CMakeLists.txt index fe39b05df2e..2b16c4b410e 100644 --- a/samples/kernel/metairq_dispatch/CMakeLists.txt +++ b/samples/kernel/metairq_dispatch/CMakeLists.txt @@ -6,3 +6,7 @@ find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE}) project(metairq_dispatch) target_sources(app PRIVATE src/main.c src/msgdev.c) + +target_include_directories(app PRIVATE + ${ZEPHYR_BASE}/kernel/include + ) diff --git a/samples/kernel/metairq_dispatch/src/msgdev.c b/samples/kernel/metairq_dispatch/src/msgdev.c index 142f46d043d..d4ba5d5895f 100644 --- a/samples/kernel/metairq_dispatch/src/msgdev.c +++ b/samples/kernel/metairq_dispatch/src/msgdev.c @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: Apache-2.0 */ -#include +#include #include "msgdev.h" /* This file implements a fake device that creates and enqueues diff --git a/soc/x86/intel_ish/intel_ish5/pm/power.c b/soc/x86/intel_ish/intel_ish5/pm/power.c index a2ea8f65ce5..3ad15eee36b 100644 --- a/soc/x86/intel_ish/intel_ish5/pm/power.c +++ b/soc/x86/intel_ish/intel_ish5/pm/power.c @@ -8,7 +8,6 @@ #include #include #include -#include #include #include #include diff --git a/subsys/pm/pm.c b/subsys/pm/pm.c index ae6e8505d89..cfeadaa4447 100644 --- a/subsys/pm/pm.c +++ b/subsys/pm/pm.c @@ -7,7 +7,6 @@ #include #include #include -#include #include #include #include