2020-01-18 08:38:21 +00:00
|
|
|
/*
|
|
|
|
* Copyright (c) 2018-2020, Andreas Kling <kling@serenityos.org>
|
|
|
|
*
|
2021-04-22 08:24:48 +00:00
|
|
|
* SPDX-License-Identifier: BSD-2-Clause
|
2020-01-18 08:38:21 +00:00
|
|
|
*/
|
|
|
|
|
2018-12-24 21:59:10 +00:00
|
|
|
#pragma once
|
|
|
|
|
2020-04-08 11:30:50 +00:00
|
|
|
#include <AK/Forward.h>
|
2018-12-24 21:59:10 +00:00
|
|
|
|
2020-02-16 00:27:42 +00:00
|
|
|
namespace Kernel {
|
|
|
|
|
2020-04-08 11:30:50 +00:00
|
|
|
struct KernelSymbol {
|
2021-02-25 15:18:36 +00:00
|
|
|
FlatPtr address;
|
2022-04-01 17:58:27 +00:00
|
|
|
char const* name;
|
2018-12-24 21:59:10 +00:00
|
|
|
};
|
|
|
|
|
2021-08-04 15:52:14 +00:00
|
|
|
enum class PrintToScreen {
|
|
|
|
No,
|
|
|
|
Yes,
|
|
|
|
};
|
|
|
|
|
2021-11-10 23:55:02 +00:00
|
|
|
FlatPtr address_for_kernel_symbol(StringView name);
|
2022-04-01 17:58:27 +00:00
|
|
|
KernelSymbol const* symbolicate_kernel_address(FlatPtr);
|
2020-04-08 11:30:50 +00:00
|
|
|
void load_kernel_symbol_table();
|
2018-12-24 21:59:10 +00:00
|
|
|
|
2020-04-08 11:30:50 +00:00
|
|
|
extern bool g_kernel_symbols_available;
|
|
|
|
extern FlatPtr g_lowest_kernel_symbol_address;
|
|
|
|
extern FlatPtr g_highest_kernel_symbol_address;
|
2019-02-24 13:51:48 +00:00
|
|
|
|
2021-08-04 15:52:14 +00:00
|
|
|
void dump_backtrace(PrintToScreen print_to_screen = PrintToScreen::No);
|
2020-02-16 00:27:42 +00:00
|
|
|
|
|
|
|
}
|