Hi AngeloGioacchino,

kernel test robot noticed the following build errors:

[auto build test ERROR on next-20250113]
[cannot apply to robh/for-next pza/reset/next linus/master pza/imx-drm/next 
drm-misc/drm-misc-next v6.13-rc7 v6.13-rc6 v6.13-rc5 v6.13-rc7]
[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/AngeloGioacchino-Del-Regno/dt-bindings-display-mediatek-dpi-Add-MT8195-and-MT8188-compat/20250113-225554
base:   next-20250113
patch link:    
https://lore.kernel.org/r/20250113145232.227674-33-angelogioacchino.delregno%40collabora.com
patch subject: [PATCH v5 32/34] drm/mediatek: Introduce HDMI/DDC v2 for 
MT8195/MT8188
config: hexagon-allmodconfig 
(https://download.01.org/0day-ci/archive/20250118/202501180257.a2og8glk-...@intel.com/config)
compiler: clang version 20.0.0git (https://github.com/llvm/llvm-project 
c23f2417dc5f6dc371afb07af5627ec2a9d373a0)
reproduce (this is a W=1 build): 
(https://download.01.org/0day-ci/archive/20250118/202501180257.a2og8glk-...@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 <l...@intel.com>
| Closes: 
https://lore.kernel.org/oe-kbuild-all/202501180257.a2og8glk-...@intel.com/

All errors (new ones prefixed by >>):

>> drivers/gpu/drm/mediatek/mtk_hdmi_v2.c:345:8: error: call to undeclared 
>> function 'FIELD_PREP'; ISO C99 and later do not support implicit function 
>> declarations [-Wimplicit-function-declaration]
     345 |         val = FIELD_PREP(SD0_MAP, sd0) | FIELD_PREP(SD1_MAP, sd1);
         |               ^
   drivers/gpu/drm/mediatek/mtk_hdmi_v2.c:378:51: error: call to undeclared 
function 'FIELD_PREP'; ISO C99 and later do not support implicit function 
declarations [-Wimplicit-function-declaration]
     378 |         regmap_update_bits(hdmi->regs, AIP_CTRL, I2S_EN, 
FIELD_PREP(I2S_EN, chnum));
         |                                                          ^
   drivers/gpu/drm/mediatek/mtk_hdmi_v2.c:410:13: error: call to undeclared 
function 'FIELD_PREP'; ISO C99 and later do not support implicit function 
declarations [-Wimplicit-function-declaration]
     410 |         fifo_map = FIELD_PREP(FIFO0_MAP, 0) | FIELD_PREP(FIFO1_MAP, 
1);
         |                    ^
   drivers/gpu/drm/mediatek/mtk_hdmi_v2.c:477:53: error: call to undeclared 
function 'FIELD_PREP'; ISO C99 and later do not support implicit function 
declarations [-Wimplicit-function-declaration]
     477 |         regmap_update_bits(hdmi->regs, AIP_CTRL, SPDIF_EN, 
FIELD_PREP(SPDIF_EN, spdif_i2s));
         |                                                            ^
   drivers/gpu/drm/mediatek/mtk_hdmi_v2.c:554:7: error: call to undeclared 
function 'FIELD_PREP'; ISO C99 and later do not support implicit function 
declarations [-Wimplicit-function-declaration]
     554 |                            FIELD_PREP(MAX_2UI_I2S_HI_WRITE, 
swapbit));
         |                            ^
   drivers/gpu/drm/mediatek/mtk_hdmi_v2.c:579:7: error: call to undeclared 
function 'FIELD_PREP'; ISO C99 and later do not support implicit function 
declarations [-Wimplicit-function-declaration]
     579 |                            FIELD_PREP(MAX_1UI_WRITE, 4));
         |                            ^
   drivers/gpu/drm/mediatek/mtk_hdmi_v2.c:715:7: error: call to undeclared 
function 'FIELD_PREP'; ISO C99 and later do not support implicit function 
declarations [-Wimplicit-function-declaration]
     715 |                            FIELD_PREP(TMDS_PACK_MODE, 
TMDS_PACK_MODE_8BPP));
         |                            ^
>> drivers/gpu/drm/mediatek/mtk_hdmi_v2.c:812:16: error: call to undeclared 
>> function 'FIELD_GET'; ISO C99 and later do not support implicit function 
>> declarations [-Wimplicit-function-declaration]
     812 |         hpd_pin_sta = FIELD_GET(HPD_PIN_STA, hpd_status);
         |                       ^
   8 errors generated.
