Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756216Ab2HVMH3 (ORCPT ); Wed, 22 Aug 2012 08:07:29 -0400 Received: from hqemgate03.nvidia.com ([216.228.121.140]:5547 "EHLO hqemgate03.nvidia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753556Ab2HVMHZ convert rfc822-to-8bit (ORCPT ); Wed, 22 Aug 2012 08:07:25 -0400 X-PGP-Universal: processed; by hqnvupgp05.nvidia.com on Wed, 22 Aug 2012 05:07:20 -0700 From: Bill Huang To: "'Thierry Reding'" CC: "sameo@linux.intel.com" , "grant.likely@secretlab.ca" , "rob.herring@calxeda.com" , "rob@landley.net" , "broonie@opensource.wolfsonmicro.com" , Laxman Dewangan , "swarren@wwwdotorg.org" , Xin Xie , "lrg@slimlogic.co.uk" , "jhovold@gmail.com" , "kyle.manna@fuel7.com" , Rhyland Klein , "devicetree-discuss@lists.ozlabs.org" , "linux-doc@vger.kernel.org" , "linux-kernel@vger.kernel.org" Date: Wed, 22 Aug 2012 20:07:15 +0800 Subject: RE: [PATCH v2 1/2] mfd: dt: tps6586x: Add power off control Thread-Topic: [PATCH v2 1/2] mfd: dt: tps6586x: Add power off control Thread-Index: Ac1+x8gQ0fYAjYtCRMmSCzgin5mspQBlGAeQ Message-ID: References: <1345424876-4365-1-git-send-email-bilhuang@nvidia.com> <1345424876-4365-2-git-send-email-bilhuang@nvidia.com> <20120820113423.GA5996@avionic-0098.mockup.avionic-design.de> In-Reply-To: <20120820113423.GA5996@avionic-0098.mockup.avionic-design.de> Accept-Language: zh-TW, en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: acceptlanguage: zh-TW, en-US MIME-Version: 1.0 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 8BIT Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 4054 Lines: 69 nvpublic > On Sun, Aug 19, 2012 at 06:07:55PM -0700, Bill Huang wrote: > > Add DT property "ti,system-power-controller" telling whether or not > > this pmic is in charge of controlling the system power, so the power > > off routine can be hooked up to system call "pm_power_off". > > > > Based on the work by: > > Dan Willemsen > > > > Signed-off-by: Bill Huang > > Tested-by: Stephen Warren > > --- > > .../devicetree/bindings/regulator/tps6586x.txt | 6 ++++++ > > drivers/mfd/tps6586x.c | 19 +++++++++++++++++++ > > include/linux/mfd/tps6586x.h | 1 + > > 3 files changed, 26 insertions(+), 0 deletions(-) > > Hi, > > I've seen the following while trying this patch applied on top of next-20120817: > > [ 40.581151] Power down. > [ 41.583160] ------------[ cut here ]------------ > [ 41.587784] WARNING: at /home/thierry.reding/src/kernel/linux-ipmp.git/drivers/i2c/busses/i2c- > tegra.c:525 tegra_i2c_xfer+0x21c/0x29c() > [ 41.599850] Modules linked in: > [ 41.602927] [] (unwind_backtrace+0x0/0xf8) from [] > (warn_slowpath_common+0x4c/0x64) > [ 41.612304] [] (warn_slowpath_common+0x4c/0x64) from [] > (warn_slowpath_null+0x1c/0x24) > [ 41.621947] [] (warn_slowpath_null+0x1c/0x24) from [] > (tegra_i2c_xfer+0x21c/0x29c) > [ 41.631244] [] (tegra_i2c_xfer+0x21c/0x29c) from [] (__i2c_transfer+0x44/0x80) > [ 41.640192] [] (__i2c_transfer+0x44/0x80) from [] (i2c_transfer+0x7c/0xb8) > [ 41.648796] [] (i2c_transfer+0x7c/0xb8) from [] (regmap_i2c_read+0x48/0x64) > [ 41.657485] [] (regmap_i2c_read+0x48/0x64) from [] (_regmap_raw_read+0x90/0x98) > [ 41.666518] [] (_regmap_raw_read+0x90/0x98) from [] (_regmap_read+0x50/0xa8) > [ 41.675290] [] (_regmap_read+0x50/0xa8) from [] (_regmap_update_bits+0x24/0x64) > [ 41.684322] [] (_regmap_update_bits+0x24/0x64) from [] > (regmap_update_bits+0x3c/0x58) > [ 41.693885] [] (regmap_update_bits+0x3c/0x58) from [] > (tps6586x_power_off+0x18/0x38) > [ 41.703362] [] (tps6586x_power_off+0x18/0x38) from [] > (machine_power_off+0x1c/0x24) > [ 41.712749] [] (machine_power_off+0x1c/0x24) from [] (sys_reboot+0x138/0x1b0) > [ 41.721612] [] (sys_reboot+0x138/0x1b0) from [] (ret_fast_syscall+0x0/0x30) > [ 41.730293] ---[ end trace 9af366974fefa459 ]--- > [ 41.734906] tegra-i2c tegra-i2c.3: i2c transfer timed out > [ 41.740689] Kernel panic - not syncing: Attempted to kill init! exitcode=0x00000000 > [ 41.740689] > [ 41.749823] [] (unwind_backtrace+0x0/0xf8) from [] (panic+0x8c/0x1d8) > [ 41.757993] [] (panic+0x8c/0x1d8) from [] (do_exit+0x694/0x750) > [ 41.765636] [] (do_exit+0x694/0x750) from [] (do_group_exit+0x3c/0xb0) > [ 41.773884] [] (do_group_exit+0x3c/0xb0) from [] (__wake_up_parent+0x0/0x18) Thanks Thierry, I can repro this on Tegra20 inconsistently and found, if current cpu is not cpu0 when doing "machine_shutdown" (it will call "smp_send_stop"), i2c controller will failed to do any transaction (looks like gic interrupt will be disabled), I'll debug further to find out the root cause. By the way, Tegra30 is good since it will always be cpu0 when doing "machine_shutdown", I still don't know why it makes the difference against Tegra20 since I'm not familiar with those cpu stuffs and what make it behave differently, I'll study a bit, thanks. > > Thierry > > * Unknown Key > * 0x7F3EB3A1 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/