Re: [PATCHv3 1/2] ARM: imx53: add secure-reg-access support for PMU

From: Fabio Estevam
Date: Fri Feb 09 2018 - 15:08:17 EST


On Fri, Feb 9, 2018 at 3:03 PM, Sebastian Reichel
<sebastian.reichel@xxxxxxxxxxxxxxx> wrote:

> + gpc_reg = ioremap(MXC_CORTEXA8_PLAT_GPC, 4);
> + if (!gpc_reg) {
> + pr_warning("unable to map GPC to enable perf\n");
> + return;
> + }
> +
> + gpc = __raw_readl(gpc_reg);

You could use readl_relaxed() instead.

> + gpc |= GPC_DBG_EN;
> + __raw_writel(gpc, gpc_reg);

You could use writel_relaxed() instead.

> +
> + return;

This 'return' can be removed.

> +}