[U-Boot] [PATCH 1/2] net: sh_eth: add cache handling

Wolfgang Denk wd at denx.de
Tue Jan 18 10:32:12 CET 2011


Dear Yoshihiro Shimoda,

In message <4D33C0DA.4000701 at renesas.com> you wrote:
> Some CPU needs cache handling. So this patch add the config of
> CONFIG_SH_ETHER_CACHE_WRITEBACK, and it calls wback function.
> 
> Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh at renesas.com>
> ---
>  drivers/net/sh_eth.c |    9 +++++++++
>  1 files changed, 9 insertions(+), 0 deletions(-)
> 
> diff --git a/drivers/net/sh_eth.c b/drivers/net/sh_eth.c
> index 86cc324..53d918d 100644
> --- a/drivers/net/sh_eth.c
> +++ b/drivers/net/sh_eth.c
> @@ -36,6 +36,12 @@
>  #ifndef CONFIG_SH_ETHER_PHY_ADDR
>  # error "Please define CONFIG_SH_ETHER_PHY_ADDR"
>  #endif
> +#ifdef CONFIG_SH_ETHER_CACHE_WRITEBACK
> +#define flush_cache_wback(addr, len)	\
> +			dcache_wback_range((u32)addr, (u32)(addr + len - 1))
> +#else
> +#define flush_cache_wback(...)
> +#endif

New config options must be documented in the README.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
When all is said and done, more is said than done.


More information about the U-Boot mailing list