[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <12c511ca0911201420i5f2d4751m25ae5288b69dbabb@mail.gmail.com>
Date: Fri, 20 Nov 2009 14:20:01 -0800
From: Tony Luck <tony.luck@...il.com>
To: Rusty Russell <rusty@...tcorp.com.au>
Cc: Alan Jenkins <alan-jenkins@...fmail.co.uk>,
Sam Ravnborg <sam@...nborg.org>,
Mike Frysinger <vapier.adi@...il.com>, greg@...ah.com,
linux-kbuild@...r.kernel.org, carmelo73@...il.com,
linux-kernel@...r.kernel.org, achiang@...com, kyle@...artin.ca,
deller@....de, jejb@...isc-linux.org,
Benjamin Herrenschmidt <benh@...nel.crashing.org>,
paulus@...ba.org
Subject: Re: [PATCH 05/10] kbuild: sort the list of symbols exported by the
kernel (__ksymtab)
The sorted ksymtab breaks ia64 (and possibly ppc64 and
parisc too).
Alex Chiang did the bisect to find this change as
the cause of the breakage. The problem is that ia64
expects that the first item in each ksymtab entry to be
a function pointer. The code in modpost that creates
.tmp_exports-asm.S doesn't know about types of exported
objects, so it uses __EXPORT_SYMBOL from linux/mod_export.h
for everything. This results in
PTR SYM(sym);
PTR SYM(__kstrtab_##sym);
which the preprocessor expands to entries like:
.long ____pagevec_lru_add
.long __kstrtab____pagevec_lru_add
which puts the address of the first instruction of the
function into the table, rather than the address of a
function pointer (which on ia64 is a two element data
object containing the code address and the global data
pointer).
The syntax you need for this* is:
.long @fptr(____pagevec_lru_add)
.long __kstrtab____pagevec_lru_add
Note that you must only use the @fptr(name) syntax for
function exports. Exported data items just need an address.
-Tony
* On ia64 ... powerpc and parisc might need something else.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists