[kernel][warnings] fix a few -Wmissing-declarations warnings in the kernel
This commit is contained in:
11
kernel/include/kernel/init.h
Normal file
11
kernel/include/kernel/init.h
Normal file
@@ -0,0 +1,11 @@
|
||||
/*
|
||||
* Copyright (c) 2021 Travis Geiselbrecht
|
||||
*
|
||||
* Use of this source code is governed by a MIT-style
|
||||
* license that can be found in the LICENSE file or at
|
||||
* https://opensource.org/licenses/MIT
|
||||
*/
|
||||
#pragma once
|
||||
|
||||
void kernel_init(void);
|
||||
|
||||
@@ -5,6 +5,8 @@
|
||||
* license that can be found in the LICENSE file or at
|
||||
* https://opensource.org/licenses/MIT
|
||||
*/
|
||||
#include <kernel/init.h>
|
||||
|
||||
#include <kernel/debug.h>
|
||||
#include <kernel/mp.h>
|
||||
#include <kernel/port.h>
|
||||
|
||||
@@ -152,7 +152,7 @@ static void novm_init(uint level) {
|
||||
LK_INIT_HOOK(novm, &novm_init, LK_INIT_LEVEL_PLATFORM_EARLY - 1);
|
||||
#endif
|
||||
|
||||
void *novm_alloc_helper(struct novm_arena *n, size_t pages) {
|
||||
static void *novm_alloc_helper(struct novm_arena *n, size_t pages) {
|
||||
if (pages == 0 || pages > n->pages)
|
||||
return NULL;
|
||||
|
||||
|
||||
@@ -108,7 +108,7 @@ static void wakeup_cpu_for_thread(thread_t *t)
|
||||
mp_reschedule(1U << pinned_cpu, 0);
|
||||
}
|
||||
|
||||
void init_thread_struct(thread_t *t, const char *name) {
|
||||
static void init_thread_struct(thread_t *t, const char *name) {
|
||||
memset(t, 0, sizeof(thread_t));
|
||||
t->magic = THREAD_MAGIC;
|
||||
thread_set_pinned_cpu(t, -1);
|
||||
|
||||
Reference in New Issue
Block a user