Skip to contentSkip to conversation

arm: omap: add support for Nokia RM-696 (Nokia N9)

PATCH New Aaro Koskinen 2 participants 8 messages Dec 9, 2011

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

cover arm: omap: add support for Nokia RM-696 (Nokia N9)

Hi,

The following patches add minimal support for Nokia RM-696 board. Tested with Linux 3.2-rc4 and busybox, basic functionality like serial console and MMC are working. So far the code is identical with RM-680.

mach-types update is needed to compile the code. I'm not sure how the file is updated these days?

For testing, the following patch is also required:
http://www.spinics.net/lists/linux-omap/msg61022.html

Aaro Koskinen (2):
arm: tools: mach-types: add nokia_rm696
arm: omap: add minimal support for Nokia RM-696

Igor Dmitriev (1):
arm: mach-omap2: sdram-nokia: add 200 MHz memory timings info

 arch/arm/mach-omap2/Kconfig                  |    3 ++-
 arch/arm/mach-omap2/board-rm680.c            |   12 +++++++++++-
 arch/arm/mach-omap2/sdram-nokia.c            |   25 ++++++++++++++++++++++++-
 arch/arm/plat-omap/include/plat/uncompress.h |    1 +
 arch/arm/tools/mach-types                    |    1 +
 5 files changed, 39 insertions(+), 3 deletions(-)
Signature · 1 line
1.7.2.5
#1 lore raw

PATCH 1/3 arm: tools: mach-types: add nokia_rm696

Add the mach-type number for RM-696.

---
 arch/arm/tools/mach-types |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
arch/arm/tools/mach-types +1 -0
index ccbe16f..63f20da 100644
@@ -1123,6 +1123,7 @@ blissc			MACH_BLISSC		BLISSC			3491
 thales_adc		MACH_THALES_ADC		THALES_ADC		3492
 ubisys_p9d_evp		MACH_UBISYS_P9D_EVP	UBISYS_P9D_EVP		3493
 atdgp318		MACH_ATDGP318		ATDGP318		3494
+nokia_rm696		MACH_NOKIA_RM696	NOKIA_RM696		3522
 m28evk			MACH_M28EVK		M28EVK			3613
 smdk4212		MACH_SMDK4212		SMDK4212		3638
 smdk4412		MACH_SMDK4412		SMDK4412		3765
Signature · 1 line
1.7.2.5
maintainer
#2 lore raw

PATCH 1/3 arm: tools: mach-types: add nokia_rm696

Russell,

Quoted 1 line · Aaro Koskinen

Add the mach-type number for RM-696.

Care to ack this one or apply into your devel-stable with the other pending mach-types updates?

This allows board-rm680.c to support Nokia N9 with minimal changes.

Regards,

Tony

Quoted 20 lines
---
 arch/arm/tools/mach-types |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
arch/arm/tools/mach-types +1 -0
index ccbe16f..63f20da 100644
@@ -1123,6 +1123,7 @@ blissc			MACH_BLISSC		BLISSC			3491
 thales_adc		MACH_THALES_ADC		THALES_ADC		3492
 ubisys_p9d_evp		MACH_UBISYS_P9D_EVP	UBISYS_P9D_EVP		3493
 atdgp318		MACH_ATDGP318		ATDGP318		3494
+nokia_rm696		MACH_NOKIA_RM696	NOKIA_RM696		3522
 m28evk			MACH_M28EVK		M28EVK			3613
 smdk4212		MACH_SMDK4212		SMDK4212		3638
 smdk4412		MACH_SMDK4412		SMDK4412		3765
Signature · 1 line
1.7.2.5
#3 lore raw

PATCH 2/3 arm: mach-omap2: sdram-nokia: add 200 MHz memory timings info

In reply to Aaro Koskinen

From: Igor Dmitriev <[email protected]>

Add memory timing info regarding the 200 MHz memory in sdram-nokia.

---
 arch/arm/mach-omap2/sdram-nokia.c |   25 ++++++++++++++++++++++++-
 1 files changed, 24 insertions(+), 1 deletions(-)
