struct fres_sa_contract *c;
long int period_usec;
fres_block_fwp_sched *fwp_sched;
-
size_t bytes;
long int duration_usec, tmp_usec;
int fragments;
int ac = FWP_AC_VO;
-
fwp_sta_t *sta;
fres_sa_scenario_for_each_no_cancel_contract(scenario, c) {
fres_contract_id_to_string(id, &c->contract->id, sizeof(id));
basic = fres_contract_get_basic(c->contract);
fwp_block = fres_contract_get_block(c->contract, FRES_BLOCK_FWP);
-
+
if(fwp_block != NULL){
//from list of all stations choose the one which has requested mac address
+ pthread_mutex_lock( &pr->mutex );
ul_list_for_each(sta_list, &pr->sta_list, sta){
//if there's a requested mac address in node
if(sta->client_mac_addr == fwp_block->mac_address){
break;
}
}
+ pthread_mutex_unlock( &pr->mutex );
+
}
-
frsh_network_budget_to_bytes(FRSH_NETPF_FWP,&basic->budget,&bytes);
ul_logmsg("processing: id=%s, period=%ld ms, budget=%lu bytes\n",
id,
(long unsigned int)bytes);
period_usec = basic ? fosa_rel_time_to_msec(basic->period)*1000 : 0;
-
/* Calculate protocol overhead */
fragments = (bytes + MTU - 1) / MTU;