--
>> drivers/gpu/drm/mediatek/mtk_hdmi_ddc_v2.c:59:8: error: call to undeclared 
>> function 'FIELD_PREP'; ISO C99 and later do not support implicit function 
>> declarations [-Wimplicit-function-declaration]
      59 |                                    FIELD_PREP(DDC_CTRL_CMD, 
DDC_CMD_CLOCK_SCL));
         |                                    ^
   drivers/gpu/drm/mediatek/mtk_hdmi_ddc_v2.c:87:7: error: call to undeclared 
function 'FIELD_PREP'; ISO C99 and later do not support implicit function 
declarations [-Wimplicit-function-declaration]
      87 |                            FIELD_PREP(HPD_DDC_DELAY_CNT, 
DDC2_DLY_CNT));
         |                            ^
   drivers/gpu/drm/mediatek/mtk_hdmi_ddc_v2.c:133:7: error: call to undeclared 
function 'FIELD_PREP'; ISO C99 and later do not support implicit function 
declarations [-Wimplicit-function-declaration]
     133 |                            FIELD_PREP(DDC_CTRL_CMD, 
DDC_CMD_CLEAR_FIFO));
         |                            ^
   drivers/gpu/drm/mediatek/mtk_hdmi_ddc_v2.c:139:9: warning: comparison of 
distinct pointer types ('typeof ((loop_counter)) *' (aka 'unsigned short *') 
and 'uint64_t *' (aka 'unsigned long long *')) 
[-Wcompare-distinct-pointer-types]
     139 |                 rem = do_div(loop_counter, temp_length);
         |                       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/asm-generic/div64.h:183:28: note: expanded from macro 'do_div'
     183 |         (void)(((typeof((n)) *)0) == ((uint64_t *)0));  \
         |                ~~~~~~~~~~~~~~~~~~ ^  ~~~~~~~~~~~~~~~
>> drivers/gpu/drm/mediatek/mtk_hdmi_ddc_v2.c:139:9: error: incompatible 
>> pointer types passing 'u16 *' (aka 'unsigned short *') to parameter of type 
>> 'uint64_t *' (aka 'unsigned long long *') 
>> [-Werror,-Wincompatible-pointer-types]
     139 |                 rem = do_div(loop_counter, temp_length);
         |                       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/asm-generic/div64.h:199:22: note: expanded from macro 'do_div'
     199 |                 __rem = __div64_32(&(n), __base);       \
         |                                    ^~~~
   include/asm-generic/div64.h:174:38: note: passing argument to parameter 
'dividend' here
     174 | extern uint32_t __div64_32(uint64_t *dividend, uint32_t divisor);
         |                                      ^
>> drivers/gpu/drm/mediatek/mtk_hdmi_ddc_v2.c:207:26: error: call to undeclared 
>> function 'FIELD_GET'; ISO C99 and later do not support implicit function 
>> declarations [-Wimplicit-function-declaration]
     207 |                         puc_value[read_idx] = 
FIELD_GET(DDC_DATA_OUT, val);
         |                                               ^
   drivers/gpu/drm/mediatek/mtk_hdmi_ddc_v2.c:139:9: warning: shift count >= 
width of type [-Wshift-count-overflow]
     139 |                 rem = do_div(loop_counter, temp_length);
         |                       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/asm-generic/div64.h:195:25: note: expanded from macro 'do_div'
     195 |         } else if (likely(((n) >> 32) == 0)) {          \
         |                                ^  ~~
   include/linux/compiler.h:76:40: note: expanded from macro 'likely'
      76 | # define likely(x)      __builtin_expect(!!(x), 1)
         |                                             ^
   2 warnings and 5 errors generated.


vim +/FIELD_PREP +345 drivers/gpu/drm/mediatek/mtk_hdmi_v2.c

   333  
   334  static u32 mtk_hdmi_v2_aud_output_channel_map(u8 sd0, u8 sd1, u8 sd2, 
u8 sd3,
   335                                                u8 sd4, u8 sd5, u8 sd6, 
u8 sd7)
   336  {
   337          u32 val;
   338  
   339          /*
   340           * Each of the Output Channels (0-7) can be mapped to get their 
input
   341           * from any of the available Input Channels (0-7): this function
   342           * takes input channel numbers and formats a value that must 
then
   343           * be written to the TOP_AUD_MAP hardware register by the 
caller.
   344           */
 > 345          val = FIELD_PREP(SD0_MAP, sd0) | FIELD_PREP(SD1_MAP, sd1);
   346          val |= FIELD_PREP(SD2_MAP, sd2) | FIELD_PREP(SD3_MAP, sd3);
   347          val |= FIELD_PREP(SD4_MAP, sd4) | FIELD_PREP(SD5_MAP, sd5);
   348          val |= FIELD_PREP(SD6_MAP, sd6) | FIELD_PREP(SD7_MAP, sd7);
   349  
   350          return val;
   351  }
   352  

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

Reply via email to