From fcccf6f1d509e94c2b6145104ba9728bbe315574 Mon Sep 17 00:00:00 2001 From: Marvin Liu Date: Mon, 4 Jul 2016 16:57:59 +0800 Subject: [PATCH] examples/vm_power_manager: remove dependency on internal header Macro CHANNEL_CMDS_MAX_CPUS stand for the maximum number of cores controlled by virtual channels. This macro only be used in the example, so remove it from library to example header file. Signed-off-by: Marvin Liu --- examples/vm_power_manager/channel_manager.h | 8 +++++++- lib/librte_power/channel_commands.h | 7 ------- 2 files changed, 7 insertions(+), 8 deletions(-) diff --git a/examples/vm_power_manager/channel_manager.h b/examples/vm_power_manager/channel_manager.h index 67e26ecb00..47c3b9cd4f 100644 --- a/examples/vm_power_manager/channel_manager.h +++ b/examples/vm_power_manager/channel_manager.h @@ -41,7 +41,13 @@ extern "C" { #include #include #include -#include "channel_commands.h" + +/* Maximum number of CPUs */ +#define CHANNEL_CMDS_MAX_CPUS 64 +#if CHANNEL_CMDS_MAX_CPUS > 64 +#error Maximum number of cores is 64, overflow is guaranteed to \ + cause problems with VM Power Management +#endif /* Maximum name length including '\0' terminator */ #define CHANNEL_MGR_MAX_NAME_LEN 64 diff --git a/lib/librte_power/channel_commands.h b/lib/librte_power/channel_commands.h index de6d9269e7..383897bf84 100644 --- a/lib/librte_power/channel_commands.h +++ b/lib/librte_power/channel_commands.h @@ -40,13 +40,6 @@ extern "C" { #include -/* Maximum number of CPUs */ -#define CHANNEL_CMDS_MAX_CPUS 64 -#if CHANNEL_CMDS_MAX_CPUS > 64 -#error Maximum number of cores is 64, overflow is guaranteed to \ - cause problems with VM Power Management -#endif - /* Maximum number of channels per VM */ #define CHANNEL_CMDS_MAX_VM_CHANNELS 64 -- 2.20.1