Hi Arun, [FYI, it's a private test report for your RFC patch.] [auto build test ERROR on net-next/master] url: https://github.com/intel-lab-lkp/linux/commits/Arun-Ramadoss/net-dsa-microchip-add-PTP-support-for-KSZ9x-and-LAN937x/20221121-234819 patch link: https://lore.kernel.org/r/20221121154150.9573-7-arun.ramadoss%40microchip.com patch subject: [RFC Patch net-next v2 6/8] net: dsa: microchip: Adding the ptp packet reception logic config: i386-randconfig-a005-20221121 compiler: clang version 14.0.6 (https://github.com/llvm/llvm-project f28c006a5895fc0e329fe15fead81e37457cb1d1) 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/c747439df1f02c175acdcfc248660b650f0941f3 git remote add linux-review https://github.com/intel-lab-lkp/linux git fetch --no-tags linux-review Arun-Ramadoss/net-dsa-microchip-add-PTP-support-for-KSZ9x-and-LAN937x/20221121-234819 git checkout c747439df1f02c175acdcfc248660b650f0941f3 # save the config file mkdir build_dir && cp config build_dir/.config COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=i386 SHELL=/bin/bash net/dsa/ If you fix the issue, kindly add following tag where applicable | Reported-by: kernel test robot All errors (new ones prefixed by >>): >> net/dsa/tag_ksz.c:227:2: error: implicit declaration of function 'ptp_header_update_correction' is invalid in C99 [-Werror,-Wimplicit-function-declaration] ptp_header_update_correction(skb, ptp_type, ptp_hdr, correction); ^ 1 error generated. vim +/ptp_header_update_correction +227 net/dsa/tag_ksz.c 172 173 static void ksz_rcv_timestamp(struct sk_buff *skb, u8 *tag, 174 struct net_device *dev, unsigned int port) 175 { 176 struct skb_shared_hwtstamps *hwtstamps = skb_hwtstamps(skb); 177 u8 *tstamp_raw = tag - KSZ9477_PTP_TAG_LEN; 178 struct dsa_switch *ds = dev->dsa_ptr->ds; 179 struct ksz_tagger_data *tagger_data; 180 struct ptp_header *ptp_hdr; 181 unsigned int ptp_type; 182 u8 ptp_msg_type; 183 ktime_t tstamp; 184 s64 correction; 185 186 tagger_data = ksz_tagger_data(ds); 187 if (!tagger_data->meta_tstamp_handler) 188 return; 189 190 /* convert time stamp and write to skb */ 191 tstamp = ksz_decode_tstamp(get_unaligned_be32(tstamp_raw)); 192 memset(hwtstamps, 0, sizeof(*hwtstamps)); 193 hwtstamps->hwtstamp = tagger_data->meta_tstamp_handler(ds, tstamp); 194 195 if (skb_headroom(skb) < ETH_HLEN) 196 return; 197 198 __skb_push(skb, ETH_HLEN); 199 ptp_type = ptp_classify_raw(skb); 200 __skb_pull(skb, ETH_HLEN); 201 202 if (ptp_type == PTP_CLASS_NONE) 203 return; 204 205 ptp_hdr = ptp_parse_header(skb, ptp_type); 206 if (!ptp_hdr) 207 return; 208 209 if (!tagger_data->is_ptp_twostep) 210 return; 211 212 if (tagger_data->is_ptp_twostep(ds, port)) 213 return; 214 215 ptp_msg_type = ptp_get_msgtype(ptp_hdr, ptp_type); 216 if (ptp_msg_type != PTP_MSGTYPE_PDELAY_REQ) 217 return; 218 219 /* Only subtract the partial time stamp from the correction field. When 220 * the hardware adds the egress time stamp to the correction field of 221 * the PDelay_Resp message on tx, also only the partial time stamp will 222 * be added. 223 */ 224 correction = (s64)get_unaligned_be64(&ptp_hdr->correction); 225 correction -= ktime_to_ns(tstamp) << 16; 226 > 227 ptp_header_update_correction(skb, ptp_type, ptp_hdr, correction); 228 } 229 -- 0-DAY CI Kernel Test Service https://01.org/lkp