<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-toradex.git/scripts/mod/modpost.h, branch tegra-10.9.9</title>
<subtitle>Linux kernel for Apalis and Colibri modules</subtitle>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/'/>
<entry>
<title>kbuild: soften modpost checks when doing cross builds</title>
<updated>2008-03-23T20:38:54+00:00</updated>
<author>
<name>Sam Ravnborg</name>
<email>sam@uranus.ravnborg.org</email>
</author>
<published>2008-03-23T20:38:54+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=4ce6efed48d736e3384c39ff87bda723e1f8e041'/>
<id>4ce6efed48d736e3384c39ff87bda723e1f8e041</id>
<content type='text'>
The module alias support in the kernel have a consistency
check where it is checked that the size of a structure
in the kernel and on the build host are the same.
For cross builds this check does not make sense so detect
when we do cross builds and silently skip the check in these
situations.
This fixes a build bug for a wireless driver when cross building
for arm.

Acked-by: Michael Buesch &lt;mb@bu3sch.de&gt;
Tested-by: Gordon Farquharson &lt;gordonfarquharson@gmail.com&gt;
Signed-off-by: Sam Ravnborg &lt;sam@ravnborg.org&gt;
Cc: stable@kernel.org
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The module alias support in the kernel have a consistency
check where it is checked that the size of a structure
in the kernel and on the build host are the same.
For cross builds this check does not make sense so detect
when we do cross builds and silently skip the check in these
situations.
This fixes a build bug for a wireless driver when cross building
for arm.

Acked-by: Michael Buesch &lt;mb@bu3sch.de&gt;
Tested-by: Gordon Farquharson &lt;gordonfarquharson@gmail.com&gt;
Signed-off-by: Sam Ravnborg &lt;sam@ravnborg.org&gt;
Cc: stable@kernel.org
</pre>
</div>
</content>
</entry>
<entry>
<title>Linux Kernel Markers: create modpost file</title>
<updated>2008-02-14T00:21:20+00:00</updated>
<author>
<name>Mathieu Desnoyers</name>
<email>mathieu.desnoyers@polymtl.ca</email>
</author>
<published>2008-02-13T23:03:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=b2e3e658b344c6bcfb8fb694100ab2f2b5b2edb0'/>
<id>b2e3e658b344c6bcfb8fb694100ab2f2b5b2edb0</id>
<content type='text'>
This adds some new magic in the MODPOST phase for CONFIG_MARKERS.  Analogous
to the Module.symvers file, the build will now write a Module.markers file
when CONFIG_MARKERS=y is set.  This file lists the name, defining module, and
format string of each marker, separated by \t characters.  This simple text
file can be used by offline build procedures for instrumentation code,
analogous to how System.map and Module.symvers can be useful to have for
kernels other than the one you are running right now.

The strings are made easy to extract by having the __trace_mark macro define
the name and format together in a single array called __mstrtab_* in the
__markers_strings section.  This is straightforward and reliable as long as
the marker structs are always defined by this macro.  It is an unreasonable
amount of hairy work to extract the string pointers from the __markers section
structs, which entails handling a relocation type for every machine under the
sun.

Mathieu :
- Ran through checkpatch.pl

Signed-off-by: Roland McGrath &lt;roland@redhat.com&gt;
Signed-off-by: Mathieu Desnoyers &lt;mathieu.desnoyers@polymtl.ca&gt;
Cc: David Smith &lt;dsmith@redhat.com&gt;
Cc: Sam Ravnborg &lt;sam@ravnborg.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This adds some new magic in the MODPOST phase for CONFIG_MARKERS.  Analogous
to the Module.symvers file, the build will now write a Module.markers file
when CONFIG_MARKERS=y is set.  This file lists the name, defining module, and
format string of each marker, separated by \t characters.  This simple text
file can be used by offline build procedures for instrumentation code,
analogous to how System.map and Module.symvers can be useful to have for
kernels other than the one you are running right now.

The strings are made easy to extract by having the __trace_mark macro define
the name and format together in a single array called __mstrtab_* in the
__markers_strings section.  This is straightforward and reliable as long as
the marker structs are always defined by this macro.  It is an unreasonable
amount of hairy work to extract the string pointers from the __markers section
structs, which entails handling a relocation type for every machine under the
sun.

