[<prev] [next>] [day] [month] [year] [list]
Message-ID: <20240507113838.760b4d47@endymion.delvare>
Date: Tue, 7 May 2024 11:38:38 +0200
From: Jean Delvare <jdelvare@...e.de>
To: LKML <linux-kernel@...r.kernel.org>
Cc: Heiner Kallweit <hkallweit1@...il.com>
Subject: [PATCH] firmware: dmi: Mark dmi_memdev_populated_nr __initdata
Static variable dmi_memdev_populated_nr is only used in __init
functions, so it can be marked __initdata.
Signed-off-by: Jean Delvare <jdelvare@...e.de>
Cc: Heiner Kallweit <hkallweit1@...il.com>
---
I could also squash this change in the commit which introduced
dmi_memdev_populated_nr, as it's not upstream yet, if Heiner is OK with
it.
drivers/firmware/dmi_scan.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- linux-6.8.orig/drivers/firmware/dmi_scan.c
+++ linux-6.8/drivers/firmware/dmi_scan.c
@@ -42,7 +42,7 @@ static struct dmi_memdev_info {
u8 type; /* DDR2, DDR3, DDR4 etc */
} *dmi_memdev;
static int dmi_memdev_nr;
-static int dmi_memdev_populated_nr;
+static int dmi_memdev_populated_nr __initdata;
static const char * __init dmi_string_nosave(const struct dmi_header *dm, u8 s)
{
--
Jean Delvare
SUSE L3 Support
Powered by blists - more mailing lists