qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH] Fix warnings in mips_r4k.c
@ 2006-07-31 10:20 Dirk Behme
  2006-07-31 12:39 ` Paul Brook
  0 siblings, 1 reply; 4+ messages in thread
From: Dirk Behme @ 2006-07-31 10:20 UTC (permalink / raw)
  To: qemu-devel

[-- Attachment #1: Type: text/plain, Size: 262 bytes --]


Fix warnings

hw/mips_r4k.c: In function  ‘mips_r4kc_init’:
hw/mips_r4k.c:230: warning: pointer targets in passing
argument 3 of ‘load_elf’ differ in signedness
hw/mips_r4k.c:256: warning: pointer targets in passing
argument 1 of ‘strcpy’ differ in signedness


[-- Attachment #2: mips_r4k_warning.patch --]
[-- Type: text/x-patch, Size: 810 bytes --]

--- ./hw/mips_r4k.c_orig	2006-07-31 12:11:32.000000000 +0200
+++ ./hw/mips_r4k.c	2006-07-31 12:14:55.000000000 +0200
@@ -195,7 +195,7 @@ void mips_r4kc_init (int ram_size, int v
                      const char *initrd_filename)
 {
     char buf[1024];
-    int64_t entry = 0;
+    uint64_t entry = 0;
     unsigned long bios_offset;
     int io_memory;
     int ret;
@@ -253,7 +253,7 @@ void mips_r4kc_init (int ram_size, int v
         }
 
 	/* Store command line.  */
-        strcpy (phys_ram_base + (16 << 20) - 256, kernel_cmdline);
+        strcpy ((char *)phys_ram_base + (16 << 20) - 256, kernel_cmdline);
         /* FIXME: little endian support */
         *(int *)(phys_ram_base + (16 << 20) - 260) = tswap32 (0x12345678);
         *(int *)(phys_ram_base + (16 << 20) - 264) = tswap32 (ram_size);


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

end of thread, other threads:[~2006-07-31 13:33 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-07-31 10:20 [Qemu-devel] [PATCH] Fix warnings in mips_r4k.c Dirk Behme
2006-07-31 12:39 ` Paul Brook
2006-07-31 13:18   ` Dirk Behme
2006-07-31 13:33     ` Paul Brook

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).