linux-doc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v1] scripts: kernel-doc: Restore anonymous enum parsing
@ 2020-11-02 17:06 Andy Shevchenko
  2020-11-02 17:27 ` Mauro Carvalho Chehab
  2020-11-13 22:10 ` Jonathan Corbet
  0 siblings, 2 replies; 6+ messages in thread
From: Andy Shevchenko @ 2020-11-02 17:06 UTC (permalink / raw)
  To: Jonathan Corbet, linux-doc
  Cc: Andy Shevchenko, kernel test robot, Mauro Carvalho Chehab

The commit d38c8cfb0571 ("scripts: kernel-doc: add support for typedef enum")
broke anonymous enum parsing. Restore it by relying on members rather than
its name.

Fixes: d38c8cfb0571 ("scripts: kernel-doc: add support for typedef enum")
Reported-by: kernel test robot <lkp@intel.com>
Cc: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
 scripts/kernel-doc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/kernel-doc b/scripts/kernel-doc
index f699cf05d409..9b6ddeb097e9 100755
--- a/scripts/kernel-doc
+++ b/scripts/kernel-doc
@@ -1390,7 +1390,7 @@ sub dump_enum($$) {
 	$members = $2;
     }
 
-    if ($declaration_name) {
+    if ($members) {
 	my %_members;
 
 	$members =~ s/\s+$//;
-- 
2.28.0


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH v1] scripts: kernel-doc: Restore anonymous enum parsing
  2020-11-02 17:06 [PATCH v1] scripts: kernel-doc: Restore anonymous enum parsing Andy Shevchenko
@ 2020-11-02 17:27 ` Mauro Carvalho Chehab
  2020-11-02 17:48   ` Andy Shevchenko
  2020-11-13 22:10 ` Jonathan Corbet
  1 sibling, 1 reply; 6+ messages in thread
From: Mauro Carvalho Chehab @ 2020-11-02 17:27 UTC (permalink / raw)
  To: Andy Shevchenko; +Cc: Jonathan Corbet, linux-doc, kernel test robot

Em Mon,  2 Nov 2020 19:06:37 +0200
Andy Shevchenko <andriy.shevchenko@linux.intel.com> escreveu:

> The commit d38c8cfb0571 ("scripts: kernel-doc: add support for typedef enum")
> broke anonymous enum parsing. Restore it by relying on members rather than
> its name.
> 
> Fixes: d38c8cfb0571 ("scripts: kernel-doc: add support for typedef enum")
> Reported-by: kernel test robot <lkp@intel.com>
> Cc: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>

Patch looks ok to me. Do you have an example about using it for
anonymous enum?

> ---
>  scripts/kernel-doc | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/scripts/kernel-doc b/scripts/kernel-doc
> index f699cf05d409..9b6ddeb097e9 100755
> --- a/scripts/kernel-doc
> +++ b/scripts/kernel-doc
> @@ -1390,7 +1390,7 @@ sub dump_enum($$) {
>  	$members = $2;
>      }
>  
> -    if ($declaration_name) {
> +    if ($members) {
>  	my %_members;
>  
>  	$members =~ s/\s+$//;



Thanks,
Mauro

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH v1] scripts: kernel-doc: Restore anonymous enum parsing
  2020-11-02 17:27 ` Mauro Carvalho Chehab
@ 2020-11-02 17:48   ` Andy Shevchenko
  2020-11-02 18:10     ` Mauro Carvalho Chehab
  0 siblings, 1 reply; 6+ messages in thread
From: Andy Shevchenko @ 2020-11-02 17:48 UTC (permalink / raw)
  To: Mauro Carvalho Chehab; +Cc: Jonathan Corbet, linux-doc, kernel test robot

On Mon, Nov 02, 2020 at 06:27:43PM +0100, Mauro Carvalho Chehab wrote:
> Em Mon,  2 Nov 2020 19:06:37 +0200
> Andy Shevchenko <andriy.shevchenko@linux.intel.com> escreveu:
> 
> > The commit d38c8cfb0571 ("scripts: kernel-doc: add support for typedef enum")
> > broke anonymous enum parsing. Restore it by relying on members rather than
> > its name.
> > 
> > Fixes: d38c8cfb0571 ("scripts: kernel-doc: add support for typedef enum")
> > Reported-by: kernel test robot <lkp@intel.com>
> > Cc: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
> > Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
> 
> Patch looks ok to me. Do you have an example about using it for
> anonymous enum?

drivers/pinctrl/intel/pinctrl-intel.c

-- 
With Best Regards,
Andy Shevchenko



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH v1] scripts: kernel-doc: Restore anonymous enum parsing
  2020-11-02 17:48   ` Andy Shevchenko
@ 2020-11-02 18:10     ` Mauro Carvalho Chehab
  2020-11-11 17:13       ` Andy Shevchenko
  0 siblings, 1 reply; 6+ messages in thread
From: Mauro Carvalho Chehab @ 2020-11-02 18:10 UTC (permalink / raw)
  To: Andy Shevchenko; +Cc: Jonathan Corbet, linux-doc, kernel test robot

Em Mon, 2 Nov 2020 19:48:46 +0200
Andy Shevchenko <andriy.shevchenko@linux.intel.com> escreveu:

> On Mon, Nov 02, 2020 at 06:27:43PM +0100, Mauro Carvalho Chehab wrote:
> > Em Mon,  2 Nov 2020 19:06:37 +0200
> > Andy Shevchenko <andriy.shevchenko@linux.intel.com> escreveu:
> >   
> > > The commit d38c8cfb0571 ("scripts: kernel-doc: add support for typedef enum")
> > > broke anonymous enum parsing. Restore it by relying on members rather than
> > > its name.
> > > 
> > > Fixes: d38c8cfb0571 ("scripts: kernel-doc: add support for typedef enum")
> > > Reported-by: kernel test robot <lkp@intel.com>
> > > Cc: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
> > > Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>  
> > 
> > Patch looks ok to me. Do you have an example about using it for
> > anonymous enum?  
> 
> drivers/pinctrl/intel/pinctrl-intel.c
> 

Thanks! 

Both include/linux/phy.h and drivers/pinctrl/intel/pinctrl-intel.c
are parsing fine after your patch.

So,

Reviewed-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>

Thanks,
Mauro

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH v1] scripts: kernel-doc: Restore anonymous enum parsing
  2020-11-02 18:10     ` Mauro Carvalho Chehab
