Hi, I love your patch! Perhaps something to improve: [auto build test WARNING on net-next/master] url: https://github.com/intel-lab-lkp/linux/commits/alexandru-tachici-analog-com/net-ethernet-adi-Add-ADIN1110-support/20220726-004159 base: https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git 086f8246ed621bcc91d07e867fdbfae9382c1fbd config: x86_64-allmodconfig (https://download.01.org/0day-ci/archive/20220726/202207261549.2tRjhI43-lkp@xxxxxxxxx/config) compiler: gcc-11 (Debian 11.3.0-3) 11.3.0 reproduce: # apt-get install sparse # sparse version: v0.6.4-39-gce1a6720-dirty # https://github.com/intel-lab-lkp/linux/commit/98b8eeb76eafcfa5bf3706812764e769004d9e32 git remote add linux-review https://github.com/intel-lab-lkp/linux git fetch --no-tags linux-review alexandru-tachici-analog-com/net-ethernet-adi-Add-ADIN1110-support/20220726-004159 git checkout 98b8eeb76eafcfa5bf3706812764e769004d9e32 # save the config file mkdir build_dir && cp config build_dir/.config make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=x86_64 SHELL=/bin/bash drivers/net/ethernet/adi/ If you fix the issue, kindly add following tag where applicable Reported-by: kernel test robot <lkp@xxxxxxxxx> sparse warnings: (new ones prefixed by >>) >> drivers/net/ethernet/adi/adin1110.c:194:39: sparse: sparse: cast to restricted __le16 >> drivers/net/ethernet/adi/adin1110.c:194:39: sparse: sparse: restricted __le16 degrades to integer >> drivers/net/ethernet/adi/adin1110.c:194:39: sparse: sparse: restricted __le16 degrades to integer drivers/net/ethernet/adi/adin1110.c:195:25: sparse: sparse: cast to restricted __le16 drivers/net/ethernet/adi/adin1110.c:195:25: sparse: sparse: restricted __le16 degrades to integer drivers/net/ethernet/adi/adin1110.c:195:25: sparse: sparse: restricted __le16 degrades to integer drivers/net/ethernet/adi/adin1110.c:242:56: sparse: sparse: cast to restricted __le16 drivers/net/ethernet/adi/adin1110.c:242:56: sparse: sparse: restricted __le16 degrades to integer drivers/net/ethernet/adi/adin1110.c:242:56: sparse: sparse: restricted __le16 degrades to integer drivers/net/ethernet/adi/adin1110.c:243:25: sparse: sparse: cast to restricted __le16 drivers/net/ethernet/adi/adin1110.c:243:25: sparse: sparse: restricted __le16 degrades to integer drivers/net/ethernet/adi/adin1110.c:243:25: sparse: sparse: restricted __le16 degrades to integer drivers/net/ethernet/adi/adin1110.c:326:39: sparse: sparse: cast to restricted __le16 drivers/net/ethernet/adi/adin1110.c:326:39: sparse: sparse: restricted __le16 degrades to integer drivers/net/ethernet/adi/adin1110.c:326:39: sparse: sparse: restricted __le16 degrades to integer drivers/net/ethernet/adi/adin1110.c:327:25: sparse: sparse: cast to restricted __le16 drivers/net/ethernet/adi/adin1110.c:327:25: sparse: sparse: restricted __le16 degrades to integer drivers/net/ethernet/adi/adin1110.c:327:25: sparse: sparse: restricted __le16 degrades to integer drivers/net/ethernet/adi/adin1110.c:395:56: sparse: sparse: cast to restricted __le16 drivers/net/ethernet/adi/adin1110.c:395:56: sparse: sparse: restricted __le16 degrades to integer drivers/net/ethernet/adi/adin1110.c:395:56: sparse: sparse: restricted __le16 degrades to integer drivers/net/ethernet/adi/adin1110.c:396:25: sparse: sparse: cast to restricted __le16 drivers/net/ethernet/adi/adin1110.c:396:25: sparse: sparse: restricted __le16 degrades to integer drivers/net/ethernet/adi/adin1110.c:396:25: sparse: sparse: restricted __le16 degrades to integer vim +194 drivers/net/ethernet/adi/adin1110.c 185 186 static int adin1110_read_reg(struct adin1110_priv *priv, u16 reg, u32 *val) 187 { 188 struct spi_transfer t[2] = {0}; 189 __le16 __reg = cpu_to_le16(reg); 190 u32 header_len = ADIN1110_RD_HEADER_LEN; 191 u32 read_len = ADIN1110_REG_LEN; 192 int ret; 193 > 194 priv->data[0] = ADIN1110_CD | FIELD_GET(GENMASK(12, 8), __reg); 195 priv->data[1] = FIELD_GET(GENMASK(7, 0), __reg); 196 priv->data[2] = 0x00; 197 198 if (priv->append_crc) { 199 priv->data[2] = adin1110_crc_data(&priv->data[0], 2); 200 priv->data[3] = 0x00; 201 header_len++; 202 } 203 204 t[0].tx_buf = &priv->data[0]; 205 t[0].len = header_len; 206 207 if (priv->append_crc) 208 read_len++; 209 210 memset(&priv->data[header_len], 0, read_len); 211 t[1].rx_buf = &priv->data[header_len]; 212 t[1].len = read_len; 213 214 ret = spi_sync_transfer(priv->spidev, t, 2); 215 if (ret) 216 return ret; 217 218 if (priv->append_crc) { 219 u8 recv_crc; 220 u8 crc; 221 222 crc = adin1110_crc_data(&priv->data[header_len], ADIN1110_REG_LEN); 223 recv_crc = priv->data[header_len + ADIN1110_REG_LEN]; 224 225 if (crc != recv_crc) { 226 dev_err_ratelimited(&priv->spidev->dev, "CRC error."); 227 return -EBADMSG; 228 } 229 } 230 231 *val = get_unaligned_be32(&priv->data[header_len]); 232 233 return ret; 234 } 235 -- 0-DAY CI Kernel Test Service https://01.org/lkp