qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PATCH] fix hw/scsi-disk.c compile errors


From: Robert Reif
Subject: [Qemu-devel] [PATCH] fix hw/scsi-disk.c compile errors
Date: Wed, 01 Jul 2009 19:40:43 -0400
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1.21) Gecko/20090303 SeaMonkey/1.1.15 (Ubuntu-1.1.15+nobinonly-0ubuntu2)

This patch fixes 2 compile errors when debugging is enabled.

CC scsi-disk.o
cc1: warnings being treated as errors
/home/reif/qemu/hw/scsi-disk.c: In function ‘scsi_send_command’:
/home/reif/qemu/hw/scsi-disk.c:797: error: format ‘%d’ expects type ‘int’, but argument 2 has type ‘uint64_t’ /home/reif/qemu/hw/scsi-disk.c:899: error: format ‘%d’ expects type ‘int’, but argument 2 has type ‘uint64_t’
make: *** [scsi-disk.o] Error 1

Signed-off-by: Robert Reif <address@hidden>
diff --git a/hw/scsi-disk.c b/hw/scsi-disk.c
index a0485db..95e484c 100644
--- a/hw/scsi-disk.c
+++ b/hw/scsi-disk.c
@@ -794,7 +794,7 @@ static int32_t scsi_send_command(SCSIDevice *d, uint32_t 
tag,
         is_write = 1;
         break;
     case 0x35:
-        DPRINTF("Synchronise cache (sector %d, count %d)\n", lba, len);
+        DPRINTF("Synchronise cache (sector %lld, count %d)\n", lba, len);
         bdrv_flush(s->bdrv);
         break;
     case 0x43:
@@ -896,7 +896,7 @@ static int32_t scsi_send_command(SCSIDevice *d, uint32_t 
tag,
         r->iov.iov_len = 16;
         break;
     case 0x2f:
-        DPRINTF("Verify (sector %d, count %d)\n", lba, len);
+        DPRINTF("Verify (sector %lld, count %d)\n", lba, len);
         break;
     default:
        DPRINTF("Unknown SCSI command (%2.2x)\n", buf[0]);

reply via email to

[Prev in Thread] Current Thread [Next in Thread]