Lines Matching refs:fcf
658 if (phba->fcf.fcf_flag & FCF_DISCOVERY) {
668 if (phba->fcf.fcf_flag & FCF_REDISC_PROG) {
994 if (phba->fcf.fcf_flag & FCF_REDISC_EVT)
1262 phba->fcf.fcf_flag &= ~(FCF_AVAILABLE | FCF_SCAN_DONE);
1588 * fcf priority list. The list deletions are done while holding the
1597 memset(phba->fcf.fcf_rr_bmask, 0, sizeof(*phba->fcf.fcf_rr_bmask));
1600 &phba->fcf.fcf_pri_list, list) {
1620 phba->fcf.fcfi = bf_get(lpfc_reg_fcfi_fcfi, &mboxq->u.mqe.un.reg_fcfi);
1623 phba->fcf.fcf_flag |= FCF_REGISTERED;
1633 phba->fcf.fcf_flag |= (FCF_SCAN_DONE | FCF_IN_USE);
1653 * lpfc_fab_name_match - Check if the fcf fabric name match.
1655 * @new_fcf_record: pointer to fcf record.
1657 * This routine compare the fcf record's fabric name with provided
1684 * lpfc_sw_name_match - Check if the fcf switch name match.
1686 * @new_fcf_record: pointer to fcf record.
1688 * This routine compare the fcf record's switch name with provided
1715 * lpfc_mac_addr_match - Check if the fcf mac address match.
1717 * @new_fcf_record: pointer to fcf record.
1719 * This routine compare the fcf record's mac address with HBA's
1751 * @new_fcf_record: pointer to hba fcf record.
1764 fcf_pri = &phba->fcf.fcf_pri[fcf_index];
1772 * lpfc_copy_fcf_record - Copy fcf information to lpfc_hba.
1773 * @fcf_rec: pointer to driver fcf record.
1774 * @new_fcf_record: pointer to fcf record.
1831 * __lpfc_update_fcf_record - Update driver fcf record
1833 * @fcf_rec: pointer to driver fcf record.
1834 * @new_fcf_record: pointer to hba fcf record.
1835 * @addr_mode: address mode to be set to the driver fcf record.
1836 * @vlan_id: vlan tag to be set to the driver fcf record.
1837 * @flag: flag bits to be set to the driver fcf record.
1866 * the fcf with HBA.
1876 if (!(phba->fcf.fcf_flag & FCF_AVAILABLE)) {
1883 if (phba->fcf.fcf_flag & FCF_REGISTERED) {
1884 phba->fcf.fcf_flag |= (FCF_SCAN_DONE | FCF_IN_USE);
1923 * @new_fcf_record: pointer to fcf record.
1928 * This routine compare the fcf record with connect list obtained from the
2058 * This fcf record matches filtering criteria.
2142 phba->fcf.fcf_flag &= ~FCF_AVAILABLE;
2163 phba->fcf.fcf_flag &= ~(FCF_REDISC_FOV | FCF_DISCOVERY);
2170 phba->fcf.fcf_flag &= ~FCF_REGISTERED;
2178 * lpfc_sli4_new_fcf_random_select - Randomly select an eligible new fcf record
2180 * @fcf_cnt: number of eligible fcf record seen so far.
2211 * @next_fcf_index: pointer to holder of next fcf index.
2213 * This routine parses the non-embedded fcf mailbox command by performing the
2280 * lpfc_sli4_log_fcf_record_info - Log the information of a fcf record
2282 * @fcf_record: pointer to the fcf record.
2283 * @vlan_id: the lowest vlan identifier associated to this fcf record.
2284 * @next_fcf_index: the index to the next fcf record in hba's fcf table.
2374 * lpfc_sli4_fcf_rr_next_proc - processing next roundrobin fcf
2376 * @fcf_index: index to next fcf.
2378 * This function processing the roundrobin fcf failover to next fcf index.
2379 * When this function is invoked, there will be a current fcf registered
2381 * Return: 0 for continue retrying flogi on currently registered fcf;
2382 * 1 for stop flogi on currently registered fcf;
2397 phba->fcf.current_rec.fcf_indx);
2403 /* Allow action to new fcf asynchronous event */
2404 phba->fcf.fcf_flag &= ~(FCF_AVAILABLE | FCF_SCAN_DONE);
2412 if (!phba->fcf.fcf_redisc_attempted) {
2419 phba->fcf.fcf_redisc_attempted = 1;
2441 rc, phba->fcf.current_rec.fcf_indx);
2455 * @fcf_index: the index of the fcf record to delete
2458 * is cleared. This routine grab the hbalock before removing the fcf
2466 new_fcf_pri = &phba->fcf.fcf_pri[fcf_index];
2473 if (phba->fcf.current_rec.priority ==
2475 phba->fcf.eligible_fcf_cnt--;
2485 * @fcf_index: the index of the fcf record to update
2488 * will try a different fcf record that does not have this bit set.
2489 * If the fcf record is re-read for any reason this flag is cleared brfore
2496 new_fcf_pri = &phba->fcf.fcf_pri[fcf_index];
2505 * @fcf_index: the index of the fcf record to add
2529 new_fcf_pri = &phba->fcf.fcf_pri[fcf_index];
2539 if (list_empty(&phba->fcf.fcf_pri_list)) {
2540 list_add(&new_fcf_pri->list, &phba->fcf.fcf_pri_list);
2546 last_index = find_first_bit(phba->fcf.fcf_rr_bmask,
2552 current_fcf_pri = phba->fcf.fcf_pri[last_index].fcf_rec.priority;
2554 list_add(&new_fcf_pri->list, &phba->fcf.fcf_pri_list);
2556 memset(phba->fcf.fcf_rr_bmask, 0,
2557 sizeof(*phba->fcf.fcf_rr_bmask));
2559 phba->fcf.eligible_fcf_cnt = 1;
2562 phba->fcf.eligible_fcf_cnt++;
2569 &phba->fcf.fcf_pri_list, list) {
2572 if (fcf_pri->list.prev == &phba->fcf.fcf_pri_list)
2574 &phba->fcf.fcf_pri_list);
2581 } else if (fcf_pri->list.next == &phba->fcf.fcf_pri_list
2601 * lpfc_mbx_cmpl_fcf_scan_read_fcf_rec - fcf scan read_fcf mbox cmpl handler.
2605 * This function iterates through all the fcf records available in
2656 * If the fcf record does not match with connect list entries
2675 if ((phba->fcf.fcf_flag & FCF_IN_USE) &&
2676 lpfc_sli4_fcf_record_match(phba, &phba->fcf.current_rec,
2679 phba->fcf.current_rec.fcf_indx) {
2686 phba->fcf.current_rec.fcf_indx);
2695 if (!(phba->fcf.fcf_flag & FCF_REDISC_PEND) &&
2696 !(phba->fcf.fcf_flag & FCF_REDISC_FOV)) {
2701 phba->fcf.current_rec.fcf_indx);
2703 phba->fcf.fcf_flag |= FCF_REDISC_FOV;
2727 if (phba->fcf.fcf_flag & FCF_IN_USE) {
2729 lpfc_sli4_fcf_record_match(phba, &phba->fcf.current_rec,
2732 phba->fcf.current_rec.fcf_indx) {
2733 phba->fcf.fcf_flag |= FCF_AVAILABLE;
2734 if (phba->fcf.fcf_flag & FCF_REDISC_PEND)
2738 else if (phba->fcf.fcf_flag & FCF_REDISC_FOV)
2740 phba->fcf.fcf_flag &= ~FCF_REDISC_FOV;
2746 phba->fcf.current_rec.fcf_indx,
2756 phba->fcf.current_rec.fcf_indx);
2765 if (!(phba->fcf.fcf_flag & FCF_REDISC_FOV)) {
2774 if (phba->fcf.fcf_flag & FCF_REDISC_FOV)
2775 fcf_rec = &phba->fcf.failover_rec;
2777 fcf_rec = &phba->fcf.current_rec;
2779 if (phba->fcf.fcf_flag & FCF_AVAILABLE) {
2782 * set and new hba fcf record has boot flag set, use
2783 * the new hba fcf record.
2822 phba->fcf.eligible_fcf_cnt = 1;
2825 phba->fcf.eligible_fcf_cnt++;
2827 phba->fcf.eligible_fcf_cnt);
2857 phba->fcf.fcf_flag |= FCF_AVAILABLE;
2859 phba->fcf.eligible_fcf_cnt = 1;
2867 if (phba->fcf.fcf_flag & FCF_REDISC_FOV) {
2876 if (!(phba->fcf.failover_rec.flag & RECORD_VALID)) {
2919 phba->fcf.current_rec.fcf_indx,
2920 phba->fcf.failover_rec.fcf_indx);
2921 memcpy(&phba->fcf.current_rec,
2922 &phba->fcf.failover_rec,
2930 phba->fcf.fcf_flag &= ~FCF_REDISC_FOV;
2939 if ((phba->fcf.fcf_flag & FCF_REDISC_EVT) ||
2940 (phba->fcf.fcf_flag & FCF_REDISC_PEND))
2944 phba->fcf.fcf_flag & FCF_IN_USE) {
2955 phba->fcf.current_rec.fcf_indx);
2957 phba->fcf.fcf_flag |= FCF_REDISC_FOV;
2978 * lpfc_mbx_cmpl_fcf_rr_read_fcf_rec - fcf roundrobin read_fcf mbox cmpl hdler
3005 phba->fcf.fcf_flag &= ~FCF_DISCOVERY;
3019 phba->fcf.fcf_flag);
3047 if (fcf_index == phba->fcf.current_rec.fcf_indx) {
3051 phba->fcf.current_rec.fcf_indx, fcf_index);
3061 phba->fcf.failover_rec.fcf_indx, fcf_index);
3063 __lpfc_update_fcf_record(phba, &phba->fcf.failover_rec,
3068 current_fcf_index = phba->fcf.current_rec.fcf_indx;
3074 memcpy(&phba->fcf.current_rec, &phba->fcf.failover_rec,
3088 * lpfc_mbx_cmpl_read_fcf_rec - read fcf completion handler.
3112 if (!(phba->fcf.fcf_flag & FCF_DISCOVERY))
3659 "fcf record\n");
3688 phba->fcf.fcf_flag |= FCF_INIT_DISC;
3696 phba->fcf.fcf_flag &= ~FCF_INIT_DISC;
6757 /* If driver cannot allocate memory, indicate fcf is in use */
6768 * unreg the fcf.
6847 * lpfc_unregister_fcf_prep - Unregister fcf record preparation
6934 lpfc_unreg_fcfi(mbox, phba->fcf.fcfi);
6950 * lpfc_unregister_fcf_rescan - Unregister currently registered fcf and rescan
6961 /* Preparation for unregistering fcf */
6976 phba->fcf.fcf_flag = 0;
6978 phba->fcf.current_rec.flag = 0;
6990 phba->fcf.fcf_flag |= FCF_INIT_DISC;
7000 phba->fcf.fcf_flag &= ~FCF_INIT_DISC;
7010 * lpfc_unregister_fcf - Unregister the currently registered fcf record
7021 /* Preparation for unregistering fcf */
7036 phba->fcf.fcf_flag &= ~FCF_REGISTERED;
7058 !(phba->fcf.fcf_flag & FCF_REGISTERED) ||
7060 (phba->fcf.fcf_flag & FCF_DISCOVERY) ||