* [PATCH][next] ACPI: APEI: EINJ: make read-only array non_mmio_desc static const
@ 2025-12-19 21:59 Colin Ian King
2026-01-07 19:48 ` Rafael J. Wysocki
0 siblings, 1 reply; 2+ messages in thread
From: Colin Ian King @ 2025-12-19 21:59 UTC (permalink / raw)
To: Rafael J . Wysocki, Tony Luck, Borislav Petkov, Hanjun Guo,
Mauro Carvalho Chehab, Shuai Xue, Len Brown, linux-acpi
Cc: kernel-janitors, linux-kernel
Don't populate the read-only array non_mmio_desc on the stack at run
time, instead make it static const.
Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
---
drivers/acpi/apei/einj-core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/acpi/apei/einj-core.c b/drivers/acpi/apei/einj-core.c
index 305c240a303f..f5bfdffe1e43 100644
--- a/drivers/acpi/apei/einj-core.c
+++ b/drivers/acpi/apei/einj-core.c
@@ -679,7 +679,7 @@ static bool is_allowed_range(u64 base_addr, u64 size)
* region intersects with known resource. So do an allow list check for
* IORES_DESCs that definitely or most likely not MMIO.
*/
- int non_mmio_desc[] = {
+ static const int non_mmio_desc[] = {
IORES_DESC_CRASH_KERNEL,
IORES_DESC_ACPI_TABLES,
IORES_DESC_ACPI_NV_STORAGE,
--
2.51.0
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH][next] ACPI: APEI: EINJ: make read-only array non_mmio_desc static const
2025-12-19 21:59 [PATCH][next] ACPI: APEI: EINJ: make read-only array non_mmio_desc static const Colin Ian King
@ 2026-01-07 19:48 ` Rafael J. Wysocki
0 siblings, 0 replies; 2+ messages in thread
From: Rafael J. Wysocki @ 2026-01-07 19:48 UTC (permalink / raw)
To: Colin Ian King
Cc: Rafael J . Wysocki, Tony Luck, Borislav Petkov, Hanjun Guo,
Mauro Carvalho Chehab, Shuai Xue, Len Brown, linux-acpi,
kernel-janitors, linux-kernel
On Fri, Dec 19, 2025 at 11:00 PM Colin Ian King <colin.i.king@gmail.com> wrote:
>
> Don't populate the read-only array non_mmio_desc on the stack at run
> time, instead make it static const.
>
> Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
> ---
> drivers/acpi/apei/einj-core.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/acpi/apei/einj-core.c b/drivers/acpi/apei/einj-core.c
> index 305c240a303f..f5bfdffe1e43 100644
> --- a/drivers/acpi/apei/einj-core.c
> +++ b/drivers/acpi/apei/einj-core.c
> @@ -679,7 +679,7 @@ static bool is_allowed_range(u64 base_addr, u64 size)
> * region intersects with known resource. So do an allow list check for
> * IORES_DESCs that definitely or most likely not MMIO.
> */
> - int non_mmio_desc[] = {
> + static const int non_mmio_desc[] = {
> IORES_DESC_CRASH_KERNEL,
> IORES_DESC_ACPI_TABLES,
> IORES_DESC_ACPI_NV_STORAGE,
> --
Applied as 6.20 material, thanks!
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-01-07 19:49 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-12-19 21:59 [PATCH][next] ACPI: APEI: EINJ: make read-only array non_mmio_desc static const Colin Ian King
2026-01-07 19:48 ` Rafael J. Wysocki
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®