Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1759698Ab1FXPoW (ORCPT ); Fri, 24 Jun 2011 11:44:22 -0400 Received: from arroyo.ext.ti.com ([192.94.94.40]:60678 "EHLO arroyo.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754280Ab1FXPoS convert rfc822-to-8bit (ORCPT ); Fri, 24 Jun 2011 11:44:18 -0400 From: "Nori, Sekhar" To: Sergei Shtylyov , "Grosen, Mark" CC: Ohad Ben-Cohen , davinci-linux-open-source , Arnd Bergmann , Brian Swetland , Rusty Russell , "linux-kernel@vger.kernel.org" , Grant Likely , "akpm@linux-foundation.org" , "linux-omap@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" Date: Fri, 24 Jun 2011 21:13:49 +0530 Subject: RE: [RFC 5/8] remoteproc: add davinci implementation Thread-Topic: [RFC 5/8] remoteproc: add davinci implementation Thread-Index: AcwygZv0mvORrL7JTyCtPxMg8s/QwAAAcl8w Message-ID: References: <1308640714-17961-1-git-send-email-ohad@wizery.com> <1308640714-17961-6-git-send-email-ohad@wizery.com> <4E035B78.3080200@mvista.com> <4E04A9AE.3030801@mvista.com> In-Reply-To: <4E04A9AE.3030801@mvista.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: acceptlanguage: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 8BIT MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1778 Lines: 49 Hi Mark, On Fri, Jun 24, 2011 at 20:43:50, Sergei Shtylyov wrote: > >>> + rproc->priv = dsp_clk; > >>> + > >>> + psc_base = ioremap(soc_info->psc_bases[0], SZ_4K); > >>> + > >>> + /* insure local reset is asserted before writing start address */ > >>> + __raw_writel(NEXT_ENABLED, psc_base + MDCTL + 4 * > >> DA8XX_LPSC0_GEM); > >>> + > >>> + __raw_writel(bootaddr, DA8XX_SYSCFG0_VIRT(HOST1CFG)); > > >> DA8XX_SYSCFG0_VIRT() is not supposed to be used outside mach-davinci. The > >> variable it refers is not exported, so driver module won't work. > > > Ooops, I clearly did not build this as a module. Suggestion how to fix this? > > Using the normal ioremap() of SYSCFG0 space, I suppose. Since procedure to set the boot address varies across DaVinci platforms, you could have a callback populated in platform data which will be implemented differently for original DaVinci and DA8xx devices. Also, all PSC accesses are better off going through clock framework to ensure proper locking and modularity. To assert/de-assert local reset when enabling or disabling PSC, you could use a flag in the clock structure to indicate the need for this. This way, if there is any other module needing a local reset, it can just define the same flag. Similarly, if the DSP does not need a local reset on a particular platform, that platform can simply skip the flag. This can be done in a manner similar to how the support for a forced transition PSC was added here: https://patchwork.kernel.org/patch/662941/ Thanks, Sekhar -- 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/