| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364 |
- /* include/kernel/kernel.h
- *
- * Copyright (C) 2021, 2022 intirain.
- *
- * This file is part of evx.
- *
- * evx is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
- *
- * evx is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with evx. If not, see <https://www.gnu.org/licenses/>
- */
- #ifndef __KMLOG_H
- #define __KMLOG_H
- #ifndef __ASSEMBLER__
- #include <sys/types.h>
- #include <config.h>
- #include <stdarg.h>
- int kmlog(char *buf, ...);
- /* i think this is enough in kernel and not so big, because kernel
- * heap in x86 has 512k+ */
- #define KMLOG_SIZE 32768
- extern char *kmlog_buf;
- extern int kmlog_index;
- #define KERN_DEBUG "#0"
- #define KERN_INFO "#1"
- #define KERN_NOTICE "#2"
- #define KERN_WARN "#3"
- #define KERN_ERR "#4"
- #define KERN_EMERG "#5"
- #define KERN_ABANDON "#6"
- #ifndef CONFIG_KMLOG_LEVEL
- #define KMLOG_LEVEL -1
- #else
- #define KMLOG_LEVEL CONFIG_KMLOG_LEVEL
- #endif
- #endif
- #endif
|