Enable PL310 power-saving modes and tune the cache ram latencies for imx6.
This commit is contained in:
parent
334b9c79c3
commit
95da66135d
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=265447
@ -44,6 +44,19 @@ __FBSDID("$FreeBSD$");
|
||||
void
|
||||
platform_pl310_init(struct pl310_softc *sc)
|
||||
{
|
||||
uint32_t reg;
|
||||
|
||||
/*
|
||||
* Enable power saving modes:
|
||||
* - Dynamic Gating stops the clock when the controller is idle.
|
||||
* - Standby stops the clock when the cores are in WFI mode.
|
||||
*/
|
||||
reg = pl310_read4(sc, PL310_POWER_CTRL);
|
||||
reg |= POWER_CTRL_ENABLE_GATING | POWER_CTRL_ENABLE_STANDBY;
|
||||
pl310_write4(sc, PL310_POWER_CTRL, reg);
|
||||
|
||||
pl310_set_ram_latency(sc, PL310_TAG_RAM_CTRL, 4, 2, 3);
|
||||
pl310_set_ram_latency(sc, PL310_DATA_RAM_CTRL, 4, 2, 3);
|
||||
}
|
||||
|
||||
void
|
||||
|
Loading…
Reference in New Issue
Block a user