Skip to contentSkip to conversation

net-2.6.24 compile breakage: error: 'ipgre_header' undeclared

PATCH Applied Kok, Auke 3 participants 4 messages Oct 4, 2007 – Oct 5, 2007

Subsystems (3)
lore
Share & tools
lore

Kok, Auke

author
#0 lore raw

I'm getting this on net-2.6.24 today:

CC [M] net/ipv4/ip_gre.o
net/ipv4/ip_gre.c:1135: error: 'ipgre_header' undeclared here (not in a function) make[2]: *** [net/ipv4/ip_gre.o] Error 1
make[1]: *** [net/ipv4] Error 2
make[1]: *** Waiting for unfinished jobs....

the git log says sch touched it last:

commit 2c1d70cafc188843ae15a1a504a0a3c9f3c0318d

Author: Stephen Hemminger <[email protected]>
Date:   Wed Sep 26 22:19:06 2007 -0700

[NET]: Move hardware header operations out of netdevice.

Since hardware header operations are part of the protocol class not the device instance, make them into a separate object and save memory.

anyone seen this? let me know if you want my .config.

PS: No, I didn't touch anything besides e1000e in that tree ;)

Auke

maintainer
#1 lore raw

From: "Kok, Auke" <[email protected]>
Date: Thu, 04 Oct 2007 14:49:10 -0700

Quoted 10 lines

I'm getting this on net-2.6.24 today:

CC [M] net/ipv4/ip_gre.o
net/ipv4/ip_gre.c:1135: error: 'ipgre_header' undeclared here (not in a function) make[2]: *** [net/ipv4/ip_gre.o] Error 1
make[1]: *** [net/ipv4] Error 2
make[1]: *** Waiting for unfinished jobs....

the git log says sch touched it last:

Please us Stephen's current email address if you really want to reach him :) It was even mentioned in the commit sign off. I've fixed it up in the CC:

Quoted 8 lines

[NET]: Move hardware header operations out of netdevice.

Since hardware header operations are part of the protocol class not the device instance, make them into a separate object and save memory.

Stephen, we need to handle the case where NET_IPGRE_BROADCAST is not enabled. ipgre_header() is only compiled in when that is set, but you reference it unconditionally.

#2 lore raw

PATCH 1/1 ip_gre: build fix

IPGRE only uses header_ops in the case of CONFIG_NET_IPGRE_BROADCAST.

net/ipv4/ip_gre.c +4 -4
@@ -1092,6 +1092,10 @@ static int ipgre_header(struct sk_buff *
 	return -t->hlen;
 }
 
+static const struct header_ops ipgre_header_ops = {
+	.create	= ipgre_header,
+};
+
 static int ipgre_open(struct net_device *dev)
 {
 	struct ip_tunnel *t = netdev_priv(dev);
@@ -1131,10 +1135,6 @@ static int ipgre_close(struct net_device
 
 #endif
 
-static const struct header_ops ipgre_header_ops = {
-	.create	= ipgre_header,
-};
-
 static void ipgre_tunnel_setup(struct net_device *dev)
 {
 	dev->uninit		= ipgre_tunnel_uninit;