From patchwork Fri Jan 1 13:42:52 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 7939201 Return-Path: X-Original-To: patchwork-linux-rockchip@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 54871BEEE5 for ; Fri, 1 Jan 2016 13:43:41 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 77D41205E5 for ; Fri, 1 Jan 2016 13:43:40 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id A1868205E1 for ; Fri, 1 Jan 2016 13:43:39 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1aEzzW-0005Pw-Ed; Fri, 01 Jan 2016 13:43:38 +0000 Received: from mout.kundenserver.de ([212.227.126.130]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1aEzzL-0005HJ-Ny; Fri, 01 Jan 2016 13:43:28 +0000 Received: from wuerfel.localnet ([134.3.118.24]) by mrelayeu.kundenserver.de (mreue003) with ESMTPSA (Nemesis) id 0LlJ1m-1Ze14D0gWU-00b3rh; Fri, 01 Jan 2016 14:42:55 +0100 From: Arnd Bergmann To: Michael Turquette , Heiko Stuebner Subject: [PATCH] [BUG] clk: rockchip: don't mark clock names as initconst Date: Fri, 01 Jan 2016 14:42:52 +0100 Message-ID: <2791943.MBZ53mI7Gp@wuerfel> User-Agent: KMail/4.11.5 (Linux/3.16.0-10-generic; KDE/4.11.5; x86_64; ; ) MIME-Version: 1.0 X-Provags-ID: V03:K0:0y7IZzECJOHuoQc4E+aaRY/qF07g8/o3wsHCO1gClfx4WPbahPj iKjeD680vkCRXqbcuYUlJYE0bbqF4UeqcB1Oig7fbQgEf+iOeph16n6Tg+1I5l5IqZOfxG2 dGnxNB6zpvIJrGQ7f/ommy2YUL8/dWdslL5Xp2ut1zQUMI9Sfy6viI2i4C1hd+GjFnsiPjp kbCN6Po3+WXNLsZMqaPTA== X-UI-Out-Filterresults: notjunk:1; V01:K0:0zZKlRdmDV8=:I6yJ9aY+DAHPnd2BtoJRbK r/JR4msCLeyV7dnXTB6r9SZI/BGCnHjS7MeThCHisut/wgRweTtOq+mmIXCJHsJ1xPR96iDsD qkzRSPJJYNU4zww9qsCUZMMlgL4FFwP6HoYRdJgzX++eQLL0gbxP5wi75UtqQ/G4CsbM9Nr0a aNF4m3MIopDeh7TAaJd8m/VTVJFn17qPrprESSC6BYQR+LDINLpjHV0vNsAGyM36tkZ7jF11O mLrIhrey2/Ui/pHHrYEe9EvyOtr+Fr/M7RvbNvduC9ak76O48MrEFFMXBwpUlQUDAM5czJq97 IUeM8YNTp3HFKY0oVeKz5d9u2E9fUjNr9GrAcBkF71pBMGNRdoS5TlBffq87TDyN4j1md3USI CmUz9XkD8v/2OFHa9vUTsulG/31uCAlSdFeZ+05NeCRDmmVCx0a882k0dZGgY64rSNeBqUrHc dXyErg/hQkQzyyEzNx8NdmVT5I+tK2l+PmvFLBYelpW/F8sxvDM1tOnsXyHSgVc1CljoTeR2z QVdneHp+A62nTiFZRCwuj3QQoYuquXrUBYTf/EhVVcVvYbCIqz2YZN8ziEZRmvIudT93SZj0b rr6pW1SalLadgc9bDOUfUPM/Clw/8Fr8e2jHPloNDF363l3PUA7y9M7pefB+fPUwTNb9INMLN pH6D2cZDh3HCySJ9yOKVxg9ZLfrtlpU3sdm40mD2jebArKwcn21ObZxnYTejd77BppIlsjB5d Yn04Dg1TPvzoS2i1 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20160101_054328_244264_B90F3708 X-CRM114-Status: GOOD ( 10.84 ) X-Spam-Score: -1.9 (-) X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Stephen Boyd , linux-kernel@vger.kernel.org, linux-rockchip@lists.infradead.org, Sjoerd Simons , linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The latest changes to the rockchip clk implementation cause tons of warnings and/or errors (depending on the configuration): WARNING: vmlinux.o(.data+0x125394): Section mismatch in reference from the variable __compound_literal.125 to the (unknown reference) .init.rodata:(unknown) The reason is a compount literal in a macro that refers to an object in the .init.rodata section: #define COMPOSITE_FRACMUX(_id, cname, pname, f, mo, df, go, gs, gf, ch) \ { \ ... .child = &(struct rockchip_clk_branch)ch, \ } 'ch' here is placed in .data, and I could find no way to override that using an attribute or pragma because there is no identifier associated with it. This patch avoids the warning by placing the names in .rodata rather than .init.rodata. However, it is not an ideal solution because we really want all those data structures to be discarded along with the initdata. Signed-off-by: Arnd Bergmann Fixes: 8ca1ca8f6039 ("clk: rockchip: handle mux dependency of fractional dividers") diff --git a/drivers/clk/rockchip/clk.h b/drivers/clk/rockchip/clk.h index 3f71ee5d1bc9..5cadf5e3fb16 100644 --- a/drivers/clk/rockchip/clk.h +++ b/drivers/clk/rockchip/clk.h @@ -244,7 +244,7 @@ struct clk *rockchip_clk_register_inverter(const char *name, void __iomem *reg, int shift, int flags, spinlock_t *lock); -#define PNAME(x) static const char *const x[] __initconst +#define PNAME(x) static const char *const x[] enum rockchip_clk_branch_type { branch_composite,