gpio: constify opaque pointer in gpio_device_find() match function
[linux-block.git] / drivers / gpio / gpiolib-of.c
index 77509aa19900264b009a8e8259e7ac5bd46dbce8..35d717fd393f28e0b35d653ebc97b68254b7ce2b 100644 (file)
@@ -118,9 +118,10 @@ int of_gpio_get_count(struct device *dev, const char *con_id)
        return ret ? ret : -ENOENT;
 }
 
-static int of_gpiochip_match_node_and_xlate(struct gpio_chip *chip, void *data)
+static int of_gpiochip_match_node_and_xlate(struct gpio_chip *chip,
+                                           const void *data)
 {
-       struct of_phandle_args *gpiospec = data;
+       const struct of_phandle_args *gpiospec = data;
 
        return device_match_of_node(&chip->gpiodev->dev, gpiospec->np) &&
                                chip->of_xlate &&
@@ -852,7 +853,7 @@ static void of_gpiochip_remove_hog(struct gpio_chip *chip,
                        gpiochip_free_own_desc(desc);
 }
 
-static int of_gpiochip_match_node(struct gpio_chip *chip, void *data)
+static int of_gpiochip_match_node(struct gpio_chip *chip, const void *data)
 {
        return device_match_of_node(&chip->gpiodev->dev, data);
 }