public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Heiko Schocher <hs@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [POWERPC] TQM8272: Fix compiling error for the TQM8272 board.
Date: Thu, 28 Aug 2008 05:35:48 +0200	[thread overview]
Message-ID: <48B61D14.3090706@denx.de> (raw)
In-Reply-To: <20080827200940.GA20876@ld0162-tx32.am.freescale.net>

Hello Scott,

Scott Wood wrote:
> On Wed, Aug 27, 2008 at 01:08:14PM +0200, Heiko Schocher wrote:
>>  static void upmnand_hwcontrol(struct mtd_info *mtd, int cmd, unsigned int ctrl)
>>  {
>>  	struct nand_chip *this = mtd->priv;
>> +	ulong base = (ulong) (this->IO_ADDR_W + chipsel * CFG_NAND_CS_DIST);
>> +	unsigned char byte = (unsigned char) cmd;
>>
>>  	if (ctrl & NAND_CTRL_CHANGE) {
>> -		if ( ctrl & NAND_CLE )
>> -			hwctl |= 0x1;
>> -		else
>> -			hwctl &= ~0x1;
>> -		if ( ctrl & NAND_ALE )
>> -			hwctl |= 0x2;
>> -		else
>> -			hwctl &= ~0x2;
>> +		if ( ctrl & NAND_CLE ) {
>> +			WRITE_NAND_UPM(byte, base, CFG_NAND_UPM_WRITE_CMD_OFS);
>> +			return ;
>> +		} else
>> +		if ( ctrl & NAND_ALE ) {
>> +			WRITE_NAND_UPM(byte, base, CFG_NAND_UPM_WRITE_ADDR_OFS);
>> +			return ;
> 
> You shouldn't be writing any bytes unless cmd != NAND_CMD_NONE.

Ah, okay ...

> As Stefan pointed out, is there any reason you can't use
> drivers/mtd/nand/fsl_upm.c?

Yes, as I wrote to Stefan, I have no longer the Hardware and I fear
such a big change ...

bye
Heiko
-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany

      reply	other threads:[~2008-08-28  3:35 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-08-27 11:08 [U-Boot] [POWERPC] TQM8272: Fix compiling error for the TQM8272 board Heiko Schocher
2008-08-27 11:13 ` Stefan Roese
2008-08-27 11:34   ` Heiko Schocher
2008-08-27 11:59     ` Stefan Roese
2008-08-27 18:37       ` [U-Boot] [PATCH v2] " Heiko Schocher
2008-08-27 20:10         ` Scott Wood
2008-08-28 11:48           ` [U-Boot] [PATCH v3] " Heiko Schocher
2008-09-06 21:31             ` Wolfgang Denk
2008-08-28 11:50           ` [U-Boot] [PATCH][POWERPC] TQM8272: move NAND part in seperate File Heiko Schocher
2008-09-06 21:32             ` Wolfgang Denk
2008-09-06 20:54         ` [U-Boot] [PATCH v2] [POWERPC] TQM8272: Fix compiling error for the TQM8272 board Wolfgang Denk
2008-08-27 20:09 ` [U-Boot] " Scott Wood
2008-08-28  3:35   ` Heiko Schocher [this message]

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=48B61D14.3090706@denx.de \
    --to=hs@denx.de \
    --cc=u-boot@lists.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