* [PATCH] scripts: kernel-doc: Bug fixed for erroneous warning
@ 2023-12-20 6:24 Muhammad Muzammil
2023-12-20 6:29 ` Randy Dunlap
` (2 more replies)
0 siblings, 3 replies; 6+ messages in thread
From: Muhammad Muzammil @ 2023-12-20 6:24 UTC (permalink / raw)
To: rdunlap, corbet, gustavoars
Cc: linux-doc, linux-kernel, linux-hardening, Muzammil Ashraf
From: Muzammil Ashraf <m.muzzammilashraf@gmail.com>
kernel-doc: fixed erroneous warning generated by '__counted_by'
Signed-off-by: Muzammil Ashraf <m.muzzammilashraf@gmail.com>
---
scripts/kernel-doc | 1 +
1 file changed, 1 insertion(+)
diff --git a/scripts/kernel-doc b/scripts/kernel-doc
index 1484127db104..ea9688df0e93 100755
--- a/scripts/kernel-doc
+++ b/scripts/kernel-doc
@@ -1661,6 +1661,7 @@ sub check_sections($$$$$) {
}
elsif (($decl_type eq "struct") or
($decl_type eq "union")) {
+ next if (index("@_", "__counted_by") != -1);
emit_warning("${file}:$.",
"Excess $decl_type member " .
"'$sects[$sx]' " .
--
2.27.0
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH] scripts: kernel-doc: Bug fixed for erroneous warning
2023-12-20 6:24 [PATCH] scripts: kernel-doc: Bug fixed for erroneous warning Muhammad Muzammil
@ 2023-12-20 6:29 ` Randy Dunlap
2023-12-20 6:35 ` Muhammad Muzammil
2023-12-20 6:30 ` Greg KH
2023-12-20 15:30 ` Jonathan Corbet
2 siblings, 1 reply; 6+ messages in thread
From: Randy Dunlap @ 2023-12-20 6:29 UTC (permalink / raw)
To: Muhammad Muzammil, corbet, gustavoars
Cc: linux-doc, linux-kernel, linux-hardening
Hi,
On 12/19/23 22:24, Muhammad Muzammil wrote:
> From: Muzammil Ashraf <m.muzzammilashraf@gmail.com>
>
> kernel-doc: fixed erroneous warning generated by '__counted_by'
>
> Signed-off-by: Muzammil Ashraf <m.muzzammilashraf@gmail.com>
> ---
> scripts/kernel-doc | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/scripts/kernel-doc b/scripts/kernel-doc
> index 1484127db104..ea9688df0e93 100755
> --- a/scripts/kernel-doc
> +++ b/scripts/kernel-doc
> @@ -1661,6 +1661,7 @@ sub check_sections($$$$$) {
> }
> elsif (($decl_type eq "struct") or
> ($decl_type eq "union")) {
> + next if (index("@_", "__counted_by") != -1);
> emit_warning("${file}:$.",
> "Excess $decl_type member " .
> "'$sects[$sx]' " .
One of both of these patches should be enough. Can you test these
instead of your patch, please?
https://lore.kernel.org/linux-doc/20231215001347.work.151-kees@kernel.org/
https://lore.kernel.org/linux-doc/87le9rjb4y.fsf@meer.lwn.net/
Thanks.
--
#Randy
https://people.kernel.org/tglx/notes-about-netiquette
https://subspace.kernel.org/etiquette.html
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] scripts: kernel-doc: Bug fixed for erroneous warning
2023-12-20 6:24 [PATCH] scripts: kernel-doc: Bug fixed for erroneous warning Muhammad Muzammil
2023-12-20 6:29 ` Randy Dunlap
@ 2023-12-20 6:30 ` Greg KH
2023-12-20 15:30 ` Jonathan Corbet
2 siblings, 0 replies; 6+ messages in thread
From: Greg KH @ 2023-12-20 6:30 UTC (permalink / raw)
To: Muhammad Muzammil
Cc: rdunlap, corbet, gustavoars, linux-doc, linux-kernel,
linux-hardening
On Wed, Dec 20, 2023 at 11:24:46AM +0500, Muhammad Muzammil wrote:
> From: Muzammil Ashraf <m.muzzammilashraf@gmail.com>
>
> kernel-doc: fixed erroneous warning generated by '__counted_by'
>
> Signed-off-by: Muzammil Ashraf <m.muzzammilashraf@gmail.com>
> ---
> scripts/kernel-doc | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/scripts/kernel-doc b/scripts/kernel-doc
> index 1484127db104..ea9688df0e93 100755
> --- a/scripts/kernel-doc
> +++ b/scripts/kernel-doc
> @@ -1661,6 +1661,7 @@ sub check_sections($$$$$) {
> }
> elsif (($decl_type eq "struct") or
> ($decl_type eq "union")) {
> + next if (index("@_", "__counted_by") != -1);
Please fix your editor to properly use tabs, and to set them to the
correct 8 column spacing.
thanks,
greg k-h
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] scripts: kernel-doc: Bug fixed for erroneous warning
2023-12-20 6:29 ` Randy Dunlap
@ 2023-12-20 6:35 ` Muhammad Muzammil
2023-12-20 6:49 ` Randy Dunlap
0 siblings, 1 reply; 6+ messages in thread
From: Muhammad Muzammil @ 2023-12-20 6:35 UTC (permalink / raw)
To: Randy Dunlap; +Cc: corbet, gustavoars, linux-doc, linux-kernel, linux-hardening
HI,
1) I already have the below patch but it does not work.
https://lore.kernel.org/linux-doc/20231215001347.work.151-kees@kernel.org/
2) When I applied the below patch. It works.
https://lore.kernel.org/linux-doc/87le9rjb4y.fsf@meer.lwn.net/
On Wed, Dec 20, 2023 at 11:29 AM Randy Dunlap <rdunlap@infradead.org> wrote:
>
> Hi,
>
> On 12/19/23 22:24, Muhammad Muzammil wrote:
> > From: Muzammil Ashraf <m.muzzammilashraf@gmail.com>
> >
> > kernel-doc: fixed erroneous warning generated by '__counted_by'
> >
> > Signed-off-by: Muzammil Ashraf <m.muzzammilashraf@gmail.com>
> > ---
> > scripts/kernel-doc | 1 +
> > 1 file changed, 1 insertion(+)
> >
> > diff --git a/scripts/kernel-doc b/scripts/kernel-doc
> > index 1484127db104..ea9688df0e93 100755
> > --- a/scripts/kernel-doc
> > +++ b/scripts/kernel-doc
> > @@ -1661,6 +1661,7 @@ sub check_sections($$$$$) {
> > }
> > elsif (($decl_type eq "struct") or
> > ($decl_type eq "union")) {
> > + next if (index("@_", "__counted_by") != -1);
> > emit_warning("${file}:$.",
> > "Excess $decl_type member " .
> > "'$sects[$sx]' " .
>
> One of both of these patches should be enough. Can you test these
> instead of your patch, please?
>
> https://lore.kernel.org/linux-doc/20231215001347.work.151-kees@kernel.org/
>
> https://lore.kernel.org/linux-doc/87le9rjb4y.fsf@meer.lwn.net/
>
> Thanks.
>
> --
> #Randy
> https://people.kernel.org/tglx/notes-about-netiquette
> https://subspace.kernel.org/etiquette.html
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] scripts: kernel-doc: Bug fixed for erroneous warning
2023-12-20 6:35 ` Muhammad Muzammil
@ 2023-12-20 6:49 ` Randy Dunlap
0 siblings, 0 replies; 6+ messages in thread
From: Randy Dunlap @ 2023-12-20 6:49 UTC (permalink / raw)
To: Muhammad Muzammil
Cc: corbet, gustavoars, linux-doc, linux-kernel, linux-hardening
On 12/19/23 22:35, Muhammad Muzammil wrote:
> HI,
>
> 1) I already have the below patch but it does not work.
> https://lore.kernel.org/linux-doc/20231215001347.work.151-kees@kernel.org/
>
> 2) When I applied the below patch. It works.
> https://lore.kernel.org/linux-doc/87le9rjb4y.fsf@meer.lwn.net/
Thanks!
> On Wed, Dec 20, 2023 at 11:29 AM Randy Dunlap <rdunlap@infradead.org> wrote:
>>
>> Hi,
>>
>> On 12/19/23 22:24, Muhammad Muzammil wrote:
>>> From: Muzammil Ashraf <m.muzzammilashraf@gmail.com>
>>>
>>> kernel-doc: fixed erroneous warning generated by '__counted_by'
>>>
>>> Signed-off-by: Muzammil Ashraf <m.muzzammilashraf@gmail.com>
>>> ---
>>> scripts/kernel-doc | 1 +
>>> 1 file changed, 1 insertion(+)
>>>
>>> diff --git a/scripts/kernel-doc b/scripts/kernel-doc
>>> index 1484127db104..ea9688df0e93 100755
>>> --- a/scripts/kernel-doc
>>> +++ b/scripts/kernel-doc
>>> @@ -1661,6 +1661,7 @@ sub check_sections($$$$$) {
>>> }
>>> elsif (($decl_type eq "struct") or
>>> ($decl_type eq "union")) {
>>> + next if (index("@_", "__counted_by") != -1);
>>> emit_warning("${file}:$.",
>>> "Excess $decl_type member " .
>>> "'$sects[$sx]' " .
>>
>> One of both of these patches should be enough. Can you test these
>> instead of your patch, please?
>>
>> https://lore.kernel.org/linux-doc/20231215001347.work.151-kees@kernel.org/
>>
>> https://lore.kernel.org/linux-doc/87le9rjb4y.fsf@meer.lwn.net/
>>
>> Thanks.
>>
>> --
>> #Randy
>> https://people.kernel.org/tglx/notes-about-netiquette
>> https://subspace.kernel.org/etiquette.html
--
#Randy
https://people.kernel.org/tglx/notes-about-netiquette
https://subspace.kernel.org/etiquette.html
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] scripts: kernel-doc: Bug fixed for erroneous warning
2023-12-20 6:24 [PATCH] scripts: kernel-doc: Bug fixed for erroneous warning Muhammad Muzammil
2023-12-20 6:29 ` Randy Dunlap
2023-12-20 6:30 ` Greg KH
@ 2023-12-20 15:30 ` Jonathan Corbet
2 siblings, 0 replies; 6+ messages in thread
From: Jonathan Corbet @ 2023-12-20 15:30 UTC (permalink / raw)
To: Muhammad Muzammil, rdunlap, gustavoars
Cc: linux-doc, linux-kernel, linux-hardening, Muzammil Ashraf
Muhammad Muzammil <m.muzzammilashraf@gmail.com> writes:
> From: Muzammil Ashraf <m.muzzammilashraf@gmail.com>
>
> kernel-doc: fixed erroneous warning generated by '__counted_by'
>
> Signed-off-by: Muzammil Ashraf <m.muzzammilashraf@gmail.com>
> ---
> scripts/kernel-doc | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/scripts/kernel-doc b/scripts/kernel-doc
> index 1484127db104..ea9688df0e93 100755
> --- a/scripts/kernel-doc
> +++ b/scripts/kernel-doc
> @@ -1661,6 +1661,7 @@ sub check_sections($$$$$) {
> }
> elsif (($decl_type eq "struct") or
> ($decl_type eq "union")) {
> + next if (index("@_", "__counted_by") != -1);
> emit_warning("${file}:$.",
> "Excess $decl_type member " .
> "'$sects[$sx]' " .
Could you give an example of the warnings that this patch addresses?
I've not seen any caused by __counted_by since f600c77aeaff was applied
to docs-next. What did it miss?
Thanks,
jon
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2023-12-20 15:30 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-12-20 6:24 [PATCH] scripts: kernel-doc: Bug fixed for erroneous warning Muhammad Muzammil
2023-12-20 6:29 ` Randy Dunlap
2023-12-20 6:35 ` Muhammad Muzammil
2023-12-20 6:49 ` Randy Dunlap
2023-12-20 6:30 ` Greg KH
2023-12-20 15:30 ` Jonathan Corbet
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox