From: Markus Elfring <Markus.Elfring@web.de>
To: cocci@inria.fr
Subject: [cocci] Test case consequences for a special SmPL disjunction
Date: Sun, 9 Nov 2025 18:23:58 +0100 [thread overview]
Message-ID: <8be602f8-5336-49f9-9ca4-d00ed372a192@web.de> (raw)
Hello,
I got into the mood to try another source code transformation out which
should be achievable also by the means of the semantic patch language.
@replacements@
expression adev, fwnode, x_name;
@@
(
-is_acpi_data_node(fwnode) ? (!strcmp(to_acpi_data_node(fwnode)->name, x_name)) : false
+acpi_data_node_match(fwnode, x_name)
|
- &adev->fwnode
+acpi_fwnode_handle(adev)
)
Questionable test result (according to the software combination “Coccinelle 1.3.0”):
Markus_Elfring@Sonne:…/Projekte/Coccinelle/Probe> /usr/bin/spatch --parse-cocci use_selected_acpi_functions2.cocci
…
minus: parse error:
File "use_selected_acpi_functions2.cocci", line 8, column 9, charpos = 190
around = 'fwnode',
whole content = - &adev->fwnode
But I know that the elements from the affected SmPL disjunction would be accepted
if their SmPL code would be parsed separately.
https://elixir.bootlin.com/linux/v6.18-rc4/source/include/acpi/acpi_bus.h#L549-L559
Under which circumstances will data processing become better supported here?
Regards,
Markus
reply other threads:[~2025-11-09 17:24 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=8be602f8-5336-49f9-9ca4-d00ed372a192@web.de \
--to=markus.elfring@web.de \
--cc=cocci@inria.fr \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).