software/drivers/sd8887/src/wlan/mlan/mlan_init.c
/**
 *  @brief This function deletes the BSS priority table
 *
 *  @param priv     A pointer to mlan_private structure
 *
 *  @return         N/A
 */
@brief This function deletes the BSS priority table
@param priv     A pointer to mlan_private structure

@return         N/A
@brief This function deletes the BSS priority table @param priv A pointer to mlan_private structure @return N / A
static t_void
wlan_delete_bsspriotbl(pmlan_private priv)
{
	int i;
	pmlan_adapter pmadapter = priv->adapter;
	mlan_bssprio_node *pbssprio_node = MNULL, *ptmp_node = MNULL, **ppcur =
		MNULL;
	pmlan_list_head phead;
	ENTER();
	for (i = 0; i < pmadapter->priv_num; ++i) {
		phead = &pmadapter->bssprio_tbl[i].bssprio_head;
		ppcur = &pmadapter->bssprio_tbl[i].bssprio_cur;
		PRINTM(MINFO,
		       "Delete BSS priority table, index = %d, i = %d, phead = %p, pcur = %p\n",
		       priv->bss_index, i, phead, *ppcur);
		if (*ppcur) {
			pbssprio_node =
				(mlan_bssprio_node *)util_peek_list(pmadapter->
								    pmoal_handle,
								    phead,
								    pmadapter->
								    callbacks.
								    moal_spin_lock,
								    pmadapter->
								    callbacks.
								    moal_spin_unlock);
			while (pbssprio_node &&
			       ((pmlan_list_head)pbssprio_node != phead)) {
				ptmp_node = pbssprio_node->pnext;
				if (pbssprio_node->priv == priv) {
					PRINTM(MINFO,
					       "Delete node, pnode = %p, pnext = %p\n",
					       pbssprio_node, ptmp_node);
					util_unlink_list(pmadapter->
							 pmoal_handle, phead,
							 (pmlan_linked_list)
							 pbssprio_node,
							 pmadapter->callbacks.
							 moal_spin_lock,
							 pmadapter->callbacks.
							 moal_spin_unlock);
					pmadapter->callbacks.
						moal_mfree(pmadapter->
							   pmoal_handle,
							   (t_u8 *)
							   pbssprio_node);
				}
				pbssprio_node = ptmp_node;
			}
			*ppcur = (mlan_bssprio_node *)phead;
		}
	}
	LEAVE();
}
static t_void wlan_delete_bsspriotbl ( pmlan_private priv ) { int i ; pmlan_adapter pmadapter = priv -> adapter ; mlan_bssprio_node * pbssprio_node = MNULL , * ptmp_node = MNULL , * * ppcur = MNULL ; pmlan_list_head phead ; ENTER ( ) ; for ( i = 0 ; i < pmadapter -> priv_num ; ++ i ) { phead = & pmadapter -> bssprio_tbl [ i ] . bssprio_head ; ppcur = & pmadapter -> bssprio_tbl [ i ] . bssprio_cur ; PRINTM ( MINFO , " \n " , priv -> bss_index , i , phead , * ppcur ) ; if ( * ppcur ) { pbssprio_node = ( mlan_bssprio_node * ) util_peek_list ( pmadapter -> pmoal_handle , phead , pmadapter -> callbacks . moal_spin_lock , pmadapter -> callbacks . moal_spin_unlock ) ; while ( pbssprio_node && ( ( pmlan_list_head ) pbssprio_node != phead ) ) { ptmp_node = pbssprio_node -> pnext ; if ( pbssprio_node -> priv == priv ) { PRINTM ( MINFO , " \n " , pbssprio_node , ptmp_node ) ; util_unlink_list ( pmadapter -> pmoal_handle , phead , ( pmlan_linked_list ) pbssprio_node , pmadapter -> callbacks . moal_spin_lock , pmadapter -> callbacks . moal_spin_unlock ) ; pmadapter -> callbacks . moal_mfree ( pmadapter -> pmoal_handle , ( t_u8 * ) pbssprio_node ) ; } pbssprio_node = ptmp_node ; } * ppcur = ( mlan_bssprio_node * ) phead ; } } LEAVE ( ) ; }
@brief This function deletes the BSS priority table
  @param priv     A pointer to mlan_private structure
@brief This function deletes the BSS priority table @param priv A pointer to mlan_private structure