mirror of https://github.com/thesofproject/sof.git
agent: add option to enable system agent
Adds config option to enable system agent. It can be disabled on the still unstable systems, which cannot guarantee that agent will execute on time. Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
This commit is contained in:
parent
742ee80785
commit
6d6f61cd72
|
@ -9,6 +9,7 @@
|
|||
#define __SOF_LIB_AGENT_H__
|
||||
|
||||
#include <sof/schedule/task.h>
|
||||
#include <config.h>
|
||||
#include <stdbool.h>
|
||||
#include <stdint.h>
|
||||
|
||||
|
@ -22,6 +23,14 @@ struct sa {
|
|||
struct task work;
|
||||
};
|
||||
|
||||
#if CONFIG_HAVE_AGENT
|
||||
|
||||
void sa_init(struct sof *sof, uint64_t timeout);
|
||||
|
||||
#else
|
||||
|
||||
static inline void sa_init(struct sof *sof, uint64_t timeout) { }
|
||||
|
||||
#endif
|
||||
|
||||
#endif /* __SOF_LIB_AGENT_H__ */
|
||||
|
|
|
@ -5,11 +5,14 @@ if(BUILD_LIBRARY)
|
|||
return()
|
||||
endif()
|
||||
|
||||
if(CONFIG_HAVE_AGENT)
|
||||
add_local_sources(sof agent.c)
|
||||
endif()
|
||||
|
||||
add_local_sources(sof
|
||||
lib.c
|
||||
alloc.c
|
||||
notifier.c
|
||||
agent.c
|
||||
pm_runtime.c
|
||||
clk.c
|
||||
dma.c
|
||||
|
|
|
@ -245,4 +245,12 @@ config SYSTICK_PERIOD
|
|||
as a timeout check value for system agent.
|
||||
Value should be provided in microseconds.
|
||||
|
||||
config HAVE_AGENT
|
||||
bool "Enable system agent"
|
||||
default y
|
||||
help
|
||||
Enables system agent. It can be disabled on systems
|
||||
which are still unstable and cannot assure that
|
||||
system agent will always execute on time.
|
||||
|
||||
endmenu
|
||||
|
|
Loading…
Reference in New Issue