From patchwork Wed Oct 14 21:02:52 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jean Delvare X-Patchwork-Id: 36027 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from bilbo.ozlabs.org (localhost [127.0.0.1]) by ozlabs.org (Postfix) with ESMTP id 9CEA3B7DC1 for ; Thu, 15 Oct 2009 08:03:03 +1100 (EST) Received: by ozlabs.org (Postfix) id 4833FB7043; Thu, 15 Oct 2009 08:02:57 +1100 (EST) Delivered-To: linuxppc-dev@ozlabs.org Received: from bamako.nerim.net (bamako.nerim.net [62.4.17.28]) by ozlabs.org (Postfix) with ESMTP id F1BC2B7B69 for ; Thu, 15 Oct 2009 08:02:55 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by bamako.nerim.net (Postfix) with ESMTP id 35E2339DCB9; Wed, 14 Oct 2009 23:02:51 +0200 (CEST) X-Virus-Scanned: amavisd-new at nerim.net Received: from bamako.nerim.net ([127.0.0.1]) by localhost (bamako.nerim.net [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 3UCBPKMrX5U8; Wed, 14 Oct 2009 23:02:50 +0200 (CEST) Received: from hyperion.delvare (jdelvare.pck.nerim.net [62.212.121.182]) by bamako.nerim.net (Postfix) with ESMTP id 3C5FF39DC38; Wed, 14 Oct 2009 23:02:50 +0200 (CEST) Date: Wed, 14 Oct 2009 23:02:52 +0200 From: Jean Delvare To: Tim Shepard Subject: Re: i2c-powermac fails Message-ID: <20091014230252.0d0cba8d@hyperion.delvare> In-Reply-To: <20091013114948.03608b7f@hyperion.delvare> References: <20091013112304.74083fd1@hyperion.delvare> <1255426348.2192.187.camel@pasglop> <20091013114948.03608b7f@hyperion.delvare> X-Mailer: Claws Mail 3.5.0 (GTK+ 2.14.4; i586-suse-linux-gnu) Mime-Version: 1.0 Cc: Paul Mackerras , linuxppc-dev@ozlabs.org X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org Hi all, On Tue, 13 Oct 2009 11:49:48 +0200, Jean Delvare wrote: > I2C bus being setup too fast sounds more likely. It might be worth > adding an arbitrary delay after initialization, just to see if it > helps. Not sure where though, as I'm not familiar with the Powermac > initialization steps. Maybe right before i2c_add_adapter() in > i2c_powermac_probe? Tim, can you please give a try to this patch? Obviously your machine will take 5 additional seconds to boot, and this isn't meant as a real fix, but if it helps, this will be an interesting hint for further debugging attempts. --- kernel32.orig/drivers/macintosh/therm_adt746x.c +++ kernel32/drivers/macintosh/therm_adt746x.c @@ -380,6 +380,7 @@ static int probe_thermostat(struct i2c_c if (thermostat) return 0; + msleep(5000); th = kzalloc(sizeof(struct thermostat), GFP_KERNEL); if (!th) return -ENOMEM;