'\" t .\" Title: ata_wait_ready .\" Author: .\" Generator: DocBook XSL Stylesheets v1.79.1 .\" Date: July 2017 .\" Manual: libata Core Internals .\" Source: Kernel Hackers Manual 4.11.6 .\" Language: English .\" .TH "ATA_WAIT_READY" "9" "July 2017" "Kernel Hackers Manual 4\&.11\&" "libata Core Internals" .\" ----------------------------------------------------------------- .\" * 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" ata_wait_ready \- wait for link to become ready .SH "SYNOPSIS" .HP \w'int\ ata_wait_ready('u .BI "int ata_wait_ready(struct\ ata_link\ *\ " "link" ", unsigned\ long\ " "deadline" ", int\ (*" "check_ready" ")\ (struct\ ata_link\ *link));" .SH "ARGUMENTS" .PP \fIstruct ata_link * link\fR .RS 4 link to be waited on .RE .PP \fIunsigned long deadline\fR .RS 4 deadline jiffies for the operation .RE .PP \fIint (*)(struct ata_link *link) check_ready\fR .RS 4 callback to check link readiness .RE .SH "DESCRIPTION" .PP Wait for \fIlink\fR to become ready\&. \fIcheck_ready\fR should return positive number if \fIlink\fR is ready, 0 if it isn\*(Aqt, \-ENODEV if link doesn\*(Aqt seem to be occupied, other errno for other error conditions\&. .PP Transient \-ENODEV conditions are allowed for ATA_TMOUT_FF_WAIT\&. .PP LOCKING: EH context\&. .SH "RETURN" .PP 0 if \fIlink\fR is ready before \fIdeadline\fR; otherwise, \-errno\&. .SH "AUTHOR" .PP \fBJeff Garzik\fR .RS 4 Author. .RE .SH "COPYRIGHT" .br