mirror of
https://github.com/apache/nuttx.git
synced 2026-05-20 20:44:39 +08:00
sched/cpuload: move g_cpuload_wdog to private chapter
coding style Signed-off-by: chao an <anchao@lixiang.com>
This commit is contained in:
@@ -86,6 +86,14 @@
|
||||
|
||||
volatile clock_t g_cpuload_total;
|
||||
|
||||
/****************************************************************************
|
||||
* Private Data
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_SCHED_CPULOAD_SYSCLK
|
||||
static struct wdog_s g_cpuload_wdog;
|
||||
#endif
|
||||
|
||||
/****************************************************************************
|
||||
* Private Functions
|
||||
****************************************************************************/
|
||||
@@ -279,7 +287,6 @@ int clock_cpuload(int pid, FAR struct cpuload_s *cpuload)
|
||||
#ifdef CONFIG_SCHED_CPULOAD_SYSCLK
|
||||
void cpuload_init(void)
|
||||
{
|
||||
static struct wdog_s g_cpuload_wdog;
|
||||
wd_start(&g_cpuload_wdog, CPULOAD_SAMPLING_PERIOD, cpuload_callback,
|
||||
(wdparm_t)&g_cpuload_wdog);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user