From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KAqDe-0005L8-OR for qemu-devel@nongnu.org; Mon, 23 Jun 2008 13:52:46 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KAqDe-0005Ko-8d for qemu-devel@nongnu.org; Mon, 23 Jun 2008 13:52:46 -0400 Received: from [199.232.76.173] (port=40309 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KAqDe-0005Kl-6A for qemu-devel@nongnu.org; Mon, 23 Jun 2008 13:52:46 -0400 Received: from savannah.gnu.org ([199.232.41.3]:35951 helo=sv.gnu.org) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1KAqDe-0008KW-GA for qemu-devel@nongnu.org; Mon, 23 Jun 2008 13:52:46 -0400 Received: from cvs.savannah.gnu.org ([199.232.41.69]) by sv.gnu.org with esmtp (Exim 4.63) (envelope-from ) id 1KAqDd-0000l7-2d for qemu-devel@nongnu.org; Mon, 23 Jun 2008 17:52:45 +0000 Received: from blueswir1 by cvs.savannah.gnu.org with local (Exim 4.63) (envelope-from ) id 1KAqDc-0000kt-Bn for qemu-devel@nongnu.org; Mon, 23 Jun 2008 17:52:44 +0000 MIME-Version: 1.0 Errors-To: blueswir1 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit From: Blue Swirl Message-Id: Date: Mon, 23 Jun 2008 17:52:44 +0000 Subject: [Qemu-devel] [4782] Fix some compiler signed/unsigned char warnings Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Revision: 4782 http://svn.sv.gnu.org/viewvc/?view=rev&root=qemu&revision=4782 Author: blueswir1 Date: 2008-06-23 17:52:43 +0000 (Mon, 23 Jun 2008) Log Message: ----------- Fix some compiler signed/unsigned char warnings Modified Paths: -------------- trunk/hw/firmware_abi.h trunk/hw/sun4m.c trunk/hw/sun4u.c Modified: trunk/hw/firmware_abi.h =================================================================== --- trunk/hw/firmware_abi.h 2008-06-23 16:58:04 UTC (rev 4781) +++ trunk/hw/firmware_abi.h 2008-06-23 17:52:43 UTC (rev 4782) @@ -139,7 +139,7 @@ } static inline uint32_t -OpenBIOS_set_var(uint8_t *nvram, uint32_t addr, const unsigned char *str) +OpenBIOS_set_var(uint8_t *nvram, uint32_t addr, const char *str) { uint32_t len; Modified: trunk/hw/sun4m.c =================================================================== --- trunk/hw/sun4m.c 2008-06-23 16:58:04 UTC (rev 4781) +++ trunk/hw/sun4m.c 2008-06-23 17:52:43 UTC (rev 4782) @@ -159,7 +159,7 @@ for (i = 0; i < sizeof(image); i++) image[i] = m48t59_read(nvram, i) & 0xff; - strcpy(header->boot_devices, boot_device); + strcpy((char *)header->boot_devices, boot_device); header->nboot_devices = strlen(boot_device) & 0xff; header->crc = cpu_to_be16(OHW_compute_crc(header, 0x00, 0xF8)); @@ -187,17 +187,17 @@ memset(image, '\0', sizeof(image)); // Try to match PPC NVRAM - strcpy(header->struct_ident, "QEMU_BIOS"); + strcpy((char *)header->struct_ident, "QEMU_BIOS"); header->struct_version = cpu_to_be32(3); /* structure v3 */ header->nvram_size = cpu_to_be16(0x2000); header->nvram_arch_ptr = cpu_to_be16(sizeof(ohwcfg_v3_t)); header->nvram_arch_size = cpu_to_be16(sizeof(struct sparc_arch_cfg)); - strcpy(header->arch, arch); + strcpy((char *)header->arch, arch); header->nb_cpus = smp_cpus & 0xff; header->RAM0_base = 0; header->RAM0_size = cpu_to_be64((uint64_t)RAM_size); - strcpy(header->boot_devices, boot_devices); + strcpy((char *)header->boot_devices, boot_devices); header->nboot_devices = strlen(boot_devices) & 0xff; header->kernel_image = cpu_to_be64((uint64_t)KERNEL_LOAD_ADDR); header->kernel_size = cpu_to_be64((uint64_t)kernel_size); Modified: trunk/hw/sun4u.c =================================================================== --- trunk/hw/sun4u.c 2008-06-23 16:58:04 UTC (rev 4781) +++ trunk/hw/sun4u.c 2008-06-23 17:52:43 UTC (rev 4782) @@ -78,7 +78,7 @@ for (i = 0; i < sizeof(image); i++) image[i] = m48t59_read(nvram, i) & 0xff; - strcpy(header->boot_devices, boot_device); + strcpy((char *)header->boot_devices, boot_device); header->nboot_devices = strlen(boot_device) & 0xff; header->crc = cpu_to_be16(OHW_compute_crc(header, 0x00, 0xF8)); @@ -91,7 +91,7 @@ extern int nographic; static int sun4u_NVRAM_set_params (m48t59_t *nvram, uint16_t NVRAM_size, - const unsigned char *arch, + const char *arch, ram_addr_t RAM_size, const char *boot_devices, uint32_t kernel_image, uint32_t kernel_size, @@ -110,17 +110,17 @@ memset(image, '\0', sizeof(image)); // Try to match PPC NVRAM - strcpy(header->struct_ident, "QEMU_BIOS"); + strcpy((char *)header->struct_ident, "QEMU_BIOS"); header->struct_version = cpu_to_be32(3); /* structure v3 */ header->nvram_size = cpu_to_be16(NVRAM_size); header->nvram_arch_ptr = cpu_to_be16(sizeof(ohwcfg_v3_t)); header->nvram_arch_size = cpu_to_be16(sizeof(struct sparc_arch_cfg)); - strcpy(header->arch, arch); + strcpy((char *)header->arch, arch); header->nb_cpus = smp_cpus & 0xff; header->RAM0_base = 0; header->RAM0_size = cpu_to_be64((uint64_t)RAM_size); - strcpy(header->boot_devices, boot_devices); + strcpy((char *)header->boot_devices, boot_devices); header->nboot_devices = strlen(boot_devices) & 0xff; header->kernel_image = cpu_to_be64((uint64_t)kernel_image); header->kernel_size = cpu_to_be64((uint64_t)kernel_size);