/* SPDX-License-Identifier: GPL-2.0-only */ /* * Copyright 2008 Cisco Systems, Inc. All rights reserved. * Copyright 2007 Nuova Systems, Inc. All rights reserved.
*/
#ifndef _FNIC_FDLS_H_ #define _FNIC_FDLS_H_
#include"fnic_stats.h" #include"fdls_fc.h"
/* FDLS - Fabric discovery and login services * -> VLAN discovery * -> retry every retry delay seconds until it succeeds. * <- List of VLANs * * -> Solicitation * <- Solicitation response (Advertisement) * * -> FCF selection & FLOGI ( FLOGI timeout - 2 * E_D_TOV) * <- FLOGI response * * -> FCF keep alive * <- FCF keep alive * * -> PLOGI to FFFFFC (DNS) (PLOGI timeout - 2 * R_A_TOV) * -> ABTS if timeout (ABTS tomeout - 2 * R_A_TOV) * <- PLOGI response * -> Retry PLOGI to FFFFFC (DNS) - Number of retries from vnic.cfg * * -> SCR to FFFFFC (DNS) (SCR timeout - 2 * R_A_TOV) * -> ABTS if timeout (ABTS tomeout - 2 * R_A_TOV) * <- SCR response * -> Retry SCR - Number of retries 2 * * -> GPN_FT to FFFFFC (GPN_FT timeout - 2 * R_A_TOV)a * -> Retry on BUSY until it succeeds * -> Retry on BUSY until it succeeds * -> 2 retries on timeout * * -> RFT_ID to FFFFFC (DNS) (RFT_ID timeout - 3 * R_A_TOV) * -> ABTS if timeout (ABTS tomeout - 2 * R_A_TOV) * -> Retry RFT_ID to FFFFFC (DNS) (Number of retries 2 ) * -> Ignore if both retires fail. * * Session establishment with targets * For each PWWN * -> PLOGI to FCID of that PWWN (PLOGI timeout 2 * R_A_TOV) * -> ABTS if timeout (ABTS tomeout - 2 * R_A_TOV) * <- PLOGI response * -> Retry PLOGI. Num retries using vnic.cfg * * -> PRLI to FCID of that PWWN (PRLI timeout 2 * R_A_TOV) * -> ABTS if timeout (ABTS tomeout - 2 * R_A_TOV) * <- PRLI response * -> Retry PRLI. Num retries using vnic.cfg *
*/
struct fnic_fdls_fabric_s { enum fnic_fdls_state_e state;
uint32_t flags; struct list_head tport_list; /* List of discovered tports */ struct timer_list retry_timer; int del_timer_inprogress; int del_fdmi_timer_inprogress; int retry_counter; int timer_pending; int fdmi_retry; struct timer_list fdmi_timer; int fdmi_pending;
};
struct fnic_tport_s { struct list_head links; /* To link the tports */ enum fdls_tgt_state_e state;
uint32_t flags;
uint32_t fcid;
uint64_t wwpn;
uint64_t wwnn;
uint16_t active_oxid;
uint16_t tgt_flags;
atomic_t in_flight; /* io counter */
uint16_t max_payload_size;
uint16_t r_a_tov;
uint16_t e_d_tov;
uint16_t lun0_delay; int max_concur_seqs;
uint32_t fcp_csp; struct timer_list retry_timer; int del_timer_inprogress; int retry_counter; int timer_pending; unsignedint num_pending_cmds; int nexus_restart_count; int exch_reset_in_progress; void *iport; struct work_struct tport_del_work; struct completion *tport_del_done; struct fc_rport *rport; char str_wwpn[20]; char str_wwnn[20];
};
/* OXID pool related structures */ struct reclaim_entry_s { struct list_head links; /* oxid that needs to be freed after 2*r_a_tov */
uint16_t oxid_idx; /* in jiffies. Use this to waiting time */ unsignedlong expires; unsignedlong *bitmap;
};
/* used for allocating oxids for fabric and fdmi requests */ struct fnic_oxid_pool_s {
DECLARE_BITMAP(bitmap, FNIC_OXID_POOL_SZ); int sz; /* size of the pool or block */ int next_idx; /* used for cycling through the oxid pool */
/* List of oxids that need to be freed and reclaimed. * This list is shared by all the oxid pools
*/ struct list_head oxid_reclaim_list; /* Work associated with reclaim list */ struct delayed_work oxid_reclaim_work;
};
struct fnic_iport_s { enum fnic_iport_state_e state; struct fnic *fnic;
uint64_t boot_time;
uint32_t flags; int usefip;
uint8_t hwmac[6]; /* HW MAC Addr */
uint8_t fpma[6]; /* Fabric Provided MA */
uint8_t fcfmac[6]; /* MAC addr of Fabric */
uint16_t vlan_id;
uint32_t fcid;
/* oxid pool */ struct fnic_oxid_pool_s oxid_pool;
/* * fabric reqs are serialized and only one req at a time. * Tracking the oxid for sending abort
*/
uint16_t active_oxid_fabric_req; /* fdmi only */
uint16_t active_oxid_fdmi_plogi;
uint16_t active_oxid_fdmi_rhba;
uint16_t active_oxid_fdmi_rpa;
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.