All of lore.kernel.org
 help / color / mirror / Atom feed
* Re: [PATCH v6 2/3] leds: Add driver for MAX8907 LED cell
@ 2026-11-22 15:08 kernel test robot
  0 siblings, 0 replies; 3+ messages in thread
From: kernel test robot @ 2026-11-22 15:08 UTC (permalink / raw)
  To: oe-kbuild; +Cc: lkp

:::::: 
:::::: Manual check reason: "linux-review patch is more than 7 days old, verify it wasn't already superseded"
:::::: 

BCC: lkp@intel.com
CC: llvm@lists.linux.dev
CC: oe-kbuild-all@lists.linux.dev
In-Reply-To: <20261115090520.102216-3-clamor95@gmail.com>
References: <20261115090520.102216-3-clamor95@gmail.com>
TO: Svyatoslav Ryhel <clamor95@gmail.com>
TO: Liam Girdwood <lgirdwood@gmail.com>
TO: Mark Brown <broonie@kernel.org>
TO: Rob Herring <robh@kernel.org>
TO: Krzysztof Kozlowski <krzk@kernel.org>
TO: Conor Dooley <conor+dt@kernel.org>
TO: Lee Jones <lee@kernel.org>
TO: Pavel Machek <pavel@kernel.org>
TO: "Griffin Kroah-Hartman" <griffin@kroah.com>
TO: Svyatoslav Ryhel <clamor95@gmail.com>
CC: linux-kernel@vger.kernel.org
CC: devicetree@vger.kernel.org
CC: linux-leds@vger.kernel.org
CC: mfd@lists.linux.dev

Hi Svyatoslav,

kernel test robot noticed the following build errors:

[auto build test ERROR on linux-review/Svyatoslav-Ryhel/regulator-dt-bindings-maxim-max8907-Convert-to-DT-schema/20261027-134631]

