From: Magnus Lindholm <linmag7@gmail.com>
To: richard.henderson@linaro.org, mattst88@gmail.com,
linux-kernel@vger.kernel.org, linux-alpha@vger.kernel.org
Cc: linmag7@gmail.com
Subject: [PATCH v3 1/2] alpha: parse early parameters before reserving contiguous memory
Date: Sun, 15 Nov 2026 11:37:42 +0100 [thread overview]
Message-ID: <20261115103809.1288167-2-linmag7@gmail.com> (raw)
In-Reply-To: <20261115103809.1288167-1-linmag7@gmail.com>
Run parse_early_param() in setup_arch(), after machine initialization
and before further memory reservations. This lets the subsequent CMA
reservation honor cma= before start_kernel() reaches its normal call.
Initialize jump labels first so early handlers can safely change static
keys. The later jump_label_init() call in start_kernel() is harmless.
The parser uses boot_command_line and guards against repeated calls.
This moves all early parameter handlers, not just the CMA handler.
Signed-off-by: Magnus Lindholm <linmag7@gmail.com>
Reviewed-by: Matt Turner <mattst88@gmail.com>
---
arch/alpha/kernel/setup.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/arch/alpha/kernel/setup.c b/arch/alpha/kernel/setup.c
index 9fda01b73b18..f21a7c8f5213 100644
--- a/arch/alpha/kernel/setup.c
+++ b/arch/alpha/kernel/setup.c
@@ -25,6 +25,7 @@
#include <linux/cpu.h>
#include <linux/errno.h>
#include <linux/init.h>
+#include <linux/jump_label.h>
#include <linux/string.h>
#include <linux/ioport.h>
#include <linux/panic_notifier.h>
@@ -579,6 +580,10 @@ setup_arch(char **cmdline_p)
if (alpha_mv.init_arch)
alpha_mv.init_arch();
+ /* Early options may change static keys and configure DMA CMA. */
+ jump_label_init();
+ parse_early_param();
+
/* Reserve standard resources. */
reserve_std_resources();
--
2.43.0
next prev parent reply other threads:[~2026-11-15 10:38 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-15 10:37 [PATCH v3 0/2] alpha: enable DMA CMA support Magnus Lindholm
2026-11-15 10:37 ` Magnus Lindholm [this message]
2026-11-15 10:37 ` [PATCH v3 2/2] alpha: enable contiguous memory allocation for coherent DMA Magnus Lindholm
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261115103809.1288167-2-linmag7@gmail.com \
--to=linmag7@gmail.com \
--cc=linux-alpha@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mattst88@gmail.com \
--cc=richard.henderson@linaro.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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®