struct obp_mem_layout layout_prop;
int layout_size;
- void *regs;
+ void __iomem *regs;
u64 timing_control1;
u64 timing_control2;
static u64 read_mcreg(struct mctrl_info *mp, unsigned long offset)
{
unsigned long ret;
+ int this_cpu = get_cpu();
- if (mp->portid == smp_processor_id()) {
+ if (mp->portid == this_cpu) {
__asm__ __volatile__("ldxa [%1] %2, %0"
: "=r" (ret)
: "r" (offset), "i" (ASI_MCU_CTRL_REG));
: "r" (mp->regs + offset),
"i" (ASI_PHYS_BYPASS_EC_E));
}
+ put_cpu();
+
return ret;
}