Hi Fenglin, Thank you for the patch! Yet something to improve: [auto build test ERROR on pavel-leds/for-next] [also build test ERROR on linus/master v6.0-rc7 next-20220927] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as documented in https://git-scm.com/docs/git-format-patch#_base_tree_information] url: https://github.com/intel-lab-lkp/linux/commits/Fenglin-Wu/Add-LED-driver-for-flash-module-in-QCOM-PMICs/20220928-104406 base: git://git.kernel.org/pub/scm/linux/kernel/git/pavel/linux-leds.git for-next config: sh-allmodconfig compiler: sh4-linux-gcc (GCC) 12.1.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 # https://github.com/intel-lab-lkp/linux/commit/f415df2219f9f17052a247383fae82a289183a50 git remote add linux-review https://github.com/intel-lab-lkp/linux git fetch --no-tags linux-review Fenglin-Wu/Add-LED-driver-for-flash-module-in-QCOM-PMICs/20220928-104406 git checkout f415df2219f9f17052a247383fae82a289183a50 # save the config file mkdir build_dir && cp config build_dir/.config COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=sh SHELL=/bin/bash drivers/leds/flash/ If you fix the issue, kindly add following tag where applicable | Reported-by: kernel test robot All errors (new ones prefixed by >>): drivers/leds/flash/leds-qcom-flash.c: In function '__set_flash_strobe': >> drivers/leds/flash/leds-qcom-flash.c:243:31: error: implicit declaration of function 'FIELD_PREP' [-Werror=implicit-function-declaration] 243 | val = FIELD_PREP(FLASH_STROBE_HW_SW_SEL_BIT, SW_STROBE_VAL); | ^~~~~~~~~~ cc1: some warnings being treated as errors vim +/FIELD_PREP +243 drivers/leds/flash/leds-qcom-flash.c 230 231 static int __set_flash_strobe(struct qcom_flash_led *led, enum led_strobe strobe, bool state) 232 { 233 struct qcom_flash_chip *chip = led->chip; 234 u8 reg, mask, val, chan_id = 0, chan_mask = 0; 235 int rc, i; 236 237 /* Set SW strobe config for all channels connected to the LED */ 238 for (i = 0; i < led->chan_count; i++) { 239 chan_id = led->chan_id[i]; 240 mask = FLASH_STROBE_HW_SW_SEL_BIT | FLASH_HW_STROBE_TRIGGER_SEL_BIT 241 | FLASH_STROBE_POLARITY_BIT; 242 if (strobe == SW_STROBE) > 243 val = FIELD_PREP(FLASH_STROBE_HW_SW_SEL_BIT, SW_STROBE_VAL); 244 else 245 val = FIELD_PREP(FLASH_STROBE_HW_SW_SEL_BIT, HW_STROBE_VAL); 246 247 val |= FIELD_PREP(FLASH_HW_STROBE_TRIGGER_SEL_BIT, STROBE_LEVEL_TRIGGER_VAL) | 248 FIELD_PREP(FLASH_STROBE_POLARITY_BIT, STROBE_ACTIVE_HIGH_VAL); 249 reg = chip->reg->chan_strobe + chan_id - 1; 250 rc = regmap_update_bits(chip->regmap, chip->reg_base + reg, mask, val); 251 if (rc < 0) 252 return rc; 253 254 chan_mask |= BIT(chan_id - 1); 255 } 256 257 /* enable/disable flash channels */ 258 mask = chan_mask; 259 val = state ? mask : 0; 260 reg = chip->reg->chan_en; 261 rc = regmap_update_bits(chip->regmap, chip->reg_base + reg, mask, val); 262 if (rc < 0) 263 return rc; 264 265 led->enabled = state; 266 return 0; 267 } 268 -- 0-DAY CI Kernel Test Service https://01.org/lkp