From: Keith Owens <kaos@ocs.com.au>
To: linux-ia64@vger.kernel.org
Subject: [Linux-ia64] Re: [RFC] NUMA functions for accessing replicated areas
Date: Sat, 19 Jan 2002 22:35:19 +0000 [thread overview]
Message-ID: <marc-linux-ia64-105590698805889@msgid-missing> (raw)
In-Reply-To: <marc-linux-ia64-105590698805887@msgid-missing>
On Sat, 19 Jan 2002 18:27:48 +0100,
Andrea Arcangeli <andrea@suse.de> wrote:
>On Sat, Jan 19, 2002 at 11:25:17AM +1100, Keith Owens wrote:
>The opaque void * spread across all the API looks rather scary.
>Furthmore I'm not convinced we need to pass any cookie to the api, all
>the calls knows the numadata info by the static status after boot.
>
>So I think something like this should be enough:
>
> int numa_replicated(unsigned long address, int size);
> int numa_getarea(void *to, unsigned long from, int size);
> int numa_putarea(unsigned long to, void *from, int size);
That assumes that all replicated data is identical. It starts off that
way but what prevents one set of replicated data being changed and not
the others? I don't mind that assumption, it makes life easier for kdb,
but I did not want to constrain NUMA implementations. However if
everyone agrees that each instance of replcated data should always be
identical then numa_getarea() can read from any instance and
numa_putarea() writes to all instances, no need for numa_replicate_loop.
>Futhmore it may be even better to drop numa_replicated completly and to
>default using numa_getarea/numa_putarea always, this should make kdb
>even cleaner. Implementation of getarea/putarea for non numa case will
>be a simple memcpy.
If numa_replicated() returns true then it is safe to use memcpy, if
numa_replicated() is omitted then the get/put functions must validate
the from address on get and the to address on put. kdb v2.1 relies on
the MMU via __copy_to_user() to detect invalid user supplied addresses.
next prev parent reply other threads:[~2002-01-19 22:35 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-01-19 17:27 [Linux-ia64] Re: [RFC] NUMA functions for accessing replicated areas Andrea Arcangeli
2002-01-19 22:35 ` Keith Owens [this message]
2002-01-20 0:15 ` Keith Owens
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-105590698805889@msgid-missing \
--to=kaos@ocs.com.au \
--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