Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755897AbYBQFJ5 (ORCPT ); Sun, 17 Feb 2008 00:09:57 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1750779AbYBQFJt (ORCPT ); Sun, 17 Feb 2008 00:09:49 -0500 Received: from cdptpa-omtalb.mail.rr.com ([75.180.132.121]:37824 "EHLO cdptpa-omtalb.mail.rr.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751306AbYBQFJs (ORCPT ); Sun, 17 Feb 2008 00:09:48 -0500 Date: Sun, 17 Feb 2008 00:09:47 -0500 Message-ID: <877ih42mp0.wl%ysato@users.sourceforge.jp> From: Yoshinori Sato To: Andrew Morton Cc: lkml Subject: Re: [PATCH 3/6] h8300 setup.c initrd support fix In-Reply-To: <20080216205502.686f1cef.akpm@linux-foundation.org> References: <87bq6ho2cu.wl%ysato@users.sourceforge.jp> <20080215222949.a22ca18e.akpm@linux-foundation.org> <87abm02o42.wl%ysato@users.sourceforge.jp> <20080216205502.686f1cef.akpm@linux-foundation.org> User-Agent: Wanderlust/2.15.5 (Almost Unreal) SEMI/1.14.6 (Maruoka) FLIM/1.14.9 (=?ISO-8859-4?Q?Goj=F2?=) APEL/10.7 Emacs/22.1 (x86_64-pc-linux-gnu) MULE/5.0 (SAKAKI) MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 4563 Lines: 125 At Sat, 16 Feb 2008 20:55:02 -0800, Andrew Morton wrote: > > On Sat, 16 Feb 2008 23:39:09 -0500 Yoshinori Sato wrote: > > > At Fri, 15 Feb 2008 22:29:49 -0800, > > Andrew Morton wrote: > > > > > > On Sat, 16 Feb 2008 01:13:37 -0500 Yoshinori Sato wrote: > > > > > > > initrd setting fix. > > > > > > > > arch/h8300/kernel/setup.c | 5 +++-- > > > > 1 files changed, 3 insertions(+), 2 deletions(-) > > > > > > > > diff --git a/arch/h8300/kernel/setup.c b/arch/h8300/kernel/setup.c > > > > index b1f25c2..75712ec 100644 > > > > --- a/arch/h8300/kernel/setup.c > > > > +++ b/arch/h8300/kernel/setup.c > > > > @@ -57,6 +57,7 @@ extern int _stext, _etext, _sdata, _edata, _sbss, _ebss, _end; > > > > extern int _ramstart, _ramend; > > > > extern char _target_name[]; > > > > extern void h8300_gpio_init(void); > > > > +extern void *initrd_start, *initrd_end; > > > > > > > > #if (defined(CONFIG_H8300H_SIM) || defined(CONFIG_H8S_SIM)) \ > > > > && defined(CONFIG_GDB_MAGICPRINT) > > > > @@ -99,8 +100,8 @@ void __init setup_arch(char **cmdline_p) > > > > /* allow for ROMFS on the end of the kernel */ > > > > if (memcmp((void *)memory_start, "-rom1fs-", 8) == 0) { > > > > #if defined(CONFIG_BLK_DEV_INITRD) > > > > - initrd_start = memory_start; > > > > - initrd_end = memory_start += be32_to_cpu(((unsigned long *) (memory_start))[2]); > > > > + initrd_start = (void *)memory_start; > > > > + initrd_end = (void *)(memory_start += be32_to_cpu(((unsigned long *) (memory_start))[2])); > > > > #else > > > > memory_start += be32_to_cpu(((unsigned long *) memory_start)[2]); > > > > #endif > > > > > > But include/linux/initrd.h declares: > > > > > > extern unsigned long initrd_start, initrd_end; > > > > > > > fix it. > > I assume this new patch is an addition to the previous one quoted above? > > > Signed-off-by: Yoshinori Sato > > > > arch/h8300/kernel/setup.c | 2 +- > > 1 files changed, 1 insertions(+), 1 deletions(-) > > > > diff --git a/arch/h8300/kernel/setup.c b/arch/h8300/kernel/setup.c > > index 75712ec..4dd744f 100644 > > --- a/arch/h8300/kernel/setup.c > > +++ b/arch/h8300/kernel/setup.c > > @@ -30,6 +30,7 @@ > > #include > > #include > > #include > > +#include > > > > #include > > #include > > @@ -57,7 +58,6 @@ extern int _stext, _etext, _sdata, _edata, _sbss, _ebss, _end; > > extern int _ramstart, _ramend; > > extern char _target_name[]; > > extern void h8300_gpio_init(void); > > -extern void *initrd_start, *initrd_end; > > > > #if (defined(CONFIG_H8300H_SIM) || defined(CONFIG_H8S_SIM)) \ > > && defined(CONFIG_GDB_MAGICPRINT) > > If so then surely it generated a warning when assigning a void* to an > unsigned long. > > So please send a complete new fully tested patch. Please also include a > changelog which describes what is being fixed, and how it is fixed. The > text "initrd setting fix." and "fit it" is not sufficient - it doesn't > tell us what was wrong with the old code, nor how the change improved it. > > Thanks. Sorry. I mistake orign. Signed-off-by: Yoshinori Sato arch/h8300/kernel/setup.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/arch/h8300/kernel/setup.c b/arch/h8300/kernel/setup.c index b1f25c2..4dd744f 100644 --- a/arch/h8300/kernel/setup.c +++ b/arch/h8300/kernel/setup.c @@ -30,6 +30,7 @@ #include #include #include +#include #include #include @@ -99,8 +100,8 @@ void __init setup_arch(char **cmdline_p) /* allow for ROMFS on the end of the kernel */ if (memcmp((void *)memory_start, "-rom1fs-", 8) == 0) { #if defined(CONFIG_BLK_DEV_INITRD) - initrd_start = memory_start; - initrd_end = memory_start += be32_to_cpu(((unsigned long *) (memory_start))[2]); + initrd_start = (void *)memory_start; + initrd_end = (void *)(memory_start += be32_to_cpu(((unsigned long *) (memory_start))[2])); #else memory_start += be32_to_cpu(((unsigned long *) memory_start)[2]); #endif -- 1.5.4.1 -- Yoshinori Sato -- 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/