'\" t .\" Title: i2o_msg_get .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] .\" Generator: DocBook XSL Stylesheets v1.78.1 .\" Date: May 2018 .\" Manual: Message-based devices .\" Source: Kernel Hackers Manual 3.16.56 .\" Language: English .\" .TH "I2O_MSG_GET" "9" "May 2018" "Kernel Hackers Manual 3\&.16\&" "Message-based devices" .\" ----------------------------------------------------------------- .\" * 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" i2o_msg_get \- obtain an I2O message from the IOP .SH "SYNOPSIS" .HP \w'struct\ i2o_message\ *\ i2o_msg_get('u .BI "struct i2o_message * i2o_msg_get(struct\ i2o_controller\ *\ " "c" ");" .SH "ARGUMENTS" .PP \fIc\fR .RS 4 I2O controller .RE .SH "DESCRIPTION" .PP This function tries to get a message frame\&. If no message frame is available do not wait until one is available (see also i2o_msg_get_wait)\&. The returned pointer to the message frame is not in I/O memory, it is allocated from a mempool\&. But because a MFA is allocated from the controller too it is guaranteed that \fBi2o_msg_post\fR will never fail\&. .PP On a success a pointer to the message frame is returned\&. If the message queue is empty \-EBUSY is returned and if no memory is available \-ENOMEM is returned\&. .SH "COPYRIGHT" .br