tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master head: 9606f9efb1cec7f8f5912326f182fbfbcad34382 commit: 0e938533d96d656764fbd3fe0e2578873ec6d3e6 [3055/4921] RDMA/bnxt_re: Remove dynamic pkey table config: riscv-allmodconfig (https://download.01.org/0day-ci/archive/20211202/202112021856.xGoHq1LN-lkp@xxxxxxxxx/config) compiler: riscv64-linux-gcc (GCC) 11.2.0 reproduce: wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # apt-get install sparse # sparse version: v0.6.4-dirty # https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id=0e938533d96d656764fbd3fe0e2578873ec6d3e6 git remote add linux-next https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git git fetch --no-tags linux-next master git checkout 0e938533d96d656764fbd3fe0e2578873ec6d3e6 # save the config file to linux build tree mkdir build_dir COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=riscv SHELL=/bin/bash drivers/infiniband/hw/bnxt_re/ If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot <lkp@xxxxxxxxx> sparse warnings: (new ones prefixed by >>) >> drivers/infiniband/hw/bnxt_re/qplib_fp.c:1260:26: sparse: sparse: incorrect type in assignment (different base types) @@ expected restricted __le16 [addressable] [assigned] [usertype] pkey @@ got int @@ drivers/infiniband/hw/bnxt_re/qplib_fp.c:1260:26: sparse: expected restricted __le16 [addressable] [assigned] [usertype] pkey drivers/infiniband/hw/bnxt_re/qplib_fp.c:1260:26: sparse: got int vim +1260 drivers/infiniband/hw/bnxt_re/qplib_fp.c 1230 1231 int bnxt_qplib_modify_qp(struct bnxt_qplib_res *res, struct bnxt_qplib_qp *qp) 1232 { 1233 struct bnxt_qplib_rcfw *rcfw = res->rcfw; 1234 struct cmdq_modify_qp req; 1235 struct creq_modify_qp_resp resp; 1236 u16 cmd_flags = 0; 1237 u32 temp32[4]; 1238 u32 bmask; 1239 int rc; 1240 1241 RCFW_CMD_PREP(req, MODIFY_QP, cmd_flags); 1242 1243 /* Filter out the qp_attr_mask based on the state->new transition */ 1244 __filter_modify_flags(qp); 1245 bmask = qp->modify_flags; 1246 req.modify_mask = cpu_to_le32(qp->modify_flags); 1247 req.qp_cid = cpu_to_le32(qp->id); 1248 if (bmask & CMDQ_MODIFY_QP_MODIFY_MASK_STATE) { 1249 req.network_type_en_sqd_async_notify_new_state = 1250 (qp->state & CMDQ_MODIFY_QP_NEW_STATE_MASK) | 1251 (qp->en_sqd_async_notify ? 1252 CMDQ_MODIFY_QP_EN_SQD_ASYNC_NOTIFY : 0); 1253 } 1254 req.network_type_en_sqd_async_notify_new_state |= qp->nw_type; 1255 1256 if (bmask & CMDQ_MODIFY_QP_MODIFY_MASK_ACCESS) 1257 req.access = qp->access; 1258 1259 if (bmask & CMDQ_MODIFY_QP_MODIFY_MASK_PKEY) > 1260 req.pkey = IB_DEFAULT_PKEY_FULL; 1261 1262 if (bmask & CMDQ_MODIFY_QP_MODIFY_MASK_QKEY) 1263 req.qkey = cpu_to_le32(qp->qkey); 1264 1265 if (bmask & CMDQ_MODIFY_QP_MODIFY_MASK_DGID) { 1266 memcpy(temp32, qp->ah.dgid.data, sizeof(struct bnxt_qplib_gid)); 1267 req.dgid[0] = cpu_to_le32(temp32[0]); 1268 req.dgid[1] = cpu_to_le32(temp32[1]); 1269 req.dgid[2] = cpu_to_le32(temp32[2]); 1270 req.dgid[3] = cpu_to_le32(temp32[3]); 1271 } 1272 if (bmask & CMDQ_MODIFY_QP_MODIFY_MASK_FLOW_LABEL) 1273 req.flow_label = cpu_to_le32(qp->ah.flow_label); 1274 1275 if (bmask & CMDQ_MODIFY_QP_MODIFY_MASK_SGID_INDEX) 1276 req.sgid_index = cpu_to_le16(res->sgid_tbl.hw_id 1277 [qp->ah.sgid_index]); 1278 1279 if (bmask & CMDQ_MODIFY_QP_MODIFY_MASK_HOP_LIMIT) 1280 req.hop_limit = qp->ah.hop_limit; 1281 1282 if (bmask & CMDQ_MODIFY_QP_MODIFY_MASK_TRAFFIC_CLASS) 1283 req.traffic_class = qp->ah.traffic_class; 1284 1285 if (bmask & CMDQ_MODIFY_QP_MODIFY_MASK_DEST_MAC) 1286 memcpy(req.dest_mac, qp->ah.dmac, 6); 1287 1288 if (bmask & CMDQ_MODIFY_QP_MODIFY_MASK_PATH_MTU) 1289 req.path_mtu = qp->path_mtu; 1290 1291 if (bmask & CMDQ_MODIFY_QP_MODIFY_MASK_TIMEOUT) 1292 req.timeout = qp->timeout; 1293 1294 if (bmask & CMDQ_MODIFY_QP_MODIFY_MASK_RETRY_CNT) 1295 req.retry_cnt = qp->retry_cnt; 1296 1297 if (bmask & CMDQ_MODIFY_QP_MODIFY_MASK_RNR_RETRY) 1298 req.rnr_retry = qp->rnr_retry; 1299 1300 if (bmask & CMDQ_MODIFY_QP_MODIFY_MASK_MIN_RNR_TIMER) 1301 req.min_rnr_timer = qp->min_rnr_timer; 1302 1303 if (bmask & CMDQ_MODIFY_QP_MODIFY_MASK_RQ_PSN) 1304 req.rq_psn = cpu_to_le32(qp->rq.psn); 1305 1306 if (bmask & CMDQ_MODIFY_QP_MODIFY_MASK_SQ_PSN) 1307 req.sq_psn = cpu_to_le32(qp->sq.psn); 1308 1309 if (bmask & CMDQ_MODIFY_QP_MODIFY_MASK_MAX_RD_ATOMIC) 1310 req.max_rd_atomic = 1311 ORD_LIMIT_TO_ORRQ_SLOTS(qp->max_rd_atomic); 1312 1313 if (bmask & CMDQ_MODIFY_QP_MODIFY_MASK_MAX_DEST_RD_ATOMIC) 1314 req.max_dest_rd_atomic = 1315 IRD_LIMIT_TO_IRRQ_SLOTS(qp->max_dest_rd_atomic); 1316 1317 req.sq_size = cpu_to_le32(qp->sq.hwq.max_elements); 1318 req.rq_size = cpu_to_le32(qp->rq.hwq.max_elements); 1319 req.sq_sge = cpu_to_le16(qp->sq.max_sge); 1320 req.rq_sge = cpu_to_le16(qp->rq.max_sge); 1321 req.max_inline_data = cpu_to_le32(qp->max_inline_data); 1322 if (bmask & CMDQ_MODIFY_QP_MODIFY_MASK_DEST_QP_ID) 1323 req.dest_qp_id = cpu_to_le32(qp->dest_qpn); 1324 1325 req.vlan_pcp_vlan_dei_vlan_id = cpu_to_le16(qp->vlan_id); 1326 1327 rc = bnxt_qplib_rcfw_send_message(rcfw, (void *)&req, 1328 (void *)&resp, NULL, 0); 1329 if (rc) 1330 return rc; 1331 qp->cur_qp_state = qp->state; 1332 return 0; 1333 } 1334 --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx