<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/scripts/checkpatch.pl, branch v3.13</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v3.13</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v3.13'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2013-11-22T00:42:27Z</updated>
<entry>
<title>checkpatch: fix "Use of uninitialized value" warnings</title>
<updated>2013-11-22T00:42:27Z</updated>
<author>
<name>Joe Perches</name>
<email>joe@perches.com</email>
</author>
<published>2013-11-21T22:31:57Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=c11230f44b3c3e055e4e7cd572fc1c4a22c6f4a9'/>
<id>urn:sha1:c11230f44b3c3e055e4e7cd572fc1c4a22c6f4a9</id>
<content type='text'>
checkpatch is currently confused about some complex macros and references
undefined variables $stat and $cond.

Make sure these are defined before using them.

Signed-off-by: Joe Perches &lt;joe@perches.com&gt;
Reported-by: Gerhard Sittig &lt;gsi@denx.de&gt;
Acked-by: Andy Whitcroft &lt;apw@canonical.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>checkpatch: add check for sscanf without return use</title>
<updated>2013-11-13T03:09:25Z</updated>
<author>
<name>Joe Perches</name>
<email>joe@perches.com</email>
</author>
<published>2013-11-12T23:10:15Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=823b794ce176bcf135a062075737be71a78629dd'/>
<id>urn:sha1:823b794ce176bcf135a062075737be71a78629dd</id>
<content type='text'>
Naked use sscanf can be troublesome because the pointed to variables may
not have been set.

Add a warning when the sscanf return value is not used.

For now, do not add __must_check to the sscanf prototype because that will
cause a couple of hundred new warnings when compiling a kernel.

Signed-off-by: Joe Perches &lt;joe@perches.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>checkpatch: don't require kernel style __attribute__ shortcuts in uapi paths</title>
<updated>2013-11-13T03:09:25Z</updated>
<author>
<name>Joe Perches</name>
<email>joe@perches.com</email>
</author>
<published>2013-11-12T23:10:14Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=2b7ab45395dc4d91ef30985f76d90a8f28f58c27'/>
<id>urn:sha1:2b7ab45395dc4d91ef30985f76d90a8f28f58c27</id>
<content type='text'>
Avoid prescribing kernel styled shortcuts for gcc extensions of
__attribute__((foo)) in the uapi include paths.

Fix $realfile filename when using -f/--file to not remove first level
directory as if the filename was used in a -P1 patch.  Only strip the
first level directory (typically a or b) for P1 patches.

Signed-off-by: Joe Perches &lt;joe@perches.com&gt;
Cc: "Dixit, Ashutosh" &lt;ashutosh.dixit@intel.com&gt;
Cc: Andy Whitcroft &lt;apw@canonical.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>checkpatch: improve "return is not a function" test</title>
<updated>2013-11-13T03:09:25Z</updated>
<author>
<name>Joe Perches</name>
<email>joe@perches.com</email>
</author>
<published>2013-11-12T23:10:13Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=507e51418ca0c98640310aa02450720825b2b6b1'/>
<id>urn:sha1:507e51418ca0c98640310aa02450720825b2b6b1</id>
<content type='text'>
Find a few more cases where parentheses are used around the value of a
return statement.

This now uses the "$balanced_parens" test and also makes the test depend
on perl v5.10 and higher.

This now finds return with parenthesis uses the old code did not find
like:

ERROR: return is not a function, parentheses are not required
#211: FILE: arch/m68k/include/asm/sun3xflop.h:211:
+		return ((error == 0) ? 0 : -1);

Signed-off-by: Joe Perches &lt;joe@perches.com&gt;
Tested-by: David Cohen &lt;david.a.cohen@linux.intel.com&gt;
Acked-by: David Cohen &lt;david.a.cohen@linux.intel.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>checkpatch.pl: check for the FSF mailing address</title>
<updated>2013-11-13T03:09:25Z</updated>
<author>
<name>Josh Triplett</name>
<email>josh@joshtriplett.org</email>
</author>
<published>2013-11-12T23:10:12Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=4783f894d0f3bfb107cf3b1d9aed1f1a0672ee1d'/>
<id>urn:sha1:4783f894d0f3bfb107cf3b1d9aed1f1a0672ee1d</id>
<content type='text'>
Kernel maintainers reject new instances of the GPL boilerplate paragraph
directing people to write to the FSF for a copy of the GPL, since the FSF
has moved in the past and may do so again.

