| Submitter | Amit Shah |
|---|---|
| Date | Sept. 24, 2012, 6:35 p.m. |
| Message ID | <62a944963063329ffcff01df8ac770f5874e0d1f.1348511596.git.amit.shah@redhat.com> |
| Download | mbox | patch |
| Permalink | /patch/186508/ |
| State | New |
| Headers | show |
Comments
Patch
diff --git a/hw/virtio.c b/hw/virtio.c index 209c763..4c9e20a3 100644 --- a/hw/virtio.c +++ b/hw/virtio.c @@ -338,7 +338,7 @@ static unsigned virtqueue_next_desc(target_phys_addr_t desc_pa, int virtqueue_avail_bytes(VirtQueue *vq, int in_bytes, int out_bytes) { unsigned int idx; - int total_bufs, in_total, out_total; + unsigned int total_bufs, in_total, out_total; idx = vq->last_avail_idx;
The virtqueue_avail_bytes() function counts bytes in an int. Use an unsigned int instead. Signed-off-by: Amit Shah <amit.shah@redhat.com> --- hw/virtio.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)