Mathieu :
- Ran through checkpatch.pl

Signed-off-by: Roland McGrath &lt;roland@redhat.com&gt;
Signed-off-by: Mathieu Desnoyers &lt;mathieu.desnoyers@polymtl.ca&gt;
Cc: David Smith &lt;dsmith@redhat.com&gt;
Cc: Sam Ravnborg &lt;sam@ravnborg.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>kbuild: try harder to find symbol names in modpost</title>
<updated>2008-01-28T22:14:40+00:00</updated>
<author>
<name>Sam Ravnborg</name>
<email>sam@ravnborg.org</email>
</author>
<published>2008-01-18T20:04:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=9ad21c3f3ecffeb56be7b35030d7ec2f30b6fe11'/>
<id>9ad21c3f3ecffeb56be7b35030d7ec2f30b6fe11</id>
<content type='text'>
The relocation record sometimes contained an address
which was not an exactly match for a symbol.

Implment some simple logic such that if there
is a symbol within 20 bytes of the address contained
in the relocation record then print the name of this
symbol.

With this change modpost could find symbol names
for the remaining .init.text symbols in my
allyesconfig build for x86_64.

Signed-off-by: Sam Ravnborg &lt;sam@ravnborg.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The relocation record sometimes contained an address
which was not an exactly match for a symbol.

Implment some simple logic such that if there
is a symbol within 20 bytes of the address contained
in the relocation record then print the name of this
symbol.

With this change modpost could find symbol names
for the remaining .init.text symbols in my
allyesconfig build for x86_64.

Signed-off-by: Sam Ravnborg &lt;sam@ravnborg.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>kbuild: Use Elfnn_Half as replacement for Elfnn_Section</title>
<updated>2007-10-12T19:13:50+00:00</updated>
<author>
<name>Sam Ravnborg</name>
<email>sam@ravnborg.org</email>
</author>
<published>2007-08-12T21:17:54+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=4f4c4ee1b79b9102db19ff39f7cb11abddaa43e1'/>
<id>4f4c4ee1b79b9102db19ff39f7cb11abddaa43e1</id>
<content type='text'>
The Elfnn_Section is not available on all platforms,
noteworthy are cygwin.
Use the safe replacement _Half.

Signed-off-by: Sam Ravnborg &lt;sam@ravnborg.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The Elfnn_Section is not available on all platforms,
noteworthy are cygwin.
Use the safe replacement _Half.

Signed-off-by: Sam Ravnborg &lt;sam@ravnborg.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>kbuild: make better section mismatch reports on i386 and mips</title>
<updated>2007-07-16T19:48:49+00:00</updated>
<author>
<name>Atsushi Nemoto</name>
<email>anemo@mba.ocn.ne.jp</email>
</author>
<published>2007-05-22T09:27:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=ae4ac12323c0ff80528cac3269151d580e23f923'/>
<id>ae4ac12323c0ff80528cac3269151d580e23f923</id>
<content type='text'>
On i386 and MIPS, warn_sec_mismatch() sometimes fails to show
usefull symbol name.  This is because empty 'refsym' due to 0 r_addend
value.  This patch is to adjust r_addend value, consulting with
apply_relocate() routine in kernel code.

Signed-off-by: Atsushi Nemoto &lt;anemo@mba.ocn.ne.jp&gt;
Signed-off-by: Sam Ravnborg &lt;sam@ravnborg.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
On i386 and MIPS, warn_sec_mismatch() sometimes fails to show
usefull symbol name.  This is because empty 'refsym' due to 0 r_addend
value.  This patch is to adjust r_addend value, consulting with
apply_relocate() routine in kernel code.

