/* * The SRAM content as seen by the ARC core always starts at 0x0 * regardless of the value given here (this was discovered by trial and * error). For SoCs older than Meson6 we probably have to set * AO_REMAP_REG1_MOVE_AHB_SRAM_TO_0X0_INSTEAD_OF_DDR to achieve the * same. (At least) For Meson8 and newer that bit must not be set.
*/
writel(0x0, priv->remap_base + AO_REMAP_REG1);
ret = reset_control_reset(priv->arc_reset); if (ret) {
clk_disable_unprepare(priv->arc_pclk); return ret;
}
usleep_range(10, 100);
/* * Convert from 0xd9000000 to 0xc9000000 as the vendor driver does. * This only seems to be relevant for the AO_CPU_CNTL register. It is * unknown why this is needed.
*/
translated_sram_addr = priv->sram_pa - MESON_AO_RPROC_MEMORY_OFFSET;
priv->secbus2_regmap = syscon_regmap_lookup_by_phandle(dev->of_node, "amlogic,secbus2"); if (IS_ERR(priv->secbus2_regmap)) {
dev_err(dev, "Failed to find SECBUS2 regmap\n");
ret = PTR_ERR(priv->secbus2_regmap); goto err_free_genpool;
}
priv->remap_base = devm_platform_ioremap_resource_byname(pdev, "remap"); if (IS_ERR(priv->remap_base)) {
ret = PTR_ERR(priv->remap_base); goto err_free_genpool;
}
priv->cpu_base = devm_platform_ioremap_resource_byname(pdev, "cpu"); if (IS_ERR(priv->cpu_base)) {
ret = PTR_ERR(priv->cpu_base); goto err_free_genpool;
}
priv->arc_reset = devm_reset_control_get_exclusive(dev, NULL); if (IS_ERR(priv->arc_reset)) {
dev_err(dev, "Failed to get ARC reset\n");
ret = PTR_ERR(priv->arc_reset); goto err_free_genpool;
}
priv->arc_pclk = devm_clk_get(dev, NULL); if (IS_ERR(priv->arc_pclk)) {
dev_err(dev, "Failed to get the ARC PCLK\n");
ret = PTR_ERR(priv->arc_pclk); goto err_free_genpool;
}
platform_set_drvdata(pdev, rproc);
ret = rproc_add(rproc); if (ret) goto err_free_genpool;
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.