* re: net: Adding support for Cavium ThunderX network controller
@ 2015-05-29 15:04 Dan Carpenter
2015-05-29 15:06 ` Dan Carpenter
0 siblings, 1 reply; 2+ messages in thread
From: Dan Carpenter @ 2015-05-29 15:04 UTC (permalink / raw)
To: kernel-janitors
Hello Sunil Goutham,
The patch 4863dea3fab0: "net: Adding support for Cavium ThunderX
network controller" from May 26, 2015, leads to the following static
checker warning:
drivers/net/ethernet/cavium/thunder/thunder_bgx.c:485 bgx_xaui_check_link()
warn: we tested 'lmac_type = 3' before and it was 'false'
drivers/net/ethernet/cavium/thunder/thunder_bgx.c
484
485 if ((lmac_type = BGX_MODE_10G_KR) || (lmac_type = BGX_MODE_XFI) ||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^^^^^
These are the both 3. That seems like it could lead to bugs down the
line.
486 (lmac_type = BGX_MODE_40G_KR) || (lmac_type = BGX_MODE_XLAUI)) {
^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^
These are both 4.
487 if (bgx_poll_reg(bgx, lmacid, BGX_SPUX_BR_STATUS1,
488 SPU_BR_STATUS_BLK_LOCK, false)) {
489 dev_err(&bgx->pdev->dev,
490 "SPU_BR_STATUS_BLK_LOCK not completed\n");
491 return -1;
492 }
493 } else {
regards,
dan carpenter
^ permalink raw reply [flat|nested] 2+ messages in thread* re: net: Adding support for Cavium ThunderX network controller
2015-05-29 15:04 net: Adding support for Cavium ThunderX network controller Dan Carpenter
@ 2015-05-29 15:06 ` Dan Carpenter
0 siblings, 0 replies; 2+ messages in thread
From: Dan Carpenter @ 2015-05-29 15:06 UTC (permalink / raw)
To: kernel-janitors
Hello Sunil Goutham,
The patch 4863dea3fab0: "net: Adding support for Cavium ThunderX
network controller" from May 26, 2015, leads to the following static
checker warning:
drivers/net/ethernet/cavium/thunder/nicvf_ethtool.c:517 nicvf_set_rxfh()
warn: we tested 'hkey' before and it was 'false'
drivers/net/ethernet/cavium/thunder/nicvf_ethtool.c
506 /* We do not allow change in unsupported parameters */
507 if (hkey ||
^^^^
We return here.
508 (hfunc != ETH_RSS_HASH_NO_CHANGE && hfunc != ETH_RSS_HASH_TOP))
509 return -EOPNOTSUPP;
510
511 rss->enable = true;
512 if (indir) {
513 for (idx = 0; idx < rss->rss_size; idx++)
514 rss->ind_tbl[idx] = indir[idx];
515 }
516
517 if (hkey) {
^^^^
So this is dead code.
518 memcpy(rss->key, hkey, RSS_HASH_KEY_SIZE * sizeof(u64));
519 nicvf_set_rss_key(nic);
520 }
521
522 nicvf_config_rss(nic);
523 return 0;
524 }
regards,
dan carpenter
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2015-05-29 15:06 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-05-29 15:04 net: Adding support for Cavium ThunderX network controller Dan Carpenter
2015-05-29 15:06 ` Dan Carpenter
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox