Skip to content

Commit

Permalink
gpio: Add missing spin_lock_init in gpio-pch driver
Browse files Browse the repository at this point in the history
This bug was introduced by commit d568a68
"gpio-pch: add spinlock in suspend/resume processing"
which adds a spinlock to struct pch_gpio but never init the spinlock.

Reported-by: Tomoya MORINAGA <tomoya.rohm@gmail.com>
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
  • Loading branch information
Axel Lin authored and Grant Likely committed Feb 2, 2012
1 parent 876cf5e commit d166370
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/gpio/gpio-pch.c
Original file line number Diff line number Diff line change
Expand Up @@ -392,6 +392,7 @@ static int __devinit pch_gpio_probe(struct pci_dev *pdev,
chip->reg = chip->base;
pci_set_drvdata(pdev, chip);
mutex_init(&chip->lock);
spin_lock_init(&chip->spinlock);
pch_gpio_setup(chip);
ret = gpiochip_add(&chip->gpio);
if (ret) {
Expand Down

0 comments on commit d166370

Please sign in to comment.