Skip to contentSkip to conversation

Fix compile on n800 if CONFIG_MACH_NOKIA_N810 is not set

PATCH In review [email protected] 2 participants 3 messages May 24, 2008

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

PATCH 1/1 Fix compile on n800 if CONFIG_MACH_NOKIA_N810 is not set

---
 arch/arm/mach-omap2/board-n800-camera.c |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)
arch/arm/mach-omap2/board-n800-camera.c +3 -2
index b525125..63bca1f 100644
@@ -221,9 +221,10 @@ static int tcm825x_power_set(int power)
 
 static const struct tcm825x_reg *tcm825x_default_regs(void)
 {
-	if (machine_is_nokia_n810())
+#ifdef CONFIG_MACH_NOKIA_N810	
+        if (machine_is_nokia_n810())
 		return tcm825x_regs_n810;
-
+#endif
 	return tcm825x_regs_n800;
 }
 
Signature · 1 line
1.5.5.1
#1 lore raw
Quoted 12 lines · On Sat, May 24, 2008 at 08:43:50PM +0200, [email protected] wrote:
---
 arch/arm/mach-omap2/board-n800-camera.c |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)
arch/arm/mach-omap2/board-n800-camera.c +0 -0
index b525125..63bca1f 100644
@@ -221,9 +221,10 @@ static int tcm825x_power_set(int power)
 

arch/arm/mach-omap2/board-n800-camera.c static int tcm825x_power_set(int power) · line 229

Quoted 10 lines
arch/arm/mach-omap2/board-n800-camera.c +3 -2
 static const struct tcm825x_reg *tcm825x_default_regs(void)
 {
-	if (machine_is_nokia_n810())
+#ifdef CONFIG_MACH_NOKIA_N810	
+        if (machine_is_nokia_n810())
 		return tcm825x_regs_n810;
-
+#endif
 	return tcm825x_regs_n800;
 }

I think the best way would be removing the ifdefs on tcm825x_regs_* Could you try it ?

Signature · 5 lines
Best Regards,

Felipe Balbi
[email protected]
http://blog.felipebalbi.com
author
#2 lore raw

Hi,

Quoted 13 lines · Felipe Balbi
Quoted 12 lines · On Sat, May 24, 2008 at 08:43:50PM +0200, [email protected] wrote:
---
 arch/arm/mach-omap2/board-n800-camera.c |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)
arch/arm/mach-omap2/board-n800-camera.c +0 -0
index b525125..63bca1f 100644
@@ -221,9 +221,10 @@ static int tcm825x_power_set(int power)
 
Quoted 13 lines

arch/arm/mach-omap2/board-n800-camera.c static int tcm825x_power_set(int power) · line 229

Quoted 10 lines
arch/arm/mach-omap2/board-n800-camera.c +3 -2
 static const struct tcm825x_reg *tcm825x_default_regs(void)
 {
-     if (machine_is_nokia_n810())
+#ifdef CONFIG_MACH_NOKIA_N810
+        if (machine_is_nokia_n810())
              return tcm825x_regs_n810;
-
+#endif
      return tcm825x_regs_n800;
 }

I think the best way would be removing the ifdefs on tcm825x_regs_* Could you try it ?

Yes you are right. Builds and and boots fine on a n800. I will send a new patch.

Quoted 8 lines

--
Best Regards,

Felipe Balbi
[email protected]
http://blog.felipebalbi.com

Signature · 1 line
Nick Loeve