From: Christoph Lameter <clameter@engr.sgi.com>
To: Andi Kleen <ak@suse.de>
Cc: Paul Jackson <pj@sgi.com>, linux-mm@kvack.org
Subject: Re: [PATCH 2/2] Fold numa_maps into mempolicy.c
Date: Wed, 16 Nov 2005 10:54:04 -0800 (PST) [thread overview]
Message-ID: <Pine.LNX.4.62.0511161048530.15919@schroedinger.engr.sgi.com> (raw)
In-Reply-To: <200511160936.04721.ak@suse.de>
On Wed, 16 Nov 2005, Andi Kleen wrote:
> > Except for /proc output, is there any call to get_vma_policy made on any
> > task other than current?
>
> In the original version there wasn't any. I still think it's a mistake
> to allow it for /proc, unfortunately the patch went in.
We could make the function local to mempolicy.c if we fold the numa_maps
interface into mempolicy.c. That would prevent outside uses of this and so
prevent additional outside uses.
But then Paul was looking for such a use?
f.e.
Index: linux-2.6.14-mm2/mm/mempolicy.c
===================================================================
--- linux-2.6.14-mm2.orig/mm/mempolicy.c 2005-11-15 14:28:32.000000000 -0800
+++ linux-2.6.14-mm2/mm/mempolicy.c 2005-11-16 10:53:01.000000000 -0800
@@ -928,7 +928,7 @@ asmlinkage long compat_sys_mbind(compat_
#endif
/* Return effective policy for a VMA */
-struct mempolicy *
+static struct mempolicy *
get_vma_policy(struct task_struct *task, struct vm_area_struct *vma, unsigned long addr)
{
struct mempolicy *pol = task->mempolicy;
Index: linux-2.6.14-mm2/include/linux/mempolicy.h
===================================================================
--- linux-2.6.14-mm2.orig/include/linux/mempolicy.h 2005-11-16 10:43:41.000000000 -0800
+++ linux-2.6.14-mm2/include/linux/mempolicy.h 2005-11-16 10:52:40.000000000 -0800
@@ -142,9 +142,6 @@ void mpol_free_shared_policy(struct shar
struct mempolicy *mpol_shared_policy_lookup(struct shared_policy *sp,
unsigned long idx);
-struct mempolicy *get_vma_policy(struct task_struct *task,
- struct vm_area_struct *vma, unsigned long addr);
-
extern void numa_default_policy(void);
extern void numa_policy_init(void);
extern void numa_policy_rebind(const nodemask_t *old, const nodemask_t *new);
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
next prev parent reply other threads:[~2005-11-16 18:54 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-11-08 23:24 [PATCH 1/2] private pointer in check_range and MPOL_MF_INVERT Christoph Lameter
2005-11-08 23:25 ` [PATCH 2/2] Fold numa_maps into mempolicy.c Christoph Lameter
2005-11-16 7:10 ` Paul Jackson
2005-11-16 8:36 ` Andi Kleen
2005-11-16 18:54 ` Christoph Lameter [this message]
2005-11-16 19:43 ` Paul Jackson
2005-11-16 18:21 ` Christoph Lameter
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=Pine.LNX.4.62.0511161048530.15919@schroedinger.engr.sgi.com \
--to=clameter@engr.sgi.com \
--cc=ak@suse.de \
--cc=linux-mm@kvack.org \
--cc=pj@sgi.com \
/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