mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: David Miller <davem@davemloft.net>
To: vst@vlnb.net
Cc: sparclinux@vger.kernel.org, simone.ricci@gmail.com,
	scst-devel@lists.sourceforge.net, linux-kernel@vger.kernel.org,
	Nick.Couchman@seakr.com
Subject: Re: Error "Unknown relocation: 36" on module load on Sparc
Date: Wed, 16 Jun 2010 13:35:40 -0700 (PDT)	[thread overview]
Message-ID: <20100616.133540.189696272.davem@davemloft.net> (raw)
In-Reply-To: <4C192085.2090404@vlnb.net>

From: Vladislav Bolkhovitin <vst@vlnb.net>
Date: Wed, 16 Jun 2010 23:05:41 +0400

> We in SCST project have a very strange problem on Sparc. Our main
> module scst.ko, if built as a module out of the kernel tree, can't be
> loaded and "modprobe scst" returns:
> 
> FATAL: Error inserting scst
> (/lib/modules/2.6.26-2-sparc64/extra/scst.ko): Invalid module format
> 
> The following message is immediately spit out by the kernel:
> [ 1686.676534] module scst: Unknown relocation: 36

You're building the module with incorrect compiler flags, in
particular somehow the "-mcmodel=medlow" option is not getting passed
into the module build and thus the wrong code model is being used to
build the module.

There are a host of other sparc64 specific compiler options that must
be present for a correct build as well.  The only way to get it done
correctly is to properly inherit the option settings made by
arch/sparc/Makefile and friends in the kernel tree.

  parent reply	other threads:[~2010-06-16 20:35 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <AANLkTimuv7nOlcGFxqPZlwcAjLmFMiLAvbA5O7F32Wbg@mail.gmail.com>
2010-06-16 19:05 ` Vladislav Bolkhovitin
2010-06-16 19:22   ` Kyle McMartin
2010-06-16 20:38     ` David Miller
2010-06-16 20:40       ` Kyle McMartin
2010-06-16 20:35   ` David Miller [this message]
2010-06-22 19:07     ` Vladislav Bolkhovitin
2010-06-22 19:35       ` Sam Ravnborg
2010-06-22 21:17         ` David Miller
2010-06-22 21:16       ` David Miller
2010-06-16 19:08 ` How to printk/sprintf uint64_t on Sparc without format and argument types mismatch Vladislav Bolkhovitin
2010-06-16 19:29   ` Kyle McMartin
2010-06-16 20:36   ` David Miller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20100616.133540.189696272.davem@davemloft.net \
    --to=davem@davemloft.net \
    --cc=Nick.Couchman@seakr.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=scst-devel@lists.sourceforge.net \
    --cc=simone.ricci@gmail.com \
    --cc=sparclinux@vger.kernel.org \
    --cc=vst@vlnb.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome