Changeset View
Changeset View
Standalone View
Standalone View
sys/arm/mv/armada38x/armada38x.c
Show First 20 Lines • Show All 167 Lines • ▼ Show 20 Lines | armada38x_scu_enable(void) | ||||
rv = bus_space_map(fdtbus_bs_tag, (bus_addr_t)MV_SCU_BASE, | rv = bus_space_map(fdtbus_bs_tag, (bus_addr_t)MV_SCU_BASE, | ||||
MV_SCU_REGS_LEN, 0, &vaddr_scu); | MV_SCU_REGS_LEN, 0, &vaddr_scu); | ||||
if (rv != 0) | if (rv != 0) | ||||
return (rv); | return (rv); | ||||
/* Enable SCU */ | /* Enable SCU */ | ||||
val = bus_space_read_4(fdtbus_bs_tag, vaddr_scu, MV_SCU_REG_CTRL); | val = bus_space_read_4(fdtbus_bs_tag, vaddr_scu, MV_SCU_REG_CTRL); | ||||
if (!(val & MV_SCU_ENABLE)) | if (!(val & MV_SCU_ENABLE)) { | ||||
/* Enable SCU Speculative linefills to L2 */ | |||||
val |= MV_SCU_SL_L2_ENABLE; | |||||
bus_space_write_4(fdtbus_bs_tag, vaddr_scu, 0, | bus_space_write_4(fdtbus_bs_tag, vaddr_scu, 0, | ||||
val | MV_SCU_ENABLE); | val | MV_SCU_ENABLE); | ||||
} | |||||
bus_space_unmap(fdtbus_bs_tag, vaddr_scu, MV_SCU_REGS_LEN); | bus_space_unmap(fdtbus_bs_tag, vaddr_scu, MV_SCU_REGS_LEN); | ||||
return (0); | return (0); | ||||
} | } |