[parisc-linux] Re: gcc-3.2 -> gcc-3.3 transition on hppa
mszick@goquest.com
mszick@goquest.com
Sun, 16 Mar 2003 16:52:19 -0600
On Friday 14 March 2003 07:17 am, Matthew Wilcox wrote:
> On Fri, Mar 14, 2003 at 01:48:59PM +0100, Joel Soete wrote:
> > net/network.o(.text.rtnetlink_rcv+0x84): In function `rtnetlink_rcv':
> > : undefined reference to `rtnetlink_rcv_skb'
> >
> > make: *** [vmlinux] Error 1
> >
> > (with gcc-3.2 with same src && same .config there was no pb)
>
> You've just hit the gcc thinks it's smarter than you are bug.
>
> net/core/rtnetlink.c:extern __inline__ int rtnetlink_rcv_skb(struct sk_buff
> *skb)
>
> gcc 3.3 decides to not believe you want this function inlined. probably
> the right fix for this is to make this function static inline (you can
> drop the `__' around inline, it's not necessary). This is also the case
> for linux 2.5.
Stolen from the GCC thread on 3.x.x inlining...
- - - - GCC - - - - -
For the record, the kernel doesn't need this any more. Go check 2.5;
new versions of <linux/compiler.h> contain this line:
#define inline __inline__ __attribute__((always_inline))
- - - - - - - - - - - -
That forces GCC to ignore its changed inline metrics and simply inline
the function.
Mike