aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/serial
diff options
context:
space:
mode:
authorJeremy Kerr <jk@ozlabs.org>2006-07-12 01:40:29 -0400
committerPaul Mackerras <paulus@samba.org>2006-07-31 01:55:05 -0400
commit018a3d1db7cdb6127656c1622ee1d2302e16436d (patch)
tree5b6714fa9fcd1441f7c1b30e0391484c095925b6 /drivers/serial
parenteeb2b723ef5100fafa381d92eb70d83e98516a44 (diff)
[POWERPC] powermac: Constify & voidify get_property()
Now that get_property() returns a void *, there's no need to cast its return value. Also, treat the return value as const, so we can constify get_property later. powermac platform & macintosh driver changes. Built for pmac32_defconfig, g5_defconfig Signed-off-by: Jeremy Kerr <jk@ozlabs.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'drivers/serial')
-rw-r--r--drivers/serial/pmac_zilog.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/serial/pmac_zilog.c b/drivers/serial/pmac_zilog.c
index bfd2a22759eb..a3b99caf80e6 100644
--- a/drivers/serial/pmac_zilog.c
+++ b/drivers/serial/pmac_zilog.c
@@ -1400,8 +1400,8 @@ static struct uart_ops pmz_pops = {
1400static int __init pmz_init_port(struct uart_pmac_port *uap) 1400static int __init pmz_init_port(struct uart_pmac_port *uap)
1401{ 1401{
1402 struct device_node *np = uap->node; 1402 struct device_node *np = uap->node;
1403 char *conn; 1403 const char *conn;
1404 struct slot_names_prop { 1404 const struct slot_names_prop {
1405 int count; 1405 int count;
1406 char name[1]; 1406 char name[1];
1407 } *slots; 1407 } *slots;
@@ -1458,7 +1458,7 @@ no_dma:
1458 uap->flags |= PMACZILOG_FLAG_IS_IRDA; 1458 uap->flags |= PMACZILOG_FLAG_IS_IRDA;
1459 uap->port_type = PMAC_SCC_ASYNC; 1459 uap->port_type = PMAC_SCC_ASYNC;
1460 /* 1999 Powerbook G3 has slot-names property instead */ 1460 /* 1999 Powerbook G3 has slot-names property instead */
1461 slots = (struct slot_names_prop *)get_property(np, "slot-names", &len); 1461 slots = get_property(np, "slot-names", &len);
1462 if (slots && slots->count > 0) { 1462 if (slots && slots->count > 0) {
1463 if (strcmp(slots->name, "IrDA") == 0) 1463 if (strcmp(slots->name, "IrDA") == 0)
1464 uap->flags |= PMACZILOG_FLAG_IS_IRDA; 1464 uap->flags |= PMACZILOG_FLAG_IS_IRDA;
@@ -1470,7 +1470,8 @@ no_dma:
1470 if (ZS_IS_INTMODEM(uap)) { 1470 if (ZS_IS_INTMODEM(uap)) {
1471 struct device_node* i2c_modem = find_devices("i2c-modem"); 1471 struct device_node* i2c_modem = find_devices("i2c-modem");
1472 if (i2c_modem) { 1472 if (i2c_modem) {
1473 char* mid = get_property(i2c_modem, "modem-id", NULL); 1473 const char* mid =
1474 get_property(i2c_modem, "modem-id", NULL);
1474 if (mid) switch(*mid) { 1475 if (mid) switch(*mid) {
1475 case 0x04 : 1476 case 0x04 :
1476 case 0x05 : 1477 case 0x05 :