static void l2x0pmu_write_counter(int idx, u32 val)
{
	/*
	 * L2X0 counters can only be written to when they are disabled.
	 * As perf core does not disable counters before writing to them
	 * under interrupts, we must do so here.
	 */
	u32 cfg = l2x0pmu_disable_counter(idx);
	writel_relaxed(val, COUNTER_ADDR(idx));
	l2x0pmu_write_cfg(cfg, idx);
}
static void l2x0pmu_write_counter(int idx, u32 val)
{
	/*
                                                                
                                                                 
                                         
  */
	u32 cfg = l2x0pmu_disable_counter(idx);
	writel_relaxed(val, COUNTER_ADDR(idx));
	l2x0pmu_write_cfg(cfg, idx);
}
static u32 l2x0pmu_read_counter(int idx)
{
	u32 val = readl_relaxed(COUNTER_ADDR(idx));

	return val;
}