[PATCH 3/5] glamo-core: initialize engine states as disabled

Thibaut Girka thib at sitedethib.com
Fri Jun 25 20:17:18 CEST 2010


This should fix random init failures such as white screen on boot.
---
 drivers/mfd/glamo-core.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diff --git a/drivers/mfd/glamo-core.c b/drivers/mfd/glamo-core.c
index 2ee8842..3c40fb6 100644
--- a/drivers/mfd/glamo-core.c
+++ b/drivers/mfd/glamo-core.c
@@ -911,7 +911,7 @@ static int __devinit glamo_supported(struct glamo_core *glamo)
 
 static int __devinit glamo_probe(struct platform_device *pdev)
 {
-	int ret = 0, irq, irq_base;
+	int ret = 0, n, irq, irq_base;
 	struct glamo_core *glamo;
 	struct resource *mem;
 
@@ -919,6 +919,9 @@ static int __devinit glamo_probe(struct platform_device *pdev)
 	if (!glamo)
 		return -ENOMEM;
 
+	for (n = 0; n < __NUM_GLAMO_ENGINES; n++)
+		glamo->engine_state[n] = GLAMO_ENGINE_DISABLED;
+
 	spin_lock_init(&glamo->lock);
 
 	glamo->pdev = pdev;
-- 
1.7.1




More information about the openmoko-kernel mailing list