1<html><head><meta http-equiv="Content-Type" content="text/html; charset=ANSI_X3.4-1968"><title>fc_remote_port_delete</title><meta name="generator" content="DocBook XSL Stylesheets V1.78.1"><link rel="home" href="index.html" title="SCSI Interfaces Guide"><link rel="up" href="Transport_classes.html#Fibre_Channel_transport" title="Fibre Channel transport"><link rel="prev" href="API-fc-remote-port-add.html" title="fc_remote_port_add"><link rel="next" href="API-fc-remote-port-rolechg.html" title="fc_remote_port_rolechg"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center"><span class="phrase">fc_remote_port_delete</span></th></tr><tr><td width="20%" align="left"><a accesskey="p" href="API-fc-remote-port-add.html">Prev</a> </td><th width="60%" align="center">Fibre Channel transport</th><td width="20%" align="right"> <a accesskey="n" href="API-fc-remote-port-rolechg.html">Next</a></td></tr></table><hr></div><div class="refentry"><a name="API-fc-remote-port-delete"></a><div class="titlepage"></div><div class="refnamediv"><h2>Name</h2><p>fc_remote_port_delete — 2 notifies the fc transport that a remote port is no longer in existence. 3 </p></div><div class="refsynopsisdiv"><h2>Synopsis</h2><div class="funcsynopsis"><table border="0" class="funcprototype-table" summary="Function synopsis" style="cellspacing: 0; cellpadding: 0;"><tr><td><code class="funcdef">void <b class="fsfunc">fc_remote_port_delete </b>(</code></td><td>struct fc_rport * <var class="pdparam">rport</var><code>)</code>;</td></tr></table><div class="funcprototype-spacer"> </div></div></div><div class="refsect1"><a name="idp1124404724"></a><h2>Arguments</h2><div class="variablelist"><dl class="variablelist"><dt><span class="term"><em class="parameter"><code>rport</code></em></span></dt><dd><p> 4 The remote port that no longer exists 5 </p></dd></dl></div></div><div class="refsect1"><a name="idp1124406356"></a><h2>Description</h2><p> 6 The LLDD calls this routine to notify the transport that a remote 7 port is no longer part of the topology. Note: Although a port 8 may no longer be part of the topology, it may persist in the remote 9 ports displayed by the fc_host. We do this under 2 conditions: 10 1) If the port was a scsi target, we delay its deletion by <span class="quote">“<span class="quote">blocking</span>”</span> it. 11 This allows the port to temporarily disappear, then reappear without 12 disrupting the SCSI device tree attached to it. During the <span class="quote">“<span class="quote">blocked</span>”</span> 13 period the port will still exist. 14 2) If the port was a scsi target and disappears for longer than we 15 expect, we'll delete the port and the tear down the SCSI device tree 16 attached to it. However, we want to semi-persist the target id assigned 17 to that port if it eventually does exist. The port structure will 18 remain (although with minimal information) so that the target id 19 bindings remails. 20 </p><p> 21 22 If the remote port is not an FCP Target, it will be fully torn down 23 and deallocated, including the fc_remote_port class device. 24 </p><p> 25 26 If the remote port is an FCP Target, the port will be placed in a 27 temporary blocked state. From the LLDD's perspective, the rport no 28 longer exists. From the SCSI midlayer's perspective, the SCSI target 29 exists, but all sdevs on it are blocked from further I/O. The following 30 is then expected. 31 </p><p> 32 33 If the remote port does not return (signaled by a LLDD call to 34 <code class="function">fc_remote_port_add</code>) within the dev_loss_tmo timeout, then the 35 scsi target is removed - killing all outstanding i/o and removing the 36 scsi devices attached ot it. The port structure will be marked Not 37 Present and be partially cleared, leaving only enough information to 38 recognize the remote port relative to the scsi target id binding if 39 it later appears. The port will remain as long as there is a valid 40 binding (e.g. until the user changes the binding type or unloads the 41 scsi host with the binding). 42 </p><p> 43 44 If the remote port returns within the dev_loss_tmo value (and matches 45 according to the target id binding type), the port structure will be 46 reused. If it is no longer a SCSI target, the target will be torn 47 down. If it continues to be a SCSI target, then the target will be 48 unblocked (allowing i/o to be resumed), and a scan will be activated 49 to ensure that all luns are detected. 50 </p><p> 51 52 Called from normal process context only - cannot be called from interrupt. 53</p></div><div class="refsect1"><a name="idp1124410828"></a><h2>Notes</h2><p> 54 This routine assumes no locks are held on entry. 55</p></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="API-fc-remote-port-add.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="Transport_classes.html#Fibre_Channel_transport">Up</a></td><td width="40%" align="right"> <a accesskey="n" href="API-fc-remote-port-rolechg.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top"><span class="phrase">fc_remote_port_add</span> </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> <span class="phrase">fc_remote_port_rolechg</span></td></tr></table></div></body></html> 56