mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Wen Yang <wen.yang@linux.dev>
To: Nicolas Schier <nicolas@fjasle.eu>
Cc: Masahiro Yamada <masahiroy@kernel.org>,
	Andrew Morton <akpm@linux-foundation.org>,
	Miguel Ojeda <ojeda@kernel.org>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] scripts: headers_install: fix a false positive
Date: Fri, 16 May 2025 23:45:23 +0800	[thread overview]
Message-ID: <3b09f8b7-579b-441b-8c0e-2dbab7ac1740@linux.dev> (raw)
In-Reply-To: <20250515-magpie-of-ideal-pluck-c6e323@bergen>



On 5/15/25 19:32, Nicolas Schier wrote:
> On Wed, May 14, 2025 at 12:00:56AM +0800, Wen Yang wrote:
>> The current implementation only handles C89 style comments (/*... */) in
>> the code, and there are false positives for C99 style comments (//...).
>>
>> This patch fixes this issue.
>>
>> Signed-off-by: Wen Yang <wen.yang@linux.dev>
>> ---
>>   scripts/headers_install.sh | 1 +
>>   1 file changed, 1 insertion(+)
>>
>> diff --git a/scripts/headers_install.sh b/scripts/headers_install.sh
>> index 6bbccb43f7e7..41722bcc8668 100755
>> --- a/scripts/headers_install.sh
>> +++ b/scripts/headers_install.sh
>> @@ -44,6 +44,7 @@ scripts/unifdef -U__KERNEL__ -D__EXPORTED_HEADERS__ $TMPFILE > $OUTFILE
>>   # Remove /* ... */ style comments, and find CONFIG_ references in code
>>   configs=$(sed -e '
>>   :comment
>> +	s://.*::
>>   	s:/\*[^*][^*]*:/*:
>>   	s:/\*\*\**\([^/]\):/*\1:
>>   	t comment
>> -- 
>> 2.25.1
> 
> thanks.  The patch looks good to me, but I cannot find any false
> positives.  Have you found any concrete?
> 

Thanks. We have enhanced dmabuf on our SoC platform and modified the 
include/uapi/linux/dma-buf.h file, and then found this issue.

--
Best wishes,
Wen

  reply	other threads:[~2025-05-16 15:45 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-05-13 16:00 Wen Yang
2025-05-15 11:32 ` Nicolas Schier
2025-05-16 15:45   ` Wen Yang [this message]
2025-06-30 13:11     ` Masahiro Yamada

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=3b09f8b7-579b-441b-8c0e-2dbab7ac1740@linux.dev \
    --to=wen.yang@linux.dev \
    --cc=akpm@linux-foundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=masahiroy@kernel.org \
    --cc=nicolas@fjasle.eu \
    --cc=ojeda@kernel.org \
    /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

all inboxes | Powered by JetHome®