mirror of
https://github.com/torvalds/linux
synced 2024-11-05 18:23:50 +00:00
nomadik-gpio: use dev name if no name is specified
Platforms may choose not to provide an additional name for the GPIO block. Signed-off-by: Rabin Vincent <rabin.vincent@stericsson.com> Signed-off-by: Linus Walleij <linus.walleij@stericsson.com>
This commit is contained in:
parent
ec4a637d35
commit
8d568ae536
1 changed files with 1 additions and 1 deletions
|
@ -672,7 +672,7 @@ static int __devinit nmk_gpio_probe(struct platform_device *dev)
|
|||
|
||||
chip = &nmk_chip->chip;
|
||||
chip->base = pdata->first_gpio;
|
||||
chip->label = pdata->name;
|
||||
chip->label = pdata->name ?: dev_name(&dev->dev);
|
||||
chip->dev = &dev->dev;
|
||||
chip->owner = THIS_MODULE;
|
||||
|
||||
|
|
Loading…
Reference in a new issue