From: Wolfgang Denk Date: Fri, 22 Jan 2010 13:55:23 +0100 Subject: [U-Boot] [PATCH] mpc512x: Add display of reset status register In-Reply-To: <1264164180-10813-1-git-send-email-dzu@denx.de> References: <1264164180-10813-1-git-send-email-dzu@denx.de> Message-ID: <20100122125523.F0B933F6C0@gemini.denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Dear Detlev Zundel, In message <1264164180-10813-1-git-send-email-dzu@denx.de> you wrote: > Content of the RSR is put into gd early so we can output it together > with the CPU info. The clearing of gd in board_init_f is redundant for > this architecture as it is done in cpu_init_f so we remove it. > > Signed-off-by: Detlev Zundel > --- > cpu/mpc512x/cpu.c | 3 ++- > lib_ppc/board.c | 5 +++-- > 2 files changed, 5 insertions(+), 3 deletions(-) > > diff --git a/cpu/mpc512x/cpu.c b/cpu/mpc512x/cpu.c > index f96a4c8..2908a0d 100644 > --- a/cpu/mpc512x/cpu.c > +++ b/cpu/mpc512x/cpu.c > @@ -66,9 +66,10 @@ int checkcpu (void) > default: > puts ("unknown "); > } > - printf ("at %s MHz, CSB at %s MHz\n", > + printf ("at %s MHz, CSB at %s MHz ", > strmhz(buf1, clock), > strmhz(buf2, gd->csb_clk) ); > + printf("(RSR=0x%04lx)\n", gd->reset_status & 0xffff); Please add to the first printf() and avoid an additional function call. > @@ -379,7 +379,8 @@ void board_init_f (ulong bootflag) > __asm__ __volatile__("": : :"memory"); > > #if !defined(CONFIG_CPM2) && !defined(CONFIG_MPC83xx) && \ > - !defined(CONFIG_MPC85xx) && !defined(CONFIG_MPC86xx) > + !defined(CONFIG_MPC85xx) && !defined(CONFIG_MPC86xx) && \ > + !defined(CONFIG_MPC512X) Please keep the list sorted. Best regards, Wolfgang Denk -- DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de All men should freely use those seven words which have the power to make any marriage run smoothly: You know dear, you may be right.