<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-toradex.git/scripts/headers_check.pl, branch v4.11-rc1</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>headers_check: don't warn about c++ guards</title>
<updated>2016-05-24T04:12:48+00:00</updated>
<author>
<name>Arnd Bergmann</name>
<email>arnd@arndb.de</email>
</author>
<published>2016-05-18T16:07:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=92181d47ee74749bdf902f080dab9fa9ef44b37f'/>
<id>92181d47ee74749bdf902f080dab9fa9ef44b37f</id>
<content type='text'>
A recent addition to the DRM tree for 4.7 added 'extern "C"' guards
for c++ to all the DRM headers, and that now causes warnings
in 'make headers_check':

usr/include/drm/amdgpu_drm.h:38: userspace cannot reference function or variable defined in the kernel
usr/include/drm/drm.h:63: userspace cannot reference function or variable defined in the kernel
usr/include/drm/drm.h:699: userspace cannot reference function or variable defined in the kernel
usr/include/drm/drm_fourcc.h:30: userspace cannot reference function or variable defined in the kernel
usr/include/drm/drm_mode.h:33: userspace cannot reference function or variable defined in the kernel
usr/include/drm/drm_sarea.h:38: userspace cannot reference function or variable defined in the kernel
usr/include/drm/exynos_drm.h:21: userspace cannot reference function or variable defined in the kernel
usr/include/drm/i810_drm.h:7: userspace cannot reference function or variable defined in the kernel

This changes the headers_check.pl script to not warn about this.
I'm listing the merge commit as introducing the problem, because
there are several patches in this branch that each do this for
one file.

Signed-off-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Fixes: 7c10ddf87472 ("Merge branch 'drm-uapi-extern-c-fixes' of https://github.com/evelikov/linux into drm-next")
Reviewed-by: Emil Velikov &lt;emil.l.velikov@gmail.com&gt;
Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
A recent addition to the DRM tree for 4.7 added 'extern "C"' guards
for c++ to all the DRM headers, and that now causes warnings
in 'make headers_check':

usr/include/drm/amdgpu_drm.h:38: userspace cannot reference function or variable defined in the kernel
usr/include/drm/drm.h:63: userspace cannot reference function or variable defined in the kernel
usr/include/drm/drm.h:699: userspace cannot reference function or variable defined in the kernel
usr/include/drm/drm_fourcc.h:30: userspace cannot reference function or variable defined in the kernel
usr/include/drm/drm_mode.h:33: userspace cannot reference function or variable defined in the kernel
usr/include/drm/drm_sarea.h:38: userspace cannot reference function or variable defined in the kernel
usr/include/drm/exynos_drm.h:21: userspace cannot reference function or variable defined in the kernel
usr/include/drm/i810_drm.h:7: userspace cannot reference function or variable defined in the kernel

This changes the headers_check.pl script to not warn about this.
I'm listing the merge commit as introducing the problem, because
there are several patches in this branch that each do this for
one file.

Signed-off-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Fixes: 7c10ddf87472 ("Merge branch 'drm-uapi-extern-c-fixes' of https://github.com/evelikov/linux into drm-next")
Reviewed-by: Emil Velikov &lt;emil.l.velikov@gmail.com&gt;
Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>kbuild: Make scripts executable</title>
<updated>2014-08-20T14:03:45+00:00</updated>
<author>
<name>Michal Marek</name>
<email>mmarek@suse.cz</email>
</author>
<published>2014-08-20T14:02:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=06ed5c2bfacaf67039e87a213fa5d1cdde34246a'/>
<id>06ed5c2bfacaf67039e87a213fa5d1cdde34246a</id>
<content type='text'>
The Makefiles call the respective interpreter explicitly, but this makes
it easier to use the scripts manually.

Signed-off-by: Michal Marek &lt;mmarek@suse.cz&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The Makefiles call the respective interpreter explicitly, but this makes
it easier to use the scripts manually.

