net: Add kerneldoc comment to napi_complete_done

Message ID 20230129132618.1361421-1-j.neuschaefer@gmx.net
State New
Headers
Series net: Add kerneldoc comment to napi_complete_done |

Commit Message

Jonathan Neuschäfer Jan. 29, 2023, 1:26 p.m. UTC
  Document napi_complete_done, so that it shows up in HTML documentation.

Signed-off-by: Jonathan Neuschäfer <j.neuschaefer@gmx.net>
---
 include/linux/netdevice.h | 9 +++++++++
 1 file changed, 9 insertions(+)

--
2.39.0
  

Comments

Jakub Kicinski Jan. 31, 2023, 2:26 a.m. UTC | #1
On Sun, 29 Jan 2023 14:26:18 +0100 Jonathan Neuschäfer wrote:
> Document napi_complete_done, so that it shows up in HTML documentation.

> diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
> index aad12a179e540..828e58791baa1 100644
> --- a/include/linux/netdevice.h
> +++ b/include/linux/netdevice.h

Please put the doc in the source file, rather than the header.
  
Jonathan Neuschäfer Jan. 31, 2023, 8:54 p.m. UTC | #2
On Mon, Jan 30, 2023 at 06:26:22PM -0800, Jakub Kicinski wrote:
> On Sun, 29 Jan 2023 14:26:18 +0100 Jonathan Neuschäfer wrote:
> > Document napi_complete_done, so that it shows up in HTML documentation.
> 
> > diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
> > index aad12a179e540..828e58791baa1 100644
> > --- a/include/linux/netdevice.h
> > +++ b/include/linux/netdevice.h
> 
> Please put the doc in the source file, rather than the header.

Will do.

Thanks,
Jonathan
  

Patch

diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
index aad12a179e540..828e58791baa1 100644
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
@@ -504,7 +504,16 @@  static inline bool napi_reschedule(struct napi_struct *napi)
 	return false;
 }

+/**
+ *	napi_complete_done - NAPI processing complete
+ *	@n: NAPI context
+ *	@work_done: The number of packets that were processed
+ *
+ * Mark NAPI processing as complete.
+ * Return false if device should avoid rearming interrupts.
+ */
 bool napi_complete_done(struct napi_struct *n, int work_done);
+
 /**
  *	napi_complete - NAPI processing complete
  *	@n: NAPI context