'\" t .\" Title: list_cut_position .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] .\" Generator: DocBook XSL Stylesheets v1.79.1 .\" Date: January 2017 .\" Manual: Data Types .\" Source: Kernel Hackers Manual 4.8.15 .\" Language: English .\" .TH "LIST_CUT_POSITION" "9" "January 2017" "Kernel Hackers Manual 4\&.8\&." "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_cut_position \- cut a list into two .SH "SYNOPSIS" .HP \w'void\ list_cut_position('u .BI "void list_cut_position(struct\ list_head\ *\ " "list" ", struct\ list_head\ *\ " "head" ", struct\ list_head\ *\ " "entry" ");" .SH "ARGUMENTS" .PP \fIlist\fR .RS 4 a new list to add all removed entries .RE .PP \fIhead\fR .RS 4 a list with entries .RE .PP \fIentry\fR .RS 4 an entry within head, could be the head itself and if so we won\*(Aqt cut the list .RE .SH "DESCRIPTION" .PP This helper moves the initial part of \fIhead\fR, up to and including \fIentry\fR, from \fIhead\fR to \fIlist\fR\&. You should pass on \fIentry\fR an element you know is on \fIhead\fR\&. \fIlist\fR should be an empty list or a list you do not care about losing its data\&. .SH "COPYRIGHT" .br