From: dcn@sgi.com (Dean Nelson)
To: linux-ia64@vger.kernel.org
Subject: [PATCH] ensure XPC and XPNET are loaded on sn2 platforms only
Date: Thu, 08 Sep 2005 15:46:58 +0000 [thread overview]
Message-ID: <43205CF2.mailx6N91YXFZ1@aqua.americas.sgi.com> (raw)
These are SN2 only drivers. They should have platform checks to prevent
them from doing evil stuff in GENERIC kernels.
Signed-off-by: Martin Hicks <mort@sgi.com>
Acked-by: Dean Nelson <dcn@sgi.com>
arch/ia64/sn/kernel/xpc_main.c | 4 ++++
arch/ia64/sn/kernel/xpnet.c | 4 ++++
2 files changed, 8 insertions(+)
Index: linux-2.6/arch/ia64/sn/kernel/xpc_main.c
=================================--- linux-2.6.orig/arch/ia64/sn/kernel/xpc_main.c 2005-09-08 06:58:26.134622631 -0500
+++ linux-2.6/arch/ia64/sn/kernel/xpc_main.c 2005-09-08 09:47:31.081587119 -0500
@@ -885,6 +885,10 @@
pid_t pid;
+ if (!ia64_platform_is("sn2")) {
+ return -ENODEV;
+ }
+
/*
* xpc_remote_copy_buffer is used as a temporary buffer for bte_copy'ng
* both a partition's reserved page and its XPC variables. Its size was
Index: linux-2.6/arch/ia64/sn/kernel/xpnet.c
=================================--- linux-2.6.orig/arch/ia64/sn/kernel/xpnet.c 2005-09-08 06:58:26.136575561 -0500
+++ linux-2.6/arch/ia64/sn/kernel/xpnet.c 2005-09-08 09:47:36.693330520 -0500
@@ -636,6 +636,10 @@
int result = -ENOMEM;
+ if (!ia64_platform_is("sn2")) {
+ return -ENODEV;
+ }
+
dev_info(xpnet, "registering network device %s\n", XPNET_DEVICE_NAME);
/*
reply other threads:[~2005-09-08 15:46 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=43205CF2.mailx6N91YXFZ1@aqua.americas.sgi.com \
--to=dcn@sgi.com \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox