From: "David H. Lynch Jr." <dhlii@dlasys.net>
To: Nilesh Agrawal <nilesh.agrawal@gmail.com>
Cc: Rajat Jain <rajat.noida.india@gmail.com>,
Rik van Riel <riel@surriel.com>,
idlisambar@gmail.com, kernelnewbies <kernelnewbies@nl.linux.org>,
Linux Newbie <linux-newbie@vger.kernel.org>
Subject: Re: Issuing BIOS interrupts in Linux
Date: Tue, 08 Aug 2006 21:50:29 -0400 [thread overview]
Message-ID: <44D93F65.7070209@dlasys.net> (raw)
In-Reply-To: <9a9e5ab90608050933x6451ee98v8d3cc2abae170bdb@mail.gmail.com>
Nilesh Agrawal wrote:
>> Okay ... NOW we are talking. Any idea / links / references on where
>> should I start looking for? How tough / practical is it to switch from
>> protected mode to real mode and back? Is it possible at all (in
>> linux)?
>
> Paging only works in protected mode. And once paging is turned off,
> all the kernel code is unusable because it is linked at PAGE_OFFSET +
> something. ( 3GB + )
>
> Disabling paging itself is not easy, let alone going to real mode
> (where only 64KB memory is available ) and coming back.
on an x86 real mode has access to 1MB of memory. Not 64K.
Frequently this is quoted a 640K because the upper part of the real
mode address space may contain graphics adapters, and roms.
uClinux is now part of the distribution kernel it is intended for
systems without an MMU. But basically uClinux means linux without
paging PAGE_OFFSET = 0;
On some processors some faults must be handled in real mode.
Switching from protected mode to real mode and back may not be all
that hard. But doing something while in real mode could be extremely hard.
You can not use any Linux resource that assumes protected mode -
that means pretty much everything.
Basically you would have to get a hunk of memory you can access in
Real Mode, switch to real mode do your task switch back and copy the
results from your memory.
While you were in real mode, interrupts would probably have to be
disabled.
The x86 also has something called virtual x86 mode which might be
more useful. I do not remember all the details, but I think you could
create a linux process, that executed in virtual x86 mode,
that would execute concurrently with virtual x386 processes. That
said Linux has no builtin facilities to work with virtual x86 processes.
>
>
> Nilesh
>
>
--
Dave Lynch DLA Systems
Software Development: Embedded Linux
717.627.3770 dhlii@dlasys.net http://www.dlasys.net
fax: 1.253.369.9244 Cell: 1.717.587.7774
Over 25 years' experience in platforms, languages, and technologies too numerous to list.
"Any intelligent fool can make things bigger and more complex... It takes a touch of genius - and a lot of courage to move in the opposite direction."
Albert Einstein
-
To unsubscribe from this list: send the line "unsubscribe linux-newbie" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.linux-learn.org/faqs
next prev parent reply other threads:[~2006-08-09 1:50 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-08-04 11:00 Issuing BIOS interrupts in Linux Rajat Jain
2006-08-05 1:20 ` Rahul Iyer
[not found] ` <292693080608050553x756e4276k33c5afa80f686f44@mail.gmail.com>
2006-08-05 13:11 ` Rajat Jain
2006-08-05 14:54 ` Rik van Riel
2006-08-05 15:26 ` Rajat Jain
2006-08-05 16:33 ` Nilesh Agrawal
2006-08-09 1:50 ` David H. Lynch Jr. [this message]
2006-08-09 5:14 ` Rajat Jain
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=44D93F65.7070209@dlasys.net \
--to=dhlii@dlasys.net \
--cc=dhlii@comcast.net \
--cc=idlisambar@gmail.com \
--cc=kernelnewbies@nl.linux.org \
--cc=linux-newbie@vger.kernel.org \
--cc=nilesh.agrawal@gmail.com \
--cc=rajat.noida.india@gmail.com \
--cc=riel@surriel.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