Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/evbarm/bcm53xx Print out u-boot args
details: https://anonhg.NetBSD.org/src/rev/f76f87a426cf
branches: trunk
changeset: 781733:f76f87a426cf
user: matt <matt%NetBSD.org@localhost>
date: Thu Sep 27 00:22:39 2012 +0000
description:
Print out u-boot args
diffstat:
sys/arch/evbarm/bcm53xx/bcm53xx_machdep.c | 16 +++++++++++++---
sys/arch/evbarm/bcm53xx/bcm53xx_start.S | 13 +++++++++++--
2 files changed, 24 insertions(+), 5 deletions(-)
diffs (95 lines):
diff -r 71c2dca4ab09 -r f76f87a426cf sys/arch/evbarm/bcm53xx/bcm53xx_machdep.c
--- a/sys/arch/evbarm/bcm53xx/bcm53xx_machdep.c Wed Sep 26 23:27:34 2012 +0000
+++ b/sys/arch/evbarm/bcm53xx/bcm53xx_machdep.c Thu Sep 27 00:22:39 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: bcm53xx_machdep.c,v 1.2 2012/09/07 11:53:49 matt Exp $ */
+/* $NetBSD: bcm53xx_machdep.c,v 1.3 2012/09/27 00:22:39 matt Exp $ */
/*-
* Copyright (c) 2012 The NetBSD Foundation, Inc.
@@ -33,7 +33,7 @@
#define IDM_PRIVATE
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: bcm53xx_machdep.c,v 1.2 2012/09/07 11:53:49 matt Exp $");
+__KERNEL_RCSID(0, "$NetBSD: bcm53xx_machdep.c,v 1.3 2012/09/27 00:22:39 matt Exp $");
#include "opt_evbarm_boardtype.h"
#include "opt_broadcom.h"
@@ -83,6 +83,8 @@
static char bootargs[MAX_BOOT_STRING];
char *boot_args = NULL;
+u_int uboot_args[4] = { 0 };
+
static void bcm53xx_system_reset(void);
/*
@@ -214,6 +216,9 @@
bcm53xx_rng_start(bcm53xx_ioreg_bst, bcm53xx_ioreg_bsh);
#endif
+ printf("uboot arg = %#x, %#x, %#x, %#x\n",
+ uboot_args[0], uboot_args[1], uboot_args[2], uboot_args[3]);
+
/* Talk to the user */
printf("\nNetBSD/evbarm (" ___STRING(EVBARM_BOARDTYPE) ") booting ...\n");
@@ -226,10 +231,15 @@
arm_cpu_max + 1, arm_cpu_max + 1 ? "s" : "",
arm_cpu_hatched);
#endif
+ printf(", CLIDR=%010o CTR=%#x",
+ armreg_clidr_read(), armreg_ctr_read());
printf("\n");
#endif
- arm32_bootmem_init(KERN_VTOPHYS(KERNEL_BASE), bcm53xx_memprobe(),
+ psize_t memsize = bcm53xx_memprobe();
+ //memsize = 128*1024*1024;
+
+ arm32_bootmem_init(KERN_VTOPHYS(KERNEL_BASE), memsize,
(paddr_t)KERNEL_BASE_phys);
/*
diff -r 71c2dca4ab09 -r f76f87a426cf sys/arch/evbarm/bcm53xx/bcm53xx_start.S
--- a/sys/arch/evbarm/bcm53xx/bcm53xx_start.S Wed Sep 26 23:27:34 2012 +0000
+++ b/sys/arch/evbarm/bcm53xx/bcm53xx_start.S Thu Sep 27 00:22:39 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: bcm53xx_start.S,v 1.3 2012/09/07 11:53:50 matt Exp $ */
+/* $NetBSD: bcm53xx_start.S,v 1.4 2012/09/27 00:22:39 matt Exp $ */
/*-
* Copyright (c) 2012 The NetBSD Foundation, Inc.
* All rights reserved.
@@ -45,7 +45,7 @@
#define CONADDR 0x18000300
#endif
-RCSID("$NetBSD: bcm53xx_start.S,v 1.3 2012/09/07 11:53:50 matt Exp $")
+RCSID("$NetBSD: bcm53xx_start.S,v 1.4 2012/09/27 00:22:39 matt Exp $")
#undef VERBOSE_INIT_ARM
#define VERBOSE_INIT_ARM
@@ -67,6 +67,12 @@
.global _C_LABEL(bcm53xx_start)
_C_LABEL(bcm53xx_start):
/*
+ * Save any arguments u-boot passed us.
+ */
+ ldr r4, .Luboot_args
+ stmia r4, {r0-r3}
+
+ /*
* Let's turn on the CCA watchdog in case something goes horribly wrong.
*/
ldr r0, .Lcca_wdog
@@ -127,6 +133,9 @@
/* NOTREACHED */
+.Luboot_args:
+ .word uboot_args
+
.Lsku_rom_lut:
.word 0xffff0400
Home |
Main Index |
Thread Index |
Old Index