gpio: davinci: use irq_data_get_chip_type
authorGeliang Tang <geliangtang@163.com>
Wed, 30 Dec 2015 14:16:38 +0000 (22:16 +0800)
committerLinus Walleij <linus.walleij@linaro.org>
Thu, 28 Jan 2016 14:28:59 +0000 (15:28 +0100)
Use irq_data_get_chip_type() instead of container_of().

Signed-off-by: Geliang Tang <geliangtang@163.com>
Reviewed-by: Grygorii Strashko <grygorii.strashko@ti.com>
Acked-by: Santosh Shilimkar <ssantosh@kernel.org>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
drivers/gpio/gpio-davinci.c

index ec58f4288649b4ee1f0c98f7761439a525ac093e..845edffbcc3fe4cd5d072cd77cc6e2f0c8eb60a9 100644 (file)
@@ -432,8 +432,7 @@ static struct irq_chip *davinci_gpio_get_irq_chip(unsigned int irq)
 {
        static struct irq_chip_type gpio_unbanked;
 
-       gpio_unbanked = *container_of(irq_get_chip(irq),
-                                     struct irq_chip_type, chip);
+       gpio_unbanked = *irq_data_get_chip_type(irq_get_irq_data(irq));
 
        return &gpio_unbanked.chip;
 };