linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: kernel mailz <kernelmailz@googlemail.com>
To: linuxppc-dev@ozlabs.org
Subject: 85xx Address space query
Date: Wed, 24 Jun 2009 15:14:31 +0530	[thread overview]
Message-ID: <abe8a1fd0906240244i6e33c260xadff5cf462df7b8c@mail.gmail.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 768 bytes --]

Hi,

I am a newbie, trying to learn but have a few queries, nice if you could
respond
For linux on 85xx systems...

(a) Kernel code runs in PR=0 AS=0 and PID=0, which user space application
run in PR=1 AS=0 and PID 1-255.
Is this correct.

(b) I am writing a small program where the application code opens invokes a
ioctl call and passes a buffer pointer ( say 0x10000 in user space)
Now the driver code is using copy_from_user.
How this works internally ?

1. User code executes ioctl
2. interrupt goes to the kernel
3. ioctl handler in driver gets invoked
The buffer pointer still contains 0x10000.

How kernel code running in PR=0 accesses it and does the copy. I am not able
to see a address space switch in the asm code of copy_tofrom_user.

Please respond

-TRX

[-- Attachment #2: Type: text/html, Size: 855 bytes --]

             reply	other threads:[~2009-06-24  9:44 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-06-24  9:44 kernel mailz [this message]
2009-06-24 13:15 ` 85xx Address space query Kumar Gala
2009-06-24 17:46   ` kernel mailz
2009-06-24 22:52     ` Scott Wood
2009-06-25 10:51       ` kernel mailz
2009-06-25 17:32         ` Kumar Gala
2009-06-25 17:52           ` kernel mailz
2009-06-25 17:58             ` Kumar Gala
2009-06-25 19:34         ` Scott Wood
2009-06-25 11:33     ` Benjamin Herrenschmidt
2009-06-25 11:32   ` Benjamin Herrenschmidt

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=abe8a1fd0906240244i6e33c260xadff5cf462df7b8c@mail.gmail.com \
    --to=kernelmailz@googlemail.com \
    --cc=linuxppc-dev@ozlabs.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;
as well as URLs for NNTP newsgroup(s).