From: "Luke Yang" <luke.adi@gmail.com>
To: "Andrew Morton" <akpm@osdl.org>, linux-kernel@vger.kernel.org
Subject: [PATCH] Replace "vmalloc_node" with "vmalloc" for no-mmu architectures in oprofile driver
Date: Tue, 28 Feb 2006 11:20:23 +0800 [thread overview]
Message-ID: <489ecd0c0602271920u7c0fc0b6p8a8cef0f408c6f3b@mail.gmail.com> (raw)
Hi,
This is a fix to the oprofile driver. It calls "vmalloc_node()" but
no-mmu CPUs do not have that function. "vmalloc()" is OK for no-mmu
CPUs.
Signed-off-by: Luke Yang <luke.adi@gmail.com>
Index: linux-2.6/drivers/oprofile/cpu_buffer.c
===================================================================
--- linux-2.6/drivers/oprofile/cpu_buffer.c 2006-02-16
16:16:35.000000000 +0800
+++ linux-2.6/drivers/oprofile/cpu_buffer.c 2006-02-16
16:20:58.000000000 +0800
@@ -51,9 +51,13 @@
for_each_online_cpu(i) {
struct oprofile_cpu_buffer * b = &cpu_buffer[i];
-
+
+#ifdef MMU
b->buffer = vmalloc_node(sizeof(struct op_sample) * buffer_size,
cpu_to_node(i));
+#else
+ b->buffer = vmalloc(sizeof(struct op_sample) * buffer_size);
+#endif
if (!b->buffer)
goto fail;
--
Best regards,
Luke Yang
magic.yyang@gmail.com; luke.adi@gmail.com
next reply other threads:[~2006-02-28 3:20 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-02-28 3:20 Luke Yang [this message]
2006-02-28 3:33 ` Andrew Morton
2006-02-28 3:45 ` Luke Yang
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=489ecd0c0602271920u7c0fc0b6p8a8cef0f408c6f3b@mail.gmail.com \
--to=luke.adi@gmail.com \
--cc=akpm@osdl.org \
--cc=linux-kernel@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
all inboxes | Powered by JetHome®