Signed-off-by: Michal Marek &lt;mmarek@suse.cz&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>headers_check: special case seqbuf_dump()</title>
<updated>2014-01-24T00:36:55+00:00</updated>
<author>
<name>Paul Bolle</name>
<email>pebolle@tiscali.nl</email>
</author>
<published>2014-01-23T23:54:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=a7e1d98f3e2a0d858fddcac7c66b78b6dcfd9d2e'/>
<id>a7e1d98f3e2a0d858fddcac7c66b78b6dcfd9d2e</id>
<content type='text'>
"make headers_check" warns about soundcard.h for (at least) five years
now:
    [...]/usr/include/linux/soundcard.h:1054: userspace cannot reference function or variable defined in the kernel

We're apparently stuck with providing OSSlib-3.8 compatibility, so let's
special case this declaration just to silence it.

Notes:

0) Support for OSSlib post 3.8 was already removed in commit 43a990765a
   ("sound: Remove OSSlib stuff from linux/soundcard.h").  Five years have
   passed since that commit: do people still care about OSSlib-3.8?  If
   not, quite a bit of code could be remove from soundcard.h (and probably
   ultrasound.h).

2) By the way, what is actually meant by:
    It is no longer possible to actually link against OSSlib with this
    header, but we still provide these macros for programs using them.

Doesn't that mean compatibility to OSSlib isn't even useful?

3) Anyhow, a previous discussion soundcard.h, which led to that commit,
   starts at https://lkml.org/lkml/2009/1/20/349 .

4) And, yes, I sneaked in a whitespace fix.

Signed-off-by: Paul Bolle &lt;pebolle@tiscali.nl&gt;
Cc: Takashi Iwai &lt;tiwai@suse.de&gt;
Acked-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Cc: Michal Marek &lt;mmarek@suse.cz&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>
"make headers_check" warns about soundcard.h for (at least) five years
now:
    [...]/usr/include/linux/soundcard.h:1054: userspace cannot reference function or variable defined in the kernel

We're apparently stuck with providing OSSlib-3.8 compatibility, so let's
special case this declaration just to silence it.

Notes:

0) Support for OSSlib post 3.8 was already removed in commit 43a990765a
   ("sound: Remove OSSlib stuff from linux/soundcard.h").  Five years have
   passed since that commit: do people still care about OSSlib-3.8?  If
   not, quite a bit of code could be remove from soundcard.h (and probably
   ultrasound.h).

2) By the way, what is actually meant by:
    It is no longer possible to actually link against OSSlib with this
    header, but we still provide these macros for programs using them.

Doesn't that mean compatibility to OSSlib isn't even useful?

3) Anyhow, a previous discussion soundcard.h, which led to that commit,
   starts at https://lkml.org/lkml/2009/1/20/349 .

4) And, yes, I sneaked in a whitespace fix.

Signed-off-by: Paul Bolle &lt;pebolle@tiscali.nl&gt;
Cc: Takashi Iwai &lt;tiwai@suse.de&gt;
Acked-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Cc: Michal Marek &lt;mmarek@suse.cz&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>headers_check: recursively search for linux/types.h inclusion</title>
<updated>2012-03-26T12:54:27+00:00</updated>
<author>
<name>Bobby Powers</name>
<email>bobbypowers@gmail.com</email>
</author>
<published>2012-03-05T23:08:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=f75a8df3bd6466e29a4e40b86b2cfc96fe06d328'/>
<id>f75a8df3bd6466e29a4e40b86b2cfc96fe06d328</id>
<content type='text'>
headers_check.pl currently emits some spurious warnings, especially for
the drm headers, about using __[us]{8,16,32,64} types without including
linux/types.h.  Recursively search for types.h inclusion, avoiding
circular references.

Signed-off-by: Bobby Powers &lt;bobbypowers@gmail.com&gt;
Cc: Sam Ravnborg &lt;sam@ravnborg.org&gt;
Cc: Dave Airlie &lt;airlied@linux.ie&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Michal Marek &lt;mmarek@suse.cz&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
headers_check.pl currently emits some spurious warnings, especially for
the drm headers, about using __[us]{8,16,32,64} types without including
linux/types.h.  Recursively search for types.h inclusion, avoiding
circular references.