arch/arm/mach-omap2/sdram-nokia.c +24 -1
index 14caa22..b394a0e 100644
@@ -1,7 +1,7 @@
 /*
  * SDRC register values for Nokia boards
  *
- * Copyright (C) 2008, 2010 Nokia Corporation
+ * Copyright (C) 2008, 2010-2011 Nokia Corporation
  *
  * Lauri Leukkunen <[email protected]>
  *
@@ -107,14 +107,37 @@ static const struct sdram_timings nokia_195dot2mhz_timings[] = {
 	},
 };
 
+static const struct sdram_timings nokia_200mhz_timings[] = {
+	{
+		.casl = 3,
+		.tDAL = 30000,
+		.tDPL = 15000,
+		.tRRD = 10000,
+		.tRCD = 20000,
+		.tRP = 15000,
+		.tRAS = 40000,
+		.tRC = 55000,
+		.tRFC = 140000,
+		.tXSR = 200000,
+
+		.tREF = 7800,
+
+		.tXP = 2,
+		.tCKE = 4,
+		.tWTR = 2
+	},
+};
+
 static const struct {
 	long rate;
 	struct sdram_timings const *data;
 } nokia_timings[] = {
 	{ 83000000, nokia_166mhz_timings },
 	{ 97600000, nokia_97dot6mhz_timings },
+	{ 100000000, nokia_200mhz_timings },
 	{ 166000000, nokia_166mhz_timings },
 	{ 195200000, nokia_195dot2mhz_timings },
+	{ 200000000, nokia_200mhz_timings },
 };
 static struct omap_sdrc_params nokia_sdrc_params[ARRAY_SIZE(nokia_timings) + 1];
 
Signature · 1 line
1.7.2.5
maintainer
#4 lore raw

PATCH 2/3 arm: mach-omap2: sdram-nokia: add 200 MHz memory timings info

Quoted 46 lines · Aaro Koskinen

From: Igor Dmitriev <[email protected]>

Add memory timing info regarding the 200 MHz memory in sdram-nokia.

---
 arch/arm/mach-omap2/sdram-nokia.c |   25 ++++++++++++++++++++++++-
 1 files changed, 24 insertions(+), 1 deletions(-)
arch/arm/mach-omap2/sdram-nokia.c +19 -1
index 14caa22..b394a0e 100644
@@ -1,7 +1,7 @@
 /*
  * SDRC register values for Nokia boards
  *
- * Copyright (C) 2008, 2010 Nokia Corporation
+ * Copyright (C) 2008, 2010-2011 Nokia Corporation
  *
  * Lauri Leukkunen <[email protected]>
  *
@@ -107,14 +107,37 @@ static const struct sdram_timings nokia_195dot2mhz_timings[] = {
 	},
 };
 
+static const struct sdram_timings nokia_200mhz_timings[] = {
+	{
+		.casl = 3,
+		.tDAL = 30000,
+		.tDPL = 15000,
+		.tRRD = 10000,
+		.tRCD = 20000,
+		.tRP = 15000,
+		.tRAS = 40000,
+		.tRC = 55000,
+		.tRFC = 140000,
+		.tXSR = 200000,
+
+		.tREF = 7800,
+
+		.tXP = 2,
+		.tCKE = 4,
+		.tWTR = 2

arch/arm/mach-omap2/sdram-nokia.c static const struct sdram_timings nokia_195dot2mhz_timings[] = { · line 137

Quoted 10 lines
arch/arm/mach-omap2/sdram-nokia.c +4 -0
+	},
+};
+
 static const struct {
 	long rate;
 	struct sdram_timings const *data;
 } nokia_timings[] = {
 	{ 83000000, nokia_166mhz_timings },
 	{ 97600000, nokia_97dot6mhz_timings },
+	{ 100000000, nokia_200mhz_timings },

Is that a typo above? Should it say nokia_100mhz_timings?

arch/arm/mach-omap2/sdram-nokia.c static const struct sdram_timings nokia_195dot2mhz_timings[] = { · line 142

Quoted 5 lines
arch/arm/mach-omap2/sdram-nokia.c +1 -0
 	{ 166000000, nokia_166mhz_timings },
 	{ 195200000, nokia_195dot2mhz_timings },
+	{ 200000000, nokia_200mhz_timings },
 };
 static struct omap_sdrc_params nokia_sdrc_params[ARRAY_SIZE(nokia_timings) + 1];

Regards,

Tony

#5 lore raw

PATCH 2/3 arm: mach-omap2: sdram-nokia: add 200 MHz memory timings info

Hi,

Quoted 51 lines · Tony Lindgren
Quoted 50 lines · Aaro Koskinen

From: Igor Dmitriev <[email protected]>

Add memory timing info regarding the 200 MHz memory in sdram-nokia.

---
 arch/arm/mach-omap2/sdram-nokia.c |   25 ++++++++++++++++++++++++-
 1 files changed, 24 insertions(+), 1 deletions(-)
arch/arm/mach-omap2/sdram-nokia.c +22 -1
index 14caa22..b394a0e 100644
@@ -1,7 +1,7 @@
 /*
  * SDRC register values for Nokia boards
  *
- * Copyright (C) 2008, 2010 Nokia Corporation
+ * Copyright (C) 2008, 2010-2011 Nokia Corporation
  *
  * Lauri Leukkunen <[email protected]>
  *
@@ -107,14 +107,37 @@ static const struct sdram_timings nokia_195dot2mhz_timings[] = {
 	},
 };
 
+static const struct sdram_timings nokia_200mhz_timings[] = {
+	{
+		.casl = 3,
+		.tDAL = 30000,
+		.tDPL = 15000,
+		.tRRD = 10000,
+		.tRCD = 20000,
+		.tRP = 15000,
+		.tRAS = 40000,
+		.tRC = 55000,
+		.tRFC = 140000,
+		.tXSR = 200000,
+
+		.tREF = 7800,
+
+		.tXP = 2,
+		.tCKE = 4,
+		.tWTR = 2
+	},
+};
+
 static const struct {
Quoted 8 lines

arch/arm/mach-omap2/sdram-nokia.c static const struct sdram_timings nokia_195dot2mhz_timings[] = { · line 137

Quoted 6 lines
arch/arm/mach-omap2/sdram-nokia.c +1 -0
 	long rate;
 	struct sdram_timings const *data;
 } nokia_timings[] = {
 	{ 83000000, nokia_166mhz_timings },
 	{ 97600000, nokia_97dot6mhz_timings },
+	{ 100000000, nokia_200mhz_timings },

Is that a typo above? Should it say nokia_100mhz_timings?

No, it's not a typo, same data is used. (Like 83/166 already in the table)

Quoted 9 lines

arch/arm/mach-omap2/sdram-nokia.c static const struct sdram_timings nokia_195dot2mhz_timings[] = { · line 142

Quoted 5 lines
arch/arm/mach-omap2/sdram-nokia.c +1 -0
 	{ 166000000, nokia_166mhz_timings },
 	{ 195200000, nokia_195dot2mhz_timings },
+	{ 200000000, nokia_200mhz_timings },
 };
 static struct omap_sdrc_params nokia_sdrc_params[ARRAY_SIZE(nokia_timings) + 1];

Regards,

Tony

A.

maintainer
#6 lore raw

PATCH 2/3 arm: mach-omap2: sdram-nokia: add 200 MHz memory timings info

Quoted 5 lines · Aaro Koskinen
Quoted 2 lines · Tony Lindgren

Is that a typo above? Should it say nokia_100mhz_timings?

No, it's not a typo, same data is used. (Like 83/166 already in the table)

OK thanks, applying this into board branch.

Tony

#7 lore raw

PATCH 3/3 arm: omap: add minimal support for Nokia RM-696

In reply to Aaro Koskinen

Add minimal support for Nokia RM-696 board.

---
 arch/arm/mach-omap2/Kconfig                  |    3 ++-
 arch/arm/mach-omap2/board-rm680.c            |   12 +++++++++++-
 arch/arm/plat-omap/include/plat/uncompress.h |    1 +
 3 files changed, 14 insertions(+), 2 deletions(-)
arch/arm/mach-omap2/Kconfig +2 -1
index e1293aa..73d86dc 100644
@@ -238,10 +238,11 @@ config MACH_NOKIA_N8X0
 	select MACH_NOKIA_N810_WIMAX
 
 config MACH_NOKIA_RM680
-	bool "Nokia RM-680 board"
+	bool "Nokia RM-680/696 board"
 	depends on ARCH_OMAP3
 	default y
 	select OMAP_PACKAGE_CBB
+	select MACH_NOKIA_RM696
 
 config MACH_NOKIA_RX51
 	bool "Nokia RX-51 board"
arch/arm/mach-omap2/board-rm680.c +11 -1
index 616fb39..a5bcc75 100644
@@ -1,5 +1,5 @@
 /*
- * Board support file for Nokia RM-680.
+ * Board support file for Nokia RM-680/696.
  *
  * Copyright (C) 2010 Nokia
  *
@@ -152,3 +152,13 @@ MACHINE_START(NOKIA_RM680, "Nokia RM-680 board")
 	.init_machine	= rm680_init,
 	.timer		= &omap3_timer,
 MACHINE_END
+
+MACHINE_START(NOKIA_RM696, "Nokia RM-696 board")
+	.atag_offset	= 0x100,
+	.reserve	= omap_reserve,
+	.map_io		= omap3_map_io,
+	.init_early	= omap3630_init_early,
+	.init_irq	= omap3_init_irq,
+	.init_machine	= rm680_init,
+	.timer		= &omap3_timer,
+MACHINE_END
arch/arm/plat-omap/include/plat/uncompress.h +1 -0
index 2f472e9..de3e35c 100644
@@ -160,6 +160,7 @@ static inline void __arch_decomp_setup(unsigned long arch_id)
 		DEBUG_LL_OMAP3(3, igep0020);
 		DEBUG_LL_OMAP3(3, igep0030);
 		DEBUG_LL_OMAP3(3, nokia_rm680);
+		DEBUG_LL_OMAP3(3, nokia_rm696);
 		DEBUG_LL_OMAP3(3, nokia_rx51);
 		DEBUG_LL_OMAP3(3, omap3517evm);
 		DEBUG_LL_OMAP3(3, omap3_beagle);
Signature · 1 line
1.7.2.5