From patchwork Tue May 17 13:06:33 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sekhar Nori X-Patchwork-Id: 791542 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id p4HD6o7f024749 for ; Tue, 17 May 2011 13:06:51 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754930Ab1EQNGt (ORCPT ); Tue, 17 May 2011 09:06:49 -0400 Received: from devils.ext.ti.com ([198.47.26.153]:43764 "EHLO devils.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754725Ab1EQNGt convert rfc822-to-8bit (ORCPT ); Tue, 17 May 2011 09:06:49 -0400 Received: from dbdp20.itg.ti.com ([172.24.170.38]) by devils.ext.ti.com (8.13.7/8.13.7) with ESMTP id p4HD6cmr001256 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 17 May 2011 08:06:40 -0500 Received: from dbde70.ent.ti.com (localhost [127.0.0.1]) by dbdp20.itg.ti.com (8.13.8/8.13.8) with ESMTP id p4HD6XSJ007246; Tue, 17 May 2011 18:36:34 +0530 (IST) Received: from dbde02.ent.ti.com ([172.24.170.145]) by dbde70.ent.ti.com ([172.24.170.148]) with mapi; Tue, 17 May 2011 18:36:33 +0530 From: "Nori, Sekhar" To: Russell King - ARM Linux , "Hilman, Kevin" , Tony Lindgren CC: "davinci-linux-open-source@linux.davincidsp.com" , "linux-omap@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" Date: Tue, 17 May 2011 18:36:33 +0530 Subject: RE: [RFC PATCH v3] Consolidate SRAM support Thread-Topic: [RFC PATCH v3] Consolidate SRAM support Thread-Index: AcwQzHRWD/EftHr+SOeSsh0CoYWQAwDxVUHA Message-ID: References: <20110415130607.GM1611@n2100.arm.linux.org.uk> <20110512174546.GB8633@n2100.arm.linux.org.uk> In-Reply-To: <20110512174546.GB8633@n2100.arm.linux.org.uk> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: acceptlanguage: en-US MIME-Version: 1.0 Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Tue, 17 May 2011 13:06:51 +0000 (UTC) Hi Russell, On Thu, May 12, 2011 at 23:15:46, Russell King - ARM Linux wrote: > diff --git a/arch/arm/mach-davinci/pm.c b/arch/arm/mach-davinci/pm.c > index 1bd73a0..c2f9767 100644 > --- a/arch/arm/mach-davinci/pm.c > +++ b/arch/arm/mach-davinci/pm.c [...] > @@ -123,14 +118,14 @@ static int __init davinci_pm_probe(struct platform_device *pdev) > return -ENOENT; > } > > - davinci_sram_suspend = sram_alloc(davinci_cpu_suspend_sz, NULL); > - if (!davinci_sram_suspend) { > + davinci_sram_suspend_mem = pv_pool_alloc(davinci_pv_pool, > + davinci_cpu_suspend_sz, NULL); > + if (!davinci_sram_suspend_mem) { > dev_err(&pdev->dev, "cannot allocate SRAM memory\n"); > return -ENOMEM; > } > - > - davinci_sram_push(davinci_sram_suspend, davinci_cpu_suspend, > - davinci_cpu_suspend_sz); > + davinci_sram_suspend = fncpy(davinci_sram_suspend_mem, > + davinci_cpu_suspend, davinci_cpu_suspend_sz); This gave these build errors: arch/arm/mach-davinci/pm.c: In function 'davinci_pm_probe': arch/arm/mach-davinci/pm.c:127: error: lvalue required in asm statement arch/arm/mach-davinci/pm.c:127: error: invalid lvalue in asm output 0 make[1]: *** [arch/arm/mach-davinci/pm.o] Error 1 Replacing davinci_cpu_suspend with &davinci_cpu_suspend fixed the issue. With that change done, tested suspend-to-RAM on DA850 platform. Also tested audio driver on DM365 platform with IRAM buffers enabled. Can you also fold the following patch in? Without this the kernel panics when suspend-to-RAM is enabled. Thanks, Sekhar --- To unsubscribe from this list: send the line "unsubscribe linux-omap" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/arch/arm/mach-davinci/sleep.S b/arch/arm/mach-davinci/sleep.S index fb5e72b..2cef533 100644 --- a/arch/arm/mach-davinci/sleep.S +++ b/arch/arm/mach-davinci/sleep.S @@ -37,6 +37,7 @@ #define DEEPSLEEP_SLEEPENABLE_BIT BIT(31) .text + .align 3 /* * Move DaVinci into deep sleep state *