]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
log: Add additional const qualifier to arrays
authorSean Anderson <seanga2@gmail.com>
Tue, 27 Oct 2020 23:55:22 +0000 (19:55 -0400)
committerTom Rini <trini@konsulko.com>
Fri, 30 Oct 2020 14:55:26 +0000 (10:55 -0400)
Both these arrays and their members are const. Fixes checkpatch complaint.

Signed-off-by: Sean Anderson <seanga2@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
common/log.c

index f1de922b3667f739cd94c5cb4fbb0fd6c4f1addc..47bb9b544e1fb229ce7c312077c15595c98a34ef 100644 (file)
@@ -13,7 +13,7 @@
 
 DECLARE_GLOBAL_DATA_PTR;
 
-static const char *log_cat_name[] = {
+static const char *const log_cat_name[] = {
        "none",
        "arch",
        "board",
@@ -31,7 +31,7 @@ static const char *log_cat_name[] = {
 _Static_assert(ARRAY_SIZE(log_cat_name) == LOGC_COUNT - LOGC_NONE,
               "log_cat_name size");
 
-static const char *log_level_name[] = {
+static const char *const log_level_name[] = {
        "EMERG",
        "ALERT",
        "CRIT",