url:    https://github.com/intel-lab-lkp/linux/commits/Svyatoslav-Ryhel/regulator-dt-bindings-maxim-max8907-Document-LED-support/20261115-110518
base:   https://github.com/intel-lab-lkp/linux Svyatoslav-Ryhel/regulator-dt-bindings-maxim-max8907-Convert-to-DT-schema/20261027-134631
patch link:    https://lore.kernel.org/r/20261115090520.102216-3-clamor95%40gmail.com
patch subject: [PATCH v6 2/3] leds: Add driver for MAX8907 LED cell
:::::: branch date: 7 days ago
:::::: commit date: 7 days ago
config: sparc64-allmodconfig (https://download.01.org/0day-ci/archive/20261122/202611222214.32wErpfA-lkp@intel.com/config)
compiler: clang version 20.1.8 (https://github.com/llvm/llvm-project 87f0227cb60147a26a1eeb4fb06e3b505e9c7261)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20261122/202611222214.32wErpfA-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/r/202611222214.32wErpfA-lkp@intel.com/

All errors (new ones prefixed by >>):

>> drivers/leds/leds-max8907.c:68:10: error: call to undeclared function 'devm_kzalloc_obj'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
      68 |         ddata = devm_kzalloc_obj(dev, struct max8907_led_data);
         |                 ^
   drivers/leds/leds-max8907.c:68:10: note: did you mean 'devm_kzalloc'?
   include/linux/device/devres.h:48:21: note: 'devm_kzalloc' declared here
      48 | static inline void *devm_kzalloc(struct device *dev, size_t size, gfp_t gfp)
         |                     ^
>> drivers/leds/leds-max8907.c:68:32: error: expected expression
      68 |         ddata = devm_kzalloc_obj(dev, struct max8907_led_data);
         |                                       ^
   2 errors generated.


vim +/devm_kzalloc_obj +68 drivers/leds/leds-max8907.c

7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  55  
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  56  static int max8907_led_probe(struct platform_device *pdev)
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  57  {
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  58  	struct device *dev = &pdev->dev;
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  59  	struct device_node *led_np __free(device_node) =
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  60  		of_get_available_child_by_name(dev_of_node(dev->parent), "led");
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  61  	struct max8907 *max8907 = dev_get_drvdata(dev->parent);
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  62  	struct led_init_data init_data = { };
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  63  	struct max8907_led_data *ddata;
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  64  
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  65  	if (!led_np)
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  66  		return -ENODEV;
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  67  
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15 @68  	ddata = devm_kzalloc_obj(dev, struct max8907_led_data);
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  69  	if (!ddata)
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  70  		return -ENOMEM;
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  71  
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  72  	ddata->regmap = max8907->regmap_gen;
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  73  
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  74  	init_data.fwnode = of_fwnode_handle(led_np);
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  75  	init_data.devicename = "max8907";
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  76  	init_data.default_label = ":wled";
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  77  
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  78  	ddata->cdev.brightness = LED_OFF;
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  79  	ddata->cdev.flags = LED_CORE_SUSPENDRESUME;
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  80  	ddata->cdev.max_brightness = LED_FULL;
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  81  
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  82  	ddata->cdev.brightness_get = max8907_led_get_brightness;
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  83  	ddata->cdev.brightness_set_blocking = max8907_led_set_brightness;
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  84  
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  85  	return devm_led_classdev_register_ext(dev, &ddata->cdev, &init_data);
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  86  }
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  87  

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

^ permalink raw reply	[flat|nested] 3+ messages in thread
* Re: [PATCH v6 2/3] leds: Add driver for MAX8907 LED cell
@ 2026-11-22 11:18 kernel test robot
  0 siblings, 0 replies; 3+ messages in thread
From: kernel test robot @ 2026-11-22 11:18 UTC (permalink / raw)
  To: oe-kbuild; +Cc: lkp

:::::: 
:::::: Manual check reason: "linux-review patch is more than 7 days old, verify it wasn't already superseded"
:::::: 

BCC: lkp@intel.com
CC: oe-kbuild-all@lists.linux.dev
In-Reply-To: <20261115090520.102216-3-clamor95@gmail.com>
References: <20261115090520.102216-3-clamor95@gmail.com>
TO: Svyatoslav Ryhel <clamor95@gmail.com>
TO: Liam Girdwood <lgirdwood@gmail.com>
TO: Mark Brown <broonie@kernel.org>
TO: Rob Herring <robh@kernel.org>
TO: Krzysztof Kozlowski <krzk@kernel.org>
TO: Conor Dooley <conor+dt@kernel.org>
TO: Lee Jones <lee@kernel.org>
TO: Pavel Machek <pavel@kernel.org>
TO: "Griffin Kroah-Hartman" <griffin@kroah.com>
TO: Svyatoslav Ryhel <clamor95@gmail.com>
CC: linux-kernel@vger.kernel.org
CC: devicetree@vger.kernel.org
CC: linux-leds@vger.kernel.org
CC: mfd@lists.linux.dev

Hi Svyatoslav,

kernel test robot noticed the following build errors:

[auto build test ERROR on linux-review/Svyatoslav-Ryhel/regulator-dt-bindings-maxim-max8907-Convert-to-DT-schema/20261027-134631]

url:    https://github.com/intel-lab-lkp/linux/commits/Svyatoslav-Ryhel/regulator-dt-bindings-maxim-max8907-Document-LED-support/20261115-110518
base:   https://github.com/intel-lab-lkp/linux Svyatoslav-Ryhel/regulator-dt-bindings-maxim-max8907-Convert-to-DT-schema/20261027-134631
patch link:    https://lore.kernel.org/r/20261115090520.102216-3-clamor95%40gmail.com
patch subject: [PATCH v6 2/3] leds: Add driver for MAX8907 LED cell
:::::: branch date: 7 days ago
:::::: commit date: 7 days ago
config: nios2-allmodconfig (https://download.01.org/0day-ci/archive/20261122/202611221902.rkRrBSnk-lkp@intel.com/config)
compiler: nios2-linux-gcc (GCC) 11.5.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20261122/202611221902.rkRrBSnk-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/r/202611221902.rkRrBSnk-lkp@intel.com/

All errors (new ones prefixed by >>):

   drivers/leds/leds-max8907.c: In function 'max8907_led_probe':
>> drivers/leds/leds-max8907.c:68:17: error: implicit declaration of function 'devm_kzalloc_obj'; did you mean 'devm_kzalloc'? [-Werror=implicit-function-declaration]
      68 |         ddata = devm_kzalloc_obj(dev, struct max8907_led_data);
         |                 ^~~~~~~~~~~~~~~~
         |                 devm_kzalloc
>> drivers/leds/leds-max8907.c:68:39: error: expected expression before 'struct'
      68 |         ddata = devm_kzalloc_obj(dev, struct max8907_led_data);
         |                                       ^~~~~~
   cc1: some warnings being treated as errors


vim +68 drivers/leds/leds-max8907.c

7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  55  
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  56  static int max8907_led_probe(struct platform_device *pdev)
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  57  {
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  58  	struct device *dev = &pdev->dev;
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  59  	struct device_node *led_np __free(device_node) =
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  60  		of_get_available_child_by_name(dev_of_node(dev->parent), "led");
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  61  	struct max8907 *max8907 = dev_get_drvdata(dev->parent);
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  62  	struct led_init_data init_data = { };
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  63  	struct max8907_led_data *ddata;
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  64  
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  65  	if (!led_np)
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  66  		return -ENODEV;
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  67  
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15 @68  	ddata = devm_kzalloc_obj(dev, struct max8907_led_data);
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  69  	if (!ddata)
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  70  		return -ENOMEM;
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  71  
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  72  	ddata->regmap = max8907->regmap_gen;
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  73  
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  74  	init_data.fwnode = of_fwnode_handle(led_np);
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  75  	init_data.devicename = "max8907";
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  76  	init_data.default_label = ":wled";
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  77  
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  78  	ddata->cdev.brightness = LED_OFF;
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  79  	ddata->cdev.flags = LED_CORE_SUSPENDRESUME;
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  80  	ddata->cdev.max_brightness = LED_FULL;
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  81  
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  82  	ddata->cdev.brightness_get = max8907_led_get_brightness;
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  83  	ddata->cdev.brightness_set_blocking = max8907_led_set_brightness;
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  84  
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  85  	return devm_led_classdev_register_ext(dev, &ddata->cdev, &init_data);
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  86  }
7b85b7d8f42900 Svyatoslav Ryhel 2026-11-15  87  

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

^ permalink raw reply	[flat|nested] 3+ messages in thread
* [PATCH v6 0/3] leds: Add driver for MAX8907 LED cell
@ 2026-11-15  9:05 Svyatoslav Ryhel
  2026-11-15  9:05 ` [PATCH v6 2/3] " Svyatoslav Ryhel
  0 siblings, 1 reply; 3+ messages in thread
From: Svyatoslav Ryhel @ 2026-11-15  9:05 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Lee Jones, Pavel Machek, Griffin Kroah-Hartman,
	Svyatoslav Ryhel
  Cc: linux-kernel, devicetree, linux-leds, mfd

Add a small driver to control the LED cell provided by the MAX8907 PMIC.
The LED does not require any specific configuration and is folded into the
PMIC's node.

Patch 1 of the series requires this patch:
("regulator: dt-bindings: maxim,max8907: Convert to DT schema")
https://lore.kernel.org/lkml/20261027114634.79706-2-clamor95@gmail.com/

---
Changes in v2:
- rebased so patch is now applicable to linux/next

Changes in v3:
- added check if led is off for get callback
- added dedicated MAX8907_REG_WLED_MODE_ON mask
- switched to devm_led_classdev_register_ext

Changes in v4:
- platform_set_drvdata dropped
- init_data.devicename dropped
- added MODULE_ALIAS

Changes in v5:
- add and document a dedicated node for LED
- split adding led cell to mfd into separate commit
- expand Kconfig description
- populate devicename and default_label of init_data
- unfold platform_driver->driver

Changes in v6:
- converted to devm_kzalloc_obj
---

Svyatoslav Ryhel (3):
  regulator: dt-bindings: maxim,max8907: Document LED support
  leds: Add driver for MAX8907 LED cell
  mfd: max8907: Add LED cell

 .../bindings/regulator/maxim,max8907.yaml     |  4 +
 drivers/leds/Kconfig                          | 10 ++
 drivers/leds/Makefile                         |  1 +
 drivers/leds/leds-max8907.c                   | 99 +++++++++++++++++++
 drivers/mfd/max8907.c                         |  1 +
 include/linux/mfd/max8907.h                   |  2 +-
 6 files changed, 116 insertions(+), 1 deletion(-)
 create mode 100644 drivers/leds/leds-max8907.c

-- 
2.53.0


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2026-11-22 15:09 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-22 15:08 [PATCH v6 2/3] leds: Add driver for MAX8907 LED cell kernel test robot
  -- strict thread matches above, loose matches on Subject: below --
2026-11-22 11:18 kernel test robot
2026-11-15  9:05 [PATCH v6 0/3] " Svyatoslav Ryhel
2026-11-15  9:05 ` [PATCH v6 2/3] " Svyatoslav Ryhel

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.