All of lore.kernel.org
 help / color / mirror / Atom feed
* Janz ICAN3 build warnings
@ 2014-01-29 14:10 Oliver Hartkopp
  2014-01-29 17:58 ` Ira W. Snyder
  0 siblings, 1 reply; 4+ messages in thread
From: Oliver Hartkopp @ 2014-01-29 14:10 UTC (permalink / raw)
  To: Ira W. Snyder, linux-can@vger.kernel.org

Hello Ira,

while addressing an issue with the skb->sk handling here

	http://marc.info/?l=linux-netdev&m=139100313304453&w=2

I was enabling the Janz ICAN3 driver to be built as I did a small change
there too.

Can you please fix these build warnings below?

Regards,
Oliver


  CC [M]  drivers/net/can/janz-ican3.o
drivers/net/can/janz-ican3.c:1086:43: warning: ‘msg.data[6]’ may be used uninitialized in this function [-Wmaybe-uninitialized]
   mod->termination_enabled = msg->data[6] & HWCONF_TERMINATE_ON;
                                           ^
drivers/net/can/janz-ican3.c:1320:20: note: ‘msg.data[6]’ was declared here
   struct ican3_msg msg;
                    ^
drivers/net/can/janz-ican3.c:1067:15: warning: ‘msg.data[5]’ may be used uninitialized in this function [-Wmaybe-uninitialized]
   cf->data[6] = txerr;
               ^
drivers/net/can/janz-ican3.c:1320:20: note: ‘msg.data[5]’ was declared here
   struct ican3_msg msg;
                    ^
drivers/net/can/janz-ican3.c:1068:15: warning: ‘msg.data[4]’ may be used uninitialized in this function [-Wmaybe-uninitialized]
   cf->data[7] = rxerr;
               ^
drivers/net/can/janz-ican3.c:1320:20: note: ‘msg.data[4]’ was declared here
   struct ican3_msg msg;
                    ^
drivers/net/can/janz-ican3.c:1014:21: warning: ‘msg.data[3]’ may be used uninitialized in this function [-Wmaybe-uninitialized]
   } else if (status & SR_ES) {
                     ^
drivers/net/can/janz-ican3.c:1320:20: note: ‘msg.data[3]’ was declared here
   struct ican3_msg msg;
                    ^
drivers/net/can/janz-ican3.c:1045:13: warning: ‘msg.data[2]’ may be used uninitialized in this function [-Wmaybe-uninitialized]
   if (!(ecc & ECC_DIR))
             ^
drivers/net/can/janz-ican3.c:1320:20: note: ‘msg.data[2]’ was declared here
   struct ican3_msg msg;
                    ^
drivers/net/can/janz-ican3.c:940:5: warning: ‘msg.data[1]’ may be used uninitialized in this function [-Wmaybe-uninitialized]
  if (msg->data[1] != CEVTIND_CHIP_SJA1000) {
     ^
drivers/net/can/janz-ican3.c:1320:20: note: ‘msg.data[1]’ was declared here
   struct ican3_msg msg;
                    ^
drivers/net/can/janz-ican3.c:1025:5: warning: ‘*((void *)&msg+4)’ may be used uninitialized in this function [-Wmaybe-uninitialized]
  if (isrc == CEVTIND_BEI) {
     ^
drivers/net/can/janz-ican3.c:1320:20: note: ‘*((void *)&msg+4)’ was declared here
   struct ican3_msg msg;
                    ^
drivers/net/can/janz-ican3.c:1098:10: warning: ‘msg.len’ may be used uninitialized in this function [-Wmaybe-uninitialized]
  dev_warn(mod->dev, "received unknown message: spec 0x%.2x length %d\n",
          ^
drivers/net/can/janz-ican3.c:1320:20: note: ‘msg.len’ was declared here
   struct ican3_msg msg;
                    ^
drivers/net/can/janz-ican3.c:900:5: warning: ‘msg.spec’ may be used uninitialized in this function [-Wmaybe-uninitialized]
  if (msg->spec == MSG_MSGLOST) {
     ^
drivers/net/can/janz-ican3.c:1320:20: note: ‘msg.spec’ was declared here
   struct ican3_msg msg;
                    ^

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2014-01-29 20:30 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-01-29 14:10 Janz ICAN3 build warnings Oliver Hartkopp
2014-01-29 17:58 ` Ira W. Snyder
2014-01-29 19:14   ` Oliver Hartkopp
2014-01-29 20:30   ` Marc Kleine-Budde

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.