driver-core: constify data for class_find_device()
[deliverable/linux.git] / drivers / power / power_supply_core.c
index 8a7cfb3cc16694e7fdd4881d9bede20b7aaf4099..5deac432e2ae7b2025bc2e985ec5b6da6dff214d 100644 (file)
@@ -141,7 +141,7 @@ int power_supply_set_battery_charged(struct power_supply *psy)
 }
 EXPORT_SYMBOL_GPL(power_supply_set_battery_charged);
 
-static int power_supply_match_device_by_name(struct device *dev, void *data)
+static int power_supply_match_device_by_name(struct device *dev, const void *data)
 {
        const char *name = data;
        struct power_supply *psy = dev_get_drvdata(dev);
@@ -149,7 +149,7 @@ static int power_supply_match_device_by_name(struct device *dev, void *data)
        return strcmp(psy->name, name) == 0;
 }
 
-struct power_supply *power_supply_get_by_name(char *name)
+struct power_supply *power_supply_get_by_name(const char *name)
 {
        struct device *dev = class_find_device(power_supply_class, NULL, name,
                                        power_supply_match_device_by_name);
This page took 0.023858 seconds and 5 git commands to generate.