[U-Boot-Users] [PATCH][RFC] lib_ppc: make the flush_cache stronger

Wolfgang Denk wd at denx.de
Thu Apr 24 16:45:17 CEST 2008


In message <1208236923.3656.15.camel at localhost.localdomain> you wrote:
> Current flush_cache code does
> 
> 1. clean the dcache with dcbst, but not invalidate dcache
> 2. invalidate icache
> 
> This patch use the dcbf instead of dcbst to have stronger
> semantic, clean the dcache and invalidate dcache.

On which processors did you test the changes? I have some unclear
memories of dcbf having problems on for example MPC8xx ?

> We have two options:
> 
> 1. Separate functions for them like linux kernel.
>    A. clean dcache (dcbst) for DMA_TO_DEVICE
>    B. invalidate dcache (dcbi) for DMA_FROM_DEVICE
>    C. flush dcache (dcbf) for DMA_BIDIRECTIONAL.
> 2. Make current flush_cache stronger semanctic.
>    use the dcbf instead of dcbst.
> 
> Which one is better? or you have better option?
> Please suggest.

We discussed this a bit on IRC; Kumar suggested to go for 1., and I
agree.

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
"I believe the use of noise to make  music  will  increase  until  we
reach  a  music  produced  through  the aid of electrical instruments
which will make available for musical purposes  any  and  all  sounds
that can be heard."                        - composer John Cage, 1937




More information about the U-Boot mailing list