]> git.sur5r.net Git - u-boot/commit
ARC: Cache: Get rid of [slc,pae,icache,dcache]_exists global variables
authorEugeniy Paltsev <Eugeniy.Paltsev@synopsys.com>
Wed, 21 Mar 2018 12:58:56 +0000 (15:58 +0300)
committerAlexey Brodkin <abrodkin@synopsys.com>
Wed, 21 Mar 2018 14:06:54 +0000 (17:06 +0300)
commit75790873202f005e93085cc5ff5076bce0f5e84a
tree83a5c67f3591eaadf23ed8b975082889466eafcf
parentea9f6f1e873cc1b6fe220e1017357532045ce988
ARC: Cache: Get rid of [slc,pae,icache,dcache]_exists global variables

There is a problem with current implementation if we start U-Boot
from ROM, as we use global variables before ther initialization,
so these variables get overwritten when we copy .data section
from ROM.

Instead we'll use icache_exists(), dcache_exists(), slc_exists(), pae_exists()
functions which directly check BCRs every time.

In U-Boot case ops are used only during self-relocation and DMA
so we shouldn't be hit by noticeable performance degradation.

Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com>
Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
arch/arc/lib/cache.c