Re: [RESEND PATCH v27 11/15] leds: lp55xx: Add multicolor framework support to lp55xx
Jacek On 6/21/20 3:24 PM, Jacek Anaszewski wrote: Dan, On 6/21/20 4:12 PM, Dan Murphy wrote: Jacek On 6/19/20 5:10 PM, Jacek Anaszewski wrote: Dan, On 6/19/20 6:35 PM, Dan Murphy wrote: Jacek On 6/18/20 6:26 PM, Jacek Anaszewski wrote: On 6/19/20 12:09 AM, Jacek Anaszewski wrote: Dan, On 6/18/20 11:44 PM, Dan Murphy wrote: Jacek On 6/18/20 4:21 PM, Jacek Anaszewski wrote: Dan, On 6/18/20 12:33 AM, Dan Murphy wrote: Jacek On 6/17/20 4:41 PM, Jacek Anaszewski wrote: Dan, On 6/17/20 9:22 PM, Dan Murphy wrote: Pavel/Jacek On 6/17/20 11:28 AM, kernel test robot wrote: Hi Dan, I love your patch! Yet something to improve: [auto build test ERROR on pavel-linux-leds/for-next] [cannot apply to j.anaszewski-leds/for-next] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Dan-Murphy/Multicolor-Framework-v27/20200616-042217 base: git://git.kernel.org/pub/scm/linux/kernel/git/pavel/linux-leds.git for-next config: ia64-randconfig-r015-20200617 (attached as .config) compiler: ia64-linux-gcc (GCC) 9.3.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=ia64 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All errors (new ones prefixed by >>, old ones prefixed by <<): ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `lp55xx_set_mc_brightness': drivers/leds/leds-lp55xx-common.c:146: undefined reference to `led_mc_calc_color_components' ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `devm_led_classdev_multicolor_register': include/linux/led-class-multicolor.h:74: undefined reference to `devm_led_classdev_multicolor_register_ext' vim +146 drivers/leds/leds-lp55xx-common.c 138 139 static int lp55xx_set_mc_brightness(struct led_classdev *cdev, 140 enum led_brightness brightness) 141 { 142 struct led_classdev_mc *mc_dev = lcdev_to_mccdev(cdev); 143 struct lp55xx_led *led = mcled_cdev_to_led(mc_dev); 144 struct lp55xx_device_config *cfg = led->chip->cfg; 145 > 146 led_mc_calc_color_components(&led->mc_cdev, brightness); 147 return cfg->multicolor_brightness_fn(led); 148 Well this was a mess to figure out. The only fix I can figure out here is to remove the depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR from each child device and add select LEDS_CLASS_MULTI_COLOR to the LP55XX_COMMON This way the Multi color framework will inherit the symbol that was set by the COMMON flag which is inherited by majority from the child flags. Did you try this? --- a/drivers/leds/Kconfig +++ b/drivers/leds/Kconfig @@ -398,6 +398,7 @@ config LEDS_LP50XX config LEDS_LP55XX_COMMON tristate "Common Driver for TI/National LP5521/5523/55231/5562/8501" depends on LEDS_LP5521 || LEDS_LP5523 || LEDS_LP5562 || LEDS_LP8501 + depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR depends on OF select FW_LOADER select FW_LOADER_USER_HELPER Yes I did That gave unmet dependencies. WARNING: unmet direct dependencies detected for LEDS_LP55XX_COMMON Depends on [m]: NEW_LEDS [=y] && (LEDS_LP5521 [=n] || LEDS_LP5523 [=m] || LEDS_LP5562 [=y] || LEDS_LP8501 [=y]) && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) && OF [=y] Selected by [y]: - LEDS_LP5562 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] - LEDS_LP8501 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] Selected by [m]: - LEDS_LP5523 [=m] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) When I was testing that yesterday I also had the same warning at some point of testing different Kconfig setups, but with what I showed above it ceased to appear. Now every time I am doing "make oldconfig" the CONFIG_LEDS_LP55XX_COMMON=y entry gets changed to =m with the config from the test bot. That is not what I saw in my testing especially after doing a distclean Could you please give your exact steps after "make distclean" and copying test bot config to the kernel root directory? Also, please share the toolchain you're using for tests. Actually at this stage the toolchain is of lesser relevance. I've tried once more and indeed the problem shows up. It is caused by the driver entries doing "select LEDS_LP55XX_COMMON". Select sets config to "y" so it conflicts with "depends on LEDS_CLA
Re: [RESEND PATCH v27 11/15] leds: lp55xx: Add multicolor framework support to lp55xx
Jacek On 6/22/20 7:42 AM, Jacek Anaszewski wrote: Dan, On 6/21/20 10:24 PM, Jacek Anaszewski wrote: Dan, On 6/21/20 4:12 PM, Dan Murphy wrote: Jacek On 6/19/20 5:10 PM, Jacek Anaszewski wrote: Dan, On 6/19/20 6:35 PM, Dan Murphy wrote: Jacek On 6/18/20 6:26 PM, Jacek Anaszewski wrote: On 6/19/20 12:09 AM, Jacek Anaszewski wrote: Dan, On 6/18/20 11:44 PM, Dan Murphy wrote: Jacek On 6/18/20 4:21 PM, Jacek Anaszewski wrote: Dan, On 6/18/20 12:33 AM, Dan Murphy wrote: Jacek On 6/17/20 4:41 PM, Jacek Anaszewski wrote: Dan, On 6/17/20 9:22 PM, Dan Murphy wrote: Pavel/Jacek On 6/17/20 11:28 AM, kernel test robot wrote: Hi Dan, I love your patch! Yet something to improve: [auto build test ERROR on pavel-linux-leds/for-next] [cannot apply to j.anaszewski-leds/for-next] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Dan-Murphy/Multicolor-Framework-v27/20200616-042217 base: git://git.kernel.org/pub/scm/linux/kernel/git/pavel/linux-leds.git for-next config: ia64-randconfig-r015-20200617 (attached as .config) compiler: ia64-linux-gcc (GCC) 9.3.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=ia64 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All errors (new ones prefixed by >>, old ones prefixed by <<): ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `lp55xx_set_mc_brightness': drivers/leds/leds-lp55xx-common.c:146: undefined reference to `led_mc_calc_color_components' ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `devm_led_classdev_multicolor_register': include/linux/led-class-multicolor.h:74: undefined reference to `devm_led_classdev_multicolor_register_ext' vim +146 drivers/leds/leds-lp55xx-common.c 138 139 static int lp55xx_set_mc_brightness(struct led_classdev *cdev, 140 enum led_brightness brightness) 141 { 142 struct led_classdev_mc *mc_dev = lcdev_to_mccdev(cdev); 143 struct lp55xx_led *led = mcled_cdev_to_led(mc_dev); 144 struct lp55xx_device_config *cfg = led->chip->cfg; 145 > 146 led_mc_calc_color_components(&led->mc_cdev, brightness); 147 return cfg->multicolor_brightness_fn(led); 148 Well this was a mess to figure out. The only fix I can figure out here is to remove the depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR from each child device and add select LEDS_CLASS_MULTI_COLOR to the LP55XX_COMMON This way the Multi color framework will inherit the symbol that was set by the COMMON flag which is inherited by majority from the child flags. Did you try this? --- a/drivers/leds/Kconfig +++ b/drivers/leds/Kconfig @@ -398,6 +398,7 @@ config LEDS_LP50XX config LEDS_LP55XX_COMMON tristate "Common Driver for TI/National LP5521/5523/55231/5562/8501" depends on LEDS_LP5521 || LEDS_LP5523 || LEDS_LP5562 || LEDS_LP8501 + depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR depends on OF select FW_LOADER select FW_LOADER_USER_HELPER Yes I did That gave unmet dependencies. WARNING: unmet direct dependencies detected for LEDS_LP55XX_COMMON Depends on [m]: NEW_LEDS [=y] && (LEDS_LP5521 [=n] || LEDS_LP5523 [=m] || LEDS_LP5562 [=y] || LEDS_LP8501 [=y]) && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) && OF [=y] Selected by [y]: - LEDS_LP5562 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] - LEDS_LP8501 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] Selected by [m]: - LEDS_LP5523 [=m] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) When I was testing that yesterday I also had the same warning at some point of testing different Kconfig setups, but with what I showed above it ceased to appear. Now every time I am doing "make oldconfig" the CONFIG_LEDS_LP55XX_COMMON=y entry gets changed to =m with the config from the test bot. That is not what I saw in my testing especially after doing a distclean Could you please give your exact steps after "make distclean" and copying test bot config to the kernel root directory? Also, please share the toolchain you're using for tests. Actually at this stage the toolchain is of lesser relevance. I've tried once more and indeed the problem shows up. It is caused by the driver entries doing "select LEDS_LP55XX_COMMON". Select sets
Re: [RESEND PATCH v27 11/15] leds: lp55xx: Add multicolor framework support to lp55xx
Dan, On 6/21/20 10:24 PM, Jacek Anaszewski wrote: Dan, On 6/21/20 4:12 PM, Dan Murphy wrote: Jacek On 6/19/20 5:10 PM, Jacek Anaszewski wrote: Dan, On 6/19/20 6:35 PM, Dan Murphy wrote: Jacek On 6/18/20 6:26 PM, Jacek Anaszewski wrote: On 6/19/20 12:09 AM, Jacek Anaszewski wrote: Dan, On 6/18/20 11:44 PM, Dan Murphy wrote: Jacek On 6/18/20 4:21 PM, Jacek Anaszewski wrote: Dan, On 6/18/20 12:33 AM, Dan Murphy wrote: Jacek On 6/17/20 4:41 PM, Jacek Anaszewski wrote: Dan, On 6/17/20 9:22 PM, Dan Murphy wrote: Pavel/Jacek On 6/17/20 11:28 AM, kernel test robot wrote: Hi Dan, I love your patch! Yet something to improve: [auto build test ERROR on pavel-linux-leds/for-next] [cannot apply to j.anaszewski-leds/for-next] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Dan-Murphy/Multicolor-Framework-v27/20200616-042217 base: git://git.kernel.org/pub/scm/linux/kernel/git/pavel/linux-leds.git for-next config: ia64-randconfig-r015-20200617 (attached as .config) compiler: ia64-linux-gcc (GCC) 9.3.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=ia64 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All errors (new ones prefixed by >>, old ones prefixed by <<): ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `lp55xx_set_mc_brightness': drivers/leds/leds-lp55xx-common.c:146: undefined reference to `led_mc_calc_color_components' ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `devm_led_classdev_multicolor_register': include/linux/led-class-multicolor.h:74: undefined reference to `devm_led_classdev_multicolor_register_ext' vim +146 drivers/leds/leds-lp55xx-common.c 138 139 static int lp55xx_set_mc_brightness(struct led_classdev *cdev, 140 enum led_brightness brightness) 141 { 142 struct led_classdev_mc *mc_dev = lcdev_to_mccdev(cdev); 143 struct lp55xx_led *led = mcled_cdev_to_led(mc_dev); 144 struct lp55xx_device_config *cfg = led->chip->cfg; 145 > 146 led_mc_calc_color_components(&led->mc_cdev, brightness); 147 return cfg->multicolor_brightness_fn(led); 148 Well this was a mess to figure out. The only fix I can figure out here is to remove the depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR from each child device and add select LEDS_CLASS_MULTI_COLOR to the LP55XX_COMMON This way the Multi color framework will inherit the symbol that was set by the COMMON flag which is inherited by majority from the child flags. Did you try this? --- a/drivers/leds/Kconfig +++ b/drivers/leds/Kconfig @@ -398,6 +398,7 @@ config LEDS_LP50XX config LEDS_LP55XX_COMMON tristate "Common Driver for TI/National LP5521/5523/55231/5562/8501" depends on LEDS_LP5521 || LEDS_LP5523 || LEDS_LP5562 || LEDS_LP8501 + depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR depends on OF select FW_LOADER select FW_LOADER_USER_HELPER Yes I did That gave unmet dependencies. WARNING: unmet direct dependencies detected for LEDS_LP55XX_COMMON Depends on [m]: NEW_LEDS [=y] && (LEDS_LP5521 [=n] || LEDS_LP5523 [=m] || LEDS_LP5562 [=y] || LEDS_LP8501 [=y]) && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) && OF [=y] Selected by [y]: - LEDS_LP5562 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] - LEDS_LP8501 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] Selected by [m]: - LEDS_LP5523 [=m] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) When I was testing that yesterday I also had the same warning at some point of testing different Kconfig setups, but with what I showed above it ceased to appear. Now every time I am doing "make oldconfig" the CONFIG_LEDS_LP55XX_COMMON=y entry gets changed to =m with the config from the test bot. That is not what I saw in my testing especially after doing a distclean Could you please give your exact steps after "make distclean" and copying test bot config to the kernel root directory? Also, please share the toolchain you're using for tests. Actually at this stage the toolchain is of lesser relevance. I've tried once more and indeed the problem shows up. It is caused by the driver entries doing "select LEDS_LP55XX_COMMON". Select sets config to "y" so it conflicts with "depends on LEDS_CLAS
Re: [RESEND PATCH v27 11/15] leds: lp55xx: Add multicolor framework support to lp55xx
Dan, On 6/21/20 4:12 PM, Dan Murphy wrote: Jacek On 6/19/20 5:10 PM, Jacek Anaszewski wrote: Dan, On 6/19/20 6:35 PM, Dan Murphy wrote: Jacek On 6/18/20 6:26 PM, Jacek Anaszewski wrote: On 6/19/20 12:09 AM, Jacek Anaszewski wrote: Dan, On 6/18/20 11:44 PM, Dan Murphy wrote: Jacek On 6/18/20 4:21 PM, Jacek Anaszewski wrote: Dan, On 6/18/20 12:33 AM, Dan Murphy wrote: Jacek On 6/17/20 4:41 PM, Jacek Anaszewski wrote: Dan, On 6/17/20 9:22 PM, Dan Murphy wrote: Pavel/Jacek On 6/17/20 11:28 AM, kernel test robot wrote: Hi Dan, I love your patch! Yet something to improve: [auto build test ERROR on pavel-linux-leds/for-next] [cannot apply to j.anaszewski-leds/for-next] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Dan-Murphy/Multicolor-Framework-v27/20200616-042217 base: git://git.kernel.org/pub/scm/linux/kernel/git/pavel/linux-leds.git for-next config: ia64-randconfig-r015-20200617 (attached as .config) compiler: ia64-linux-gcc (GCC) 9.3.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=ia64 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All errors (new ones prefixed by >>, old ones prefixed by <<): ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `lp55xx_set_mc_brightness': drivers/leds/leds-lp55xx-common.c:146: undefined reference to `led_mc_calc_color_components' ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `devm_led_classdev_multicolor_register': include/linux/led-class-multicolor.h:74: undefined reference to `devm_led_classdev_multicolor_register_ext' vim +146 drivers/leds/leds-lp55xx-common.c 138 139 static int lp55xx_set_mc_brightness(struct led_classdev *cdev, 140 enum led_brightness brightness) 141 { 142 struct led_classdev_mc *mc_dev = lcdev_to_mccdev(cdev); 143 struct lp55xx_led *led = mcled_cdev_to_led(mc_dev); 144 struct lp55xx_device_config *cfg = led->chip->cfg; 145 > 146 led_mc_calc_color_components(&led->mc_cdev, brightness); 147 return cfg->multicolor_brightness_fn(led); 148 Well this was a mess to figure out. The only fix I can figure out here is to remove the depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR from each child device and add select LEDS_CLASS_MULTI_COLOR to the LP55XX_COMMON This way the Multi color framework will inherit the symbol that was set by the COMMON flag which is inherited by majority from the child flags. Did you try this? --- a/drivers/leds/Kconfig +++ b/drivers/leds/Kconfig @@ -398,6 +398,7 @@ config LEDS_LP50XX config LEDS_LP55XX_COMMON tristate "Common Driver for TI/National LP5521/5523/55231/5562/8501" depends on LEDS_LP5521 || LEDS_LP5523 || LEDS_LP5562 || LEDS_LP8501 + depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR depends on OF select FW_LOADER select FW_LOADER_USER_HELPER Yes I did That gave unmet dependencies. WARNING: unmet direct dependencies detected for LEDS_LP55XX_COMMON Depends on [m]: NEW_LEDS [=y] && (LEDS_LP5521 [=n] || LEDS_LP5523 [=m] || LEDS_LP5562 [=y] || LEDS_LP8501 [=y]) && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) && OF [=y] Selected by [y]: - LEDS_LP5562 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] - LEDS_LP8501 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] Selected by [m]: - LEDS_LP5523 [=m] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) When I was testing that yesterday I also had the same warning at some point of testing different Kconfig setups, but with what I showed above it ceased to appear. Now every time I am doing "make oldconfig" the CONFIG_LEDS_LP55XX_COMMON=y entry gets changed to =m with the config from the test bot. That is not what I saw in my testing especially after doing a distclean Could you please give your exact steps after "make distclean" and copying test bot config to the kernel root directory? Also, please share the toolchain you're using for tests. Actually at this stage the toolchain is of lesser relevance. I've tried once more and indeed the problem shows up. It is caused by the driver entries doing "select LEDS_LP55XX_COMMON". Select sets config to "y" so it conflicts with "depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR" in the "config L
Re: [RESEND PATCH v27 11/15] leds: lp55xx: Add multicolor framework support to lp55xx
Jacek On 6/19/20 5:10 PM, Jacek Anaszewski wrote: Dan, On 6/19/20 6:35 PM, Dan Murphy wrote: Jacek On 6/18/20 6:26 PM, Jacek Anaszewski wrote: On 6/19/20 12:09 AM, Jacek Anaszewski wrote: Dan, On 6/18/20 11:44 PM, Dan Murphy wrote: Jacek On 6/18/20 4:21 PM, Jacek Anaszewski wrote: Dan, On 6/18/20 12:33 AM, Dan Murphy wrote: Jacek On 6/17/20 4:41 PM, Jacek Anaszewski wrote: Dan, On 6/17/20 9:22 PM, Dan Murphy wrote: Pavel/Jacek On 6/17/20 11:28 AM, kernel test robot wrote: Hi Dan, I love your patch! Yet something to improve: [auto build test ERROR on pavel-linux-leds/for-next] [cannot apply to j.anaszewski-leds/for-next] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Dan-Murphy/Multicolor-Framework-v27/20200616-042217 base: git://git.kernel.org/pub/scm/linux/kernel/git/pavel/linux-leds.git for-next config: ia64-randconfig-r015-20200617 (attached as .config) compiler: ia64-linux-gcc (GCC) 9.3.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=ia64 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All errors (new ones prefixed by >>, old ones prefixed by <<): ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `lp55xx_set_mc_brightness': drivers/leds/leds-lp55xx-common.c:146: undefined reference to `led_mc_calc_color_components' ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `devm_led_classdev_multicolor_register': include/linux/led-class-multicolor.h:74: undefined reference to `devm_led_classdev_multicolor_register_ext' vim +146 drivers/leds/leds-lp55xx-common.c 138 139 static int lp55xx_set_mc_brightness(struct led_classdev *cdev, 140 enum led_brightness brightness) 141 { 142 struct led_classdev_mc *mc_dev = lcdev_to_mccdev(cdev); 143 struct lp55xx_led *led = mcled_cdev_to_led(mc_dev); 144 struct lp55xx_device_config *cfg = led->chip->cfg; 145 > 146 led_mc_calc_color_components(&led->mc_cdev, brightness); 147 return cfg->multicolor_brightness_fn(led); 148 Well this was a mess to figure out. The only fix I can figure out here is to remove the depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR from each child device and add select LEDS_CLASS_MULTI_COLOR to the LP55XX_COMMON This way the Multi color framework will inherit the symbol that was set by the COMMON flag which is inherited by majority from the child flags. Did you try this? --- a/drivers/leds/Kconfig +++ b/drivers/leds/Kconfig @@ -398,6 +398,7 @@ config LEDS_LP50XX config LEDS_LP55XX_COMMON tristate "Common Driver for TI/National LP5521/5523/55231/5562/8501" depends on LEDS_LP5521 || LEDS_LP5523 || LEDS_LP5562 || LEDS_LP8501 + depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR depends on OF select FW_LOADER select FW_LOADER_USER_HELPER Yes I did That gave unmet dependencies. WARNING: unmet direct dependencies detected for LEDS_LP55XX_COMMON Depends on [m]: NEW_LEDS [=y] && (LEDS_LP5521 [=n] || LEDS_LP5523 [=m] || LEDS_LP5562 [=y] || LEDS_LP8501 [=y]) && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) && OF [=y] Selected by [y]: - LEDS_LP5562 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] - LEDS_LP8501 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] Selected by [m]: - LEDS_LP5523 [=m] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) When I was testing that yesterday I also had the same warning at some point of testing different Kconfig setups, but with what I showed above it ceased to appear. Now every time I am doing "make oldconfig" the CONFIG_LEDS_LP55XX_COMMON=y entry gets changed to =m with the config from the test bot. That is not what I saw in my testing especially after doing a distclean Could you please give your exact steps after "make distclean" and copying test bot config to the kernel root directory? Also, please share the toolchain you're using for tests. Actually at this stage the toolchain is of lesser relevance. I've tried once more and indeed the problem shows up. It is caused by the driver entries doing "select LEDS_LP55XX_COMMON". Select sets config to "y" so it conflicts with "depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR" in the "config LEDS_LP55XX_COMMON". Your proposed fix will b
Re: [RESEND PATCH v27 11/15] leds: lp55xx: Add multicolor framework support to lp55xx
Dan, On 6/19/20 6:35 PM, Dan Murphy wrote: Jacek On 6/18/20 6:26 PM, Jacek Anaszewski wrote: On 6/19/20 12:09 AM, Jacek Anaszewski wrote: Dan, On 6/18/20 11:44 PM, Dan Murphy wrote: Jacek On 6/18/20 4:21 PM, Jacek Anaszewski wrote: Dan, On 6/18/20 12:33 AM, Dan Murphy wrote: Jacek On 6/17/20 4:41 PM, Jacek Anaszewski wrote: Dan, On 6/17/20 9:22 PM, Dan Murphy wrote: Pavel/Jacek On 6/17/20 11:28 AM, kernel test robot wrote: Hi Dan, I love your patch! Yet something to improve: [auto build test ERROR on pavel-linux-leds/for-next] [cannot apply to j.anaszewski-leds/for-next] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Dan-Murphy/Multicolor-Framework-v27/20200616-042217 base: git://git.kernel.org/pub/scm/linux/kernel/git/pavel/linux-leds.git for-next config: ia64-randconfig-r015-20200617 (attached as .config) compiler: ia64-linux-gcc (GCC) 9.3.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=ia64 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All errors (new ones prefixed by >>, old ones prefixed by <<): ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `lp55xx_set_mc_brightness': drivers/leds/leds-lp55xx-common.c:146: undefined reference to `led_mc_calc_color_components' ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `devm_led_classdev_multicolor_register': include/linux/led-class-multicolor.h:74: undefined reference to `devm_led_classdev_multicolor_register_ext' vim +146 drivers/leds/leds-lp55xx-common.c 138 139 static int lp55xx_set_mc_brightness(struct led_classdev *cdev, 140 enum led_brightness brightness) 141 { 142 struct led_classdev_mc *mc_dev = lcdev_to_mccdev(cdev); 143 struct lp55xx_led *led = mcled_cdev_to_led(mc_dev); 144 struct lp55xx_device_config *cfg = led->chip->cfg; 145 > 146 led_mc_calc_color_components(&led->mc_cdev, brightness); 147 return cfg->multicolor_brightness_fn(led); 148 Well this was a mess to figure out. The only fix I can figure out here is to remove the depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR from each child device and add select LEDS_CLASS_MULTI_COLOR to the LP55XX_COMMON This way the Multi color framework will inherit the symbol that was set by the COMMON flag which is inherited by majority from the child flags. Did you try this? --- a/drivers/leds/Kconfig +++ b/drivers/leds/Kconfig @@ -398,6 +398,7 @@ config LEDS_LP50XX config LEDS_LP55XX_COMMON tristate "Common Driver for TI/National LP5521/5523/55231/5562/8501" depends on LEDS_LP5521 || LEDS_LP5523 || LEDS_LP5562 || LEDS_LP8501 + depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR depends on OF select FW_LOADER select FW_LOADER_USER_HELPER Yes I did That gave unmet dependencies. WARNING: unmet direct dependencies detected for LEDS_LP55XX_COMMON Depends on [m]: NEW_LEDS [=y] && (LEDS_LP5521 [=n] || LEDS_LP5523 [=m] || LEDS_LP5562 [=y] || LEDS_LP8501 [=y]) && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) && OF [=y] Selected by [y]: - LEDS_LP5562 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] - LEDS_LP8501 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] Selected by [m]: - LEDS_LP5523 [=m] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) When I was testing that yesterday I also had the same warning at some point of testing different Kconfig setups, but with what I showed above it ceased to appear. Now every time I am doing "make oldconfig" the CONFIG_LEDS_LP55XX_COMMON=y entry gets changed to =m with the config from the test bot. That is not what I saw in my testing especially after doing a distclean Could you please give your exact steps after "make distclean" and copying test bot config to the kernel root directory? Also, please share the toolchain you're using for tests. Actually at this stage the toolchain is of lesser relevance. I've tried once more and indeed the problem shows up. It is caused by the driver entries doing "select LEDS_LP55XX_COMMON". Select sets config to "y" so it conflicts with "depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR" in the "config LEDS_LP55XX_COMMON". Your proposed fix will block the possibility of building LED_CLASS_MULTI_COLOR as a
Re: [RESEND PATCH v27 11/15] leds: lp55xx: Add multicolor framework support to lp55xx
Jacek On 6/18/20 6:26 PM, Jacek Anaszewski wrote: On 6/19/20 12:09 AM, Jacek Anaszewski wrote: Dan, On 6/18/20 11:44 PM, Dan Murphy wrote: Jacek On 6/18/20 4:21 PM, Jacek Anaszewski wrote: Dan, On 6/18/20 12:33 AM, Dan Murphy wrote: Jacek On 6/17/20 4:41 PM, Jacek Anaszewski wrote: Dan, On 6/17/20 9:22 PM, Dan Murphy wrote: Pavel/Jacek On 6/17/20 11:28 AM, kernel test robot wrote: Hi Dan, I love your patch! Yet something to improve: [auto build test ERROR on pavel-linux-leds/for-next] [cannot apply to j.anaszewski-leds/for-next] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Dan-Murphy/Multicolor-Framework-v27/20200616-042217 base: git://git.kernel.org/pub/scm/linux/kernel/git/pavel/linux-leds.git for-next config: ia64-randconfig-r015-20200617 (attached as .config) compiler: ia64-linux-gcc (GCC) 9.3.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=ia64 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All errors (new ones prefixed by >>, old ones prefixed by <<): ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `lp55xx_set_mc_brightness': drivers/leds/leds-lp55xx-common.c:146: undefined reference to `led_mc_calc_color_components' ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `devm_led_classdev_multicolor_register': include/linux/led-class-multicolor.h:74: undefined reference to `devm_led_classdev_multicolor_register_ext' vim +146 drivers/leds/leds-lp55xx-common.c 138 139 static int lp55xx_set_mc_brightness(struct led_classdev *cdev, 140 enum led_brightness brightness) 141 { 142 struct led_classdev_mc *mc_dev = lcdev_to_mccdev(cdev); 143 struct lp55xx_led *led = mcled_cdev_to_led(mc_dev); 144 struct lp55xx_device_config *cfg = led->chip->cfg; 145 > 146 led_mc_calc_color_components(&led->mc_cdev, brightness); 147 return cfg->multicolor_brightness_fn(led); 148 Well this was a mess to figure out. The only fix I can figure out here is to remove the depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR from each child device and add select LEDS_CLASS_MULTI_COLOR to the LP55XX_COMMON This way the Multi color framework will inherit the symbol that was set by the COMMON flag which is inherited by majority from the child flags. Did you try this? --- a/drivers/leds/Kconfig +++ b/drivers/leds/Kconfig @@ -398,6 +398,7 @@ config LEDS_LP50XX config LEDS_LP55XX_COMMON tristate "Common Driver for TI/National LP5521/5523/55231/5562/8501" depends on LEDS_LP5521 || LEDS_LP5523 || LEDS_LP5562 || LEDS_LP8501 + depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR depends on OF select FW_LOADER select FW_LOADER_USER_HELPER Yes I did That gave unmet dependencies. WARNING: unmet direct dependencies detected for LEDS_LP55XX_COMMON Depends on [m]: NEW_LEDS [=y] && (LEDS_LP5521 [=n] || LEDS_LP5523 [=m] || LEDS_LP5562 [=y] || LEDS_LP8501 [=y]) && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) && OF [=y] Selected by [y]: - LEDS_LP5562 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] - LEDS_LP8501 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] Selected by [m]: - LEDS_LP5523 [=m] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) When I was testing that yesterday I also had the same warning at some point of testing different Kconfig setups, but with what I showed above it ceased to appear. Now every time I am doing "make oldconfig" the CONFIG_LEDS_LP55XX_COMMON=y entry gets changed to =m with the config from the test bot. That is not what I saw in my testing especially after doing a distclean Could you please give your exact steps after "make distclean" and copying test bot config to the kernel root directory? Also, please share the toolchain you're using for tests. Actually at this stage the toolchain is of lesser relevance. I've tried once more and indeed the problem shows up. It is caused by the driver entries doing "select LEDS_LP55XX_COMMON". Select sets config to "y" so it conflicts with "depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR" in the "config LEDS_LP55XX_COMMON". Your proposed fix will block the possibility of building LED_CLASS_MULTI_COLOR as a module when LP55XX drivers are enabled so thi
Re: [RESEND PATCH v27 11/15] leds: lp55xx: Add multicolor framework support to lp55xx
Jacek On 6/18/20 6:26 PM, Jacek Anaszewski wrote: On 6/19/20 12:09 AM, Jacek Anaszewski wrote: Dan, On 6/18/20 11:44 PM, Dan Murphy wrote: Jacek On 6/18/20 4:21 PM, Jacek Anaszewski wrote: Dan, On 6/18/20 12:33 AM, Dan Murphy wrote: Jacek On 6/17/20 4:41 PM, Jacek Anaszewski wrote: Dan, On 6/17/20 9:22 PM, Dan Murphy wrote: Pavel/Jacek On 6/17/20 11:28 AM, kernel test robot wrote: Hi Dan, I love your patch! Yet something to improve: [auto build test ERROR on pavel-linux-leds/for-next] [cannot apply to j.anaszewski-leds/for-next] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Dan-Murphy/Multicolor-Framework-v27/20200616-042217 base: git://git.kernel.org/pub/scm/linux/kernel/git/pavel/linux-leds.git for-next config: ia64-randconfig-r015-20200617 (attached as .config) compiler: ia64-linux-gcc (GCC) 9.3.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=ia64 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All errors (new ones prefixed by >>, old ones prefixed by <<): ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `lp55xx_set_mc_brightness': drivers/leds/leds-lp55xx-common.c:146: undefined reference to `led_mc_calc_color_components' ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `devm_led_classdev_multicolor_register': include/linux/led-class-multicolor.h:74: undefined reference to `devm_led_classdev_multicolor_register_ext' vim +146 drivers/leds/leds-lp55xx-common.c 138 139 static int lp55xx_set_mc_brightness(struct led_classdev *cdev, 140 enum led_brightness brightness) 141 { 142 struct led_classdev_mc *mc_dev = lcdev_to_mccdev(cdev); 143 struct lp55xx_led *led = mcled_cdev_to_led(mc_dev); 144 struct lp55xx_device_config *cfg = led->chip->cfg; 145 > 146 led_mc_calc_color_components(&led->mc_cdev, brightness); 147 return cfg->multicolor_brightness_fn(led); 148 Well this was a mess to figure out. The only fix I can figure out here is to remove the depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR from each child device and add select LEDS_CLASS_MULTI_COLOR to the LP55XX_COMMON This way the Multi color framework will inherit the symbol that was set by the COMMON flag which is inherited by majority from the child flags. Did you try this? --- a/drivers/leds/Kconfig +++ b/drivers/leds/Kconfig @@ -398,6 +398,7 @@ config LEDS_LP50XX config LEDS_LP55XX_COMMON tristate "Common Driver for TI/National LP5521/5523/55231/5562/8501" depends on LEDS_LP5521 || LEDS_LP5523 || LEDS_LP5562 || LEDS_LP8501 + depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR depends on OF select FW_LOADER select FW_LOADER_USER_HELPER Yes I did That gave unmet dependencies. WARNING: unmet direct dependencies detected for LEDS_LP55XX_COMMON Depends on [m]: NEW_LEDS [=y] && (LEDS_LP5521 [=n] || LEDS_LP5523 [=m] || LEDS_LP5562 [=y] || LEDS_LP8501 [=y]) && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) && OF [=y] Selected by [y]: - LEDS_LP5562 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] - LEDS_LP8501 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] Selected by [m]: - LEDS_LP5523 [=m] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) When I was testing that yesterday I also had the same warning at some point of testing different Kconfig setups, but with what I showed above it ceased to appear. Now every time I am doing "make oldconfig" the CONFIG_LEDS_LP55XX_COMMON=y entry gets changed to =m with the config from the test bot. That is not what I saw in my testing especially after doing a distclean Could you please give your exact steps after "make distclean" and copying test bot config to the kernel root directory? Also, please share the toolchain you're using for tests. Actually at this stage the toolchain is of lesser relevance. I've tried once more and indeed the problem shows up. It is caused by the driver entries doing "select LEDS_LP55XX_COMMON". Select sets config to "y" so it conflicts with "depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR" in the "config LEDS_LP55XX_COMMON". Your proposed fix will block the possibility of building LED_CLASS_MULTI_COLOR as a module when LP55XX drivers are enabled so thi
Re: [RESEND PATCH v27 11/15] leds: lp55xx: Add multicolor framework support to lp55xx
On 6/19/20 12:09 AM, Jacek Anaszewski wrote: Dan, On 6/18/20 11:44 PM, Dan Murphy wrote: Jacek On 6/18/20 4:21 PM, Jacek Anaszewski wrote: Dan, On 6/18/20 12:33 AM, Dan Murphy wrote: Jacek On 6/17/20 4:41 PM, Jacek Anaszewski wrote: Dan, On 6/17/20 9:22 PM, Dan Murphy wrote: Pavel/Jacek On 6/17/20 11:28 AM, kernel test robot wrote: Hi Dan, I love your patch! Yet something to improve: [auto build test ERROR on pavel-linux-leds/for-next] [cannot apply to j.anaszewski-leds/for-next] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Dan-Murphy/Multicolor-Framework-v27/20200616-042217 base: git://git.kernel.org/pub/scm/linux/kernel/git/pavel/linux-leds.git for-next config: ia64-randconfig-r015-20200617 (attached as .config) compiler: ia64-linux-gcc (GCC) 9.3.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=ia64 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All errors (new ones prefixed by >>, old ones prefixed by <<): ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `lp55xx_set_mc_brightness': drivers/leds/leds-lp55xx-common.c:146: undefined reference to `led_mc_calc_color_components' ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `devm_led_classdev_multicolor_register': include/linux/led-class-multicolor.h:74: undefined reference to `devm_led_classdev_multicolor_register_ext' vim +146 drivers/leds/leds-lp55xx-common.c 138 139 static int lp55xx_set_mc_brightness(struct led_classdev *cdev, 140 enum led_brightness brightness) 141 { 142 struct led_classdev_mc *mc_dev = lcdev_to_mccdev(cdev); 143 struct lp55xx_led *led = mcled_cdev_to_led(mc_dev); 144 struct lp55xx_device_config *cfg = led->chip->cfg; 145 > 146 led_mc_calc_color_components(&led->mc_cdev, brightness); 147 return cfg->multicolor_brightness_fn(led); 148 Well this was a mess to figure out. The only fix I can figure out here is to remove the depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR from each child device and add select LEDS_CLASS_MULTI_COLOR to the LP55XX_COMMON This way the Multi color framework will inherit the symbol that was set by the COMMON flag which is inherited by majority from the child flags. Did you try this? --- a/drivers/leds/Kconfig +++ b/drivers/leds/Kconfig @@ -398,6 +398,7 @@ config LEDS_LP50XX config LEDS_LP55XX_COMMON tristate "Common Driver for TI/National LP5521/5523/55231/5562/8501" depends on LEDS_LP5521 || LEDS_LP5523 || LEDS_LP5562 || LEDS_LP8501 + depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR depends on OF select FW_LOADER select FW_LOADER_USER_HELPER Yes I did That gave unmet dependencies. WARNING: unmet direct dependencies detected for LEDS_LP55XX_COMMON Depends on [m]: NEW_LEDS [=y] && (LEDS_LP5521 [=n] || LEDS_LP5523 [=m] || LEDS_LP5562 [=y] || LEDS_LP8501 [=y]) && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) && OF [=y] Selected by [y]: - LEDS_LP5562 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] - LEDS_LP8501 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] Selected by [m]: - LEDS_LP5523 [=m] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) When I was testing that yesterday I also had the same warning at some point of testing different Kconfig setups, but with what I showed above it ceased to appear. Now every time I am doing "make oldconfig" the CONFIG_LEDS_LP55XX_COMMON=y entry gets changed to =m with the config from the test bot. That is not what I saw in my testing especially after doing a distclean Could you please give your exact steps after "make distclean" and copying test bot config to the kernel root directory? Also, please share the toolchain you're using for tests. Actually at this stage the toolchain is of lesser relevance. I've tried once more and indeed the problem shows up. It is caused by the driver entries doing "select LEDS_LP55XX_COMMON". Select sets config to "y" so it conflicts with "depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR" in the "config LEDS_LP55XX_COMMON". Your proposed fix will block the possibility of building LED_CLASS_MULTI_COLOR as a module when LP55XX drivers are enabled so this is also not an option. Solving this riddle will re
Re: [RESEND PATCH v27 11/15] leds: lp55xx: Add multicolor framework support to lp55xx
Dan, On 6/18/20 11:44 PM, Dan Murphy wrote: Jacek On 6/18/20 4:21 PM, Jacek Anaszewski wrote: Dan, On 6/18/20 12:33 AM, Dan Murphy wrote: Jacek On 6/17/20 4:41 PM, Jacek Anaszewski wrote: Dan, On 6/17/20 9:22 PM, Dan Murphy wrote: Pavel/Jacek On 6/17/20 11:28 AM, kernel test robot wrote: Hi Dan, I love your patch! Yet something to improve: [auto build test ERROR on pavel-linux-leds/for-next] [cannot apply to j.anaszewski-leds/for-next] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Dan-Murphy/Multicolor-Framework-v27/20200616-042217 base: git://git.kernel.org/pub/scm/linux/kernel/git/pavel/linux-leds.git for-next config: ia64-randconfig-r015-20200617 (attached as .config) compiler: ia64-linux-gcc (GCC) 9.3.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=ia64 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All errors (new ones prefixed by >>, old ones prefixed by <<): ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `lp55xx_set_mc_brightness': drivers/leds/leds-lp55xx-common.c:146: undefined reference to `led_mc_calc_color_components' ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `devm_led_classdev_multicolor_register': include/linux/led-class-multicolor.h:74: undefined reference to `devm_led_classdev_multicolor_register_ext' vim +146 drivers/leds/leds-lp55xx-common.c 138 139 static int lp55xx_set_mc_brightness(struct led_classdev *cdev, 140 enum led_brightness brightness) 141 { 142 struct led_classdev_mc *mc_dev = lcdev_to_mccdev(cdev); 143 struct lp55xx_led *led = mcled_cdev_to_led(mc_dev); 144 struct lp55xx_device_config *cfg = led->chip->cfg; 145 > 146 led_mc_calc_color_components(&led->mc_cdev, brightness); 147 return cfg->multicolor_brightness_fn(led); 148 Well this was a mess to figure out. The only fix I can figure out here is to remove the depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR from each child device and add select LEDS_CLASS_MULTI_COLOR to the LP55XX_COMMON This way the Multi color framework will inherit the symbol that was set by the COMMON flag which is inherited by majority from the child flags. Did you try this? --- a/drivers/leds/Kconfig +++ b/drivers/leds/Kconfig @@ -398,6 +398,7 @@ config LEDS_LP50XX config LEDS_LP55XX_COMMON tristate "Common Driver for TI/National LP5521/5523/55231/5562/8501" depends on LEDS_LP5521 || LEDS_LP5523 || LEDS_LP5562 || LEDS_LP8501 + depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR depends on OF select FW_LOADER select FW_LOADER_USER_HELPER Yes I did That gave unmet dependencies. WARNING: unmet direct dependencies detected for LEDS_LP55XX_COMMON Depends on [m]: NEW_LEDS [=y] && (LEDS_LP5521 [=n] || LEDS_LP5523 [=m] || LEDS_LP5562 [=y] || LEDS_LP8501 [=y]) && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) && OF [=y] Selected by [y]: - LEDS_LP5562 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] - LEDS_LP8501 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] Selected by [m]: - LEDS_LP5523 [=m] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) When I was testing that yesterday I also had the same warning at some point of testing different Kconfig setups, but with what I showed above it ceased to appear. Now every time I am doing "make oldconfig" the CONFIG_LEDS_LP55XX_COMMON=y entry gets changed to =m with the config from the test bot. That is not what I saw in my testing especially after doing a distclean Could you please give your exact steps after "make distclean" and copying test bot config to the kernel root directory? Also, please share the toolchain you're using for tests. -- Best regards, Jacek Anaszewski
Re: [RESEND PATCH v27 11/15] leds: lp55xx: Add multicolor framework support to lp55xx
Jacek On 6/18/20 4:21 PM, Jacek Anaszewski wrote: Dan, On 6/18/20 12:33 AM, Dan Murphy wrote: Jacek On 6/17/20 4:41 PM, Jacek Anaszewski wrote: Dan, On 6/17/20 9:22 PM, Dan Murphy wrote: Pavel/Jacek On 6/17/20 11:28 AM, kernel test robot wrote: Hi Dan, I love your patch! Yet something to improve: [auto build test ERROR on pavel-linux-leds/for-next] [cannot apply to j.anaszewski-leds/for-next] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Dan-Murphy/Multicolor-Framework-v27/20200616-042217 base: git://git.kernel.org/pub/scm/linux/kernel/git/pavel/linux-leds.git for-next config: ia64-randconfig-r015-20200617 (attached as .config) compiler: ia64-linux-gcc (GCC) 9.3.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=ia64 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All errors (new ones prefixed by >>, old ones prefixed by <<): ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `lp55xx_set_mc_brightness': drivers/leds/leds-lp55xx-common.c:146: undefined reference to `led_mc_calc_color_components' ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `devm_led_classdev_multicolor_register': include/linux/led-class-multicolor.h:74: undefined reference to `devm_led_classdev_multicolor_register_ext' vim +146 drivers/leds/leds-lp55xx-common.c 138 139 static int lp55xx_set_mc_brightness(struct led_classdev *cdev, 140 enum led_brightness brightness) 141 { 142 struct led_classdev_mc *mc_dev = lcdev_to_mccdev(cdev); 143 struct lp55xx_led *led = mcled_cdev_to_led(mc_dev); 144 struct lp55xx_device_config *cfg = led->chip->cfg; 145 > 146 led_mc_calc_color_components(&led->mc_cdev, brightness); 147 return cfg->multicolor_brightness_fn(led); 148 Well this was a mess to figure out. The only fix I can figure out here is to remove the depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR from each child device and add select LEDS_CLASS_MULTI_COLOR to the LP55XX_COMMON This way the Multi color framework will inherit the symbol that was set by the COMMON flag which is inherited by majority from the child flags. Did you try this? --- a/drivers/leds/Kconfig +++ b/drivers/leds/Kconfig @@ -398,6 +398,7 @@ config LEDS_LP50XX config LEDS_LP55XX_COMMON tristate "Common Driver for TI/National LP5521/5523/55231/5562/8501" depends on LEDS_LP5521 || LEDS_LP5523 || LEDS_LP5562 || LEDS_LP8501 + depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR depends on OF select FW_LOADER select FW_LOADER_USER_HELPER Yes I did That gave unmet dependencies. WARNING: unmet direct dependencies detected for LEDS_LP55XX_COMMON Depends on [m]: NEW_LEDS [=y] && (LEDS_LP5521 [=n] || LEDS_LP5523 [=m] || LEDS_LP5562 [=y] || LEDS_LP8501 [=y]) && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) && OF [=y] Selected by [y]: - LEDS_LP5562 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] - LEDS_LP8501 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] Selected by [m]: - LEDS_LP5523 [=m] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) When I was testing that yesterday I also had the same warning at some point of testing different Kconfig setups, but with what I showed above it ceased to appear. Now every time I am doing "make oldconfig" the CONFIG_LEDS_LP55XX_COMMON=y entry gets changed to =m with the config from the test bot. That is not what I saw in my testing especially after doing a distclean Dan
Re: [RESEND PATCH v27 11/15] leds: lp55xx: Add multicolor framework support to lp55xx
Dan, On 6/18/20 12:33 AM, Dan Murphy wrote: Jacek On 6/17/20 4:41 PM, Jacek Anaszewski wrote: Dan, On 6/17/20 9:22 PM, Dan Murphy wrote: Pavel/Jacek On 6/17/20 11:28 AM, kernel test robot wrote: Hi Dan, I love your patch! Yet something to improve: [auto build test ERROR on pavel-linux-leds/for-next] [cannot apply to j.anaszewski-leds/for-next] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Dan-Murphy/Multicolor-Framework-v27/20200616-042217 base: git://git.kernel.org/pub/scm/linux/kernel/git/pavel/linux-leds.git for-next config: ia64-randconfig-r015-20200617 (attached as .config) compiler: ia64-linux-gcc (GCC) 9.3.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=ia64 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All errors (new ones prefixed by >>, old ones prefixed by <<): ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `lp55xx_set_mc_brightness': drivers/leds/leds-lp55xx-common.c:146: undefined reference to `led_mc_calc_color_components' ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `devm_led_classdev_multicolor_register': include/linux/led-class-multicolor.h:74: undefined reference to `devm_led_classdev_multicolor_register_ext' vim +146 drivers/leds/leds-lp55xx-common.c 138 139 static int lp55xx_set_mc_brightness(struct led_classdev *cdev, 140 enum led_brightness brightness) 141 { 142 struct led_classdev_mc *mc_dev = lcdev_to_mccdev(cdev); 143 struct lp55xx_led *led = mcled_cdev_to_led(mc_dev); 144 struct lp55xx_device_config *cfg = led->chip->cfg; 145 > 146 led_mc_calc_color_components(&led->mc_cdev, brightness); 147 return cfg->multicolor_brightness_fn(led); 148 Well this was a mess to figure out. The only fix I can figure out here is to remove the depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR from each child device and add select LEDS_CLASS_MULTI_COLOR to the LP55XX_COMMON This way the Multi color framework will inherit the symbol that was set by the COMMON flag which is inherited by majority from the child flags. Did you try this? --- a/drivers/leds/Kconfig +++ b/drivers/leds/Kconfig @@ -398,6 +398,7 @@ config LEDS_LP50XX config LEDS_LP55XX_COMMON tristate "Common Driver for TI/National LP5521/5523/55231/5562/8501" depends on LEDS_LP5521 || LEDS_LP5523 || LEDS_LP5562 || LEDS_LP8501 + depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR depends on OF select FW_LOADER select FW_LOADER_USER_HELPER Yes I did That gave unmet dependencies. WARNING: unmet direct dependencies detected for LEDS_LP55XX_COMMON Depends on [m]: NEW_LEDS [=y] && (LEDS_LP5521 [=n] || LEDS_LP5523 [=m] || LEDS_LP5562 [=y] || LEDS_LP8501 [=y]) && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) && OF [=y] Selected by [y]: - LEDS_LP5562 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] - LEDS_LP8501 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] Selected by [m]: - LEDS_LP5523 [=m] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) When I was testing that yesterday I also had the same warning at some point of testing different Kconfig setups, but with what I showed above it ceased to appear. Now every time I am doing "make oldconfig" the CONFIG_LEDS_LP55XX_COMMON=y entry gets changed to =m with the config from the test bot. -- Best regards, Jacek Anaszewski
Re: [RESEND PATCH v27 11/15] leds: lp55xx: Add multicolor framework support to lp55xx
Jacek On 6/17/20 4:41 PM, Jacek Anaszewski wrote: Dan, On 6/17/20 9:22 PM, Dan Murphy wrote: Pavel/Jacek On 6/17/20 11:28 AM, kernel test robot wrote: Hi Dan, I love your patch! Yet something to improve: [auto build test ERROR on pavel-linux-leds/for-next] [cannot apply to j.anaszewski-leds/for-next] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Dan-Murphy/Multicolor-Framework-v27/20200616-042217 base: git://git.kernel.org/pub/scm/linux/kernel/git/pavel/linux-leds.git for-next config: ia64-randconfig-r015-20200617 (attached as .config) compiler: ia64-linux-gcc (GCC) 9.3.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=ia64 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All errors (new ones prefixed by >>, old ones prefixed by <<): ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `lp55xx_set_mc_brightness': drivers/leds/leds-lp55xx-common.c:146: undefined reference to `led_mc_calc_color_components' ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `devm_led_classdev_multicolor_register': include/linux/led-class-multicolor.h:74: undefined reference to `devm_led_classdev_multicolor_register_ext' vim +146 drivers/leds/leds-lp55xx-common.c 138 139 static int lp55xx_set_mc_brightness(struct led_classdev *cdev, 140 enum led_brightness brightness) 141 { 142 struct led_classdev_mc *mc_dev = lcdev_to_mccdev(cdev); 143 struct lp55xx_led *led = mcled_cdev_to_led(mc_dev); 144 struct lp55xx_device_config *cfg = led->chip->cfg; 145 > 146 led_mc_calc_color_components(&led->mc_cdev, brightness); 147 return cfg->multicolor_brightness_fn(led); 148 Well this was a mess to figure out. The only fix I can figure out here is to remove the depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR from each child device and add select LEDS_CLASS_MULTI_COLOR to the LP55XX_COMMON This way the Multi color framework will inherit the symbol that was set by the COMMON flag which is inherited by majority from the child flags. Did you try this? --- a/drivers/leds/Kconfig +++ b/drivers/leds/Kconfig @@ -398,6 +398,7 @@ config LEDS_LP50XX config LEDS_LP55XX_COMMON tristate "Common Driver for TI/National LP5521/5523/55231/5562/8501" depends on LEDS_LP5521 || LEDS_LP5523 || LEDS_LP5562 || LEDS_LP8501 + depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR depends on OF select FW_LOADER select FW_LOADER_USER_HELPER Yes I did That gave unmet dependencies. WARNING: unmet direct dependencies detected for LEDS_LP55XX_COMMON Depends on [m]: NEW_LEDS [=y] && (LEDS_LP5521 [=n] || LEDS_LP5523 [=m] || LEDS_LP5562 [=y] || LEDS_LP8501 [=y]) && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m]) && OF [=y] Selected by [y]: - LEDS_LP5562 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] - LEDS_LP8501 [=y] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] Selected by [m]: - LEDS_LP5523 [=m] && NEW_LEDS [=y] && LEDS_CLASS [=y] && I2C [=y] && (LEDS_CLASS_MULTI_COLOR [=m] || !LEDS_CLASS_MULTI_COLOR [=m])
Re: [RESEND PATCH v27 11/15] leds: lp55xx: Add multicolor framework support to lp55xx
Dan, On 6/17/20 9:22 PM, Dan Murphy wrote: Pavel/Jacek On 6/17/20 11:28 AM, kernel test robot wrote: Hi Dan, I love your patch! Yet something to improve: [auto build test ERROR on pavel-linux-leds/for-next] [cannot apply to j.anaszewski-leds/for-next] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Dan-Murphy/Multicolor-Framework-v27/20200616-042217 base: git://git.kernel.org/pub/scm/linux/kernel/git/pavel/linux-leds.git for-next config: ia64-randconfig-r015-20200617 (attached as .config) compiler: ia64-linux-gcc (GCC) 9.3.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=ia64 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All errors (new ones prefixed by >>, old ones prefixed by <<): ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `lp55xx_set_mc_brightness': drivers/leds/leds-lp55xx-common.c:146: undefined reference to `led_mc_calc_color_components' ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `devm_led_classdev_multicolor_register': include/linux/led-class-multicolor.h:74: undefined reference to `devm_led_classdev_multicolor_register_ext' vim +146 drivers/leds/leds-lp55xx-common.c 138 139 static int lp55xx_set_mc_brightness(struct led_classdev *cdev, 140 enum led_brightness brightness) 141 { 142 struct led_classdev_mc *mc_dev = lcdev_to_mccdev(cdev); 143 struct lp55xx_led *led = mcled_cdev_to_led(mc_dev); 144 struct lp55xx_device_config *cfg = led->chip->cfg; 145 > 146 led_mc_calc_color_components(&led->mc_cdev, brightness); 147 return cfg->multicolor_brightness_fn(led); 148 Well this was a mess to figure out. The only fix I can figure out here is to remove the depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR from each child device and add select LEDS_CLASS_MULTI_COLOR to the LP55XX_COMMON This way the Multi color framework will inherit the symbol that was set by the COMMON flag which is inherited by majority from the child flags. Did you try this? --- a/drivers/leds/Kconfig +++ b/drivers/leds/Kconfig @@ -398,6 +398,7 @@ config LEDS_LP50XX config LEDS_LP55XX_COMMON tristate "Common Driver for TI/National LP5521/5523/55231/5562/8501" depends on LEDS_LP5521 || LEDS_LP5523 || LEDS_LP5562 || LEDS_LP8501 + depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR depends on OF select FW_LOADER select FW_LOADER_USER_HELPER -- Best regards, Jacek Anaszewski
Re: [RESEND PATCH v27 11/15] leds: lp55xx: Add multicolor framework support to lp55xx
Pavel/Jacek On 6/17/20 11:28 AM, kernel test robot wrote: Hi Dan, I love your patch! Yet something to improve: [auto build test ERROR on pavel-linux-leds/for-next] [cannot apply to j.anaszewski-leds/for-next] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Dan-Murphy/Multicolor-Framework-v27/20200616-042217 base: git://git.kernel.org/pub/scm/linux/kernel/git/pavel/linux-leds.git for-next config: ia64-randconfig-r015-20200617 (attached as .config) compiler: ia64-linux-gcc (GCC) 9.3.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=ia64 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All errors (new ones prefixed by >>, old ones prefixed by <<): ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `lp55xx_set_mc_brightness': drivers/leds/leds-lp55xx-common.c:146: undefined reference to `led_mc_calc_color_components' ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `devm_led_classdev_multicolor_register': include/linux/led-class-multicolor.h:74: undefined reference to `devm_led_classdev_multicolor_register_ext' vim +146 drivers/leds/leds-lp55xx-common.c 138 139 static int lp55xx_set_mc_brightness(struct led_classdev *cdev, 140 enum led_brightness brightness) 141 { 142 struct led_classdev_mc *mc_dev = lcdev_to_mccdev(cdev); 143 struct lp55xx_led *led = mcled_cdev_to_led(mc_dev); 144 struct lp55xx_device_config *cfg = led->chip->cfg; 145 > 146 led_mc_calc_color_components(&led->mc_cdev, brightness); 147 return cfg->multicolor_brightness_fn(led); 148 Well this was a mess to figure out. The only fix I can figure out here is to remove the depends on LEDS_CLASS_MULTI_COLOR || !LEDS_CLASS_MULTI_COLOR from each child device and add select LEDS_CLASS_MULTI_COLOR to the LP55XX_COMMON This way the Multi color framework will inherit the symbol that was set by the COMMON flag which is inherited by majority from the child flags. Dan
Re: [RESEND PATCH v27 11/15] leds: lp55xx: Add multicolor framework support to lp55xx
Hi Dan, I love your patch! Yet something to improve: [auto build test ERROR on pavel-linux-leds/for-next] [cannot apply to j.anaszewski-leds/for-next] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Dan-Murphy/Multicolor-Framework-v27/20200616-042217 base: git://git.kernel.org/pub/scm/linux/kernel/git/pavel/linux-leds.git for-next config: ia64-randconfig-r015-20200617 (attached as .config) compiler: ia64-linux-gcc (GCC) 9.3.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=ia64 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All errors (new ones prefixed by >>, old ones prefixed by <<): ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `lp55xx_set_mc_brightness': >> drivers/leds/leds-lp55xx-common.c:146: undefined reference to >> `led_mc_calc_color_components' ia64-linux-ld: drivers/leds/leds-lp55xx-common.o: in function `devm_led_classdev_multicolor_register': >> include/linux/led-class-multicolor.h:74: undefined reference to >> `devm_led_classdev_multicolor_register_ext' vim +146 drivers/leds/leds-lp55xx-common.c 138 139 static int lp55xx_set_mc_brightness(struct led_classdev *cdev, 140 enum led_brightness brightness) 141 { 142 struct led_classdev_mc *mc_dev = lcdev_to_mccdev(cdev); 143 struct lp55xx_led *led = mcled_cdev_to_led(mc_dev); 144 struct lp55xx_device_config *cfg = led->chip->cfg; 145 > 146 led_mc_calc_color_components(&led->mc_cdev, brightness); 147 return cfg->multicolor_brightness_fn(led); 148 --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-...@lists.01.org .config.gz Description: application/gzip
[RESEND PATCH v27 11/15] leds: lp55xx: Add multicolor framework support to lp55xx
Add multicolor framework support for the lp55xx family. Acked-by: Pavel Machek Acked-by: Jacek Anaszewski Signed-off-by: Dan Murphy --- drivers/leds/Kconfig | 1 + drivers/leds/leds-lp5521.c| 14 +- drivers/leds/leds-lp5523.c| 14 +- drivers/leds/leds-lp5562.c| 13 +- drivers/leds/leds-lp55xx-common.c | 177 +++--- drivers/leds/leds-lp55xx-common.h | 14 +- drivers/leds/leds-lp8501.c| 14 +- include/linux/platform_data/leds-lp55xx.h | 8 + 8 files changed, 208 insertions(+), 47 deletions(-) diff --git a/drivers/leds/Kconfig b/drivers/leds/Kconfig index d3a792cac814..8fe94f3571e2 100644 --- a/drivers/leds/Kconfig +++ b/drivers/leds/Kconfig @@ -388,6 +388,7 @@ config LEDS_LP50XX config LEDS_LP55XX_COMMON tristate "Common Driver for TI/National LP5521/5523/55231/5562/8501" depends on LEDS_LP5521 || LEDS_LP5523 || LEDS_LP5562 || LEDS_LP8501 + depends on OF select FW_LOADER select FW_LOADER_USER_HELPER help diff --git a/drivers/leds/leds-lp5521.c b/drivers/leds/leds-lp5521.c index 6d2163c0f625..6ff81d6be789 100644 --- a/drivers/leds/leds-lp5521.c +++ b/drivers/leds/leds-lp5521.c @@ -505,9 +505,16 @@ static int lp5521_probe(struct i2c_client *client, struct lp55xx_platform_data *pdata = dev_get_platdata(&client->dev); struct device_node *np = client->dev.of_node; + chip = devm_kzalloc(&client->dev, sizeof(*chip), GFP_KERNEL); + if (!chip) + return -ENOMEM; + + chip->cfg = &lp5521_cfg; + if (!pdata) { if (np) { - pdata = lp55xx_of_populate_pdata(&client->dev, np); + pdata = lp55xx_of_populate_pdata(&client->dev, np, +chip); if (IS_ERR(pdata)) return PTR_ERR(pdata); } else { @@ -516,10 +523,6 @@ static int lp5521_probe(struct i2c_client *client, } } - chip = devm_kzalloc(&client->dev, sizeof(*chip), GFP_KERNEL); - if (!chip) - return -ENOMEM; - led = devm_kcalloc(&client->dev, pdata->num_channels, sizeof(*led), GFP_KERNEL); if (!led) @@ -527,7 +530,6 @@ static int lp5521_probe(struct i2c_client *client, chip->cl = client; chip->pdata = pdata; - chip->cfg = &lp5521_cfg; mutex_init(&chip->lock); diff --git a/drivers/leds/leds-lp5523.c b/drivers/leds/leds-lp5523.c index 15e7051392f5..b076c16df9ab 100644 --- a/drivers/leds/leds-lp5523.c +++ b/drivers/leds/leds-lp5523.c @@ -872,9 +872,16 @@ static int lp5523_probe(struct i2c_client *client, struct lp55xx_platform_data *pdata = dev_get_platdata(&client->dev); struct device_node *np = client->dev.of_node; + chip = devm_kzalloc(&client->dev, sizeof(*chip), GFP_KERNEL); + if (!chip) + return -ENOMEM; + + chip->cfg = &lp5523_cfg; + if (!pdata) { if (np) { - pdata = lp55xx_of_populate_pdata(&client->dev, np); + pdata = lp55xx_of_populate_pdata(&client->dev, np, +chip); if (IS_ERR(pdata)) return PTR_ERR(pdata); } else { @@ -883,10 +890,6 @@ static int lp5523_probe(struct i2c_client *client, } } - chip = devm_kzalloc(&client->dev, sizeof(*chip), GFP_KERNEL); - if (!chip) - return -ENOMEM; - led = devm_kcalloc(&client->dev, pdata->num_channels, sizeof(*led), GFP_KERNEL); if (!led) @@ -894,7 +897,6 @@ static int lp5523_probe(struct i2c_client *client, chip->cl = client; chip->pdata = pdata; - chip->cfg = &lp5523_cfg; mutex_init(&chip->lock); diff --git a/drivers/leds/leds-lp5562.c b/drivers/leds/leds-lp5562.c index 1c94422408b0..7ecdd199d7ef 100644 --- a/drivers/leds/leds-lp5562.c +++ b/drivers/leds/leds-lp5562.c @@ -520,9 +520,16 @@ static int lp5562_probe(struct i2c_client *client, struct lp55xx_platform_data *pdata = dev_get_platdata(&client->dev); struct device_node *np = client->dev.of_node; + chip = devm_kzalloc(&client->dev, sizeof(*chip), GFP_KERNEL); + if (!chip) + return -ENOMEM; + + chip->cfg = &lp5562_cfg; + if (!pdata) { if (np) { - pdata = lp55xx_of_populate_pdata(&client->dev, np); + pdata = lp55xx_of_populate_pdata(&client->dev, np, +chip); if (IS_ERR(pdata)) return PTR_ERR(pdata); } else { @@ -531,9 +538,6 @@ st