Commit 19fa17e5 authored by Paul Mackerras's avatar Paul Mackerras

powerpc: Use rtas_call not call_rtas in CHRP code

The nvram driver imported from the ppc code uses call_rtas, but
rtas_call is the name we are using in merged code (since ppc64 used
that name, and it uses far more RTAS calls than ppc32).
Signed-off-by: default avatarPaul Mackerras <paulus@samba.org>
parent f2cad7a8
...@@ -34,7 +34,8 @@ static unsigned char chrp_nvram_read(int addr) ...@@ -34,7 +34,8 @@ static unsigned char chrp_nvram_read(int addr)
return 0xff; return 0xff;
} }
spin_lock_irqsave(&nvram_lock, flags); spin_lock_irqsave(&nvram_lock, flags);
if ((call_rtas("nvram-fetch", 3, 2, &done, addr, __pa(nvram_buf), 1) != 0) || 1 != done) if ((rtas_call(rtas_token("nvram-fetch"), 3, 2, &done, addr,
__pa(nvram_buf), 1) != 0) || 1 != done)
ret = 0xff; ret = 0xff;
else else
ret = nvram_buf[0]; ret = nvram_buf[0];
...@@ -54,7 +55,8 @@ static void chrp_nvram_write(int addr, unsigned char val) ...@@ -54,7 +55,8 @@ static void chrp_nvram_write(int addr, unsigned char val)
} }
spin_lock_irqsave(&nvram_lock, flags); spin_lock_irqsave(&nvram_lock, flags);
nvram_buf[0] = val; nvram_buf[0] = val;
if ((call_rtas("nvram-store", 3, 2, &done, addr, __pa(nvram_buf), 1) != 0) || 1 != done) if ((rtas_call(rtas_token("nvram-store"), 3, 2, &done, addr,
__pa(nvram_buf), 1) != 0) || 1 != done)
printk(KERN_DEBUG "rtas IO error storing 0x%02x at %d", val, addr); printk(KERN_DEBUG "rtas IO error storing 0x%02x at %d", val, addr);
spin_unlock_irqrestore(&nvram_lock, flags); spin_unlock_irqrestore(&nvram_lock, flags);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment