From: Cliff Wickman <cpw@sgi.com>
To: linux-kernel@vger.kernel.org
Cc: mingo@elte.hu
Subject: [PATCH] UV: redundant creation of sgi_uv
Date: Mon, 10 Nov 2008 16:16:31 -0600 [thread overview]
Message-ID: <E1Kzf3f-0008FR-Nh@eag09.americas.sgi.com> (raw)
From: Cliff Wickman <cpw@sgi.com>
There is a collision between two UV functions:
both uv_ptc_init() and gru_proc_init() try to make /proc/sgi_uv
So move it's creation to a single place: uv_system_init()
Diffed against 2.6.28-rc3
Signed-off-by: Cliff Wickman <cpw@sgi.com>
---
arch/x86/kernel/genx2apic_uv_x.c | 2 ++
arch/x86/kernel/tlb_uv.c | 4 ----
drivers/misc/sgi-gru/gruprocfs.c | 1 -
3 files changed, 2 insertions(+), 5 deletions(-)
Index: linux/arch/x86/kernel/genx2apic_uv_x.c
===================================================================
--- linux.orig/arch/x86/kernel/genx2apic_uv_x.c
+++ linux/arch/x86/kernel/genx2apic_uv_x.c
@@ -19,6 +19,7 @@
#include <linux/module.h>
#include <linux/hardirq.h>
#include <linux/timer.h>
+#include <linux/proc_fs.h>
#include <asm/current.h>
#include <asm/smp.h>
#include <asm/ipi.h>
@@ -569,4 +570,5 @@ void __init uv_system_init(void)
uv_cpu_init();
uv_scir_register_cpu_notifier();
+ proc_mkdir("sgi_uv", NULL);
}
Index: linux/arch/x86/kernel/tlb_uv.c
===================================================================
--- linux.orig/arch/x86/kernel/tlb_uv.c
+++ linux/arch/x86/kernel/tlb_uv.c
@@ -566,14 +566,10 @@ static int __init uv_ptc_init(void)
if (!is_uv_system())
return 0;
- if (!proc_mkdir("sgi_uv", NULL))
- return -EINVAL;
-
proc_uv_ptc = create_proc_entry(UV_PTC_BASENAME, 0444, NULL);
if (!proc_uv_ptc) {
printk(KERN_ERR "unable to create %s proc entry\n",
UV_PTC_BASENAME);
- remove_proc_entry("sgi_uv", NULL);
return -EINVAL;
}
proc_uv_ptc->proc_fops = &proc_uv_ptc_operations;
Index: linux/drivers/misc/sgi-gru/gruprocfs.c
===================================================================
--- linux.orig/drivers/misc/sgi-gru/gruprocfs.c
+++ linux/drivers/misc/sgi-gru/gruprocfs.c
@@ -317,7 +317,6 @@ int gru_proc_init(void)
{
struct proc_entry *p;
- proc_mkdir("sgi_uv", NULL);
proc_gru = proc_mkdir("sgi_uv/gru", NULL);
for (p = proc_files; p->name; p++)
next reply other threads:[~2008-11-10 22:17 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-11-10 22:16 Cliff Wickman [this message]
2008-11-11 10:40 ` Ingo Molnar
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=E1Kzf3f-0008FR-Nh@eag09.americas.sgi.com \
--to=cpw@sgi.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
/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®