'\" t .\" Title: __scsi_device_lookup_by_target .\" Author: .\" Generator: DocBook XSL Stylesheets v1.79.1 .\" Date: January 2017 .\" Manual: SCSI mid layer .\" Source: Kernel Hackers Manual 4.8.15 .\" Language: English .\" .TH "__SCSI_DEVICE_LOOKUP" "9" "January 2017" "Kernel Hackers Manual 4\&.8\&." "SCSI mid layer" .\" ----------------------------------------------------------------- .\" * 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" __scsi_device_lookup_by_target \- find a device given the target (UNLOCKED) .SH "SYNOPSIS" .HP \w'struct\ scsi_device\ *\ __scsi_device_lookup_by_target('u .BI "struct scsi_device * __scsi_device_lookup_by_target(struct\ scsi_target\ *\ " "starget" ", u64\ " "lun" ");" .SH "ARGUMENTS" .PP \fIstarget\fR .RS 4 SCSI target pointer .RE .PP \fIlun\fR .RS 4 SCSI Logical Unit Number .RE .SH "DESCRIPTION" .PP Looks up the scsi_device with the specified \fIlun\fR for a given \fIstarget\fR\&. The returned scsi_device does not have an additional reference\&. You must hold the host\*(Aqs host_lock over this call and any access to the returned scsi_device\&. A scsi_device in state SDEV_DEL is skipped\&. .SH "NOTE" .PP The only reason why drivers should use this is because they need to access the device list in irq context\&. Otherwise you really want to use scsi_device_lookup_by_target instead\&. .SH "AUTHORS" .PP \fBJames Bottomley\fR <\&James.Bottomley@hansenpartnership.com\&> .RS 4 Author. .RE .PP \fBRob Landley\fR <\&rob@landley.net\&> .RS 4 Author. .RE .SH "COPYRIGHT" .br