/* This function is called with no lock held. When QUE_BUFTAG_BIT bit is set in the tag the buffer is posted for a particular exchange, the function will return the buffer without replacing the buffer. If the buffer is for unsolicited ELS or CT traffic, this function returns the buffer and also posts another buffer to the firmware.  */
static struct lpfc_dmabuf* lpfc_sli_get_buff(struct lpfc_hba *phba, struct lpfc_sli_ring *pring, uint32_t tag)
/* This function is called with no lock held. When QUE_BUFTAG_BIT bit is set in the tag the buffer is posted for a particular exchange, the function will return the buffer without replacing the buffer. If the buffer is for unsolicited ELS or CT traffic, this function returns the buffer and also posts another buffer to the firmware.  */
static struct lpfc_dmabuf* lpfc_sli_get_buff(struct lpfc_hba *phba, struct lpfc_sli_ring *pring, uint32_t tag)
{
	struct hbq_dmabuf *hbq_entry;
	if (tag & QUE_BUFTAG_BIT)
		return lpfc_sli_ring_taggedbuf_get(phba, pring, tag);
	hbq_entry = lpfc_sli_hbqbuf_find(phba, tag);
	if (!hbq_entry)
		return NULL;
	return &hbq_entry->dbuf;
}