From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751466AbbCUXpn (ORCPT ); Sat, 21 Mar 2015 19:45:43 -0400 Received: from mail.kmu-office.ch ([178.209.48.109]:43996 "EHLO mail.kmu-office.ch" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751159AbbCUXpk (ORCPT ); Sat, 21 Mar 2015 19:45:40 -0400 From: Stefan Agner To: rjui@broadcom.com, sbranden@broadcom.com, f.fainelli@gmail.com Cc: bcm@fixthebug.org, mporter@linaro.org, linux@arm.linux.org.uk, jonathar@broadcom.com, bcm-kernel-feedback-list@broadcom.com, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, llvmlinux@lists.linuxfoundation.org, Stefan Agner Subject: [PATCH] ARM: cygnus: fix const declaration bcm_cygnus_dt_compat Date: Sun, 22 Mar 2015 00:45:35 +0100 Message-Id: <1426981535-1800-1-git-send-email-stefan@agner.ch> X-Mailer: git-send-email 2.3.3 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The const declaration for char* is actually duplicated, however the array of strings is currently not constant. However, typically the dt_compat array is declared as const char *const. Follow that convention and also add the __initconst macro for constant initialization data. Signed-off-by: Stefan Agner --- This was uncovered by a LLVM/clang warning: arch/arm/mach-bcm/bcm_cygnus.c:16:19: warning: duplicate 'const' declaration specifier [-Wduplicate-decl-specifier] static const char const *bcm_cygnus_dt_compat[] = { ^~~~~~ 1 warning generated. arch/arm/mach-bcm/bcm_cygnus.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/mach-bcm/bcm_cygnus.c b/arch/arm/mach-bcm/bcm_cygnus.c index 30dc58b..7ae894c 100644 --- a/arch/arm/mach-bcm/bcm_cygnus.c +++ b/arch/arm/mach-bcm/bcm_cygnus.c @@ -13,7 +13,7 @@ #include -static const char const *bcm_cygnus_dt_compat[] = { +static const char * const bcm_cygnus_dt_compat[] __initconst = { "brcm,cygnus", NULL, }; -- 2.3.3