Skip to contentSkip to conversation

fou: Don't use const __read_mostly

PATCH Applied Andi Kleen 2 participants 2 messages Apr 8, 2015

Subsystems (2)
lore
Share & tools
lore

Andi Kleen

author
#0 lore raw

PATCH 1/1 fou: Don't use const __read_mostly

From: Andi Kleen <[email protected]>

const __read_mostly is a senseless combination. If something is already const it cannot be __read_mostly. Remove the bogus __read_mostly in the fou driver.

This fixes section conflicts with LTO.

---
 net/ipv4/fou.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
net/ipv4/fou.c +2 -2
index ff069f6..335e752 100644
@@ -771,12 +771,12 @@ EXPORT_SYMBOL(gue_build_header);
 
 #ifdef CONFIG_NET_FOU_IP_TUNNELS
 
-static const struct ip_tunnel_encap_ops __read_mostly fou_iptun_ops = {
+static const struct ip_tunnel_encap_ops fou_iptun_ops = {
 	.encap_hlen = fou_encap_hlen,
 	.build_header = fou_build_header,
 };
 
-static const struct ip_tunnel_encap_ops __read_mostly gue_iptun_ops = {
+static const struct ip_tunnel_encap_ops gue_iptun_ops = {
 	.encap_hlen = gue_encap_hlen,
 	.build_header = gue_build_header,
 };
Signature · 1 line
2.3.3
maintainer Applied
#1 lore raw

From: Andi Kleen <[email protected]>
Date: Wed, 8 Apr 2015 06:04:31 -0700

Quoted 9 lines

From: Andi Kleen <[email protected]>

const __read_mostly is a senseless combination. If something is already const it cannot be __read_mostly. Remove the bogus __read_mostly in the fou driver.

This fixes section conflicts with LTO.

Applied, thank you.