Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 328461
b: refs/heads/master
c: 3c05288
h: refs/heads/master
i:
  328459: 26817ac
v: v3
  • Loading branch information
Kuninori Morimoto authored and Linus Walleij committed Sep 12, 2012
1 parent f349199 commit 6d6e7b0
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 20bc4d5d565159eb2b942bf4b7fae86fba94e32c
refs/heads/master: 3c0528810c18213a4d820da74557ba89339cb6ed
6 changes: 3 additions & 3 deletions trunk/drivers/gpio/gpio-pcf857x.c
Original file line number Diff line number Diff line change
Expand Up @@ -285,7 +285,7 @@ static int pcf857x_probe(struct i2c_client *client,
gpio->chip.ngpio = id->driver_data;

/* enable gpio_to_irq() if platform has settings */
if (pdata->irq) {
if (pdata && pdata->irq) {
status = pcf857x_irq_domain_init(gpio, pdata, &client->dev);
if (status < 0) {
dev_err(&client->dev, "irq_domain init failed\n");
Expand Down Expand Up @@ -394,7 +394,7 @@ static int pcf857x_probe(struct i2c_client *client,
dev_dbg(&client->dev, "probe error %d for '%s'\n",
status, client->name);

if (pdata->irq)
if (pdata && pdata->irq)
pcf857x_irq_domain_cleanup(gpio);

kfree(gpio);
Expand All @@ -418,7 +418,7 @@ static int pcf857x_remove(struct i2c_client *client)
}
}

if (pdata->irq)
if (pdata && pdata->irq)
pcf857x_irq_domain_cleanup(gpio);

status = gpiochip_remove(&gpio->chip);
Expand Down

0 comments on commit 6d6e7b0

Please sign in to comment.