Signed-off-by: Atsushi Nemoto &lt;anemo@mba.ocn.ne.jp&gt;
Signed-off-by: Sam Ravnborg &lt;sam@ravnborg.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Revert "kbuild: make better section mismatch reports on i386, arm and mips"</title>
<updated>2007-05-22T01:41:17+00:00</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@woody.linux-foundation.org</email>
</author>
<published>2007-05-22T01:41:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=efa5bf1dd2cf3cdee0bfe97cfd76ff2296179ae4'/>
<id>efa5bf1dd2cf3cdee0bfe97cfd76ff2296179ae4</id>
<content type='text'>
This reverts commit f892b7d480eec809a5dfbd6e65742b3f3155e50e, which
totally broke the build on x86 with CONFIG_RELOCATABLE (which, as far as
I can tell, is the only case where it should even matter!) due to a
SIGSEGV in modpost.

Cc: Sam Ravnborg &lt;sam@ravnborg.org&gt;
Cc: Atsushi Nemoto &lt;anemo@mba.ocn.ne.jp&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This reverts commit f892b7d480eec809a5dfbd6e65742b3f3155e50e, which
totally broke the build on x86 with CONFIG_RELOCATABLE (which, as far as
I can tell, is the only case where it should even matter!) due to a
SIGSEGV in modpost.

Cc: Sam Ravnborg &lt;sam@ravnborg.org&gt;
Cc: Atsushi Nemoto &lt;anemo@mba.ocn.ne.jp&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>kbuild: make better section mismatch reports on i386, arm and mips</title>
<updated>2007-05-19T07:11:57+00:00</updated>
<author>
<name>Atsushi Nemoto</name>
<email>anemo@mba.ocn.ne.jp</email>
</author>
<published>2007-05-16T16:14:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=f892b7d480eec809a5dfbd6e65742b3f3155e50e'/>
<id>f892b7d480eec809a5dfbd6e65742b3f3155e50e</id>
<content type='text'>
On i386, ARM and MIPS, warn_sec_mismatch() sometimes fails to show
usefull symbol name.  This is because empty 'refsym' due to 0 r_addend
value.  This patch is to adjust r_addend value, consulting with
apply_relocate() routine in kernel code.

Without this patch:
  MODPOST vmlinux
WARNING: init/built-in.o - Section mismatch: reference to .init.text: from .text between 'rest_init' (at offset 0xf4) and 'try_name'
WARNING: mm/built-in.o - Section mismatch: reference to .init.text: from .text between 'kmem_cache_create' (at offset 0x18a39) and 'cache_reap'
WARNING: mm/built-in.o - Section mismatch: reference to .init.text: from .text between 'kmem_cache_create' (at offset 0x18a6b) and 'cache_reap'

With this patch:
  MODPOST vmlinux
WARNING: mm/built-in.o - Section mismatch: reference to .init.text:set_up_list3s from .text between 'kmem_cache_create' (at offset 0x18a39) and 'cache_reap'
WARNING: mm/built-in.o - Section mismatch: reference to .init.text:set_up_list3s from .text between 'kmem_cache_create' (at offset 0x18a6b) and 'cache_reap'

Now modpost can detect "kernel_init" name (and whitelist it) and show
"set_up_list3s" name.

Signed-off-by: Atsushi Nemoto &lt;anemo@mba.ocn.ne.jp&gt;
Signed-off-by: Sam Ravnborg &lt;sam@ravnborg.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
On i386, ARM and MIPS, warn_sec_mismatch() sometimes fails to show
usefull symbol name.  This is because empty 'refsym' due to 0 r_addend
value.  This patch is to adjust r_addend value, consulting with
apply_relocate() routine in kernel code.

Without this patch:
  MODPOST vmlinux
WARNING: init/built-in.o - Section mismatch: reference to .init.text: from .text between 'rest_init' (at offset 0xf4) and 'try_name'
WARNING: mm/built-in.o - Section mismatch: reference to .init.text: from .text between 'kmem_cache_create' (at offset 0x18a39) and 'cache_reap'
WARNING: mm/built-in.o - Section mismatch: reference to .init.text: from .text between 'kmem_cache_create' (at offset 0x18a6b) and 'cache_reap'

With this patch:
  MODPOST vmlinux
WARNING: mm/built-in.o - Section mismatch: reference to .init.text:set_up_list3s from .text between 'kmem_cache_create' (at offset 0x18a39) and 'cache_reap'
WARNING: mm/built-in.o - Section mismatch: reference to .init.text:set_up_list3s from .text between 'kmem_cache_create' (at offset 0x18a6b) and 'cache_reap'