Signed-off-by: Bobby Powers &lt;bobbypowers@gmail.com&gt;
Cc: Sam Ravnborg &lt;sam@ravnborg.org&gt;
Cc: Dave Airlie &lt;airlied@linux.ie&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Michal Marek &lt;mmarek@suse.cz&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>headers_check: Fix warning text</title>
<updated>2010-12-14T16:05:08+00:00</updated>
<author>
<name>akpm@linux-foundation.org</name>
<email>akpm@linux-foundation.org</email>
</author>
<published>2010-11-30T21:52:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=d52784eb3607bf887628742f99041b4f18d7d1de'/>
<id>d52784eb3607bf887628742f99041b4f18d7d1de</id>
<content type='text'>
Fix the warning text too, per Randy.

Cc: Alexander Shishkin &lt;virtuoso@slind.org&gt;
Cc: Michal Marek &lt;mmarek@suse.cz&gt;
Cc: Randy Dunlap &lt;randy.dunlap@oracle.com&gt;
Cc: Stephen Hemminger &lt;shemminger@vyatta.com&gt;
Cc: WANG Cong &lt;amwang@redhat.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Michal Marek &lt;mmarek@suse.cz&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fix the warning text too, per Randy.

Cc: Alexander Shishkin &lt;virtuoso@slind.org&gt;
Cc: Michal Marek &lt;mmarek@suse.cz&gt;
Cc: Randy Dunlap &lt;randy.dunlap@oracle.com&gt;
Cc: Stephen Hemminger &lt;shemminger@vyatta.com&gt;
Cc: WANG Cong &lt;amwang@redhat.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Michal Marek &lt;mmarek@suse.cz&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>headers_check: better search for functions in headers</title>
<updated>2010-12-14T16:02:45+00:00</updated>
<author>
<name>akpm@linux-foundation.org</name>
<email>akpm@linux-foundation.org</email>
</author>
<published>2010-11-30T21:51:13+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=de323f22a83b024b7432e813609c6efb74b1bbfc'/>
<id>de323f22a83b024b7432e813609c6efb74b1bbfc</id>
<content type='text'>
Some headers don't bother with "extern" in function prototypes, which
results in said prototypes being unnoticed and exported to userland.

This patch slightly improves detection of such cases by checking for C
type names as well in the beginning of a line.

Signed-off-by: Alexander Shishkin &lt;virtuoso@slind.org&gt;
Cc: Stephen Hemminger &lt;shemminger@vyatta.com&gt;
Cc: Michal Marek &lt;mmarek@suse.cz&gt;
Cc: WANG Cong &lt;amwang@redhat.com&gt;
Cc: Randy Dunlap &lt;randy.dunlap@oracle.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Michal Marek &lt;mmarek@suse.cz&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Some headers don't bother with "extern" in function prototypes, which
results in said prototypes being unnoticed and exported to userland.

This patch slightly improves detection of such cases by checking for C
type names as well in the beginning of a line.

Signed-off-by: Alexander Shishkin &lt;virtuoso@slind.org&gt;
Cc: Stephen Hemminger &lt;shemminger@vyatta.com&gt;
Cc: Michal Marek &lt;mmarek@suse.cz&gt;
Cc: WANG Cong &lt;amwang@redhat.com&gt;
Cc: Randy Dunlap &lt;randy.dunlap@oracle.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Michal Marek &lt;mmarek@suse.cz&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>headers_check: fix perl warnings</title>
<updated>2010-03-07T20:43:07+00:00</updated>
<author>
<name>Stephen Hemminger</name>
<email>shemminger@vyatta.com</email>
</author>
<published>2010-02-22T23:17:24+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=dbbe33e99f41a6f07e61dbce455964112d8ac72b'/>
<id>dbbe33e99f41a6f07e61dbce455964112d8ac72b</id>
<content type='text'>
According to PBP; best way practice is to use local reference for file
handle and three argument open. Also perl prototypes are a mistake.

Signed-off-by: Stephen Hemminger &lt;shemminger@vyatta.com&gt;
Acked-by: WANG Cong &lt;amwang@redhat.com&gt;
Cc: Michal Marek &lt;mmarek@suse.cz&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Michal Marek &lt;mmarek@suse.cz&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
According to PBP; best way practice is to use local reference for file
handle and three argument open. Also perl prototypes are a mistake.

