Date: Thu, 31 Dec 2009 04:16:18 +0000 (UTC) From: Matt Jacob <mjacob@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r201325 - head/sys/dev/isp Message-ID: <200912310416.nBV4GI8u085627@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: mjacob Date: Thu Dec 31 04:16:18 2009 New Revision: 201325 URL: http://svn.freebsd.org/changeset/base/201325 Log: Create a Node WWN from the *Port* WWN, not vice versa, for 2400s. If the NAA is type 2, the Node WWN is the Port WWN with the 12 bits of port (48..60) cleared. This iff a wwn fetched from NVRAM is zero. MFC after: 1 week Modified: head/sys/dev/isp/isp.c Modified: head/sys/dev/isp/isp.c ============================================================================== --- head/sys/dev/isp/isp.c Thu Dec 31 04:16:13 2009 (r201324) +++ head/sys/dev/isp/isp.c Thu Dec 31 04:16:18 2009 (r201325) @@ -8350,11 +8350,6 @@ isp_parse_nvram_2400(ispsoftc_t *isp, ui ISP2400_NVRAM_FIRMWARE_OPTIONS3(nvram_data)); wwn = ISP2400_NVRAM_PORT_NAME(nvram_data); - if (wwn) { - if ((wwn >> 60) != 2 && (wwn >> 60) != 5) { - wwn = 0; - } - } fcp->isp_wwpn_nvram = wwn; wwn = ISP2400_NVRAM_NODE_NAME(nvram_data); @@ -8363,6 +8358,10 @@ isp_parse_nvram_2400(ispsoftc_t *isp, ui wwn = 0; } } + if (wwn == 0 && (fcp->isp_wwpn_nvram >> 60) == 2) { + wwn = fcp->isp_wwpn_nvram; + wwn &= ~((uint64_t) 0xfff << 48); + } fcp->isp_wwnn_nvram = wwn; if (ISP2400_NVRAM_EXCHANGE_COUNT(nvram_data)) {
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200912310416.nBV4GI8u085627>