X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=drivers%2Fchar%2Fhvc_vio.c;h=79711aa4b41d4ae85de49cf8bddad9a0c50ded18;hb=f694e53bd0db69557ee8e0db2d1602818ff173b0;hp=651e5d25f58b6437aeea17fc7f31b2cd5ed5ffc2;hpb=790e05d8c2b9941218c7c9ffb5c318382fab0a8b;p=linux-2.6 diff --git a/drivers/char/hvc_vio.c b/drivers/char/hvc_vio.c index 651e5d25f5..79711aa4b4 100644 --- a/drivers/char/hvc_vio.c +++ b/drivers/char/hvc_vio.c @@ -35,6 +35,7 @@ #include #include #include +#include #include "hvc_console.h" @@ -120,6 +121,9 @@ static int hvc_vio_init(void) { int rc; + if (firmware_has_feature(FW_FEATURE_ISERIES)) + return -EIO; + /* Register as a vio device to receive callbacks */ rc = vio_register_driver(&hvc_vio_driver); @@ -141,7 +145,7 @@ static int hvc_find_vtys(void) for (vty = of_find_node_by_name(NULL, "vty"); vty != NULL; vty = of_find_node_by_name(vty, "vty")) { - uint32_t *vtermno; + const uint32_t *vtermno; /* We have statically defined space for only a certain number * of console adapters. @@ -149,11 +153,11 @@ static int hvc_find_vtys(void) if (num_found >= MAX_NR_HVC_CONSOLES) break; - vtermno = (uint32_t *)get_property(vty, "reg", NULL); + vtermno = of_get_property(vty, "reg", NULL); if (!vtermno) continue; - if (device_is_compatible(vty, "hvterm1")) { + if (of_device_is_compatible(vty, "hvterm1")) { hvc_instantiate(*vtermno, num_found, &hvc_get_put_ops); ++num_found; }