]> git.proxmox.com Git - mirror_ubuntu-focal-kernel.git/blobdiff - drivers/gpio/gpio-twl6040.c
gpio: change member .dev to .parent
[mirror_ubuntu-focal-kernel.git] / drivers / gpio / gpio-twl6040.c
index c946e7eef3ee75f7c1d0e9cf183ee8f5e03999a6..2da7c5f70034cd9970e15adec19636d0449771e0 100644 (file)
@@ -36,7 +36,7 @@ static struct gpio_chip twl6040gpo_chip;
 
 static int twl6040gpo_get(struct gpio_chip *chip, unsigned offset)
 {
-       struct twl6040 *twl6040 = dev_get_drvdata(chip->dev->parent);
+       struct twl6040 *twl6040 = dev_get_drvdata(chip->parent->parent);
        int ret = 0;
 
        ret = twl6040_reg_read(twl6040, TWL6040_REG_GPOCTL);
@@ -55,7 +55,7 @@ static int twl6040gpo_direction_out(struct gpio_chip *chip, unsigned offset,
 
 static void twl6040gpo_set(struct gpio_chip *chip, unsigned offset, int value)
 {
-       struct twl6040 *twl6040 = dev_get_drvdata(chip->dev->parent);
+       struct twl6040 *twl6040 = dev_get_drvdata(chip->parent->parent);
        int ret;
        u8 gpoctl;
 
@@ -95,7 +95,7 @@ static int gpo_twl6040_probe(struct platform_device *pdev)
        else
                twl6040gpo_chip.ngpio = 1; /* twl6041 have 1 GPO */
 
-       twl6040gpo_chip.dev = &pdev->dev;
+       twl6040gpo_chip.parent = &pdev->dev;
 #ifdef CONFIG_OF_GPIO
        twl6040gpo_chip.of_node = twl6040_core_dev->of_node;
 #endif