Two misc fixes:
- Fix deadlock caused by return with host_lock held in lpfc_findnode_did
- Initialize all fields of the allocated mail box structure to zero.
Was causing some sysfs mailbox commands to fail immediately after load.
Signed-off-by: James Smart <James.Smart@emulex.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
mbox = mempool_alloc(phba->mbox_mem_pool, GFP_KERNEL);
if (!mbox)
return -ENOMEM;
-
+ memset(mbox, 0, sizeof (LPFC_MBOXQ_t));
}
spin_lock_irq(host->host_lock);
phba->brd_no,
ndlp, ndlp->nlp_DID,
ndlp->nlp_flag, data1);
+ spin_unlock_irq(phba->host->host_lock);
return ndlp;
}
}
phba->brd_no,
ndlp, ndlp->nlp_DID,
ndlp->nlp_flag, data1);
+ spin_unlock_irq(phba->host->host_lock);
return ndlp;
}
}