From: Jeff Dike <jdike@addtoit.com>
To: BlaisorBlade <blaisorblade_spam@yahoo.it>
Cc: user-mode-linux-devel@lists.sourceforge.net
Subject: Re: [uml-devel] [PATCH] fix writing into /dev/kmem
Date: Wed, 03 Mar 2004 21:02:16 -0500 [thread overview]
Message-ID: <200403040202.i2422GWo008953@ccure.user-mode-linux.org> (raw)
In-Reply-To: Your message of "Tue, 02 Mar 2004 19:41:52 +0100." <200403021941.52257.blaisorblade_spam@yahoo.it>
blaisorblade_spam@yahoo.it said:
> Well, on *i386* that is 0xc0000001; since klogd is built with i386
> kernel headers, it will use those.
This was the stupidity that I was refusing to believe in. This means that
if you take a normal klogd and move it to a 2G/2G system, where the kernel
starts at 0x80000000, it won't work.
> Anyway, here comes that copy_{to,from}_user are buggy. Since fixing
> those would have a good performance hit (to test, but that will
> probably be sensitive
In skas mode, I wasn't expecting any legitimate unfixable kernel mode access
faults, so I wasn't setting up the fault_catcher. So, what I did was add
a wrapper around the guts of copy_user which does a setjmp, and returns
whether it got longjmp-ed back to.
Reading /dev/kmem now produces -EFAULT. Writing to it still causes a hang
because write_kmem doesn't check the return value of do_write_mem. With that
fixed, everything produces -EFAULT.
The fix will be in the next patch.
Jeff
-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
_______________________________________________
User-mode-linux-devel mailing list
User-mode-linux-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/user-mode-linux-devel
next prev parent reply other threads:[~2004-03-04 1:45 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-02-29 2:36 [uml-devel] [PATCH] fix writing into /dev/kmem Jeff Dike
2004-02-29 12:25 ` BlaisorBlade
2004-03-02 1:31 ` Jeff Dike
2004-03-02 18:41 ` BlaisorBlade
2004-03-04 2:02 ` Jeff Dike [this message]
2004-03-08 11:50 ` BlaisorBlade
2004-02-29 16:20 ` BlaisorBlade
2004-03-02 1:11 ` Jeff Dike
2004-03-02 1:31 ` Jeff Dike
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=200403040202.i2422GWo008953@ccure.user-mode-linux.org \
--to=jdike@addtoit.com \
--cc=blaisorblade_spam@yahoo.it \
--cc=user-mode-linux-devel@lists.sourceforge.net \
/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