Make this an error for new code, but just a --strict CHK in --file mode;
anyone interested in doing tree-wide cleanups of this form can enable this
test explicitly.

Signed-off-by: Josh Triplett &lt;josh@joshtriplett.org&gt;
Acked-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Acked-by: Joe Perches &lt;joe@perches.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>checkpatch: make the memory barrier test noisier</title>
<updated>2013-11-13T03:09:25Z</updated>
<author>
<name>Joe Perches</name>
<email>joe@perches.com</email>
</author>
<published>2013-11-12T23:10:11Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=c1fd7bb99637e69994d26df5f6e33192319d3866'/>
<id>urn:sha1:c1fd7bb99637e69994d26df5f6e33192319d3866</id>
<content type='text'>
Peter Zijlstra prefers that comments be required near uses of memory
barriers.

Change the message level for memory barrier uses from a --strict test only
to a normal WARN so it's always emitted.

This might produce false positives around insertions of memory barriers
when a comment is outside the patch context block.

And checkpatch is still stupid, it only looks for existence of any
comment, not at the comment content.

Signed-off-by: Joe Perches &lt;joe@perches.com&gt;
Suggested-by: Peter Zijlstra &lt;peterz@infradead.org&gt;
Acked-by: Peter Zijlstra &lt;peterz@infradead.org&gt;
Acked-by: Paul E. McKenney &lt;paulmck@linux.vnet.ibm.com&gt;
Cc: Oliver Neukum &lt;oliver@neukum.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>
</entry>
<entry>
<title>checkpatch: add rules to check init attribute and const defects</title>
<updated>2013-11-13T03:09:25Z</updated>
<author>
<name>Joe Perches</name>
<email>joe@perches.com</email>
</author>
<published>2013-11-12T23:10:10Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=e970b8846ae4763e64be3c93dc06b4eaebf9ad63'/>
<id>urn:sha1:e970b8846ae4763e64be3c93dc06b4eaebf9ad63</id>
<content type='text'>
People get this regularly wrong and it breaks the LTO builds, as it causes
a section attribute conflict.

Add --fix capability too.

Based on a patch from Andi Kleen.

Signed-off-by: Joe Perches &lt;joe@perches.com&gt;
Cc: Andi Kleen &lt;ak@linux.intel.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>checkpatch: add test for #defines of ARCH_HAS_&lt;foo&gt;</title>
<updated>2013-11-13T03:09:24Z</updated>
<author>
<name>Joe Perches</name>
<email>joe@perches.com</email>
</author>
<published>2013-11-12T23:10:09Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=52ea85061d188031c827ecef9bce47ae93f1e52e'/>
<id>urn:sha1:52ea85061d188031c827ecef9bce47ae93f1e52e</id>
<content type='text'>
Add a test for these #defines

Additionally, moved string_find_replace sub as it screws up subsequent
formatting when placed inside another sub.

Signed-off-by: Joe Perches &lt;joe@perches.com&gt;
Suggested-by: Andrew Morton &lt;akpm@linux-foundation.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>
</entry>
<entry>
<title>checkpatch: find CamelCase definitions of struct/union/enum</title>
<updated>2013-11-13T03:09:24Z</updated>
<author>
<name>Joe Perches</name>
<email>joe@perches.com</email>
</author>
<published>2013-11-12T23:10:08Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=11ea516a6c578564a65a352abb08ef558d365946'/>
<id>urn:sha1:11ea516a6c578564a65a352abb08ef558d365946</id>
<content type='text'>
Checkpatch doesn't currently find CamelCase definitions of structs, unions
or enums.

Add that ability.

Signed-off-by: Joe Perches &lt;joe@perches.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>checkpatch: update seq_&lt;foo&gt; tests</title>
<updated>2013-11-13T03:09:24Z</updated>
<author>
<name>Joe Perches</name>
<email>joe@perches.com</email>
</author>
<published>2013-11-12T23:10:07Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=066687279ccf5e9e935f7780c4b311d18ebaf977'/>
<id>urn:sha1:066687279ccf5e9e935f7780c4b311d18ebaf977</id>
<content type='text'>
seq_vprintf, seq_printf and seq_puts are logging functions and should be
allowed to exceed the maximium line length.

Add maximum line length exceptions for these functions.

Also, suggesting seq_printf conversions to seq_puts should be tested for
arguments after the format.

Signed-off-by: Joe Perches &lt;joe@perches.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
</feed>
