diff options
Diffstat (limited to 'drivers/s390/scsi/zfcp_aux.c')
-rw-r--r-- | drivers/s390/scsi/zfcp_aux.c | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/drivers/s390/scsi/zfcp_aux.c b/drivers/s390/scsi/zfcp_aux.c index bdaad5535e22..9cd789b8acd4 100644 --- a/drivers/s390/scsi/zfcp_aux.c +++ b/drivers/s390/scsi/zfcp_aux.c | |||
@@ -1748,4 +1748,25 @@ zfcp_handle_els_rjt(u32 sq, struct zfcp_ls_rjt_par *rjt_par) | |||
1748 | return ret; | 1748 | return ret; |
1749 | } | 1749 | } |
1750 | 1750 | ||
1751 | /** | ||
1752 | * zfcp_plogi_evaluate - evaluate PLOGI playload and copy important fields | ||
1753 | * into zfcp_port structure | ||
1754 | * @port: zfcp_port structure | ||
1755 | * @plogi: plogi payload | ||
1756 | */ | ||
1757 | void | ||
1758 | zfcp_plogi_evaluate(struct zfcp_port *port, struct fsf_plogi *plogi) | ||
1759 | { | ||
1760 | port->maxframe_size = plogi->serv_param.common_serv_param[7] | | ||
1761 | ((plogi->serv_param.common_serv_param[6] & 0x0F) << 8); | ||
1762 | if (plogi->serv_param.class1_serv_param[0] & 0x80) | ||
1763 | port->supported_classes |= FC_COS_CLASS1; | ||
1764 | if (plogi->serv_param.class2_serv_param[0] & 0x80) | ||
1765 | port->supported_classes |= FC_COS_CLASS2; | ||
1766 | if (plogi->serv_param.class3_serv_param[0] & 0x80) | ||
1767 | port->supported_classes |= FC_COS_CLASS3; | ||
1768 | if (plogi->serv_param.class4_serv_param[0] & 0x80) | ||
1769 | port->supported_classes |= FC_COS_CLASS4; | ||
1770 | } | ||
1771 | |||
1751 | #undef ZFCP_LOG_AREA | 1772 | #undef ZFCP_LOG_AREA |