diff options
Diffstat (limited to 'drivers/macintosh')
-rw-r--r-- | drivers/macintosh/smu.c | 4 | ||||
-rw-r--r-- | drivers/macintosh/windfarm_lm75_sensor.c | 2 | ||||
-rw-r--r-- | drivers/macintosh/windfarm_lm87_sensor.c | 2 | ||||
-rw-r--r-- | drivers/macintosh/windfarm_smu_sat.c | 3 | ||||
-rw-r--r-- | drivers/macintosh/windfarm_smu_sensors.c | 3 |
5 files changed, 4 insertions, 10 deletions
diff --git a/drivers/macintosh/smu.c b/drivers/macintosh/smu.c index 96684581a25d..94fb63a7b357 100644 --- a/drivers/macintosh/smu.c +++ b/drivers/macintosh/smu.c @@ -638,7 +638,7 @@ static void smu_expose_childs(struct work_struct *unused) { struct device_node *np; - for (np = NULL; (np = of_get_next_child(smu->of_node, np)) != NULL;) + for_each_child_of_node(smu->of_node, np) if (of_device_is_compatible(np, "smu-sensors")) of_platform_device_create(np, "smu-sensors", &smu->of_dev->dev); @@ -1015,7 +1015,7 @@ static struct smu_sdbp_header *smu_create_sdb_partition(int id) /* Note: Only allowed to return error code in pointers (using ERR_PTR) * when interruptible is 1 */ -const struct smu_sdbp_header *__smu_get_sdb_partition(int id, +static const struct smu_sdbp_header *__smu_get_sdb_partition(int id, unsigned int *size, int interruptible) { char pname[32]; diff --git a/drivers/macintosh/windfarm_lm75_sensor.c b/drivers/macintosh/windfarm_lm75_sensor.c index 1e5fa09845e7..29f48c2028b6 100644 --- a/drivers/macintosh/windfarm_lm75_sensor.c +++ b/drivers/macintosh/windfarm_lm75_sensor.c @@ -152,8 +152,6 @@ static int wf_lm75_remove(struct i2c_client *client) { struct wf_lm75_sensor *lm = i2c_get_clientdata(client); - DBG("wf_lm75: i2c detatch called for %s\n", lm->sens.name); - /* Mark client detached */ lm->i2c = NULL; diff --git a/drivers/macintosh/windfarm_lm87_sensor.c b/drivers/macintosh/windfarm_lm87_sensor.c index d011899c0a8a..9fab0b47cd3d 100644 --- a/drivers/macintosh/windfarm_lm87_sensor.c +++ b/drivers/macintosh/windfarm_lm87_sensor.c @@ -149,8 +149,6 @@ static int wf_lm87_remove(struct i2c_client *client) { struct wf_lm87_sensor *lm = i2c_get_clientdata(client); - DBG("wf_lm87: i2c detatch called for %s\n", lm->sens.name); - /* Mark client detached */ lm->i2c = NULL; diff --git a/drivers/macintosh/windfarm_smu_sat.c b/drivers/macintosh/windfarm_smu_sat.c index cb75dc035616..e46e1153a0b4 100644 --- a/drivers/macintosh/windfarm_smu_sat.c +++ b/drivers/macintosh/windfarm_smu_sat.c @@ -216,8 +216,7 @@ static int wf_sat_probe(struct i2c_client *client, vsens[0] = vsens[1] = -1; isens[0] = isens[1] = -1; - child = NULL; - while ((child = of_get_next_child(dev, child)) != NULL) { + for_each_child_of_node(dev, child) { reg = of_get_property(child, "reg", NULL); loc = of_get_property(child, "location", NULL); if (reg == NULL || loc == NULL) diff --git a/drivers/macintosh/windfarm_smu_sensors.c b/drivers/macintosh/windfarm_smu_sensors.c index 3e6059eaa138..c8706cfb83fd 100644 --- a/drivers/macintosh/windfarm_smu_sensors.c +++ b/drivers/macintosh/windfarm_smu_sensors.c @@ -421,8 +421,7 @@ static int __init smu_sensors_init(void) return -ENODEV; /* Look for sensors subdir */ - for (sensors = NULL; - (sensors = of_get_next_child(smu, sensors)) != NULL;) + for_each_child_of_node(smu, sensors) if (of_node_name_eq(sensors, "sensors")) break; |