Subject: Re: Do LKMs work *at*all* on powerpc platforms?
To: Todd Vierling <tv@wasabisystems.com>
From: Bill Studenmund <wrstuden@zembu.com>
List: port-macppc
Date: 08/15/2000 16:11:28
On Mon, 14 Aug 2000, Todd Vierling wrote:

> On Mon, 14 Aug 2000, Bill Studenmund wrote:
> 
> : and 2) getting it to work for built-ins (mainly memcpy).
> 
> gcc builtins are just that--built in.  They produce either inlined code (the
> most common case), or an in-compilation-unit subroutine that has no global
> symbol.  These should not be affected by the calling convention used across
> compilation units.

Well, gabriel rosenkoetter <gr@eclipsed.net> has had problems. He made
prototypes of all kernel functions with __attribute__ ((long-call)), and
made an lkm. He was still left with truncated references to memcpy - the
module still had it as an external symbol, and had used the too-small
branch option.

Here's a quote from a message where I was quoting him:

> Here's an attempted make load from my modified source:
> 
> achemar:misc/module# make load
> modload -o miscmod -emiscmod combined.o
> combined.o: In function `miscmod_handle':
> combined.o(.text+0x114): relocation truncated to fit: R_PPC_REL24 memcpy
> combined.o(.text+0x140): relocation truncated to fit: R_PPC_REL24 memcpy
> combined.o(.text+0x1f8): relocation truncated to fit: R_PPC_REL24 memcpy
> modload: can't link `combined.o' creating `miscmod' bound to 0xe9212000
> *** Error code 1

??

Take care,

Bill