From: Hans de Goede <hdego...@redhat.com>

platform/x86: int3472: Stop setting a supply-name for GPIO regulators

upstream status: queued in platform-drivers-x86/for-next:
https://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86.git/log/?h=for-next

The supply_name field is not mandatory and is supposed to be set to
the name of another regulator when it is known that the regulator being
registered is supplied by that other regulator.

Having a regulator supplying the regulator which is being registered does
not apply to the INT3472 GPIO regulator, stop setting a supply_name.

Reviewed-by: Andy Shevchenko <a...@kernel.org>
Signed-off-by: Hans de Goede <hdego...@redhat.com>
Tested-by: David Heidelberg <da...@ixit.cz>  # Dell Latitude 9440
Reviewed-by: Sakari Ailus <sakari.ai...@linux.intel.com>
Link: https://lore.kernel.org/r/20250417111337.38142-3-hdego...@redhat.com
Reviewed-by: Ilpo Järvinen <ilpo.jarvi...@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvi...@linux.intel.com>

diff --git a/drivers/platform/x86/intel/int3472/clk_and_regulator.c 
b/drivers/platform/x86/intel/int3472/clk_and_regulator.c
index blahblah..blahblah 100644
--- a/drivers/platform/x86/intel/int3472/clk_and_regulator.c
+++ b/drivers/platform/x86/intel/int3472/clk_and_regulator.c
@@ -256,12 +256,9 @@ int skl_int3472_register_regulator(struct 
int3472_discrete_device *int3472,
        snprintf(int3472->regulator.regulator_name,
                 sizeof(int3472->regulator.regulator_name), "%s-regulator",
                 acpi_dev_name(int3472->adev));
-       snprintf(int3472->regulator.supply_name,
-                GPIO_REGULATOR_SUPPLY_NAME_LENGTH, "supply-0");
 
        int3472->regulator.rdesc = INT3472_REGULATOR(
                                                
int3472->regulator.regulator_name,
-                                               int3472->regulator.supply_name,
                                                &int3472_gpio_regulator_ops);
 
        int3472->regulator.gpio = gpio;
diff --git a/drivers/platform/x86/intel/int3472/common.h 
b/drivers/platform/x86/intel/int3472/common.h
index blahblah..blahblah 100644
--- a/drivers/platform/x86/intel/int3472/common.h
+++ b/drivers/platform/x86/intel/int3472/common.h
@@ -27,17 +27,15 @@
 #define INT3472_MAX_SENSOR_GPIOS                               3
 
 #define GPIO_REGULATOR_NAME_LENGTH                             21
-#define GPIO_REGULATOR_SUPPLY_NAME_LENGTH                      9
 #define GPIO_REGULATOR_SUPPLY_MAP_COUNT                                2
 
 #define INT3472_LED_MAX_NAME_LEN                               32
 
 #define CIO2_SENSOR_SSDB_MCLKSPEED_OFFSET                      86
 
-#define INT3472_REGULATOR(_name, _supply, _ops)                        \
+#define INT3472_REGULATOR(_name, _ops)                         \
        (const struct regulator_desc) {                         \
                .name = _name,                                  \
-               .supply_name = _supply,                         \
                .type = REGULATOR_VOLTAGE,                      \
                .ops = _ops,                                    \
                .owner = THIS_MODULE,                           \
@@ -82,7 +80,6 @@ struct int3472_discrete_device {
                /* SUPPLY_MAP_COUNT * 2 to make room for second sensor mappings 
*/
                struct regulator_consumer_supply 
supply_map[GPIO_REGULATOR_SUPPLY_MAP_COUNT * 2];
                char regulator_name[GPIO_REGULATOR_NAME_LENGTH];
-               char supply_name[GPIO_REGULATOR_SUPPLY_NAME_LENGTH];
                struct gpio_desc *gpio;
                struct regulator_dev *rdev;
                struct regulator_desc rdesc;

--
https://gitlab.com/cki-project/kernel-ark/-/merge_requests/3854

-- 
_______________________________________________
kernel mailing list -- kernel@lists.fedoraproject.org
To unsubscribe send an email to kernel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/kernel@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue

Reply via email to