* [U-Boot-Users] [Attn: Joe Loelinger] Re: [PATCH] Fix up flash_read_uchar() to read uchar more safely in cfi_flash.c.
[not found] ` <45C2D1B1.6000704@orkun.us>
@ 2007-02-02 6:13 ` Tolunay Orkun
2007-02-02 17:37 ` Jon Loeliger
0 siblings, 1 reply; 2+ messages in thread
From: Tolunay Orkun @ 2007-02-02 6:13 UTC (permalink / raw)
To: u-boot
I have to send this to Joe Loelinger through the list due to an
blacklisting issue. Direct mail bounced with the following error:
----- The following addresses had permanent fatal errors -----
<jdl@jdl.com>
(reason: 550-sender IP address 207.115.20.70 is locally blacklisted here. If you think)
I have to send via my ISP mail server "smtp.sbcglobal.net" even though I
am using orkun.us as my email. The IP is assigned by PPPoE.
Regards,
Tolunay
Tolunay Orkun wrote:
> Jon Loeliger wrote:
>> From: Zhang Wei <wei.zhang@freescale.com>
>>
>> Signed-off-by: Zhang Wei <wei.zhang@freescale.com>
>> Signed-off-by: Jon Loeliger <jdl@freescale.com>
>>
>> ---
>> Tolunay,
>>
>> What do you think of this proposed solution to the problem
>> of handling the flash read width issue that we were having
>> with the 8641 HPCN board?
>>
>> If you think this is an acceptable approach, I can resubmit
>> this patch to the U-Boot list if you'd like.
>>
>> Thanks,
>> jdl
>>
>
> I think the approach is sound except I have a few comments below.
>
> Meanwhile, the debugging lead me to conclude the flash_read_uchar() is
> not really the root cause of your problem.
>
> Please refer to email exchange I had with Haiying yesterday. We
> probably need to add "asm("sync;"); to flash_write_cmd() and/or
> udelay(); after reset.
>
>> drivers/cfi_flash.c | 30 ++++++++++++++++++++++++++----
>> 1 files changed, 26 insertions(+), 4 deletions(-)
>>
>> diff --git a/drivers/cfi_flash.c b/drivers/cfi_flash.c
>> index 696f9a4..d109c5e 100644
>> - --- a/drivers/cfi_flash.c
>> +++ b/drivers/cfi_flash.c
>> @@ -255,13 +255,35 @@ #endif
>> */
>> inline uchar flash_read_uchar (flash_info_t * info, uint offset)
>> {
>> - - uchar *cp;
>> + union {
>> + u8 c;
>> + u16 s;
>> + u32 l;
>> + u64 ll;
>> + u8 b[FLASH_CFI_64BIT];
>> + } cp;
>>
> Instead of a anonymous union use cfiword_t and cfiptr_t just like
> flash_write_cmd() does. Remember to use "volatile" for pointer of type
> cfiptr_t.
>
> You will need to augment cfiword_t union for byte access to individual
> bytes (i.e. u8 b[FLASH_CFI_64BIT]);
>
> In addition to this, we need to rework, flash_read_ushort() and
> flash_read_long() similarly for portwidth based accesses. Currently,
> like flash_read_uchar() these are reading single bytes;
>
> Best regards,
> Tolunay
>
^ permalink raw reply [flat|nested] 2+ messages in thread
* [U-Boot-Users] [Attn: Joe Loelinger] Re: [PATCH] Fix up flash_read_uchar() to read uchar more safely in cfi_flash.c.
2007-02-02 6:13 ` [U-Boot-Users] [Attn: Joe Loelinger] Re: [PATCH] Fix up flash_read_uchar() to read uchar more safely in cfi_flash.c Tolunay Orkun
@ 2007-02-02 17:37 ` Jon Loeliger
0 siblings, 0 replies; 2+ messages in thread
From: Jon Loeliger @ 2007-02-02 17:37 UTC (permalink / raw)
To: u-boot
On Fri, 2007-02-02 at 00:13, Tolunay Orkun wrote:
> I have to send this to Joe Loelinger through the list due to an
> blacklisting issue. Direct mail bounced with the following error:
>
> ----- The following addresses had permanent fatal errors -----
> <jdl@jdl.com>
> (reason: 550-sender IP address 207.115.20.70 is locally blacklisted here. If you think)
Bah. Sorry about that.
> I have to send via my ISP mail server "smtp.sbcglobal.net" even though I
> am using orkun.us as my email. The IP is assigned by PPPoE.
I'll whitelist that address for you at home too. Sorry.
> > I think the approach is sound except I have a few comments below.
> >
> > Meanwhile, the debugging lead me to conclude the flash_read_uchar() is
> > not really the root cause of your problem.
> >
> > Please refer to email exchange I had with Haiying yesterday. We
> > probably need to add "asm("sync;"); to flash_write_cmd() and/or
> > udelay(); after reset.
Yeah, I'm just catching up on that thread now. I agree with
folks that the sync (or delay) approach might be the real
issue at work here. I'm waiting on that new version of the
patch as well. I'll give that a try and see how Chris Fester
fares with it as well! :-)
Thanks,
jdl
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2007-02-02 17:37 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <E1HCeLt-0004Io-UA@jdl.com>
[not found] ` <45C2D1B1.6000704@orkun.us>
2007-02-02 6:13 ` [U-Boot-Users] [Attn: Joe Loelinger] Re: [PATCH] Fix up flash_read_uchar() to read uchar more safely in cfi_flash.c Tolunay Orkun
2007-02-02 17:37 ` Jon Loeliger
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.