Skip to contentSkip to conversation

ARM: mach-shmobile: Marzen early console hack

PATCH New Magnus Damm 1 participant 1 message Dec 6, 2011

Subsystems (4)
lore
Share & tools
lore

Magnus Damm

author maintainer
#0 lore raw

PATCH 4/7 ARM: mach-shmobile: Marzen early console hack

From: Magnus Damm <[email protected]>

Hack the Marzen board code to get early debug print outs. Use with "earlyprint=sh-sci.2,11520" on the kernel command line.

Good to have when tracking down early timer or PFC issues.

Needed by the r8a7779 PFC map hack further in the series.

---

 arch/arm/mach-shmobile/board-marzen.c  |    8 ++++++++
 arch/arm/mach-shmobile/setup-r8a7779.c |    4 ++--
 2 files changed, 10 insertions(+), 2 deletions(-)
arch/arm/mach-shmobile/board-marzen.c +8 -0
@@ -54,6 +54,13 @@ static struct map_desc marzen_io_desc[]
 		.length		= SZ_16M,
 		.type		= MT_DEVICE_NONSHARED
 	},
+	/* 16M debug map between 0xfdxxxxxx and 0xffxxxxxx */
+	{
+		.virtual	= 0xfd000000,
+		.pfn		= __phys_to_pfn(0xff000000),
+		.length		= SZ_16M,
+		.type		= MT_DEVICE_NONSHARED
+	},
 };
 
 static void __init marzen_map_io(void)
@@ -80,6 +87,7 @@ static void __init marzen_init_early(voi
 	 * As a final step pass earlyprint=sh-sci.2,115200 on the kernel
 	 * command line.
 	 */
+	shmobile_setup_console();
 }
 
 static void __init marzen_init(void)
arch/arm/mach-shmobile/setup-r8a7779.c +2 -2
@@ -70,8 +70,8 @@ static struct platform_device scif1_devi
 };
 
 static struct plat_sci_port scif2_platform_data = {
-	.mapbase	= 0xffe42000,
-	.flags		= UPF_BOOT_AUTOCONF | UPF_IOREMAP,
+	.mapbase	= 0xfde42000,
+	.flags		= UPF_BOOT_AUTOCONF,
 	.scscr		= SCSCR_RE | SCSCR_TE | SCSCR_CKE1,
 	.scbrr_algo_id	= SCBRR_ALGO_2,
 	.type		= PORT_SCIF,