From: Matthew Wilcox <matthew@wil.cx>
To: Richard Hirst <rhirst@linuxcare.com>
Cc: Matthew Wilcox <matthew@wil.cx>,
David Huggins-Daines <dhd@linuxcare.com>,
parisc-linux@thepuffingroup.com
Subject: Re: [parisc-linux] 2.4.0-test6 lack of speed
Date: Wed, 30 Aug 2000 14:18:25 +0100 [thread overview]
Message-ID: <20000830141825.A3463@parcelfarce.linux.theplanet.co.uk> (raw)
In-Reply-To: <20000830111523.F877@linuxcare.com>; from rhirst@linuxcare.com on Wed, Aug 30, 2000 at 11:15:23AM +0100
On Wed, Aug 30, 2000 at 11:15:23AM +0100, Richard Hirst wrote:
> What do you make of arch/parisc/lib/usercopy.c
>
> unsigned long
> __generic_copy_to_user(void *to, const void *from, unsigned long n)
> {
> if (access_ok(VERIFY_WRITE, to, n)) {
> __flush_dcache_range((unsigned long)from, n);
> lcopy_to_user(to,from,n);
> __flush_dcache_range((unsigned long)to, n);
> }
> return 0;
> }
>
> Typically 'from' would be a kernel virtual address, and 'to' would
> be a user virtual address, yes? So, that is expecting __flush_dcache_range()
> to know which space register to use. But then sometimes these functions
> for accessing user space are redirected at kernel space by set_fs().
> In that case both addresses are kernel virtual addresses.
Right. But I don't see why we need to flush any caches at all here.
We're not changing any mappings, we're accessing through a fixed space
register, there's no other device involved, if there were another CPU
involved then it would be cache-coherent _anyway_ -- what's the problem?
prev parent reply other threads:[~2000-08-30 13:18 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2000-08-22 14:38 [parisc-linux] 2.4.0-test6 lack of speed Richard Hirst
2000-08-22 14:52 ` Richard Hirst
2000-08-22 15:50 ` Richard Hirst
2000-08-22 16:05 ` David Huggins-Daines
2000-08-23 16:23 ` Richard Hirst
2000-08-23 16:38 ` Paul Bame
2000-08-24 13:46 ` Richard Hirst
2000-08-29 21:23 ` Matthew Wilcox
2000-08-30 0:17 ` Matthew Wilcox
2000-08-30 8:15 ` Richard Hirst
2000-08-30 12:41 ` Richard Hirst
2000-08-30 10:15 ` Richard Hirst
2000-08-30 13:18 ` Matthew Wilcox [this message]
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=20000830141825.A3463@parcelfarce.linux.theplanet.co.uk \
--to=matthew@wil.cx \
--cc=dhd@linuxcare.com \
--cc=parisc-linux@thepuffingroup.com \
--cc=rhirst@linuxcare.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