linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: "Duje Mihanović" <duje.mihanovic@skole.hr>
Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev,
	Linux Memory Management List <linux-mm@kvack.org>,
	Lee Jones <lee@kernel.org>,
	Daniel Thompson <daniel.thompson@linaro.org>
Subject: [linux-next:master 9077/11156] drivers/leds/leds-gpio-register.c:23:32: error: redefinition of 'gpio_led_register_device'
Date: Fri, 1 Mar 2024 10:46:31 +0800	[thread overview]
Message-ID: <202403011013.7cDG1rwi-lkp@intel.com> (raw)

Hi Duje,

First bad commit (maybe != root cause):

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head:   f303a3e2bcfba900efb5aee55236d17030e9f882
commit: 7a28f9cf6b7c8cad760b4d4ee7f53231cd76d8e4 [9077/11156] Revert "leds: Only descend into leds directory when CONFIG_NEW_LEDS is set"
config: mips-bcm47xx_defconfig (https://download.01.org/0day-ci/archive/20240301/202403011013.7cDG1rwi-lkp@intel.com/config)
compiler: clang version 15.0.7 (https://github.com/llvm/llvm-project.git 8dfdcc7b7bf66834a761bd8de445840ef68e4d1a)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240301/202403011013.7cDG1rwi-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/oe-kbuild-all/202403011013.7cDG1rwi-lkp@intel.com/

Note: the linux-next/master HEAD f303a3e2bcfba900efb5aee55236d17030e9f882 builds fine.
      It may have been fixed somewhere.

All errors (new ones prefixed by >>):

   drivers/leds/leds-gpio-register.c:23:25: warning: attribute declaration must precede definition [-Wignored-attributes]
   struct platform_device *__init gpio_led_register_device(
                           ^
   include/linux/init.h:52:17: note: expanded from macro '__init'
   #define __init          __section(".init.text") __cold  __latent_entropy __noinitretpoline
                           ^
   include/linux/compiler_attributes.h:334:56: note: expanded from macro '__section'
   #define __section(section)              __attribute__((__section__(section)))
                                                          ^
   include/linux/leds.h:646:39: note: previous definition is here
   static inline struct platform_device *gpio_led_register_device(
                                         ^
   drivers/leds/leds-gpio-register.c:23:25: warning: attribute declaration must precede definition [-Wignored-attributes]
   struct platform_device *__init gpio_led_register_device(
                           ^
   include/linux/init.h:52:41: note: expanded from macro '__init'
   #define __init          __section(".init.text") __cold  __latent_entropy __noinitretpoline
                                                   ^
   include/linux/compiler_types.h:113:34: note: expanded from macro '__cold'
   #define __cold                          __attribute__((__cold__))
                                                          ^
   include/linux/leds.h:646:39: note: previous definition is here
   static inline struct platform_device *gpio_led_register_device(
                                         ^
>> drivers/leds/leds-gpio-register.c:23:32: error: redefinition of 'gpio_led_register_device'
   struct platform_device *__init gpio_led_register_device(
                                  ^
   include/linux/leds.h:646:39: note: previous definition is here
   static inline struct platform_device *gpio_led_register_device(
                                         ^
   2 warnings and 1 error generated.


vim +/gpio_led_register_device +23 drivers/leds/leds-gpio-register.c

4440673a95e63a Uwe Kleine-König 2011-05-24  10  
4440673a95e63a Uwe Kleine-König 2011-05-24  11  /**
4440673a95e63a Uwe Kleine-König 2011-05-24  12   * gpio_led_register_device - register a gpio-led device
4440673a95e63a Uwe Kleine-König 2011-05-24  13   * @pdata: the platform data used for the new device
c5a87a4ac2bfec Lee Jones        2021-05-28  14   * @id: platform ID
4440673a95e63a Uwe Kleine-König 2011-05-24  15   *
4440673a95e63a Uwe Kleine-König 2011-05-24  16   * Makes a copy of pdata and pdata->leds and registers a new leds-gpio device
4440673a95e63a Uwe Kleine-König 2011-05-24  17   * with the result. This allows to have pdata and pdata-leds in .init.rodata
4440673a95e63a Uwe Kleine-König 2011-05-24  18   * and so saves some bytes compared to a static struct platform_device with
4440673a95e63a Uwe Kleine-König 2011-05-24  19   * static platform data.
4440673a95e63a Uwe Kleine-König 2011-05-24  20   *
4440673a95e63a Uwe Kleine-König 2011-05-24  21   * Returns the registered device or an error pointer.
4440673a95e63a Uwe Kleine-König 2011-05-24  22   */
4440673a95e63a Uwe Kleine-König 2011-05-24 @23  struct platform_device *__init gpio_led_register_device(

:::::: The code at line 23 was first introduced by commit
:::::: 4440673a95e63ad888a41db596edaa0c55d3a332 leds: provide helper to register "leds-gpio" devices

:::::: TO: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
:::::: CC: Linus Torvalds <torvalds@linux-foundation.org>

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


                 reply	other threads:[~2024-03-01  2:46 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=202403011013.7cDG1rwi-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=daniel.thompson@linaro.org \
    --cc=duje.mihanovic@skole.hr \
    --cc=lee@kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=llvm@lists.linux.dev \
    --cc=oe-kbuild-all@lists.linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox