mirror of
https://github.com/ipxe/ipxe
synced 2025-12-21 04:20:17 +03:00
[fc] Do not use the command reference number in FCP_CMND IUs
The FCP command reference number is intended to be used for controlling precise delivery of FCP commands, rather than being an essentially arbitrary tag field (as with iSCSI and SRP). Use the Fibre Channel local exchange ID as the tag for FCP commands, instead of the FCP command reference. The local exchange ID does not appear within the FCP IU itself, but does appear within the FC frame header; debug traces can therefore still be correlated with packet captures. Reported-by: Hadar Hen Zion <hadarh@mellanox.co.il> Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
@@ -265,6 +265,7 @@ static struct interface_descriptor fc_els_job_desc =
|
||||
static void fc_els_step ( struct process *process ) {
|
||||
struct fc_els *els =
|
||||
container_of ( process, struct fc_els, process );
|
||||
int xchg_id;
|
||||
int rc;
|
||||
|
||||
/* Sanity check */
|
||||
@@ -274,9 +275,10 @@ static void fc_els_step ( struct process *process ) {
|
||||
process_del ( &els->process );
|
||||
|
||||
/* Create exchange */
|
||||
if ( ( rc = fc_xchg_originate ( &els->xchg, els->port,
|
||||
&els->peer_port_id,
|
||||
FC_TYPE_ELS ) ) != 0 ) {
|
||||
if ( ( xchg_id = fc_xchg_originate ( &els->xchg, els->port,
|
||||
&els->peer_port_id,
|
||||
FC_TYPE_ELS ) ) < 0 ) {
|
||||
rc = xchg_id;
|
||||
DBGC ( els, FCELS_FMT " could not create exchange: %s\n",
|
||||
FCELS_ARGS ( els ), strerror ( rc ) );
|
||||
fc_els_close ( els, rc );
|
||||
|
||||
Reference in New Issue
Block a user