.\" This manpage has been automatically generated by docbook2man .\" from a DocBook document. This tool can be found at: .\" .\" Please send any bug reports, improvements, comments, patches, .\" etc. to Steve Cheng . .TH "SEQ_OPEN" "9" "09 October 2005" "" "" .SH NAME seq_open \- initialize sequential file .SH SYNOPSIS "SYNOPSIS" .sp \fB .sp int seq_open (struct file * \fIfile\fB, struct seq_operations * \fIop\fB); \fR .SH "ARGUMENTS" .TP \fB\fIfile\fB\fR file we initialize .TP \fB\fIop\fB\fR method table describing the sequence .SH "DESCRIPTION" .PP \fBseq_open\fR sets \fIfile\fR, associating it with a sequence described by \fIop\fR\&. \fIop\fR->\fBstart\fR sets the iterator up and returns the first element of sequence. \fIop\fR->\fBstop\fR shuts it down. \fIop\fR->\fBnext\fR returns the next element of sequence. \fIop\fR->\fBshow\fR prints element into the buffer. In case of error ->\fBstart\fR and ->\fBnext\fR return ERR_PTR(error). In the end of sequence they return NULL\&. ->\fBshow\fR returns 0 in case of success and negative number in case of error.