<feed xmlns='http://www.w3.org/2005/Atom'>
<title>pm24.git/scripts/coccinelle, branch v6.14-rc2</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.
</subtitle>
<id>https://git.kobert.dev/pm24.git/atom?h=v6.14-rc2</id>
<link rel='self' href='https://git.kobert.dev/pm24.git/atom?h=v6.14-rc2'/>
<link rel='alternate' type='text/html' href='https://git.kobert.dev/pm24.git/'/>
<updated>2025-01-13T04:21:01Z</updated>
<entry>
<title>coccinelle: misc: add secs_to_jiffies script</title>
<updated>2025-01-13T04:21:01Z</updated>
<author>
<name>Easwar Hariharan</name>
<email>eahariha@linux.microsoft.com</email>
</author>
<published>2024-12-10T22:02:33Z</published>
<link rel='alternate' type='text/html' href='https://git.kobert.dev/pm24.git/commit/?id=551dbd1ec7ff10e06ec077eb264cec0c971b66eb'/>
<id>urn:sha1:551dbd1ec7ff10e06ec077eb264cec0c971b66eb</id>
<content type='text'>
This script finds and suggests conversions of timeout patterns that result
in seconds-denominated timeouts to use the new secs_to_jiffies() API in
include/linux/jiffies.h for better readability.

