Lines Matching refs:array

17     DbgBreakIf(pdev->context_info->array[cid].invalid != LM_CONTEXT_VALID);  in lm_get_context()
39 DbgBreakIf(pdev->context_info->array[cid].invalid != LM_CONTEXT_VALID); in lm_get_context_phys()
177 cid_resc = &pdev->context_info->array[cid].cid_resc; in lm_init_cid_resc()
199 struct lm_context_cookie* array = NULL ; in lm_setup_context_pool() local
218 array = context->array ; in lm_setup_context_pool()
223 context->array = array ; in lm_setup_context_pool()
238 if CHK_NULL(context->array) in lm_setup_context_pool()
240 DbgBreakIf(!( context->array)); in lm_setup_context_pool()
244 mm_mem_zero(context->array, sizeof(struct lm_context_cookie)*num_con); in lm_setup_context_pool()
253 context->array[j].next = j+1; in lm_setup_context_pool()
254 context->array[j].invalid = LM_CONTEXT_VALID; in lm_setup_context_pool()
255 context->array[j].ip_type = 0; in lm_setup_context_pool()
256 context->array[j].h_val = 0; in lm_setup_context_pool()
269 context->array[context->proto_end[i]].next = 0; in lm_setup_context_pool()
276 context->array[j].cid_resc.mapped_cid_bar_addr = in lm_setup_context_pool()
279 context->array[j].cid_resc.reg_handle = pdev->vars.reg_handle[BAR_0]; in lm_setup_context_pool()
284 context->array[j].cid_resc.mapped_cid_bar_addr = in lm_setup_context_pool()
287 context->array[j].cid_resc.reg_handle = pdev->vars.reg_handle[BAR_1]; in lm_setup_context_pool()
329 context->array = mm_alloc_mem(pdev, sizeof(struct lm_context_cookie)*num_con, mm_cli_idx); in lm_alloc_context_pool()
330 if CHK_NULL(context->array) in lm_alloc_context_pool()
365 DbgBreakIf( context->array[i].cid_resc.cookies[j] != NULL ); in lm_release_context_pool()
503 DbgBreakIf(context->array[cid].ip_type); /* cid can't be inserted twice */ in lm_searcher_mirror_hash_insert()
504 context->array[cid].ip_type = tuple->ip_type; in lm_searcher_mirror_hash_insert()
505 context->array[cid].h_val = h_val; in lm_searcher_mirror_hash_insert()
526 if(!context->array[cid].ip_type) { in lm_searcher_mirror_hash_remove()
538 h_val = context->array[cid].h_val; in lm_searcher_mirror_hash_remove()
541 if (context->array[cid].ip_type == LM_IP_TYPE_V6) { in lm_searcher_mirror_hash_remove()
559 context->array[cid].ip_type = 0; in lm_searcher_mirror_hash_remove()
560 context->array[cid].h_val = 0; in lm_searcher_mirror_hash_remove()
582 CHK_NULL(pdev->context_info->array) || in lm_allocate_cid()
590 DbgBreakIf(!pdev->context_info->array); in lm_allocate_cid()
615 context->proto_pending[type] = context->array[cid].next; in lm_allocate_cid()
616 context->array[cid].next = 0; in lm_allocate_cid()
617 context->array[cid].cid_resc.cookies[type] = cookie; in lm_allocate_cid()
618 context->array[cid].cid_resc.cid_pending = LM_CID_STATE_PENDING; in lm_allocate_cid()
625 context->array[cid].prev = 0; in lm_allocate_cid()
632 context->proto_ffree[type] = context->array[cid].next; in lm_allocate_cid()
633 context->array[cid].next = 0; in lm_allocate_cid()
634 context->array[cid].prev = 0; in lm_allocate_cid()
635 context->array[cid].cid_resc.cookies[type] = cookie; in lm_allocate_cid()
656 context->array[cid].cid_resc.mapped_cid_bar_addr = in lm_allocate_cid()
659 context->array[cid].cid_resc.reg_handle = pdev->vars.reg_handle[BAR_1]; in lm_allocate_cid()
666 &context->array[cid].cid_resc.reg_handle); in lm_allocate_cid()
671 context->array[cid].cid_resc.mapped_cid_bar_addr = in lm_allocate_cid()
681 if CHK_NULL(context->array[cid].cid_resc.mapped_cid_bar_addr) in lm_allocate_cid()
688 context->array[cid].next = pdev->context_info->proto_ffree[type]; in lm_allocate_cid()
690 context->array[cid].invalid = LM_CONTEXT_VALID; in lm_allocate_cid()
707 ERR_IF(pdev->context_info->array[cid].invalid != LM_CONTEXT_INVALID_WAIT) ) in lm_cfc_delete()
714 DbgBreakIf(pdev->context_info->array[cid].invalid != LM_CONTEXT_INVALID_WAIT); in lm_cfc_delete()
718 …pdev, FATAL, "lm_cfc_delete: invalid %d for cid=%d\n", pdev->context_info->array[cid].invalid,cid); in lm_cfc_delete()
720 if (pdev->context_info->array[cid].invalid != LM_CONTEXT_INVALID_DELETE) in lm_cfc_delete()
728 pdev->context_info->array[cid].invalid = LM_CONTEXT_INVALID_DELETE; in lm_cfc_delete()
760 …(!lm_fl_reset_is_inprogress(pdev) && (pdev->context_info->array[cid].invalid != LM_CONTEXT_VALID))) in lm_free_cid()
767 DbgBreakIf(pdev->context_info->array[cid].invalid != LM_CONTEXT_VALID); in lm_free_cid()
774 DbgBreakIf(pdev->context_info->array[cid].cid_resc.cookies[proto_idx]); in lm_free_cid()
788 pdev->context_info->array[cid].invalid = LM_CONTEXT_INVALID_WAIT; in lm_free_cid()
793 pdev->context_info->array[cid].next = curr_cid; in lm_free_cid()
794 pdev->context_info->array[cid].prev = 0; in lm_free_cid()
797 pdev->context_info->array[curr_cid].prev = cid; in lm_free_cid()
803 pdev->context_info->array[cid].invalid = LM_CONTEXT_INVALID_DELETE; in lm_free_cid()
838 ERR_IF(pdev->context_info->array[cid].invalid != LM_CONTEXT_INVALID_DELETE) || in lm_recycle_cid()
842 DbgBreakIf(pdev->context_info->array[cid].invalid != LM_CONTEXT_INVALID_DELETE); in lm_recycle_cid()
868 if (pdev->context_info->array[cid].cid_resc.cid_pending == FALSE) { in lm_recycle_cid()
870 prev_cid = pdev->context_info->array[cid].prev; in lm_recycle_cid()
871 next_cid = pdev->context_info->array[cid].next; in lm_recycle_cid()
873 pdev->context_info->array[prev_cid].next = next_cid; in lm_recycle_cid()
876 pdev->context_info->array[next_cid].prev = prev_cid; in lm_recycle_cid()
882 pdev->context_info->array[cid].prev = pdev->context_info->array[cid].next = 0; in lm_recycle_cid()
884 pdev->context_info->array[cid].next = pdev->context_info->proto_ffree[type]; in lm_recycle_cid()
885 pdev->context_info->array[cid].invalid = LM_CONTEXT_VALID; in lm_recycle_cid()
886 pdev->context_info->array[cid].cfc_delete_cnt = 0; in lm_recycle_cid()
891 …mm_unmap_io_space(pdev,(void *)pdev->context_info->array[cid].cid_resc.mapped_cid_bar_addr, LM_DQ_… in lm_recycle_cid()
901 pdev->context_info->array[cid].invalid = LM_CONTEXT_VALID; in lm_recycle_cid()
915 …pdev->cid_recycled_callbacks[type](pdev, pdev->context_info->array[cid].cid_resc.cookies[type], ci… in lm_recycle_cid()
930 CHK_NULL(pdev->context_info->array[cid].cid_resc.cookies[type]) || in lm_cid_cookie()
931 ERR_IF(pdev->context_info->array[cid].invalid != LM_CONTEXT_VALID) ) in lm_cid_cookie()
937 DbgBreakIf(pdev->context_info->array[cid].invalid != LM_CONTEXT_VALID); in lm_cid_cookie()
940 if (pdev->context_info->array[cid].cid_resc.cookies[type] == NULL) in lm_cid_cookie()
947 if (pdev->context_info->array[cid].cid_resc.cid_pending != LM_CID_STATE_VALID) in lm_cid_cookie()
952 return pdev->context_info->array[cid].cid_resc.cookies[type]; in lm_cid_cookie()
969 return &pdev->context_info->array[cid].cid_resc; in lm_cid_resc()