From: Tolunay Orkun <listmember@orkun.us>
To: u-boot@lists.denx.de
Subject: [U-Boot-Users] [PATCH] Add sync at the end of flash_write_cmd for MPC86xx
Date: Tue, 06 Feb 2007 03:10:35 -0600 [thread overview]
Message-ID: <45C8460B.1060004@orkun.us> (raw)
In-Reply-To: <1170706772.3901.14.camel@udp097531uds.am.freescale.net>
Haiying Wang wrote:
> diff --git a/drivers/cfi_flash.c b/drivers/cfi_flash.c
> index 696f9a4..a93e94d 100644
> --- a/drivers/cfi_flash.c
> +++ b/drivers/cfi_flash.c
> @@ -971,6 +971,9 @@ static void flash_write_cmd (flash_info_t * info, flash_sect_t sect, uint offset
> #endif
> break;
> }
> +#ifdef CONFIG_MPC86xx
> + asm("sync;");
> +#endif
> }
>
> static void flash_unlock_seq (flash_info_t * info, flash_sect_t sect)
I think for consistency of the code, you should either relocate blackfin
sync instruction to the end or add MPC86xx sync instructions to each
case just like blackfin does.
Having addressed that, I think this patch would be OK for me except that
as you have probably seen the discussion in the list, it will be better
to define SYNC macros in cpu architecture files and call SYNC; instead
fo asm("sync;");
So, please create an independent patch that adds SYNC to all CPU
architectures (dummy stub if architecture does not have such feature)
and submit that patch first. Refer to other email for details. Right now
all PowerPC variants and Blackfin needs this but more might come.
Having submitted that patch, please modify this patch about to use SYNC;
and submit as well.
I know it is probably a bit more work than you wished for but we should
do this the right way.
Tolunay
prev parent reply other threads:[~2007-02-06 9:10 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-02-05 20:19 [U-Boot-Users] [PATCH] Add sync at the end of flash_write_cmd for MPC86xx Haiying Wang
2007-02-05 21:01 ` Andrew Dyer
2007-02-05 21:11 ` Haavard Skinnemoen
2007-02-06 7:06 ` Stefan Roese
2007-02-06 8:50 ` Tolunay Orkun
2007-02-06 11:31 ` Haavard Skinnemoen
2007-02-05 21:11 ` Haiying Wang
2007-02-06 9:10 ` Tolunay Orkun [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=45C8460B.1060004@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