public inbox for kernel-janitors@vger.kernel.org
 help / color / mirror / Atom feed
* 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

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