From 5a368e9010a500d9714c292552877ba5b4885c74 Mon Sep 17 00:00:00 2001 From: batt Date: Wed, 25 Mar 2009 10:47:26 +0000 Subject: [PATCH] Start to refactor kernel configuration. git-svn-id: https://src.develer.com/svnoss/bertos/trunk@2414 38d2e660-2303-0410-9eaa-f027e97ec537 --- bertos/cfg/cfg_proc.h | 105 ++++++++++++++++++++++++++++++++++++++++++ bertos/kern/proc.h | 2 +- 2 files changed, 106 insertions(+), 1 deletion(-) create mode 100644 bertos/cfg/cfg_proc.h diff --git a/bertos/cfg/cfg_proc.h b/bertos/cfg/cfg_proc.h new file mode 100644 index 00000000..7b7785e1 --- /dev/null +++ b/bertos/cfg/cfg_proc.h @@ -0,0 +1,105 @@ +/** + * \file + * + * + * \brief Kernel configuration parameters + * + * \version $Id$ + * \author Bernie Innocenti + */ + +#ifndef CFG_PROC_H +#define CFG_PROC_H + +/** + * Enable the multithreading kernel. + * + * $WIZ$ type = "autoenabled" + */ +#define CONFIG_KERN 0 + +/** + * Left for backwards compatibility, do not use. + * Will be deprecated. + */ +#define CONFIG_KERN_SCHED CONFIG_KERN + +/** + * Kernel interrupt supervisor. + * $WIZ$ type = "boolean" + */ +#define CONFIG_KERN_IRQ 0 + +/** + * Dynamic memory allocation for processes. + * + * $WIZ$ type = "boolean" + */ +#define CONFIG_KERN_HEAP 0 + +/** + * Preemptive process scheduling. WARNING: Experimental, do not use! + * + * $WIZ$ type = "boolean" + */ +#define CONFIG_KERN_PREEMPT 0 + +/** + * Priority-based scheduling policy. + * $WIZ$ type = "boolean" + */ +#define CONFIG_KERN_PRI 0 + +/** + * Time sharing quantum (a prime number prevents interference effects) [ms]. + * + * $WIZ$ type = "int" + * $WIZ$ min = "0" + */ +#define CONFIG_KERN_QUANTUM 47 + +/** + * Module logging level. + * + * $WIZ$ type = "enum" + * $WIZ$ value_list = "log_level" + */ +#define KERN_LOG_LEVEL LOG_LVL_ERR + +/** + * Module logging level. + * + * $WIZ$ type = "enum" + * $WIZ$ value_list = "log_level" + */ +#define KERN_LOG_FORMAT LOG_FMT_VERBOSE + +#endif /* CFG_PROC_H */ diff --git a/bertos/kern/proc.h b/bertos/kern/proc.h index cb35af5d..abd68fc6 100644 --- a/bertos/kern/proc.h +++ b/bertos/kern/proc.h @@ -36,7 +36,7 @@ * \author Bernie Innocenti * * $WIZ$ module_name = "kernel" - * $WIZ$ module_configuration = "bertos/cfg/cfg_kern.h" + * $WIZ$ module_configuration = "bertos/cfg/cfg_proc.h" */ #ifndef KERN_PROC_H -- 2.25.1