Date: Fri, 19 Jun 2015 00:53:16 +0000 (UTC) From: Alexander Motin <mav@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r284586 - stable/10/sys/cam/ctl Message-ID: <201506190053.t5J0rG5t059041@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: mav Date: Fri Jun 19 00:53:15 2015 New Revision: 284586 URL: https://svnweb.freebsd.org/changeset/base/284586 Log: MFC r284013: Allow setting only WWNN or only WWPN. Modified: stable/10/sys/cam/ctl/scsi_ctl.c Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/cam/ctl/scsi_ctl.c ============================================================================== --- stable/10/sys/cam/ctl/scsi_ctl.c Fri Jun 19 00:10:30 2015 (r284585) +++ stable/10/sys/cam/ctl/scsi_ctl.c Fri Jun 19 00:53:15 2015 (r284586) @@ -1657,16 +1657,24 @@ ctlfe_onoffline(void *arg, int online) * down to the SIM. Otherwise, record what the SIM * has reported. */ - if ((bus_softc->port.wwnn != 0) - && (bus_softc->port.wwpn != 0)) { + if (bus_softc->port.wwnn != 0 && bus_softc->port.wwnn + != ccb->knob.xport_specific.fc.wwnn) { ccb->knob.xport_specific.fc.wwnn = - bus_softc->port.wwnn; - ccb->knob.xport_specific.fc.wwpn = - bus_softc->port.wwpn; + bus_softc->port.wwnn; set_wwnn = 1; } else { ctl_port_set_wwns(&bus_softc->port, true, ccb->knob.xport_specific.fc.wwnn, + false, 0); + } + if (bus_softc->port.wwpn != 0 && bus_softc->port.wwpn + != ccb->knob.xport_specific.fc.wwpn) { + ccb->knob.xport_specific.fc.wwpn = + bus_softc->port.wwpn; + set_wwnn = 1; + } else { + ctl_port_set_wwns(&bus_softc->port, + false, 0, true, ccb->knob.xport_specific.fc.wwpn); } #endif /* RANDOM_WWNN */
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201506190053.t5J0rG5t059041>