All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] kernel-doc: Add support for __deprecated
@ 2021-04-27 11:48 Matthew Wilcox
  2021-04-27 15:59 ` Jonathan Corbet
  0 siblings, 1 reply; 2+ messages in thread
From: Matthew Wilcox @ 2021-04-27 11:48 UTC (permalink / raw)
  To: linux-doc; +Cc: Jonathan Corbet, mchehab+huawei, yashsri421, lukas.bulwahn

The current linux-next tree has a new error:

./Documentation/gpu/drm-mm:445: ./drivers/gpu/drm/drm_prime.c:994: WARNING: Error in declarator or parameters
Invalid C declaration: Expecting "(" in parameters. [error at 17]
  int __deprecated drm_prime_sg_to_page_array (struct sg_table *sgt, struct page **pages, int max_entries)
  -----------------^

While we might consider that documenting a deprecated interface is not
necessarily best practice, removing the error is easy.

Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>

diff --git a/scripts/kernel-doc b/scripts/kernel-doc
index 2a85d34fdcd0..4840e748fca8 100755
--- a/scripts/kernel-doc
+++ b/scripts/kernel-doc
@@ -1777,6 +1777,7 @@ sub dump_function($$) {
     $prototype =~ s/^noinline +//;
     $prototype =~ s/__init +//;
     $prototype =~ s/__init_or_module +//;
+    $prototype =~ s/__deprecated +//;
     $prototype =~ s/__flatten +//;
     $prototype =~ s/__meminit +//;
     $prototype =~ s/__must_check +//;

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

* Re: [PATCH] kernel-doc: Add support for __deprecated
  2021-04-27 11:48 [PATCH] kernel-doc: Add support for __deprecated Matthew Wilcox
@ 2021-04-27 15:59 ` Jonathan Corbet
  0 siblings, 0 replies; 2+ messages in thread
From: Jonathan Corbet @ 2021-04-27 15:59 UTC (permalink / raw)
  To: Matthew Wilcox, linux-doc; +Cc: mchehab+huawei, yashsri421, lukas.bulwahn

Matthew Wilcox <willy@infradead.org> writes:

> The current linux-next tree has a new error:
>
> ./Documentation/gpu/drm-mm:445: ./drivers/gpu/drm/drm_prime.c:994: WARNING: Error in declarator or parameters
> Invalid C declaration: Expecting "(" in parameters. [error at 17]
>   int __deprecated drm_prime_sg_to_page_array (struct sg_table *sgt, struct page **pages, int max_entries)
>   -----------------^
>
> While we might consider that documenting a deprecated interface is not
> necessarily best practice, removing the error is easy.
>
> Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
>
> diff --git a/scripts/kernel-doc b/scripts/kernel-doc
> index 2a85d34fdcd0..4840e748fca8 100755
> --- a/scripts/kernel-doc
> +++ b/scripts/kernel-doc
> @@ -1777,6 +1777,7 @@ sub dump_function($$) {
>      $prototype =~ s/^noinline +//;
>      $prototype =~ s/__init +//;
>      $prototype =~ s/__init_or_module +//;
> +    $prototype =~ s/__deprecated +//;
>      $prototype =~ s/__flatten +//;
>      $prototype =~ s/__meminit +//;
>      $prototype =~ s/__must_check +//;

Applied, thanks.

jon

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

end of thread, other threads:[~2021-04-27 15:59 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-27 11:48 [PATCH] kernel-doc: Add support for __deprecated Matthew Wilcox
2021-04-27 15:59 ` Jonathan Corbet

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.