Link: https://lkml.kernel.org/r/20241210-converge-secs-to-jiffies-v3-2-ddfefd7e9f2a@linux.microsoft.com
Signed-off-by: Easwar Hariharan &lt;eahariha@linux.microsoft.com&gt;
Suggested-by: Anna-Maria Behnsen &lt;anna-maria@linutronix.de&gt;
Cc: Alexander Gordeev &lt;agordeev@linux.ibm.com&gt;
Cc: Andrew Lunn &lt;andrew+netdev@lunn.ch&gt;
Cc: Catalin Marinas &lt;catalin.marinas@arm.com&gt;
Cc: Christian Borntraeger &lt;borntraeger@linux.ibm.com&gt;
Cc: Christophe Leroy &lt;christophe.leroy@csgroup.eu&gt;
Cc: Daniel Mack &lt;daniel@zonque.org&gt;
Cc: David Airlie &lt;airlied@gmail.com&gt;
Cc: David S. Miller &lt;davem@davemloft.net&gt;
Cc: Dick Kennedy &lt;dick.kennedy@broadcom.com&gt;
Cc: Eric Dumazet &lt;edumazet@google.com&gt;
Cc: Florian Fainelli &lt;florian.fainelli@broadcom.com&gt;
Cc: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Cc: Haojian Zhuang &lt;haojian.zhuang@gmail.com&gt;
Cc: Heiko Carstens &lt;hca@linux.ibm.com&gt;
Cc: Ilya Dryomov &lt;idryomov@gmail.com&gt;
Cc: Jack Wang &lt;jinpu.wang@cloud.ionos.com&gt;
Cc: Jakub Kicinski &lt;kuba@kernel.org&gt;
Cc: James Bottomley &lt;James.Bottomley@HansenPartnership.com&gt;
Cc: James Smart &lt;james.smart@broadcom.com&gt;
Cc: Jaroslav Kysela &lt;perex@perex.cz&gt;
Cc: Jeff Johnson &lt;jjohnson@kernel.org&gt;
Cc: Jeff Johnson &lt;quic_jjohnson@quicinc.com&gt;
Cc: Jens Axboe &lt;axboe@kernel.dk&gt;
Cc: Jeroen de Borst &lt;jeroendb@google.com&gt;
Cc: Jiri Kosina &lt;jikos@kernel.org&gt;
Cc: Joe Lawrence &lt;joe.lawrence@redhat.com&gt;
Cc: Johan Hedberg &lt;johan.hedberg@gmail.com&gt;
Cc: Josh Poimboeuf &lt;jpoimboe@kernel.org&gt;
Cc: Jozsef Kadlecsik &lt;kadlec@netfilter.org&gt;
Cc: Julia Lawall &lt;julia.lawall@inria.fr&gt;
Cc: Kalle Valo &lt;kvalo@kernel.org&gt;
Cc: Louis Peens &lt;louis.peens@corigine.com&gt;
Cc: Lucas De Marchi &lt;lucas.demarchi@intel.com&gt;
Cc: Luiz Augusto von Dentz &lt;luiz.dentz@gmail.com&gt;
Cc: Maarten Lankhorst &lt;maarten.lankhorst@linux.intel.com&gt;
Cc: Madhavan Srinivasan &lt;maddy@linux.ibm.com&gt;
Cc: Marcel Holtmann &lt;marcel@holtmann.org&gt;
Cc: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
Cc: Maxime Ripard &lt;mripard@kernel.org&gt;
Cc: Michael Ellerman &lt;mpe@ellerman.id.au&gt;
Cc: Miroslav Benes &lt;mbenes@suse.cz&gt;
Cc: Naveen N Rao &lt;naveen@kernel.org&gt;
Cc: Nicholas Piggin &lt;npiggin@gmail.com&gt;
Cc: Nicolas Palix &lt;nicolas.palix@imag.fr&gt;
Cc: Oded Gabbay &lt;ogabbay@kernel.org&gt;
Cc: Ofir Bitton &lt;obitton@habana.ai&gt;
Cc: Pablo Neira Ayuso &lt;pablo@netfilter.org&gt;
Cc: Paolo Abeni &lt;pabeni@redhat.com&gt;
Cc: Petr Mladek &lt;pmladek@suse.com&gt;
Cc: Praveen Kaligineedi &lt;pkaligineedi@google.com&gt;
Cc: Ray Jui &lt;rjui@broadcom.com&gt;
Cc: Robert Jarzmik &lt;robert.jarzmik@free.fr&gt;
Cc: Rodrigo Vivi &lt;rodrigo.vivi@intel.com&gt;
Cc: Roger Pau Monné &lt;roger.pau@citrix.com&gt;
Cc: Russell King &lt;linux@armlinux.org.uk&gt;
Cc: Scott Branden &lt;sbranden@broadcom.com&gt;
Cc: Shailend Chand &lt;shailend@google.com&gt;
Cc: Simona Vetter &lt;simona@ffwll.ch&gt;
Cc: Simon Horman &lt;horms@kernel.org&gt;
Cc: Sven Schnelle &lt;svens@linux.ibm.com&gt;
Cc: Takashi Iwai &lt;tiwai@suse.com&gt;
Cc: Thomas Hellström &lt;thomas.hellstrom@linux.intel.com&gt;
Cc: Thomas Zimmermann &lt;tzimmermann@suse.de&gt;
Cc: Vasily Gorbik &lt;gor@linux.ibm.com&gt;
Cc: Xiubo Li &lt;xiubli@redhat.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>scripts/nsdeps: get 'make nsdeps' working again</title>
<updated>2024-12-03T16:22:25Z</updated>
<author>
<name>Masahiro Yamada</name>
<email>masahiroy@kernel.org</email>
</author>
<published>2024-12-03T10:21:05Z</published>
<link rel='alternate' type='text/html' href='https://git.kobert.dev/pm24.git/commit/?id=62aa6f2ede976dfb3539e59ee55c62cfd3c3faa3'/>
<id>urn:sha1:62aa6f2ede976dfb3539e59ee55c62cfd3c3faa3</id>
<content type='text'>
Since commit cdd30ebb1b9f ("module: Convert symbol namespace to string
literal"), when MODULE_IMPORT_NS() is missing, 'make nsdeps' inserts
pointless code:

    MODULE_IMPORT_NS("ns");

Here, "ns" is not a namespace, but the variable in the semantic patch.
It must not be quoted. Instead, a string literal must be passed to
Coccinelle.

Fixes: cdd30ebb1b9f ("module: Convert symbol namespace to string literal")
Signed-off-by: Masahiro Yamada &lt;masahiroy@kernel.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>module: Convert symbol namespace to string literal</title>
<updated>2024-12-02T19:34:44Z</updated>
<author>
<name>Peter Zijlstra</name>
<email>peterz@infradead.org</email>
</author>
<published>2024-12-02T14:59:47Z</published>
<link rel='alternate' type='text/html' href='https://git.kobert.dev/pm24.git/commit/?id=cdd30ebb1b9f36159d66f088b61aee264e649d7a'/>
<id>urn:sha1:cdd30ebb1b9f36159d66f088b61aee264e649d7a</id>
<content type='text'>
Clean up the existing export namespace code along the same lines of
commit 33def8498fdd ("treewide: Convert macro and uses of __section(foo)
to __section("foo")") and for the same reason, it is not desired for the
namespace argument to be a macro expansion itself.

Scripted using

  git grep -l -e MODULE_IMPORT_NS -e EXPORT_SYMBOL_NS | while read file;
  do
    awk -i inplace '
      /^#define EXPORT_SYMBOL_NS/ {
        gsub(/__stringify\(ns\)/, "ns");
        print;
        next;
      }
      /^#define MODULE_IMPORT_NS/ {
        gsub(/__stringify\(ns\)/, "ns");
        print;
        next;
      }
      /MODULE_IMPORT_NS/ {
        $0 = gensub(/MODULE_IMPORT_NS\(([^)]*)\)/, "MODULE_IMPORT_NS(\"\\1\")", "g");
      }
      /EXPORT_SYMBOL_NS/ {
        if ($0 ~ /(EXPORT_SYMBOL_NS[^(]*)\(([^,]+),/) {
  	if ($0 !~ /(EXPORT_SYMBOL_NS[^(]*)\(([^,]+), ([^)]+)\)/ &amp;&amp;
  	    $0 !~ /(EXPORT_SYMBOL_NS[^(]*)\(\)/ &amp;&amp;
  	    $0 !~ /^my/) {
  	  getline line;
  	  gsub(/[[:space:]]*\\$/, "");
  	  gsub(/[[:space:]]/, "", line);
  	  $0 = $0 " " line;
  	}

  	$0 = gensub(/(EXPORT_SYMBOL_NS[^(]*)\(([^,]+), ([^)]+)\)/,
  		    "\\1(\\2, \"\\3\")", "g");
        }
      }
      { print }' $file;
  done

Requested-by: Masahiro Yamada &lt;masahiroy@kernel.org&gt;
Signed-off-by: Peter Zijlstra (Intel) &lt;peterz@infradead.org&gt;
Link: https://mail.google.com/mail/u/2/#inbox/FMfcgzQXKWgMmjdFwwdsfgxzKpVHWPlc
Acked-by: Greg KH &lt;gregkh@linuxfoundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>Reduce Coccinelle choices in string_choices.cocci</title>
<updated>2024-09-28T19:33:11Z</updated>
<author>
<name>Julia Lawall</name>
<email>Julia.Lawall@inria.fr</email>
</author>
<published>2024-09-28T19:26:22Z</published>
<link rel='alternate' type='text/html' href='https://git.kobert.dev/pm24.git/commit/?id=4003ba664bd16f5a969cc883295a9eb5a5aef19e'/>
<id>urn:sha1:4003ba664bd16f5a969cc883295a9eb5a5aef19e</id>
<content type='text'>
The isomorphism neg_if_exp negates the test of a ?: conditional,
making it unnecessary to have an explicit case for a negated test
with the branches inverted.

At the same time, we can disable neg_if_exp in cases where a
different API function may be more suitable for a negated test.

Finally, in the non-patch cases, E matches an expression with
parentheses around it, so there is no need to mention ()
explicitly in the pattern.  The () are still needed in the patch
cases, because we want to drop them, if they are present.

Signed-off-by: Julia Lawall &lt;Julia.Lawall@inria.fr&gt;
</content>
</entry>
<entry>
<title>coccinelle: Remove unnecessary parentheses for only one possible change.</title>
<updated>2024-09-28T19:23:31Z</updated>
<author>
<name>Hongbo Li</name>
<email>lihongbo22@huawei.com</email>
</author>
<published>2024-09-11T01:09:27Z</published>
<link rel='alternate' type='text/html' href='https://git.kobert.dev/pm24.git/commit/?id=f584e3752ca7bb1f8849a85816b3c974f1aa67ec'/>
<id>urn:sha1:f584e3752ca7bb1f8849a85816b3c974f1aa67ec</id>
<content type='text'>
The parentheses are only needed if there is a disjunction, ie a
set of possible changes. If there is only one pattern, we can
remove these parentheses. Just like the format:

  -  x
  +  y

not:

  (
  -  x
  +  y
  )

Signed-off-by: Hongbo Li &lt;lihongbo22@huawei.com&gt;
Signed-off-by: Julia Lawall &lt;Julia.Lawall@inria.fr&gt;
</content>
</entry>
<entry>
<title>coccinelle: Add rules to find str_yes_no() replacements</title>
<updated>2024-09-28T19:23:21Z</updated>
<author>
<name>Hongbo Li</name>
<email>lihongbo22@huawei.com</email>
</author>
<published>2024-09-11T01:09:26Z</published>
<link rel='alternate' type='text/html' href='https://git.kobert.dev/pm24.git/commit/?id=253244cdf16a755039f9078b0a785176712f2584'/>
<id>urn:sha1:253244cdf16a755039f9078b0a785176712f2584</id>
<content type='text'>
As other rules done, we add rules for str_yes_no()
to check the relative opportunities.

Signed-off-by: Hongbo Li &lt;lihongbo22@huawei.com&gt;
Signed-off-by: Julia Lawall &lt;Julia.Lawall@inria.fr&gt;
</content>
</entry>
<entry>
<title>coccinelle: Add rules to find str_on_off() replacements</title>
<updated>2024-09-28T19:23:14Z</updated>
<author>
<name>Hongbo Li</name>
<email>lihongbo22@huawei.com</email>
</author>
<published>2024-09-11T01:09:25Z</published>
<link rel='alternate' type='text/html' href='https://git.kobert.dev/pm24.git/commit/?id=9b5b4810559d3716aef9fdc8d555e4db1a031749'/>
<id>urn:sha1:9b5b4810559d3716aef9fdc8d555e4db1a031749</id>
<content type='text'>
As other rules done, we add rules for str_on_off()
to check the relative opportunities.

Signed-off-by: Hongbo Li &lt;lihongbo22@huawei.com&gt;
Signed-off-by: Julia Lawall &lt;Julia.Lawall@inria.fr&gt;
</content>
</entry>
<entry>
<title>coccinelle: Add rules to find str_write_read() replacements</title>
<updated>2024-09-28T19:23:05Z</updated>
<author>
<name>Hongbo Li</name>
<email>lihongbo22@huawei.com</email>
</author>
<published>2024-09-11T01:09:24Z</published>
<link rel='alternate' type='text/html' href='https://git.kobert.dev/pm24.git/commit/?id=c81ca023c30691dcae543bd770e7a3a4c63263ff'/>
<id>urn:sha1:c81ca023c30691dcae543bd770e7a3a4c63263ff</id>
<content type='text'>
As other rules done, we add rules for str_write_read()
to check the relative opportunities.

Signed-off-by: Hongbo Li &lt;lihongbo22@huawei.com&gt;
Signed-off-by: Julia Lawall &lt;Julia.Lawall@inria.fr&gt;
</content>
</entry>
<entry>
<title>coccinelle: Add rules to find str_read_write() replacements</title>
<updated>2024-09-28T19:22:58Z</updated>
<author>
<name>Hongbo Li</name>
<email>lihongbo22@huawei.com</email>
</author>
<published>2024-09-11T01:09:23Z</published>
<link rel='alternate' type='text/html' href='https://git.kobert.dev/pm24.git/commit/?id=ba4b514a6f4ac420d872b8f16245e3ffa05c10a5'/>
<id>urn:sha1:ba4b514a6f4ac420d872b8f16245e3ffa05c10a5</id>
<content type='text'>
As other rules done, we add rules for str_read_write()
to check the relative opportunities.

Signed-off-by: Hongbo Li &lt;lihongbo22@huawei.com&gt;
Signed-off-by: Julia Lawall &lt;Julia.Lawall@inria.fr&gt;
</content>
</entry>
<entry>
<title>coccinelle: Add rules to find str_enable{d}_disable{d}() replacements</title>
<updated>2024-09-28T19:22:50Z</updated>
<author>
<name>Hongbo Li</name>
<email>lihongbo22@huawei.com</email>
</author>
<published>2024-09-11T01:09:22Z</published>
<link rel='alternate' type='text/html' href='https://git.kobert.dev/pm24.git/commit/?id=dd2275d349c2f02ceb6cd37f89b8b9920c602488'/>
<id>urn:sha1:dd2275d349c2f02ceb6cd37f89b8b9920c602488</id>
<content type='text'>
As other rules done, we add rules for str_enable{d}_
disable{d}() to check the relative opportunities.

Signed-off-by: Hongbo Li &lt;lihongbo22@huawei.com&gt;
Signed-off-by: Julia Lawall &lt;Julia.Lawall@inria.fr&gt;
</content>
</entry>
</feed>
