From: Thomas Gleixner <tglx@linutronix.de>
To: "Ruslan V. Sushko" <rsushko@ru.mvista.com>
Cc: linux-mtd@lists.infradead.org
Subject: Re: [PATH] NAND Flash support for Intel IXP4xx platform
Date: Mon, 30 Apr 2007 10:17:56 +0200 [thread overview]
Message-ID: <1177921076.5791.189.camel@localhost.localdomain> (raw)
In-Reply-To: <46359C8A.4040306@ru.mvista.com>
Ruslan,
Can you please read, understand and comply with
http://www.infradead.org/~dwmw2/email.html
On Mon, 2007-04-30 at 11:36 +0400, Ruslan V. Sushko wrote:
> Thomas,
>
> I have tried to fit driver's functionality into common platform
> structures. Unfortunately the device hasn't NAND controller and some
> signals (ALE/CLE(pins on data bus) and CS(gpio)) are driven in custom
> way. Current platform structures have not enough fields to carry
> platform dependent data for this driver without hack (I guess use fields
> not used in driver but designed for other things is not good idea).
> Additionally due to device haven't NAND controller future version of
> board may change the way which is used to drive CS signal,
I really do not understand what you are talking about. There is no need
for extra fields and no need for hacks at all.
A generic platform driver, which can be used for any board with a
similar simple interface structure as yours, is just a basic interface
to the nand driver and provides common code like initialization, .....
The platform dependent code (in arch/whatever) has the hardware
dependent functions, which are given via the platform mechanism to the
generic platform driver:
struct platform_nand_ctrl {
void (*hwcontrol)(struct mtd_info *mtd, int cmd);
int (*dev_ready)(struct mtd_info *mtd);
void (*select_chip)(struct mtd_info *mtd, int chip);
void *priv;
};
It does not matter whether your board has a special NAND controller or
not. A GPIO based interface fits into this as well, simply because it is
the hardware interface, which controls the NAND flash.
> So I move
> this functionality completely to hardware dependent part of driver (sent
> to LAKML)
Sigh. You need a platform driver in drivers/mtd/nand first to move
anything related to nand into your arch code.
tglx
next prev parent reply other threads:[~2007-04-30 8:15 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-04-28 11:41 [PATH] NAND Flash support for Intel IXP4xx platform Ruslan V. Sushko
2007-04-28 12:33 ` David Woodhouse
2007-04-28 13:32 ` Ruslan V. Sushko
2007-04-28 12:35 ` Thomas Gleixner
2007-04-28 13:42 ` Ruslan V. Sushko
2007-04-28 21:02 ` Thomas Gleixner
2007-04-30 7:36 ` Ruslan V. Sushko
2007-04-30 8:17 ` Thomas Gleixner [this message]
2007-04-30 8:24 ` Vitaly Wool
2007-05-02 16:03 ` Deepak Saxena
2007-05-02 18:09 ` Vitaly Wool
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=1177921076.5791.189.camel@localhost.localdomain \
--to=tglx@linutronix.de \
--cc=linux-mtd@lists.infradead.org \
--cc=rsushko@ru.mvista.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