From: ebiederman@lnxi.com (Eric W. Biederman)
To: David Woodhouse <dwmw2@infradead.org>
Cc: linux-mtd@lists.infradead.org, ajlennon@arcom.co.uk
Subject: Re: CPU caching of flash regions.
Date: 14 May 2001 10:32:47 -0600 [thread overview]
Message-ID: <m3vgn36gcw.fsf@DLT.linuxnetworx.com> (raw)
In-Reply-To: David Woodhouse's message of "Mon, 14 May 2001 17:17:45 +0100"
David Woodhouse <dwmw2@infradead.org> writes:
> ebiederman@lnxi.com said:
> > What kind of scenario are we talking about? Do the pages get read
> > multiple times? Of is it just that that copy_from needs to be more
> > highly optimized like memcpy? I suspect that before the whole
> > interface changes you should experiment and see what really needs to
> > be done.
>
> This is during the initial mount of JFFS2. Nothing should be read twice -
> but we should at least be able to fill cache lines and do burst reads from
> the flash chips, shouldn't we?
Definentily. To date I've only had a real hard look at the write
case. So I can't answer off the top of my head what needs to happen.
> > But I really think you should be able to get it working faster simply
> > by optimizing the copy_from routine.
>
> Most of the copy_from routines use memcpy_fromio(), which on i386 is just
> a memcpy(). It ought to be fairly close to optimal.
O.k. So that shouldn't be an issue if the kernel is properly
optimized.
> Actually, the board used for the offending profile is a board with paged
> access to the flash, so it's slightly slower than some others - but the
> overhead shouldn't be too high. And the cache benefit would be more limited.
First. What kind of chip is being used? What bus is it on? And how
fast is it?
Second. What kind of processor, and what kind of chipset are being used?
Getting bandwidth numbers out of the memcpy would be a useful
debugging technique. I really suspect the overhead is in the chip
itself. Flash chips are not know for their speed.
If the chip is out on the ISA bus unless you set up approriate
decoders for it, the chip PCI->ISA bridge will be doing subtractive
decode which will slow you down.
If we could start with some theoretical bandwidth numbers for
the chip, and compare that to what memcpy_fromio is giving we can see
how much room their is for optimization.
Eric
next prev parent reply other threads:[~2001-05-14 16:29 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-05-14 14:15 CPU caching of flash regions David Woodhouse
2001-05-14 15:51 ` Eric W. Biederman
2001-05-14 16:17 ` David Woodhouse
2001-05-14 16:32 ` Eric W. Biederman [this message]
2001-05-15 10:46 ` Alex Lennon
2001-05-15 14:32 ` Eric W. Biederman
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=m3vgn36gcw.fsf@DLT.linuxnetworx.com \
--to=ebiederman@lnxi.com \
--cc=ajlennon@arcom.co.uk \
--cc=dwmw2@infradead.org \
--cc=linux-mtd@lists.infradead.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