From: Mike Rapoport <mike@compulab.co.il>
To: Mike Frysinger <vapier.adi@gmail.com>
Cc: Russ Dill <russ.dill@gmail.com>,
linux-mtd <linux-mtd@lists.infradead.org>,
Russell King - ARM Linux <linux@arm.linux.org.uk>,
David Woodhouse <dwmw2@infradead.org>,
Ben Dooks <ben-linux-arm@fluff.org>
Subject: Re: [PATCH] [MTD] [NAND] GPIO NAND flash driver
Date: Wed, 08 Oct 2008 10:28:11 +0200 [thread overview]
Message-ID: <48EC6F1B.7040404@compulab.co.il> (raw)
In-Reply-To: <8bd0f97a0810080029o6f8250cfi734d19191eb92c1d@mail.gmail.com>
Mike Frysinger wrote:
> On Wed, Oct 8, 2008 at 03:28, Russell King - ARM Linux wrote:
>> On Wed, Oct 08, 2008 at 02:20:13AM -0400, Mike Frysinger wrote:
>>> On Wed, Oct 8, 2008 at 02:01, Mike Rapoport wrote:
>>>> +/* gpio_nand_dosync()
>>>> + *
>>>> + * needed due to bus-reordering within the PXA itself (see section on
>>>> + * I/O ordering in PXA manual (section 2.3, p35)
>>>> + */
>>>> +static void gpio_nand_dosync(struct gpiomtd *gpiomtd)
>>>> +{
>>>> + unsigned long tmp;
>>>> +
>>>> + if (gpiomtd->io_sync) {
>>>> + /*
>>>> + * this should generate the read, followed by
>>>> + * something that depends on the read
>>>> + */
>>>> + tmp = readl(gpiomtd->io_sync);
>>>> + asm volatile("mov %1, %0\n" : "=r" (tmp) : "r" (tmp));
>>>> + }
>>>> +}
>>> there isnt much point in attempting to write a generic solution if
>>> you're just going to turn around and stick straight assembly in the
>>> middle of it. why not use a real arch-generic method like a memory
>>> barrier.
>> Linux memory barriers don't cater for what's required here. What's
>> required is what's there - a read from a separate region with a
>> dependency on that read. Linux has no such barrier.
>
> thanks, this kind of comment in the source would be useful ... but
> what is also needed is '#ifdef __arm__'
If '#ifdef' is preferable than 'depend on ARM' I can send an updated patch.
> -mike
>
> ______________________________________________________
> Linux MTD discussion mailing list
> http://lists.infradead.org/mailman/listinfo/linux-mtd/
>
--
Sincerely yours,
Mike.
next prev parent reply other threads:[~2008-10-08 8:28 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-10-08 6:01 [PATCH] [MTD] [NAND] GPIO NAND flash driver Mike Rapoport
2008-10-08 6:20 ` Mike Frysinger
2008-10-08 7:28 ` Russell King - ARM Linux
2008-10-08 7:29 ` Mike Frysinger
2008-10-08 8:28 ` Mike Rapoport [this message]
2008-10-08 17:41 ` Mike Frysinger
2008-10-10 10:46 ` Mike Rapoport
2008-10-10 14:19 ` Jamie Lokier
2008-10-10 21:48 ` Russell King - ARM Linux
2008-10-10 22:07 ` Mike Frysinger
2008-10-12 8:02 ` Mike Rapoport
2008-10-12 8:14 ` Mike Frysinger
2008-10-12 8:28 ` Russell King - ARM Linux
2008-10-12 8:56 ` Mike Frysinger
2008-10-12 10:13 ` Russell King - ARM Linux
2008-10-12 10:35 ` David Woodhouse
2008-10-12 10:43 ` Russell King - ARM Linux
2008-10-12 15:04 ` Jamie Lokier
2008-10-12 19:04 ` Mike Frysinger
2008-10-12 19:09 ` Russell King - ARM Linux
2008-10-12 19:22 ` Mike Frysinger
2008-10-12 19:40 ` Russell King - ARM Linux
2008-10-12 10:04 ` Mike Rapoport
2008-10-13 13:59 ` David Woodhouse
2008-10-15 6:38 ` Mike Rapoport
2008-10-15 7:52 ` Russell King - ARM Linux
2008-10-15 8:25 ` Mike Rapoport
2008-10-08 8:30 ` David Woodhouse
2008-10-08 14:25 ` Paulius Zaleckas
-- strict thread matches above, loose matches on Subject: below --
2008-10-19 23:51 David Brownell
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=48EC6F1B.7040404@compulab.co.il \
--to=mike@compulab.co.il \
--cc=ben-linux-arm@fluff.org \
--cc=dwmw2@infradead.org \
--cc=linux-mtd@lists.infradead.org \
--cc=linux@arm.linux.org.uk \
--cc=russ.dill@gmail.com \
--cc=vapier.adi@gmail.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