[TIPC]: fix printk warning
authorJeff Garzik <jeff@garzik.org>
Tue, 3 Oct 2006 23:25:34 +0000 (16:25 -0700)
committerDavid S. Miller <davem@sunset.davemloft.net>
Wed, 4 Oct 2006 07:31:03 +0000 (00:31 -0700)
gcc spits out this warning:

net/tipc/link.c: In function ‘link_retransmit_failure’:
net/tipc/link.c:1669: warning: cast from pointer to integer of different
size

More than a little bit ugly, storing integers in void*, but at least the
code is correct, unlike some of the more crufty Linux kernel code found
elsewhere.

Rather than having two casts to massage the value into u32, it's easier
just to have a single cast and use "%lu", since it's just a printk.

Signed-off-by: Jeff Garzik <jeff@garzik.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/tipc/link.c

index 693f02eca6d68226966c02642b4396d013849d05..53bc8cb5adbc7bc98e2ede758f89e7ba3b1d05c4 100644 (file)
@@ -1666,8 +1666,9 @@ static void link_retransmit_failure(struct link *l_ptr, struct sk_buff *buf)
                char addr_string[16];
 
                tipc_printf(TIPC_OUTPUT, "Msg seq number: %u,  ", msg_seqno(msg));
-               tipc_printf(TIPC_OUTPUT, "Outstanding acks: %u\n", (u32)TIPC_SKB_CB(buf)->handle);
-               
+               tipc_printf(TIPC_OUTPUT, "Outstanding acks: %lu\n",
+                                    (unsigned long) TIPC_SKB_CB(buf)->handle);
+
                n_ptr = l_ptr->owner->next;
                tipc_node_lock(n_ptr);