linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: arnd@arndb.de (Arnd Bergmann)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 2/3] ARM: orion: mark orion_ge00_mvmdio_bus_name as const
Date: Tue, 20 Feb 2018 17:24:51 +0100	[thread overview]
Message-ID: <20180220162519.1498223-2-arnd@arndb.de> (raw)
In-Reply-To: <20180220162519.1498223-1-arnd@arndb.de>

A section type mismatch warning shows up when building with LTO,
since orion_ge00_mvmdio_bus_name was put in __initconst but not marked
const itself:

include/linux/of.h: In function 'spear_setup_of_timer':
arch/arm/mach-spear/time.c:207:34: error: 'timer_of_match' causes a section type conflict with 'orion_ge00_mvmdio_bus_name'
 static const struct of_device_id timer_of_match[] __initconst = {
                                  ^
arch/arm/plat-orion/common.c:475:32: note: 'orion_ge00_mvmdio_bus_name' was declared here
 static __initconst const char *orion_ge00_mvmdio_bus_name = "orion-mii";
                                ^

This marks it const as well.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 arch/arm/plat-orion/common.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/plat-orion/common.c b/arch/arm/plat-orion/common.c
index aff6994950ba..4e1d8270537c 100644
--- a/arch/arm/plat-orion/common.c
+++ b/arch/arm/plat-orion/common.c
@@ -472,7 +472,7 @@ void __init orion_ge11_init(struct mv643xx_eth_platform_data *eth_data,
 /*****************************************************************************
  * Ethernet switch
  ****************************************************************************/
-static __initconst const char *orion_ge00_mvmdio_bus_name = "orion-mii";
+static __initconst const char *const orion_ge00_mvmdio_bus_name = "orion-mii";
 static __initdata struct mdio_board_info
 		  orion_ge00_switch_board_info;
 
-- 
2.9.0

  reply	other threads:[~2018-02-20 16:24 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-02-20 16:24 [PATCH 1/3] ARM: clps711x: mark clps711x_compat as const Arnd Bergmann
2018-02-20 16:24 ` Arnd Bergmann [this message]
2018-02-21  3:49   ` [PATCH 2/3] ARM: orion: mark orion_ge00_mvmdio_bus_name " Andrew Lunn
2018-02-21 11:34     ` Arnd Bergmann
2018-02-20 16:24 ` [PATCH 3/3] ARM: davinci: mark spi_board_info arrays " Arnd Bergmann
2018-02-22 16:43   ` Arnd Bergmann
2018-02-23 10:00     ` Sekhar Nori
2018-02-22 16:43 ` [PATCH 1/3] ARM: clps711x: mark clps711x_compat " Arnd Bergmann

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20180220162519.1498223-2-arnd@arndb.de \
    --to=arnd@arndb.de \
    --cc=linux-arm-kernel@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).