Commit 1502b480 authored by Anton Blanchard's avatar Anton Blanchard Committed by Benjamin Herrenschmidt

powerpc: Make device tree accesses in HVC VIO console endian safe

Signed-off-by: default avatarAnton Blanchard <anton@samba.org>
Signed-off-by: default avatarBenjamin Herrenschmidt <benh@kernel.crashing.org>
parent 493adffc
...@@ -404,7 +404,7 @@ module_exit(hvc_vio_exit); ...@@ -404,7 +404,7 @@ module_exit(hvc_vio_exit);
void __init hvc_vio_init_early(void) void __init hvc_vio_init_early(void)
{ {
struct device_node *stdout_node; struct device_node *stdout_node;
const u32 *termno; const __be32 *termno;
const char *name; const char *name;
const struct hv_ops *ops; const struct hv_ops *ops;
...@@ -429,7 +429,7 @@ void __init hvc_vio_init_early(void) ...@@ -429,7 +429,7 @@ void __init hvc_vio_init_early(void)
termno = of_get_property(stdout_node, "reg", NULL); termno = of_get_property(stdout_node, "reg", NULL);
if (termno == NULL) if (termno == NULL)
goto out; goto out;
hvterm_priv0.termno = *termno; hvterm_priv0.termno = of_read_number(termno, 1);
spin_lock_init(&hvterm_priv0.buf_lock); spin_lock_init(&hvterm_priv0.buf_lock);
hvterm_privs[0] = &hvterm_priv0; hvterm_privs[0] = &hvterm_priv0;
......
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