[SCSI] libfc: add host number to lport link up/down messages.
The libfc link up/down messages don't indicate which port is changing. The Port ID will often be 0. Signed-off-by: Joe Eykholt <jeykholt@cisco.com> Signed-off-by: Robert Love <robert.w.love@intel.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>hifive-unleashed-5.1
parent
093bb6a2d3
commit
e6d8a1b0b5
|
@ -568,8 +568,8 @@ void __fc_linkup(struct fc_lport *lport)
|
||||||
*/
|
*/
|
||||||
void fc_linkup(struct fc_lport *lport)
|
void fc_linkup(struct fc_lport *lport)
|
||||||
{
|
{
|
||||||
printk(KERN_INFO "libfc: Link up on port (%6x)\n",
|
printk(KERN_INFO "host%d: libfc: Link up on port (%6x)\n",
|
||||||
fc_host_port_id(lport->host));
|
lport->host->host_no, fc_host_port_id(lport->host));
|
||||||
|
|
||||||
mutex_lock(&lport->lp_mutex);
|
mutex_lock(&lport->lp_mutex);
|
||||||
__fc_linkup(lport);
|
__fc_linkup(lport);
|
||||||
|
@ -598,8 +598,8 @@ void __fc_linkdown(struct fc_lport *lport)
|
||||||
*/
|
*/
|
||||||
void fc_linkdown(struct fc_lport *lport)
|
void fc_linkdown(struct fc_lport *lport)
|
||||||
{
|
{
|
||||||
printk(KERN_INFO "libfc: Link down on port (%6x)\n",
|
printk(KERN_INFO "host%d: libfc: Link down on port (%6x)\n",
|
||||||
fc_host_port_id(lport->host));
|
lport->host->host_no, fc_host_port_id(lport->host));
|
||||||
|
|
||||||
mutex_lock(&lport->lp_mutex);
|
mutex_lock(&lport->lp_mutex);
|
||||||
__fc_linkdown(lport);
|
__fc_linkdown(lport);
|
||||||
|
@ -699,8 +699,9 @@ void fc_lport_disc_callback(struct fc_lport *lport, enum fc_disc_event event)
|
||||||
FC_LPORT_DBG(lport, "Discovery succeeded\n");
|
FC_LPORT_DBG(lport, "Discovery succeeded\n");
|
||||||
break;
|
break;
|
||||||
case DISC_EV_FAILED:
|
case DISC_EV_FAILED:
|
||||||
printk(KERN_ERR "libfc: Discovery failed for port (%6x)\n",
|
printk(KERN_ERR "host%d: libfc: "
|
||||||
fc_host_port_id(lport->host));
|
"Discovery failed for port (%6x)\n",
|
||||||
|
lport->host->host_no, fc_host_port_id(lport->host));
|
||||||
mutex_lock(&lport->lp_mutex);
|
mutex_lock(&lport->lp_mutex);
|
||||||
fc_lport_enter_reset(lport);
|
fc_lport_enter_reset(lport);
|
||||||
mutex_unlock(&lport->lp_mutex);
|
mutex_unlock(&lport->lp_mutex);
|
||||||
|
@ -791,8 +792,9 @@ static void fc_lport_recv_flogi_req(struct fc_seq *sp_in,
|
||||||
goto out;
|
goto out;
|
||||||
remote_wwpn = get_unaligned_be64(&flp->fl_wwpn);
|
remote_wwpn = get_unaligned_be64(&flp->fl_wwpn);
|
||||||
if (remote_wwpn == lport->wwpn) {
|
if (remote_wwpn == lport->wwpn) {
|
||||||
printk(KERN_WARNING "libfc: Received FLOGI from port "
|
printk(KERN_WARNING "host%d: libfc: Received FLOGI from port "
|
||||||
"with same WWPN %llx\n", remote_wwpn);
|
"with same WWPN %llx\n",
|
||||||
|
lport->host->host_no, remote_wwpn);
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
FC_LPORT_DBG(lport, "FLOGI from port WWPN %llx\n", remote_wwpn);
|
FC_LPORT_DBG(lport, "FLOGI from port WWPN %llx\n", remote_wwpn);
|
||||||
|
@ -1471,8 +1473,10 @@ void fc_lport_flogi_resp(struct fc_seq *sp, struct fc_frame *fp,
|
||||||
lport->e_d_tov = e_d_tov;
|
lport->e_d_tov = e_d_tov;
|
||||||
lport->r_a_tov = 2 * e_d_tov;
|
lport->r_a_tov = 2 * e_d_tov;
|
||||||
fc_lport_set_port_id(lport, did, fp);
|
fc_lport_set_port_id(lport, did, fp);
|
||||||
printk(KERN_INFO "libfc: Port (%6x) entered "
|
printk(KERN_INFO "host%d: libfc: "
|
||||||
"point to point mode\n", did);
|
"Port (%6x) entered "
|
||||||
|
"point-to-point mode\n",
|
||||||
|
lport->host->host_no, did);
|
||||||
fc_lport_ptp_setup(lport, ntoh24(fh->fh_s_id),
|
fc_lport_ptp_setup(lport, ntoh24(fh->fh_s_id),
|
||||||
get_unaligned_be64(
|
get_unaligned_be64(
|
||||||
&flp->fl_wwpn),
|
&flp->fl_wwpn),
|
||||||
|
|
Loading…
Reference in New Issue