'\" t .\" Title: list_safe_reset_next .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] .\" Generator: DocBook XSL Stylesheets v1.79.1 .\" Date: March 2017 .\" Manual: Data Types .\" Source: Kernel Hackers Manual 4.10.7 .\" Language: English .\" .TH "LIST_SAFE_RESET_NEXT" "9" "March 2017" "Kernel Hackers Manual 4\&.10\&" "Data Types" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" list_safe_reset_next \- reset a stale list_for_each_entry_safe loop .SH "SYNOPSIS" .HP \w'list_safe_reset_next('u .BI "list_safe_reset_next(" "pos" ", " "n" ", " "member" ");" .SH "ARGUMENTS" .PP \fIpos\fR .RS 4 the loop cursor used in the list_for_each_entry_safe loop .RE .PP \fIn\fR .RS 4 temporary storage used in list_for_each_entry_safe .RE .PP \fImember\fR .RS 4 the name of the list_head within the struct\&. .RE .SH "DESCRIPTION" .PP list_safe_reset_next is not safe to use in general if the list may be modified concurrently (eg\&. the lock is dropped in the loop body)\&. An exception to this is if the cursor element (pos) is pinned in the list, and list_safe_reset_next is called after re\-taking the lock and before completing the current iteration of the loop body\&. .SH "COPYRIGHT" .br