From: "Ian Thompson" <ithompso@stargateip.com>
To: <root@chaos.analogic.com>
Cc: "Helge Hafting" <helgehaf@idb.hist.no>, <linux-kernel@vger.kernel.org>
Subject: RE: How can I jump to non-linux address space?
Date: Thu, 4 Oct 2001 17:35:51 -0700 [thread overview]
Message-ID: <NFBBIBIEHMPDJNKCIKOBGEIOCAAA.ithompso@stargateip.com> (raw)
In-Reply-To: <Pine.LNX.3.95.1011004155938.1774A-100000@chaos.analogic.com>
Hey Dick,
Thanks for the help! A couple more questions for you...
> You use ioremap() to create a virtual address from 0x1000. Then
> you copy the relocated code, currently in some array, to the relocated
> address (0x1000), using the cookie returned from ioremap().
How does this make the virtual address the same as the physical address? Or
are addr's in the first page (or 1st MB?) automatically mapped to the same
address when you call ioremap()? I printed out the __ioremap() addr's for
0x1000 and 0x3000, and neither of the virt addr's were equal to the physical
ones.
I tried something slightly different, which didn't work... Should it have?
What I did was put the code to turn off the MMU at physical address 0x3000,
and jumped to it (via branching to __ioremap(0x3000)). I think the branch
is working, since I can load the correct instruction via this reloc'ed
address. However, running the code that turns off the MMU instead reboots
the machine. =(
> In the code, you can disable the paging bit and set DS, ES to the
> page-table selector, which looks at linear addressing. Now you can
> see and access everything as 32-bit linear address-space.
Should I be looking for something else to twiddle instead of the MMU bit in
the CPU register? You mentioned the paging bit; is this different? Also,
what are DS & ES?
gracias,
-ian
next prev parent reply other threads:[~2001-10-05 0:35 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-10-04 1:10 How can I jump to non-linux address space? Ian Thompson
2001-10-04 9:04 ` Helge Hafting
2001-10-04 19:40 ` Ian Thompson
2001-10-04 20:32 ` Richard B. Johnson
2001-10-05 0:35 ` Ian Thompson [this message]
2001-10-05 7:55 ` Russell King
2001-10-08 12:51 ` Richard B. Johnson
2001-10-04 20:35 ` Russell King
2001-10-06 0:38 ` Ian Thompson
2001-10-06 7:57 ` Russell King
2001-10-08 17:43 ` Ian Thompson
2001-10-08 20:01 ` Russell King
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=NFBBIBIEHMPDJNKCIKOBGEIOCAAA.ithompso@stargateip.com \
--to=ithompso@stargateip.com \
--cc=helgehaf@idb.hist.no \
--cc=linux-kernel@vger.kernel.org \
--cc=root@chaos.analogic.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