From: Dan Malek <dan@embeddededge.com>
To: Shie Erlich <shie_e@elbit.co.il>
Cc: "Linuxppc-Embedded mailing list (E-mail)"
<linuxppc-embedded@lists.linuxppc.org>
Subject: Re: 64 bit memory access - again ...
Date: Mon, 03 Dec 2001 12:01:44 -0500 [thread overview]
Message-ID: <3C0BAFF8.5060309@embeddededge.com> (raw)
In-Reply-To: 937610FE9B70D511B3E700508B8B65770E53CA@MAIL1
Shie Erlich wrote:
> i also know that floating point in the kernel is a big NO, but if no other
> choice is found, i'll have to do it. my questions are:
If possible, I would mmap() the device from user space and perform
the access there.
> a) what is the recommended way of doing a 64bit access in the linux kernel ?
I would first try to do it with a cache line burst access. Put it in
copyback mode, zero the line, write the line, flush the line, invalidate
the line.
> b) if the fpu is the way to go, what do i need to do so that the kernel does
> not
> trap my floating point access ?
You can't trap and emulate, that defeats the purpose. The biggest challenge
when using floating point in the kernel is context switching the FPU.
I would probably force the kernel to always context switch the FPU (as
it does on SMP) so you would always have a clean context to use in
the kernel. I would then disable interrupts (to avoid other FPU context
problems), enable the FPU, perform the access, ensure the context is
reloaded for the switched-in thread, disable the FPU, enable interrupts.
Any system performance gains you thought you may have by using 64-bit
I/O are likely to be significantly reduced by the amount of software
overhead needed to manage this.
Depending upon what you are using for a bridge/memory controller you
may have a DMA controller that could perform this access as well.
-- Dan
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
next prev parent reply other threads:[~2001-12-03 17:01 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-12-03 11:14 64 bit memory access - again Shie Erlich
2001-12-03 17:01 ` Dan Malek [this message]
-- strict thread matches above, loose matches on Subject: below --
2001-12-05 9:25 Shie Erlich
2001-12-05 17:16 ` Dan Malek
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=3C0BAFF8.5060309@embeddededge.com \
--to=dan@embeddededge.com \
--cc=linuxppc-embedded@lists.linuxppc.org \
--cc=shie_e@elbit.co.il \
/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).