Thread (16 messages) 16 messages, 3 authors, 2017-01-20

Re: [PATCH v4 3/3] modversions: treat symbol CRCs as 32 bit quantities on 64 bit archs

From: Ard Biesheuvel <hidden>
Date: 2017-01-19 09:31:03
Also in: lkml

On 19 January 2017 at 00:15, Linus Torvalds
[off-list ref] wrote:
On Wed, Jan 18, 2017 at 2:37 PM, Ard Biesheuvel
[off-list ref] wrote:
quoted
For a ballpark number of 10,000 CRCs in the core kernel, this would
increase the size of the image by 40 KB for 32-bit architectures (and
if saving 40 KB is essential, chances are you won't be using
modversions in the first place).
As you say, I don't think the space issue is much of a problem.

I'm more worried about the replacement of one crazy model that has
problems due to linker subtlety with _another_ one.

Your genksyms.c change is not exactly obvious. I looked at it, and my
brain just shut down. Why both the

  LONG(0x%08lx);

_and_ the

  "%s__crc_%s = 0x%08lx;\n"

in the linker script? I'm sure there's a good reason, but I'd like to
see a more explicit explanation fo what the generated linker script
does and what the rules are.
This is simply because modpost still uses the value of the symbol
rather than the value it points to to generate the /other/ side of the
comparison (i.e., Module.symvers etc)

I will look into updating modpost to dereference the symbol as well,
and update the RFC patch accordingly.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help