[drv.uart] Make level_names and area_names const

The bug from 3be4b10 should not have happened in the first place, as
level_names and area_names should not have been in .data but in .rodata
(or .data.rel.ro in this case), so this change makes them const.
This commit is contained in:
Justin C. Miller
2022-02-13 00:12:42 -08:00
parent b46b6363ff
commit b353d68193

View File

@@ -31,8 +31,8 @@ struct entry
};
static const uint8_t level_colors[] = {0x07, 0x07, 0x0f, 0x0b, 0x09};
const char *level_names[] = {"", "debug", "info", "warn", "error", "fatal"};
const char *area_names[] = {
char const * const level_names[] = {"", "debug", "info", "warn", "error", "fatal"};
char const * const area_names[] = {
#define LOG(name, lvl) #name ,
#include <j6/tables/log_areas.inc>
#undef LOG