]> git.baikalelectronics.ru Git - kernel.git/commit
cxgb4: fix usage of uninitialized variable
authorfrançois romieu <romieu@fr.zoreil.com>
Fri, 4 Sep 2015 21:05:42 +0000 (23:05 +0200)
committerDavid S. Miller <davem@davemloft.net>
Mon, 7 Sep 2015 06:59:26 +0000 (23:59 -0700)
commit8c48ad92974bd1038269b8dedbae1edbcb932ce7
tree07f5963fb8bc7bf82250ee8c17357458f6917e03
parent63c523c2bd153d351601e36b61058d937a6ed10b
cxgb4: fix usage of uninitialized variable

drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c: In function ‘init_one’:
drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c:4579:8: warning: ‘chip’ may be used uninitialized in this function [-Wmaybe-uninitialized]
   chip |= CHELSIO_CHIP_CODE(CHELSIO_T4, pl_rev);
        ^
drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c:4571:11: note: ‘chip’ was declared here
  int ver, chip;
           ^

Fixes: af137d917226 ("cxgb4/cxgb4vf: read the correct bits of PL Who Am I register")
Signed-off-by: Francois Romieu <romieu@fr.zoreil.com>
Cc: Hariprasad Shenai <hariprasad@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c