summaryrefslogtreecommitdiff
path: root/drivers/gpio/gpio-menz127.c
diff options
context:
space:
mode:
authorAxel Lin <axel.lin@ingics.com>2016-03-09 20:39:57 +0800
committerLinus Walleij <linus.walleij@linaro.org>2016-03-30 10:38:50 +0200
commit86d3f367686852cde028cf6c12cb0e944f28a784 (patch)
tree7585840e3d61937256c47d60dc36d287b2bc3cea /drivers/gpio/gpio-menz127.c
parentf55532a0c0b8bb6148f4e07853b876ef73bc69ca (diff)
downloadlwn-86d3f367686852cde028cf6c12cb0e944f28a784.tar.gz
lwn-86d3f367686852cde028cf6c12cb0e944f28a784.zip
gpio: menz127: Drop *mdev field from struct men_z127_gpio
No need to store *medv in struct men_z127_gpio. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/gpio/gpio-menz127.c')
-rw-r--r--drivers/gpio/gpio-menz127.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/gpio/gpio-menz127.c b/drivers/gpio/gpio-menz127.c
index a68e199d579d..8c1ab8e1974f 100644
--- a/drivers/gpio/gpio-menz127.c
+++ b/drivers/gpio/gpio-menz127.c
@@ -35,7 +35,6 @@
struct men_z127_gpio {
struct gpio_chip gc;
void __iomem *reg_base;
- struct mcb_device *mdev;
struct resource *mem;
spinlock_t lock;
};
@@ -44,7 +43,7 @@ static int men_z127_debounce(struct gpio_chip *gc, unsigned gpio,
unsigned debounce)
{
struct men_z127_gpio *priv = gpiochip_get_data(gc);
- struct device *dev = &priv->mdev->dev;
+ struct device *dev = gc->parent;
unsigned int rnd;
u32 db_en, db_cnt;
@@ -136,7 +135,6 @@ static int men_z127_probe(struct mcb_device *mdev,
goto err_release;
}
- men_z127_gpio->mdev = mdev;
mcb_set_drvdata(mdev, men_z127_gpio);
ret = bgpio_init(&men_z127_gpio->gc, &mdev->dev, 4,