Signed-off-by: Stephen Hemminger &lt;shemminger@vyatta.com&gt;
Acked-by: WANG Cong &lt;amwang@redhat.com&gt;
Cc: Michal Marek &lt;mmarek@suse.cz&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Michal Marek &lt;mmarek@suse.cz&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>kbuild/headers_check: refine extern check</title>
<updated>2009-06-09T20:37:56+00:00</updated>
<author>
<name>Amerigo Wang</name>
<email>amwang@redhat.com</email>
</author>
<published>2009-06-05T02:12:01+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=67b7ebe091cd92fd69f732da3170720d79c4e632'/>
<id>67b7ebe091cd92fd69f732da3170720d79c4e632</id>
<content type='text'>
'extern' checking information is not clear, refine it.
Plus, fix a comment.

Signed-off-by: WANG Cong &lt;amwang@redhat.com&gt;
[sam: redid the extern error message]
Acked-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Signed-off-by: Sam Ravnborg &lt;sam@ravnborg.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
'extern' checking information is not clear, refine it.
Plus, fix a comment.

Signed-off-by: WANG Cong &lt;amwang@redhat.com&gt;
[sam: redid the extern error message]
Acked-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Signed-off-by: Sam Ravnborg &lt;sam@ravnborg.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>scripts/headers_check.pl: correct RE in header CONFIG leak check</title>
<updated>2009-06-09T20:37:52+00:00</updated>
<author>
<name>Robert P. J. Day</name>
<email>rpjday@crashcourse.ca</email>
</author>
<published>2009-05-12T20:43:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=1581c1cede3b180b77aa08024c6ca406252cc21f'/>
<id>1581c1cede3b180b77aa08024c6ca406252cc21f</id>
<content type='text'>
Correct the regular expression in scripts/headers_check.pl to include '_'
as a valid character in the class; otherwise, the check will report a
"leaked" symbol of CONFIG_A_B_C as merely CONFIG_A.

This patch will make no difference whatsoever in the current kernel tree
as the call to the perl routine that does that check is currently
commented out:

                &amp;check_include();
                &amp;check_asm_types();
                &amp;check_sizetypes();
                &amp;check_prototypes();
                # Dropped for now. Too much noise &amp;check_config();

However, I noticed that problem when I was building the yum downloadable
kernel source rpm for fedora 11 (beta), which *does* run that check, and
that's where the problem became obvious.

Signed-off-by: Robert P. J. Day &lt;rpjday@crashcourse.ca&gt;
Cc: David Woodhouse &lt;dwmw2@infradead.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Sam Ravnborg &lt;sam@ravnborg.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Correct the regular expression in scripts/headers_check.pl to include '_'
as a valid character in the class; otherwise, the check will report a
"leaked" symbol of CONFIG_A_B_C as merely CONFIG_A.

This patch will make no difference whatsoever in the current kernel tree
as the call to the perl routine that does that check is currently
commented out:

                &amp;check_include();
                &amp;check_asm_types();
                &amp;check_sizetypes();
                &amp;check_prototypes();
                # Dropped for now. Too much noise &amp;check_config();

However, I noticed that problem when I was building the yum downloadable
kernel source rpm for fedora 11 (beta), which *does* run that check, and
that's where the problem became obvious.

Signed-off-by: Robert P. J. Day &lt;rpjday@crashcourse.ca&gt;
Cc: David Woodhouse &lt;dwmw2@infradead.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Sam Ravnborg &lt;sam@ravnborg.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>kbuild: drop check for CONFIG_ in headers_check</title>
<updated>2009-01-30T23:36:15+00:00</updated>
<author>
<name>Sam Ravnborg</name>
<email>sam@ravnborg.org</email>
</author>
<published>2009-01-30T22:56:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=7e3fa56141175026136b392fd026d5d07c49720e'/>
<id>7e3fa56141175026136b392fd026d5d07c49720e</id>
<content type='text'>
The check for references to CONFIG_ symbols in exported headers turned
out to be too agressive with the current state of affairs.
After the work of Jaswinder to clean up all relevant cases we are down
to almost pure noise.

So lets drop the check for now - we can always add it back later
should our headers be ready for that.

Signed-off-by: Sam Ravnborg &lt;sam@ravnborg.org&gt;
Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The check for references to CONFIG_ symbols in exported headers turned
out to be too agressive with the current state of affairs.
After the work of Jaswinder to clean up all relevant cases we are down
to almost pure noise.

So lets drop the check for now - we can always add it back later
should our headers be ready for that.

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