mirror of
https://github.com/edk2-porting/linux-next.git
synced 2025-01-07 13:13:57 +08:00
ARM: OMAP4+: PRM: setup prm_features from the PRM init time flags
Currently some cpu_is_X checks are used to setup prm_features, however the same can be accomplished by just passing these flags from the PRM init data. This is done in preparation to make PRM a separate driver. Signed-off-by: Tero Kristo <t-kristo@ti.com>
This commit is contained in:
parent
425dc8b2df
commit
8b5b9a22b5
@ -707,10 +707,10 @@ int __init omap44xx_prm_init(const struct omap_prcm_init_data *data)
|
|||||||
{
|
{
|
||||||
omap_prm_base_init();
|
omap_prm_base_init();
|
||||||
|
|
||||||
if (cpu_is_omap44xx() || soc_is_omap54xx() || soc_is_dra7xx())
|
if (data->flags & PRM_HAS_IO_WAKEUP)
|
||||||
prm_features |= PRM_HAS_IO_WAKEUP;
|
prm_features |= PRM_HAS_IO_WAKEUP;
|
||||||
|
|
||||||
if (!soc_is_dra7xx())
|
if (data->flags & PRM_HAS_VOLTAGE)
|
||||||
prm_features |= PRM_HAS_VOLTAGE;
|
prm_features |= PRM_HAS_VOLTAGE;
|
||||||
|
|
||||||
omap4_prminst_set_prm_dev_inst(data->device_inst_offset);
|
omap4_prminst_set_prm_dev_inst(data->device_inst_offset);
|
||||||
|
@ -669,6 +669,7 @@ static struct omap_prcm_init_data omap4_prm_data __initdata = {
|
|||||||
.index = TI_CLKM_PRM,
|
.index = TI_CLKM_PRM,
|
||||||
.init = omap44xx_prm_init,
|
.init = omap44xx_prm_init,
|
||||||
.device_inst_offset = OMAP4430_PRM_DEVICE_INST,
|
.device_inst_offset = OMAP4430_PRM_DEVICE_INST,
|
||||||
|
.flags = PRM_HAS_IO_WAKEUP | PRM_HAS_VOLTAGE,
|
||||||
};
|
};
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@ -677,6 +678,7 @@ static struct omap_prcm_init_data omap5_prm_data __initdata = {
|
|||||||
.index = TI_CLKM_PRM,
|
.index = TI_CLKM_PRM,
|
||||||
.init = omap44xx_prm_init,
|
.init = omap44xx_prm_init,
|
||||||
.device_inst_offset = OMAP54XX_PRM_DEVICE_INST,
|
.device_inst_offset = OMAP54XX_PRM_DEVICE_INST,
|
||||||
|
.flags = PRM_HAS_IO_WAKEUP | PRM_HAS_VOLTAGE,
|
||||||
};
|
};
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@ -685,6 +687,7 @@ static struct omap_prcm_init_data dra7_prm_data __initdata = {
|
|||||||
.index = TI_CLKM_PRM,
|
.index = TI_CLKM_PRM,
|
||||||
.init = omap44xx_prm_init,
|
.init = omap44xx_prm_init,
|
||||||
.device_inst_offset = DRA7XX_PRM_DEVICE_INST,
|
.device_inst_offset = DRA7XX_PRM_DEVICE_INST,
|
||||||
|
.flags = PRM_HAS_IO_WAKEUP,
|
||||||
};
|
};
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user