From: Kenneth Johansson <ken@kieraypc01.tn.sw.ericsson.se>
To: "Muaddi, Cecilia" <cecilia.muaddi@alloptic.com>
Cc: "'Wolfgang Denk'" <wd@denx.de>,
"linuxppc-embedded@lists.linuxppc.org"
<linuxppc-embedded@lists.linuxppc.org>
Subject: RE: access memory mapped registers
Date: 13 Jan 2003 16:14:27 +0100 [thread overview]
Message-ID: <1042470867.663.34.camel@spawn> (raw)
In-Reply-To: <885489B3B89FB6449F93E525DF78777F064542@srvnt506.ALLOPTIC.COM>
On Fri, 2003-01-10 at 01:46, Muaddi, Cecilia wrote:
>
> I can see if I mmap the internal 860 CPU registers, and screw up that, I
> will
> definitely screw up the system, and require it to be reboot. BUt if the
> hardware we are mapping is outside the CPU internal memory and outside the
> RAM,
> shouldn't the failure be limited to the user application only then?
>
> for example, an ethernet switch chip in a layer 2 router is controlled
> by the PPC 860. THe 860 is only used for configuration (not in the
> datapath)
> if I mmap
> only the memory regions that is mapped to the ethernet switching chip,
> even if I screw up on the hardware setup, shouldn't my kernel still be
> protected? At most, the application faults and I should be able to restart
> the application without rebooting the system?
>
Yes you are safe. There is nothing wrong with doing things in userspace
if you can. I have designed our system like this and have a very simple
IRQ driver that signals to userspace that an interrupt is pending to get
response time down and avoid polling but that is the only part I have in
the kernel.
The only reason to put anything into the kernel is speed and protection
so the first option should be to try to do it in userspace failing that
move it or parts to the kernel.
--
Kenneth Johansson
Ericsson AB Tel: +46 8 404 71 83
Tellusborgsvägen 94 Fax: +46 8 404 72 72
126 25 Stockholm ken@switchboard.ericsson.se
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
next prev parent reply other threads:[~2003-01-13 15:14 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <885489B3B89FB6449F93E525DF78777F064542@srvnt506.ALLOPTIC.COM>
2003-01-10 1:20 ` access memory mapped registers Wolfgang Denk
2003-01-13 15:14 ` Kenneth Johansson [this message]
2003-01-10 0:27 Muaddi, Cecilia
2003-01-10 1:12 ` Wolfgang Denk
[not found] <885489B3B89FB6449F93E525DF78777F06453E@srvnt506.ALLOPTIC.COM>
2003-01-10 0:25 ` Wolfgang Denk
-- strict thread matches above, loose matches on Subject: below --
2003-01-10 0:18 Kerl, John
2003-01-09 22:00 Muaddi, Cecilia
2003-01-09 23:14 ` Wolfgang Denk
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=1042470867.663.34.camel@spawn \
--to=ken@kieraypc01.tn.sw.ericsson.se \
--cc=cecilia.muaddi@alloptic.com \
--cc=linuxppc-embedded@lists.linuxppc.org \
--cc=wd@denx.de \
/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).