ARM: mm: cache-l2x0: Add support for re-enabling l2x0
authorColin Cross <ccross@android.com>
Sat, 22 Jan 2011 08:37:09 +0000 (00:37 -0800)
committerDan Willemsen <dwillemsen@nvidia.com>
Thu, 1 Dec 2011 05:34:14 +0000 (21:34 -0800)
commit98ff33dac47885f0b26cfd80fe090a144c6e499d
tree61e959ee8c633e9932f4aecb524de2a79749600d
parent50983012b693831e04c73741de5d31496945c144
ARM: mm: cache-l2x0: Add support for re-enabling l2x0

Remove __init annotation from l2x0_init so it can be used to
reinitialize the l2x0 after it has been reset during suspend.

Only print the init messages the first time l2x0_init is called.

Add l2x0_enable to re-enable the l2x0 after l2x0_disable if
the l2x0 was not reset.

l2x0_disable cannot use writel, as writel calls wmb(), and wmb()
may call outer_cache_sync, which takes the same spinlock as
l2x0_disable.

Change-Id: Iaddedb4f582c7eeaef3cbe2a1e463787f0f809a4
Signed-off-by: Colin Cross <ccross@android.com>
arch/arm/include/asm/hardware/cache-l2x0.h
arch/arm/mm/cache-l2x0.c