From mboxrd@z Thu Jan 1 00:00:00 1970 From: Tomasz Figa Subject: Re: [PATCH 3/9] clk: samsung: exynos4: Move suspend/resume handling to SoC driver Date: Thu, 17 Oct 2013 16:16:29 +0200 Message-ID: <1821539.dxQ3vs372W@amdc1227> References: <1381921698-5060-1-git-send-email-t.figa@samsung.com> <1381921698-5060-4-git-send-email-t.figa@samsung.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7Bit Return-path: Received: from mailout4.w1.samsung.com ([210.118.77.14]:31369 "EHLO mailout4.w1.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755703Ab3JQOQd (ORCPT ); Thu, 17 Oct 2013 10:16:33 -0400 Received: from eucpsbgm2.samsung.com (unknown [203.254.199.245]) by mailout4.w1.samsung.com (Oracle Communications Messaging Server 7u4-24.01(7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0MUT00M7FGYU26B0@mailout4.w1.samsung.com> for linux-samsung-soc@vger.kernel.org; Thu, 17 Oct 2013 15:16:31 +0100 (BST) In-reply-to: Sender: linux-samsung-soc-owner@vger.kernel.org List-Id: linux-samsung-soc@vger.kernel.org To: Yadwinder Singh Brar Cc: linux-samsung-soc , "linux-arm-kernel@lists.infradead.org" , Kukjin Kim , Mike Turquette , Heiko Stuebner , Kyungmin Park , Rahul Sharma , Thomas Abraham , Tushar Behera , Yadwinder Singh Brar On Thursday 17 of October 2013 19:12:08 Yadwinder Singh Brar wrote: > Hi Tomasz, > > [ ... ] > > /* > > * list of controller registers to be saved and restored during a > > * suspend/resume cycle. > > @@ -288,6 +299,70 @@ static unsigned long exynos4_clk_regs[] __initdata = { > > GATE_IP_CPU, > > }; > > > > +static int exynos4_clk_suspend(void) > > +{ > > + samsung_clk_save(reg_base, exynos4_save_common, > > + ARRAY_SIZE(exynos4_clk_regs)); > > a doubt here, Is sizeof(exynos4_clk_regs) works with > exynos4_clk_regs[] as __initdata ? Hmm, this is a compile time constant, so I don't see why it couldn't work. > > + > > + if (exynos4_soc == EXYNOS4210) > > + samsung_clk_save(reg_base, exynos4_save_soc, > > + ARRAY_SIZE(exynos4210_clk_save)); > > [ ... ] > > +static void exynos4_clk_sleep_init(void) > > I think, this fuction can be placed in __init section. That's right. Thanks for pointing this out. Best regards, Tomasz