lkml.org 
[lkml]   [2019]   [Mar]   [26]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH] Change in comment for the list_empty() routine.
Date
Hello,

In one of the observations it was noticed that list_empty() routine
returns true when the list is empty (head->next == head) OR False
otherwise. Hence the proposed patch.

Thank you,
Nitin Yewale

Signed-off-by: Nitin U. Yewale <nyewale@redhat.com>
---
drivers/gpu/drm/nouveau/include/nvif/list.h | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/drivers/gpu/drm/nouveau/include/nvif/list.h b/drivers/gpu/drm/nouveau/include/nvif/list.h
index 8af5d144ecb0..12bf7e3333e4 100644
--- a/drivers/gpu/drm/nouveau/include/nvif/list.h
+++ b/drivers/gpu/drm/nouveau/include/nvif/list.h
@@ -226,10 +226,7 @@ static inline void list_move_tail(struct list_head *list,
/**
* Check if the list is empty.
*
- * Example:
- * list_empty(&bar->list_of_foos);
- *
- * @return True if the list contains one or more elements or False otherwise.
+ * @return True if the list is empty (head->next == head) or False otherwise.
*/
static inline bool
list_empty(struct list_head *head)
--
2.17.2
\
 
 \ /
  Last update: 2019-03-26 07:21    [W:0.025 / U:0.248 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site