aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorStephen Rothwell <sfr@canb.auug.org.au>2007-05-03 03:26:52 -0400
committerPaul Mackerras <paulus@samba.org>2007-05-07 06:31:14 -0400
commit55b61fec22caa3e7872caea6c4100fc75cb8f49b (patch)
tree995c2cf733bbd9ee1adc6e77773b0e31e9c21267 /drivers
parentd9333afd6a714760c13f76ba275a32ec7bd979c1 (diff)
[POWERPC] Rename device_is_compatible to of_device_is_compatible
for consistency with other Open Firmware interfaces (and Sparc). This is just a straight replacement. This leaves the compatibility define in place. Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/char/hvc_iseries.c2
-rw-r--r--drivers/char/hvc_vio.c2
-rw-r--r--drivers/char/tpm/tpm_atmel.h2
-rw-r--r--drivers/hwmon/ams/ams-core.c4
-rw-r--r--drivers/ide/pci/pdc202xx_new.c2
-rw-r--r--drivers/ide/ppc/pmac.c14
-rw-r--r--drivers/macintosh/smu.c2
-rw-r--r--drivers/macintosh/therm_adt746x.c4
-rw-r--r--drivers/macintosh/via-pmu.c10
-rw-r--r--drivers/macintosh/windfarm_lm75_sensor.c4
-rw-r--r--drivers/macintosh/windfarm_max6690_sensor.c2
-rw-r--r--drivers/macintosh/windfarm_smu_controls.c2
-rw-r--r--drivers/macintosh/windfarm_smu_sat.c2
-rw-r--r--drivers/serial/pmac_zilog.c2
-rw-r--r--drivers/usb/host/ohci-ppc-of.c4
-rw-r--r--drivers/video/offb.c4
16 files changed, 31 insertions, 31 deletions
diff --git a/drivers/char/hvc_iseries.c b/drivers/char/hvc_iseries.c
index ec420fe8a908..b37f1d5a5be6 100644
--- a/drivers/char/hvc_iseries.c
+++ b/drivers/char/hvc_iseries.c
@@ -579,7 +579,7 @@ static int hvc_find_vtys(void)
579 if (!vtermno) 579 if (!vtermno)
580 continue; 580 continue;
581 581
582 if (!device_is_compatible(vty, "IBM,iSeries-vty")) 582 if (!of_device_is_compatible(vty, "IBM,iSeries-vty"))
583 continue; 583 continue;
584 584
585 if (num_found == 0) 585 if (num_found == 0)
diff --git a/drivers/char/hvc_vio.c b/drivers/char/hvc_vio.c
index 94a542e20efb..79711aa4b41d 100644
--- a/drivers/char/hvc_vio.c
+++ b/drivers/char/hvc_vio.c
@@ -157,7 +157,7 @@ static int hvc_find_vtys(void)
157 if (!vtermno) 157 if (!vtermno)
158 continue; 158 continue;
159 159
160 if (device_is_compatible(vty, "hvterm1")) { 160 if (of_device_is_compatible(vty, "hvterm1")) {
161 hvc_instantiate(*vtermno, num_found, &hvc_get_put_ops); 161 hvc_instantiate(*vtermno, num_found, &hvc_get_put_ops);
162 ++num_found; 162 ++num_found;
163 } 163 }
diff --git a/drivers/char/tpm/tpm_atmel.h b/drivers/char/tpm/tpm_atmel.h
index 377bc6077c6f..c912d8691cbd 100644
--- a/drivers/char/tpm/tpm_atmel.h
+++ b/drivers/char/tpm/tpm_atmel.h
@@ -47,7 +47,7 @@ static void __iomem * atmel_get_base_addr(unsigned long *base, int *region_size)
47 if (!dn) 47 if (!dn)
48 return NULL; 48 return NULL;
49 49
50 if (!device_is_compatible(dn, "AT97SC3201")) { 50 if (!of_device_is_compatible(dn, "AT97SC3201")) {
51 of_node_put(dn); 51 of_node_put(dn);
52 return NULL; 52 return NULL;
53 } 53 }
diff --git a/drivers/hwmon/ams/ams-core.c b/drivers/hwmon/ams/ams-core.c
index 93b963fd1293..dbe6a32c064e 100644
--- a/drivers/hwmon/ams/ams-core.c
+++ b/drivers/hwmon/ams/ams-core.c
@@ -208,14 +208,14 @@ int __init ams_init(void)
208 208
209#ifdef CONFIG_SENSORS_AMS_I2C 209#ifdef CONFIG_SENSORS_AMS_I2C
210 np = of_find_node_by_name(NULL, "accelerometer"); 210 np = of_find_node_by_name(NULL, "accelerometer");
211 if (np && device_is_compatible(np, "AAPL,accelerometer_1")) 211 if (np && of_device_is_compatible(np, "AAPL,accelerometer_1"))
212 /* Found I2C motion sensor */ 212 /* Found I2C motion sensor */
213 return ams_i2c_init(np); 213 return ams_i2c_init(np);
214#endif 214#endif
215 215
216#ifdef CONFIG_SENSORS_AMS_PMU 216#ifdef CONFIG_SENSORS_AMS_PMU
217 np = of_find_node_by_name(NULL, "sms"); 217 np = of_find_node_by_name(NULL, "sms");
218 if (np && device_is_compatible(np, "sms")) 218 if (np && of_device_is_compatible(np, "sms"))
219 /* Found PMU motion sensor */ 219 /* Found PMU motion sensor */
220 return ams_pmu_init(np); 220 return ams_pmu_init(np);
221#endif 221#endif
diff --git a/drivers/ide/pci/pdc202xx_new.c b/drivers/ide/pci/pdc202xx_new.c
index ace98929cc3d..ae20fb3f6cbc 100644
--- a/drivers/ide/pci/pdc202xx_new.c
+++ b/drivers/ide/pci/pdc202xx_new.c
@@ -398,7 +398,7 @@ static void __devinit apple_kiwi_init(struct pci_dev *pdev)
398 unsigned int class_rev = 0; 398 unsigned int class_rev = 0;
399 u8 conf; 399 u8 conf;
400 400
401 if (np == NULL || !device_is_compatible(np, "kiwi-root")) 401 if (np == NULL || !of_device_is_compatible(np, "kiwi-root"))
402 return; 402 return;
403 403
404 pci_read_config_dword(pdev, PCI_CLASS_REVISION, &class_rev); 404 pci_read_config_dword(pdev, PCI_CLASS_REVISION, &class_rev);
diff --git a/drivers/ide/ppc/pmac.c b/drivers/ide/ppc/pmac.c
index 774bfd39a599..a49ebe44babd 100644
--- a/drivers/ide/ppc/pmac.c
+++ b/drivers/ide/ppc/pmac.c
@@ -1157,18 +1157,18 @@ pmac_ide_setup_device(pmac_ide_hwif_t *pmif, ide_hwif_t *hwif)
1157 1157
1158 pmif->cable_80 = 0; 1158 pmif->cable_80 = 0;
1159 pmif->broken_dma = pmif->broken_dma_warn = 0; 1159 pmif->broken_dma = pmif->broken_dma_warn = 0;
1160 if (device_is_compatible(np, "shasta-ata")) 1160 if (of_device_is_compatible(np, "shasta-ata"))
1161 pmif->kind = controller_sh_ata6; 1161 pmif->kind = controller_sh_ata6;
1162 else if (device_is_compatible(np, "kauai-ata")) 1162 else if (of_device_is_compatible(np, "kauai-ata"))
1163 pmif->kind = controller_un_ata6; 1163 pmif->kind = controller_un_ata6;
1164 else if (device_is_compatible(np, "K2-UATA")) 1164 else if (of_device_is_compatible(np, "K2-UATA"))
1165 pmif->kind = controller_k2_ata6; 1165 pmif->kind = controller_k2_ata6;
1166 else if (device_is_compatible(np, "keylargo-ata")) { 1166 else if (of_device_is_compatible(np, "keylargo-ata")) {
1167 if (strcmp(np->name, "ata-4") == 0) 1167 if (strcmp(np->name, "ata-4") == 0)
1168 pmif->kind = controller_kl_ata4; 1168 pmif->kind = controller_kl_ata4;
1169 else 1169 else
1170 pmif->kind = controller_kl_ata3; 1170 pmif->kind = controller_kl_ata3;
1171 } else if (device_is_compatible(np, "heathrow-ata")) 1171 } else if (of_device_is_compatible(np, "heathrow-ata"))
1172 pmif->kind = controller_heathrow; 1172 pmif->kind = controller_heathrow;
1173 else { 1173 else {
1174 pmif->kind = controller_ohare; 1174 pmif->kind = controller_ohare;
@@ -1190,8 +1190,8 @@ pmac_ide_setup_device(pmac_ide_hwif_t *pmif, ide_hwif_t *hwif)
1190 * they have a 80 conductor cable, this seem to be always the case unless 1190 * they have a 80 conductor cable, this seem to be always the case unless
1191 * the user mucked around 1191 * the user mucked around
1192 */ 1192 */
1193 if (device_is_compatible(np, "K2-UATA") || 1193 if (of_device_is_compatible(np, "K2-UATA") ||
1194 device_is_compatible(np, "shasta-ata")) 1194 of_device_is_compatible(np, "shasta-ata"))
1195 pmif->cable_80 = 1; 1195 pmif->cable_80 = 1;
1196 1196
1197 /* On Kauai-type controllers, we make sure the FCR is correct */ 1197 /* On Kauai-type controllers, we make sure the FCR is correct */
diff --git a/drivers/macintosh/smu.c b/drivers/macintosh/smu.c
index a98a328b1cfc..f8e1a135bf9d 100644
--- a/drivers/macintosh/smu.c
+++ b/drivers/macintosh/smu.c
@@ -606,7 +606,7 @@ static void smu_expose_childs(struct work_struct *unused)
606 struct device_node *np; 606 struct device_node *np;
607 607
608 for (np = NULL; (np = of_get_next_child(smu->of_node, np)) != NULL;) 608 for (np = NULL; (np = of_get_next_child(smu->of_node, np)) != NULL;)
609 if (device_is_compatible(np, "smu-sensors")) 609 if (of_device_is_compatible(np, "smu-sensors"))
610 of_platform_device_create(np, "smu-sensors", 610 of_platform_device_create(np, "smu-sensors",
611 &smu->of_dev->dev); 611 &smu->of_dev->dev);
612} 612}
diff --git a/drivers/macintosh/therm_adt746x.c b/drivers/macintosh/therm_adt746x.c
index 228903403cfc..178afa1fd56c 100644
--- a/drivers/macintosh/therm_adt746x.c
+++ b/drivers/macintosh/therm_adt746x.c
@@ -560,9 +560,9 @@ thermostat_init(void)
560 np = of_find_node_by_name(NULL, "fan"); 560 np = of_find_node_by_name(NULL, "fan");
561 if (!np) 561 if (!np)
562 return -ENODEV; 562 return -ENODEV;
563 if (device_is_compatible(np, "adt7460")) 563 if (of_device_is_compatible(np, "adt7460"))
564 therm_type = ADT7460; 564 therm_type = ADT7460;
565 else if (device_is_compatible(np, "adt7467")) 565 else if (of_device_is_compatible(np, "adt7467"))
566 therm_type = ADT7467; 566 therm_type = ADT7467;
567 else 567 else
568 return -ENODEV; 568 return -ENODEV;
diff --git a/drivers/macintosh/via-pmu.c b/drivers/macintosh/via-pmu.c
index 1729d3fd7a11..0707624dfad3 100644
--- a/drivers/macintosh/via-pmu.c
+++ b/drivers/macintosh/via-pmu.c
@@ -310,14 +310,14 @@ int __init find_via_pmu(void)
310 PMU_INT_TICK; 310 PMU_INT_TICK;
311 311
312 if (vias->parent->name && ((strcmp(vias->parent->name, "ohare") == 0) 312 if (vias->parent->name && ((strcmp(vias->parent->name, "ohare") == 0)
313 || device_is_compatible(vias->parent, "ohare"))) 313 || of_device_is_compatible(vias->parent, "ohare")))
314 pmu_kind = PMU_OHARE_BASED; 314 pmu_kind = PMU_OHARE_BASED;
315 else if (device_is_compatible(vias->parent, "paddington")) 315 else if (of_device_is_compatible(vias->parent, "paddington"))
316 pmu_kind = PMU_PADDINGTON_BASED; 316 pmu_kind = PMU_PADDINGTON_BASED;
317 else if (device_is_compatible(vias->parent, "heathrow")) 317 else if (of_device_is_compatible(vias->parent, "heathrow"))
318 pmu_kind = PMU_HEATHROW_BASED; 318 pmu_kind = PMU_HEATHROW_BASED;
319 else if (device_is_compatible(vias->parent, "Keylargo") 319 else if (of_device_is_compatible(vias->parent, "Keylargo")
320 || device_is_compatible(vias->parent, "K2-Keylargo")) { 320 || of_device_is_compatible(vias->parent, "K2-Keylargo")) {
321 struct device_node *gpiop; 321 struct device_node *gpiop;
322 struct device_node *adbp; 322 struct device_node *adbp;
323 u64 gaddr = OF_BAD_ADDR; 323 u64 gaddr = OF_BAD_ADDR;
diff --git a/drivers/macintosh/windfarm_lm75_sensor.c b/drivers/macintosh/windfarm_lm75_sensor.c
index ab4d1b63f63e..a0fabf3c2008 100644
--- a/drivers/macintosh/windfarm_lm75_sensor.c
+++ b/drivers/macintosh/windfarm_lm75_sensor.c
@@ -188,10 +188,10 @@ static int wf_lm75_attach(struct i2c_adapter *adapter)
188 if (loc == NULL || addr == 0) 188 if (loc == NULL || addr == 0)
189 continue; 189 continue;
190 /* real lm75 */ 190 /* real lm75 */
191 if (device_is_compatible(dev, "lm75")) 191 if (of_device_is_compatible(dev, "lm75"))
192 wf_lm75_create(adapter, addr, 0, loc); 192 wf_lm75_create(adapter, addr, 0, loc);
193 /* ds1775 (compatible, better resolution */ 193 /* ds1775 (compatible, better resolution */
194 else if (device_is_compatible(dev, "ds1775")) 194 else if (of_device_is_compatible(dev, "ds1775"))
195 wf_lm75_create(adapter, addr, 1, loc); 195 wf_lm75_create(adapter, addr, 1, loc);
196 } 196 }
197 return 0; 197 return 0;
diff --git a/drivers/macintosh/windfarm_max6690_sensor.c b/drivers/macintosh/windfarm_max6690_sensor.c
index eaa74afa175b..5f03aab9fb5d 100644
--- a/drivers/macintosh/windfarm_max6690_sensor.c
+++ b/drivers/macintosh/windfarm_max6690_sensor.c
@@ -131,7 +131,7 @@ static int wf_max6690_attach(struct i2c_adapter *adapter)
131 */ 131 */
132 if (!pmac_i2c_match_adapter(dev, adapter)) 132 if (!pmac_i2c_match_adapter(dev, adapter))
133 continue; 133 continue;
134 if (!device_is_compatible(dev, "max6690")) 134 if (!of_device_is_compatible(dev, "max6690"))
135 continue; 135 continue;
136 addr = pmac_i2c_get_dev_addr(dev); 136 addr = pmac_i2c_get_dev_addr(dev);
137 loc = of_get_property(dev, "hwsensor-location", NULL); 137 loc = of_get_property(dev, "hwsensor-location", NULL);
diff --git a/drivers/macintosh/windfarm_smu_controls.c b/drivers/macintosh/windfarm_smu_controls.c
index ff398adc0283..58c2590f05ec 100644
--- a/drivers/macintosh/windfarm_smu_controls.c
+++ b/drivers/macintosh/windfarm_smu_controls.c
@@ -263,7 +263,7 @@ static int __init smu_controls_init(void)
263 /* Look for RPM fans */ 263 /* Look for RPM fans */
264 for (fans = NULL; (fans = of_get_next_child(smu, fans)) != NULL;) 264 for (fans = NULL; (fans = of_get_next_child(smu, fans)) != NULL;)
265 if (!strcmp(fans->name, "rpm-fans") || 265 if (!strcmp(fans->name, "rpm-fans") ||
266 device_is_compatible(fans, "smu-rpm-fans")) 266 of_device_is_compatible(fans, "smu-rpm-fans"))
267 break; 267 break;
268 for (fan = NULL; 268 for (fan = NULL;
269 fans && (fan = of_get_next_child(fans, fan)) != NULL;) { 269 fans && (fan = of_get_next_child(fans, fan)) != NULL;) {
diff --git a/drivers/macintosh/windfarm_smu_sat.c b/drivers/macintosh/windfarm_smu_sat.c
index 9a6c2cf8fd0e..1043b39aa123 100644
--- a/drivers/macintosh/windfarm_smu_sat.c
+++ b/drivers/macintosh/windfarm_smu_sat.c
@@ -380,7 +380,7 @@ static int wf_sat_attach(struct i2c_adapter *adapter)
380 busnode = pmac_i2c_get_bus_node(bus); 380 busnode = pmac_i2c_get_bus_node(bus);
381 381
382 while ((dev = of_get_next_child(busnode, dev)) != NULL) 382 while ((dev = of_get_next_child(busnode, dev)) != NULL)
383 if (device_is_compatible(dev, "smu-sat")) 383 if (of_device_is_compatible(dev, "smu-sat"))
384 wf_sat_create(adapter, dev); 384 wf_sat_create(adapter, dev);
385 return 0; 385 return 0;
386} 386}
diff --git a/drivers/serial/pmac_zilog.c b/drivers/serial/pmac_zilog.c
index cd92a3966b0c..0fa9f6761763 100644
--- a/drivers/serial/pmac_zilog.c
+++ b/drivers/serial/pmac_zilog.c
@@ -1450,7 +1450,7 @@ no_dma:
1450 /* 1450 /*
1451 * Detect port type 1451 * Detect port type
1452 */ 1452 */
1453 if (device_is_compatible(np, "cobalt")) 1453 if (of_device_is_compatible(np, "cobalt"))
1454 uap->flags |= PMACZILOG_FLAG_IS_INTMODEM; 1454 uap->flags |= PMACZILOG_FLAG_IS_INTMODEM;
1455 conn = of_get_property(np, "AAPL,connector", &len); 1455 conn = of_get_property(np, "AAPL,connector", &len);
1456 if (conn && (strcmp(conn, "infrared") == 0)) 1456 if (conn && (strcmp(conn, "infrared") == 0))
diff --git a/drivers/usb/host/ohci-ppc-of.c b/drivers/usb/host/ohci-ppc-of.c
index 08e237c7bc43..c43b66acd4d5 100644
--- a/drivers/usb/host/ohci-ppc-of.c
+++ b/drivers/usb/host/ohci-ppc-of.c
@@ -97,8 +97,8 @@ ohci_hcd_ppc_of_probe(struct of_device *op, const struct of_device_id *match)
97 return -ENODEV; 97 return -ENODEV;
98 98
99 is_bigendian = 99 is_bigendian =
100 device_is_compatible(dn, "ohci-bigendian") || 100 of_device_is_compatible(dn, "ohci-bigendian") ||
101 device_is_compatible(dn, "ohci-be"); 101 of_device_is_compatible(dn, "ohci-be");
102 102
103 dev_dbg(&op->dev, "initializing PPC-OF USB Controller\n"); 103 dev_dbg(&op->dev, "initializing PPC-OF USB Controller\n");
104 104
diff --git a/drivers/video/offb.c b/drivers/video/offb.c
index 3cf603c0127f..885b42836cbb 100644
--- a/drivers/video/offb.c
+++ b/drivers/video/offb.c
@@ -322,8 +322,8 @@ static void __init offb_init_fb(const char *name, const char *full_name,
322 ioremap(base + 0x7ff000, 0x1000) + 0xcc0; 322 ioremap(base + 0x7ff000, 0x1000) + 0xcc0;
323 par->cmap_data = par->cmap_adr + 1; 323 par->cmap_data = par->cmap_adr + 1;
324 par->cmap_type = cmap_m64; 324 par->cmap_type = cmap_m64;
325 } else if (dp && (device_is_compatible(dp, "pci1014,b7") || 325 } else if (dp && (of_device_is_compatible(dp, "pci1014,b7") ||
326 device_is_compatible(dp, "pci1014,21c"))) { 326 of_device_is_compatible(dp, "pci1014,21c"))) {
327 par->cmap_adr = offb_map_reg(dp, 0, 0x6000, 0x1000); 327 par->cmap_adr = offb_map_reg(dp, 0, 0x6000, 0x1000);
328 if (par->cmap_adr) 328 if (par->cmap_adr)
329 par->cmap_type = cmap_gxt2000; 329 par->cmap_type = cmap_gxt2000;