mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-11-17 12:14:43 +00:00
gpiolib: remove a redundant check in gpiod_to_chip()
This non-functional change slightly simplifies the implementation of gpiod_to_chip() function. Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
This commit is contained in:
parent
30322bcf82
commit
dd3b9a4408
1 changed files with 1 additions and 1 deletions
|
|
@ -161,7 +161,7 @@ EXPORT_SYMBOL_GPL(desc_to_gpio);
|
||||||
*/
|
*/
|
||||||
struct gpio_chip *gpiod_to_chip(const struct gpio_desc *desc)
|
struct gpio_chip *gpiod_to_chip(const struct gpio_desc *desc)
|
||||||
{
|
{
|
||||||
if (!desc || !desc->gdev || !desc->gdev->chip)
|
if (!desc || !desc->gdev)
|
||||||
return NULL;
|
return NULL;
|
||||||
return desc->gdev->chip;
|
return desc->gdev->chip;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue