From: Andreas Schwab <schwab@suse.de>
To: linux-ia64@vger.kernel.org
Subject: [Linux-ia64] Fix request_module from ia32 process
Date: Thu, 27 Mar 2003 14:07:32 +0000 [thread overview]
Message-ID: <marc-linux-ia64-105590723705333@msgid-missing> (raw)
When an ia32 process triggers request_module the kernel cannot execute
modprobe because the kernel thread still has the ia32 address limits in
force. I think a kernel thread should always have the ia64 address
limits, similar to what sys32_execve is doing.
Andreas.
--- linux-2.4.19/arch/ia64/kernel/process.c.~1~ 2002-08-03 02:39:42.000000000 +0200
+++ linux-2.4.19/arch/ia64/kernel/process.c 2003-03-27 11:29:02.000000000 +0100
@@ -476,6 +476,15 @@ kernel_thread (int (*fn)(void *), void *
tid = clone(flags | CLONE_VM, 0);
if (parent != current) {
+#ifdef CONFIG_IA32_SUPPORT
+ if (IS_IA32_PROCESS(ia64_task_regs(current))) {
+ /* A kernel thread is always a 64-bit process. */
+ current->thread.map_base = DEFAULT_MAP_BASE;
+ current->thread.task_size = DEFAULT_TASK_SIZE;
+ ia64_set_kr(IA64_KR_IO_BASE, current->thread.old_iob);
+ ia64_set_kr(IA64_KR_TSSD, current->thread.old_k1);
+ }
+#endif
result = (*fn)(arg);
_exit(result);
}
--
Andreas Schwab, SuSE Labs, schwab@suse.de
SuSE Linux AG, Deutschherrnstr. 15-19, D-90429 Nürnberg
Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."
next reply other threads:[~2003-03-27 14:07 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-03-27 14:07 Andreas Schwab [this message]
2003-03-27 20:43 ` [Linux-ia64] Fix request_module from ia32 process David Mosberger
2003-04-16 22:56 ` Bjorn Helgaas
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=marc-linux-ia64-105590723705333@msgid-missing \
--to=schwab@suse.de \
--cc=linux-ia64@vger.kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.