Now modpost can detect "kernel_init" name (and whitelist it) and show
"set_up_list3s" name.

Signed-off-by: Atsushi Nemoto &lt;anemo@mba.ocn.ne.jp&gt;
Signed-off-by: Sam Ravnborg &lt;sam@ravnborg.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>kbuild: distinguish between errors and warnings in modpost</title>
<updated>2007-05-02T18:58:08+00:00</updated>
<author>
<name>Matthew Wilcox</name>
<email>matthew@wil.cx</email>
</author>
<published>2006-10-07T11:35:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=2a11665945d510e1a4df8dc44dc3668b01945ade'/>
<id>2a11665945d510e1a4df8dc44dc3668b01945ade</id>
<content type='text'>
Some of modpost's warnings are fatal, and some are not.  Adopt the
compiler distinction between errors and warnings by calling merror()
for fatal diagnostics and warn() for non-fatal ones.
merror() was used as replacemtn for error() to avoid clash with glibc

Signed-off-by: Matthew Wilcox &lt;matthew@wil.cx&gt;
Signed-off-by: Sam Ravnborg &lt;sam@ravnborg.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Some of modpost's warnings are fatal, and some are not.  Adopt the
compiler distinction between errors and warnings by calling merror()
for fatal diagnostics and warn() for non-fatal ones.
merror() was used as replacemtn for error() to avoid clash with glibc

Signed-off-by: Matthew Wilcox &lt;matthew@wil.cx&gt;
Signed-off-by: Sam Ravnborg &lt;sam@ravnborg.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>kbuild: warn when a moduled uses a symbol marked UNUSED</title>
<updated>2006-07-01T09:44:23+00:00</updated>
<author>
<name>Sam Ravnborg</name>
<email>sam@mars.ravnborg.org</email>
</author>
<published>2006-07-01T09:44:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=c96fca213737a5b4bc569e1d9a0ef6adeff661e9'/>
<id>c96fca213737a5b4bc569e1d9a0ef6adeff661e9</id>
<content type='text'>
We now have infrastructure in place to mark an EXPORTed symbol
as unused. So the natural next step is to warn during buildtime when
a module uses a symbol marked UNUSED.

Signed-off-by: Sam Ravnborg &lt;sam@ravnborg.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We now have infrastructure in place to mark an EXPORTed symbol
as unused. So the natural next step is to warn during buildtime when
a module uses a symbol marked UNUSED.

Signed-off-by: Sam Ravnborg &lt;sam@ravnborg.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>kbuild: check license compatibility when building modules</title>
<updated>2006-06-09T19:53:55+00:00</updated>
<author>
<name>Sam Ravnborg</name>
<email>sam@mars.ravnborg.org</email>
</author>
<published>2006-06-09T19:53:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=b817f6feff4a565b08f0e699a5790b4008b8f494'/>
<id>b817f6feff4a565b08f0e699a5790b4008b8f494</id>
<content type='text'>
Modules that uses GPL symbols can no longer be build with kbuild,
the build will fail during the modpost step.
When a GPL-incompatible module uses a EXPORT_SYMBOL_GPL_FUTURE symbol
then warn during modpost so author are actually notified.

The actual license compatibility check is shared with the kernel
to make sure it is in sync.

Patch originally from: Andreas Gruenbacher &lt;agruen@suse.de&gt; and
Ram Pai &lt;linuxram@us.ibm.com&gt;

Signed-off-by: Sam Ravnborg &lt;sam@ravnborg.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Modules that uses GPL symbols can no longer be build with kbuild,
the build will fail during the modpost step.
When a GPL-incompatible module uses a EXPORT_SYMBOL_GPL_FUTURE symbol
then warn during modpost so author are actually notified.

The actual license compatibility check is shared with the kernel
to make sure it is in sync.

Patch originally from: Andreas Gruenbacher &lt;agruen@suse.de&gt; and
Ram Pai &lt;linuxram@us.ibm.com&gt;

Signed-off-by: Sam Ravnborg &lt;sam@ravnborg.org&gt;
</pre>
</div>
</content>
</entry>
</feed>
