public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Tolunay Orkun <listmember@orkun.us>
To: u-boot@lists.denx.de
Subject: [U-Boot-Users] [RFC] CFI Driver Little-Endian write Issue
Date: Tue, 08 Aug 2006 14:51:16 -0500	[thread overview]
Message-ID: <44D8EB34.1010701@orkun.us> (raw)
In-Reply-To: <17624.38357.887902.767831@astp0002.localdomain>

Yuli Barcohen wrote:

> As I mentioned, it's for byte lanes swapping. If you connect a 16-bit
> flash chip to a PPC, you need to connect only two byte lanes of the PPC
> data bus i.e. lines D0-D15. For PPC, D0 is MSB and D15 is LSB. For the
> flash, D0 is LSB and D15 is MSB. So, you can connect D0 to D15, D1 to
> D14, and so on. 

This is the correct way of interfacing flash chip per PowerPC documentation.

> Another possibility D0-D7 of PPC to D7-D0 of the flash and D8-D15 of PPC
> to D15-D8 of the flash. The latter case is the case of swapped byte lanes
> because PPC's most significant byte goes always to D0-D7 and thus to the 
> least significant byte of the flash. 

This is really not the correct way to interface the Flash. It seems like 
hardware designer goofed up and asking the software guys to fix his/her 
mess.

> So, in the latter case, you have to define CFG_FLASH_CFI_SWAP. Without
> CFG_FLASH_CFI_SWAP, any flash command (which is always single byte) will
> go to PPC's D8-D15 and consequently to the most significant byte of the
> flash. This won't work because the commands must go to the flash's least
> significant byte. Of course, PPC is only an example, the same problem
> can occur with other CPUs too, it only depends on the bus architecture.

Really it depends on the designer. The hardware designer can scramble 
the data bus in many more ways.

Best regards,
Tolunay

  reply	other threads:[~2006-08-08 19:51 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-08-08 11:21 [U-Boot-Users] [RFC] CFI Driver Little-Endian write Issue Li Yang-r58472
2006-08-08 13:47 ` Yuli Barcohen
2006-08-08 19:51   ` Tolunay Orkun [this message]
2006-08-09 11:59     ` Yuli Barcohen
  -- strict thread matches above, loose matches on Subject: below --
2006-08-04 12:32 Sam Song
2006-08-04 13:44 ` Wolfgang Denk
2006-08-07 10:34   ` Sam Song
2006-08-07 11:04   ` Yuli Barcohen
2006-08-07 11:43     ` Stefan Roese
2006-08-08  1:59     ` Sam Song
2006-08-08  2:15       ` Zang Roy-r61911
2006-08-08  4:54         ` Sam Song
2006-08-08  5:18           ` Zang Roy-r61911
2006-08-08 10:52             ` Sam Song
2006-08-08 11:00               ` Yuli Barcohen
2006-08-08 11:10                 ` Li Yang-r58472
2006-08-08 11:25                   ` Yuli Barcohen
2006-08-08 11:42                     ` Li Yang-r58472
2006-08-09  6:22                       ` Zang Roy-r61911
2006-08-08 13:10                     ` Sam Song
2006-08-08 13:31                       ` Yuli Barcohen
2006-08-08 14:44                         ` Sam Song
2006-08-09  6:14                 ` Zang Roy-r61911
2006-08-10 15:09                   ` Sam Song
2006-08-09  1:32               ` Zang Roy-r61911
2006-08-07  7:24 ` Zang Roy-r61911
2006-08-08  2:12   ` Sam Song
2006-08-08  2:30     ` Zang Roy-r61911
2006-08-08  4:59       ` Sam Song
2006-08-08  5:13         ` Zang Roy-r61911
2006-08-08 11:00           ` Sam Song

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=44D8EB34.1010701@orkun.us \
    --to=listmember@orkun.us \
    --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