@ 2020-11-11 17:13       ` Andy Shevchenko
  0 siblings, 0 replies; 6+ messages in thread
From: Andy Shevchenko @ 2020-11-11 17:13 UTC (permalink / raw)
  To: Mauro Carvalho Chehab; +Cc: Jonathan Corbet, linux-doc, kernel test robot

On Mon, Nov 02, 2020 at 07:10:41PM +0100, Mauro Carvalho Chehab wrote:
> Em Mon, 2 Nov 2020 19:48:46 +0200
> Andy Shevchenko <andriy.shevchenko@linux.intel.com> escreveu:
> 
> > On Mon, Nov 02, 2020 at 06:27:43PM +0100, Mauro Carvalho Chehab wrote:
> > > Em Mon,  2 Nov 2020 19:06:37 +0200
> > > Andy Shevchenko <andriy.shevchenko@linux.intel.com> escreveu:
> > >   
> > > > The commit d38c8cfb0571 ("scripts: kernel-doc: add support for typedef enum")
> > > > broke anonymous enum parsing. Restore it by relying on members rather than
> > > > its name.
> > > > 
> > > > Fixes: d38c8cfb0571 ("scripts: kernel-doc: add support for typedef enum")
> > > > Reported-by: kernel test robot <lkp@intel.com>
> > > > Cc: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
> > > > Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>  
> > > 
> > > Patch looks ok to me. Do you have an example about using it for
> > > anonymous enum?  
> > 
> > drivers/pinctrl/intel/pinctrl-intel.c
> > 
> 
> Thanks! 
> 
> Both include/linux/phy.h and drivers/pinctrl/intel/pinctrl-intel.c
> are parsing fine after your patch.
> 
> So,
> 
> Reviewed-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>

Thanks!

Jonathan, can we have this applied?

-- 
With Best Regards,
Andy Shevchenko



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH v1] scripts: kernel-doc: Restore anonymous enum parsing
  2020-11-02 17:06 [PATCH v1] scripts: kernel-doc: Restore anonymous enum parsing Andy Shevchenko
  2020-11-02 17:27 ` Mauro Carvalho Chehab
@ 2020-11-13 22:10 ` Jonathan Corbet
  1 sibling, 0 replies; 6+ messages in thread
From: Jonathan Corbet @ 2020-11-13 22:10 UTC (permalink / raw)
  To: Andy Shevchenko; +Cc: linux-doc, kernel test robot, Mauro Carvalho Chehab

On Mon,  2 Nov 2020 19:06:37 +0200
Andy Shevchenko <andriy.shevchenko@linux.intel.com> wrote:

> The commit d38c8cfb0571 ("scripts: kernel-doc: add support for typedef enum")
> broke anonymous enum parsing. Restore it by relying on members rather than
> its name.
> 
> Fixes: d38c8cfb0571 ("scripts: kernel-doc: add support for typedef enum")
> Reported-by: kernel test robot <lkp@intel.com>
> Cc: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
> ---
>  scripts/kernel-doc | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/scripts/kernel-doc b/scripts/kernel-doc
> index f699cf05d409..9b6ddeb097e9 100755
> --- a/scripts/kernel-doc
> +++ b/scripts/kernel-doc
> @@ -1390,7 +1390,7 @@ sub dump_enum($$) {
>  	$members = $2;
>      }
>  
> -    if ($declaration_name) {
> +    if ($members) {
>  	my %_members;

Applied, thanks.

jon

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2020-11-13 22:11 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-11-02 17:06 [PATCH v1] scripts: kernel-doc: Restore anonymous enum parsing Andy Shevchenko
2020-11-02 17:27 ` Mauro Carvalho Chehab
2020-11-02 17:48   ` Andy Shevchenko
2020-11-02 18:10     ` Mauro Carvalho Chehab
2020-11-11 17:13       ` Andy Shevchenko
2020-11-13 22:10 ` Jonathan Corbet

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 NNTP newsgroup(s).