Re: [2.6 patch] fs/buffer.c:init_buffer() mustn't be inline

From: Adrian Bunk
Date: Mon Apr 28 2008 - 12:49:03 EST


On Mon, Apr 28, 2008 at 09:01:42AM -0700, Linus Torvalds wrote:
>
>
> On Mon, 28 Apr 2008, Adrian Bunk wrote:
> <
> > This patch fixes the following build error with UML and gcc 4.3:
> >
> > <-- snip -->
> >
> > ...
> > CC fs/buffer.o
> > /home/bunk/linux/kernel-2.6/git/linux-2.6/fs/buffer.c: In function âinit_page_buffersâ:
> > /home/bunk/linux/kernel-2.6/git/linux-2.6/fs/buffer.c:51: sorry, unimplemented: inlining failed in call to âinit_bufferâ: function body not available
> > /home/bunk/linux/kernel-2.6/git/linux-2.6/fs/buffer.c:1007: sorry, unimplemented: called from here
> > make[2]: *** [fs/buffer.o] Error 1
>
> Can somebody tell why this is not a gcc bug?

It is a gcc bug.

But having a global function marked as extern was already questionable,
and all assumptions an "inline" would always inline the code are anyway
now broken in your tree.

So let's work around a gcc bug by fixing the kernel...

> Linus

cu
Adrian

--

"Is there not promise of rain?" Ling Tan asked suddenly out
of the darkness. There had been need of rain for many days.
"Only a promise," Lao Er said.
Pearl S. Buck - Dragon Seed

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/