Signed-off-by: Robert Love <[EMAIL PROTECTED]>
---
drivers/scsi/libfc/fc_rport.c | 26 ++++++++++++++++++++++++++
1 files changed, 26 insertions(+), 0 deletions(-)
diff --git a/drivers/scsi/libfc/fc_rport.c b/drivers/scsi/libfc/fc_rport.c
index 3f55587..7b6dc15 100644
--- a/drivers/scsi/libfc/fc_rport.c
+++ b/drivers/scsi/libfc/fc_rport.c
@@ -59,6 +59,32 @@ static void fc_rport_recv_logo_req(struct fc_rport *,
static void fc_rport_timeout(struct work_struct *);
static void fc_rport_error(struct fc_rport *, struct fc_frame *);
+
+static const char *fc_rport_state_names[] = {
+ [RPORT_ST_NONE] = "None",
+ [RPORT_ST_INIT] = "Init",
+ [RPORT_ST_GPN_ID] = "GPN_ID",
+ [RPORT_ST_GNN_ID] = "GNN_ID",
+ [RPORT_ST_PLOGI] = "PLOGI",
+ [RPORT_ST_PLOGI_RECV] = "PLOGI recv",
+ [RPORT_ST_PRLI] = "PRLI",
+ [RPORT_ST_RTV] = "RTV",
+ [RPORT_ST_ERROR] = "Error",
+ [RPORT_ST_READY] = "Ready",
+ [RPORT_ST_LOGO] = "LOGO",
+};
+
+static const char *fc_rport_state(struct fc_rport *rp)
+{
+ const char *cp;
+ struct fc_rport_libfc_priv *rpp = rp->dd_data;
+
+ cp = fc_rport_state_names[rpp->rp_state];
+ if (!cp)
+ cp = "Unknown";
+ return cp;
+}
+
static struct fc_rport *fc_remote_port_create(struct fc_lport *,
struct fc_rport_identifiers *);
_______________________________________________
devel mailing list
[email protected]
http://www.open-fcoe.org/mailman/listinfo/devel