net/xen-netfront: Correct printf format in xennet_get_responses
authorJulien Grall <julien.grall@citrix.com>
Tue, 16 Jun 2015 19:10:46 +0000 (20:10 +0100)
committerDavid S. Miller <davem@davemloft.net>
Sun, 21 Jun 2015 16:40:40 +0000 (09:40 -0700)
rx->status is an int16_t, print it using %d rather than %u in order to
have a meaningful value when the field is negative.

Also use %u rather than %x for rx->offset.

Signed-off-by: Julien Grall <julien.grall@citrix.com>
Reviewed-by: David Vrabel <david.vrabel@citrix.com>
Cc: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Cc: Boris Ostrovsky <boris.ostrovsky@oracle.com>
Cc: netdev@vger.kernel.org
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/xen-netfront.c

index c89ca26e254d3b4b4e92cd28418386e39f801fb6..56d8afd11077de5d1f7b475bba37d1164c92bf41 100644 (file)
@@ -733,7 +733,7 @@ static int xennet_get_responses(struct netfront_queue *queue,
                if (unlikely(rx->status < 0 ||
                             rx->offset + rx->status > PAGE_SIZE)) {
                        if (net_ratelimit())
-                               dev_warn(dev, "rx->offset: %x, size: %u\n",
+                               dev_warn(dev, "rx->offset: %u, size: %d\n",
                                         rx->offset, rx->status);
                        xennet_move_rx_slot(queue, skb, ref);
                        err = -EINVAL;