Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F107160617
D3983.id9631.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D3983.id9631.diff
View Options
Index: share/man/man3/queue.3
===================================================================
--- share/man/man3/queue.3
+++ share/man/man3/queue.3
@@ -28,10 +28,12 @@
.\" @(#)queue.3 8.2 (Berkeley) 1/24/94
.\" $FreeBSD$
.\"
-.Dd June 24, 2015
+.Dd October 22, 2015
.Dt QUEUE 3
.Os
.Sh NAME
+.Nm queue(3)
+\(em
.Nm SLIST_CLASS_ENTRY ,
.Nm SLIST_CLASS_HEAD ,
.Nm SLIST_EMPTY ,
@@ -1244,6 +1246,47 @@
}
TAILQ_INIT(&head);
.Ed
+.Sh DIAGNOSTICS
+In the kernel (with
+.Va INVARIANTS
+enabled), a number of other macros are available for debugging
+.Nm :
+.Bl -hang -offset indent
+.It Fn QMD_LIST_CHECK_HEAD "LIST_HEAD *head" "LIST_ENTRY NAME"
+.Pp
+If the list is non-empty, validates that the first element of the list points
+back at
+.Fa head .
+.It Fn QMD_LIST_CHECK_NEXT "TYPE *elm" "LIST_ENTRY NAME"
+.Pp
+If an element follows
+.Fa elm
+in the list, validates that the next element points back at
+.Fa elm .
+.It Fn QMD_LIST_CHECK_PREV "TYPE *elm" "LIST_ENTRY NAME"
+.Pp
+Validates that the previous element (or head of the list) points to
+.Fa elm .
+.It Fn QMD_TAILQ_CHECK_HEAD "TAILQ_HEAD *head" "TAILQ_ENTRY NAME"
+.Pp
+If the tailq is non-empty, validates that the first element of the tailq points
+back at
+.Fa head .
+.It Fn QMD_TAILQ_CHECK_TAIL "TAILQ_HEAD *head" "TAILQ_ENTRY NAME"
+.Pp
+Validates that the tail of the tailq is a pointer to pointer to
+.Va NULL .
+.It Fn QMD_TAILQ_CHECK_NEXT "TYPE *elm" "TAILQ_ENTRY NAME"
+.Pp
+If an element follows
+.Fa elm
+in the tailq, validates that the next element points back at
+.Fa elm .
+.It Fn QMD_TAILQ_CHECK_PREV "TYPE *elm" "TAILQ_ENTRY NAME"
+.Pp
+Validates that the previous element (or head of the tailq) points to
+.Fa elm .
+.El
.Sh SEE ALSO
.Xr tree 3
.Sh HISTORY
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Jan 12, 1:33 AM (15 h, 28 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
15759649
Default Alt Text
D3983.id9631.diff (1 KB)
Attached To
Mode
D3983: [1/3] queue.3: Document existing QMD_* macros
Attached
Detach File
Event Timeline
Log In to Comment