Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S267364AbUITVT6 (ORCPT ); Mon, 20 Sep 2004 17:19:58 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S267363AbUITVT6 (ORCPT ); Mon, 20 Sep 2004 17:19:58 -0400 Received: from mail.dif.dk ([193.138.115.101]:17056 "EHLO mail.dif.dk") by vger.kernel.org with ESMTP id S267364AbUITVTz (ORCPT ); Mon, 20 Sep 2004 17:19:55 -0400 Date: Mon, 20 Sep 2004 23:26:38 +0200 (CEST) From: Jesper Juhl To: David Woodhouse Cc: linux-mtd , linux-kernel Subject: [PATCH] attempt to fix warnings in dilnetpc.c Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1892 Lines: 48 Hi, I see these warnings when building 2.6.9-rc2-bk5 allyesconfig : CC drivers/mtd/maps/dilnetpc.o drivers/mtd/maps/dilnetpc.c: In function `init_dnpc': drivers/mtd/maps/dilnetpc.c:406: warning: assignment makes pointer from integer without a cast drivers/mtd/maps/dilnetpc.c:416: warning: long unsigned int format, pointer arg (arg 2) drivers/mtd/maps/dilnetpc.c:416: warning: long unsigned int format, pointer arg (arg 2) Here's a patch to attempt to fix those. I don't have the hardware, so all I could do was read the code, think about it and then compile test my changes. I hope I got it right. Signed-off-by: Jesper Juhl diff -up linux-2.6.9-rc2-bk5-orig/drivers/mtd/maps/dilnetpc.c linux-2.6.9-rc2-bk5/drivers/mtd/maps/dilnetpc.c --- linux-2.6.9-rc2-bk5-orig/drivers/mtd/maps/dilnetpc.c 2004-08-14 07:36:32.000000000 +0200 +++ linux-2.6.9-rc2-bk5/drivers/mtd/maps/dilnetpc.c 2004-09-20 23:19:34.000000000 +0200 @@ -403,7 +403,7 @@ static int __init init_dnpc(void) printk(KERN_NOTICE "DIL/Net %s flash: 0x%lx at 0x%lx\n", is_dnp ? "DNPC" : "ADNP", dnpc_map.size, dnpc_map.phys); - dnpc_map.virt = (unsigned long)ioremap_nocache(dnpc_map.phys, dnpc_map.size); + dnpc_map.virt = (unsigned long *)ioremap_nocache(dnpc_map.phys, dnpc_map.size); dnpc_map_flash(dnpc_map.phys, dnpc_map.size); @@ -413,7 +413,7 @@ static int __init init_dnpc(void) } simple_map_init(&dnpc_map); - printk("FLASH virtual address: 0x%lx\n", dnpc_map.virt); + printk("FLASH virtual address: 0x%lx\n", (unsigned long)dnpc_map.virt); mymtd = do_map_probe("jedec_probe", &dnpc_map); Please CC me on replies. - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/