From: Wolfgang Denk Date: Thu, 04 Jan 2007 10:23:31 +0100 Subject: [U-Boot-Users] [PATCH] Fixed cfi flash read uchar bug. In-Reply-To: Your message of "Thu, 04 Jan 2007 16:36:34 +0800." <46B96294322F7D458F9648B60E15112C03EEE0@zch01exm26.fsl.freescale.net> Message-ID: <20070104092331.EC2C4353C96@atlas.denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de In message <46B96294322F7D458F9648B60E15112C03EEE0@zch01exm26.fsl.freescale.net> you wrote: > > The below is the previous email: > > Wolfgang Denk wrote: > > Now this is what I want to understand. What exactly is the "potential > > problem"? > > That's the issue in the flash 'Spinsion S29GL064M90TFIR6' with x16 > connection. After running flash_read_jedec_ids(), any follow CFI query > command will get the data with high 8bit = 0xff, but the low 8bit is > valid. And if we only read low 8bit, we'll get the 0xff too. In > addition, the second follow CFI query command has no that issue. So, I > read the full 16bit date and only take the valid low 8bit. etc. etc. I didn't see any new facts in your current posting. My position has not changed either: I don't see how your character-wise copy using memcpy() would be different from accessing the flash through a uchar pointer; also I still think that if the compiler version changes behaviour then we don't really understand what's going on here. Maybe Tolunay or Stefan can comment now that both are back from their Xmas breaks; they both know the CFI driver much better than me. I tend to reject your proposed patch until we really understand the problem. To me, the patch seems to be wrong. Best regards, Wolfgang Denk -- Software Engineering: Embedded and Realtime Systems, Embedded Linux Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de Unix is like a toll road on which you have to stop every 50 feet to pay another nickel. But hey! You only feel 5 cents poorer each time. - Larry Wall in <1992Aug13.192357.15731@netlabs.com>