lkml.org 
[lkml]   [2022]   [Sep]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH v1 05/17] pinctrl: cy8c95x0: Fix pin control name to enable more than one
Date
The Cypress GPIO expander is an I²C discrete component. Hence
the platform may contain more than one of a such. Currently
this has limitations in the driver due to same name used for
all chips of a type. Replace this with device instance specific
name.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
drivers/pinctrl/pinctrl-cy8c95x0.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/pinctrl/pinctrl-cy8c95x0.c b/drivers/pinctrl/pinctrl-cy8c95x0.c
index f016c283af57..a05fbf818bf2 100644
--- a/drivers/pinctrl/pinctrl-cy8c95x0.c
+++ b/drivers/pinctrl/pinctrl-cy8c95x0.c
@@ -1188,8 +1188,7 @@ static int cy8c95x0_setup_pinctrl(struct cy8c95x0_pinctrl *chip)
pd->confops = &cy8c95x0_pinconf_ops;
pd->pmxops = &cy8c95x0_pmxops;
pd->npins = chip->gpio_chip.ngpio;
- pd->name = devm_kasprintf(chip->dev, GFP_KERNEL, "pinctrl-%s",
- chip->name);
+ pd->name = dev_name(chip->dev);
pd->pins = cy8c9560_pins;
pd->npins = chip->tpin;
pd->owner = THIS_MODULE;
--
2.35.1
\
 
 \ /
  Last update: 2022-09-02 20:36    [W:0.197 / U:0.084 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site