[pso] [Tema4][Linux]Sleeping function called from invalid context
sorin gsmcreation
gsmcreation at yahoo.com
Sat May 19 01:00:19 EEST 2007
Salutare.
Am dat de alta problema acum:
In hook-ul de output iau o variabila struct fwr
possible_rule pe care o completez in cazul TCP -
initiere conexiune si o pasez ca parametru functiei
care adauga o regula la lista de reguli dinamice
pentru TCP.
La apelarea acestei functii, se genereaza eroarea
descrisa in subiectul mesajului.
Aveti cumva vreo idee de la ce ar putea fi? Iata cum
arata functia de alocare:
static int add_dynamic_rule_tcp(struct fwr regula)
{
struct dynamic_rules_list *drl = (struct
dynamic_rules_list*) kmalloc(sizeof(struct
dynamic_rules_list), GFP_KERNEL);
if (!drl)
return -ENOMEM;
INIT_LIST_HEAD(&drl->list);
drl->rule=regula;
atomic_inc(&indice_regula_dinamica);
drl->indice=atomic_read(&indice_regula_dinamica);
setup_timer(&drl->timer,tcp_timer_timeout,drl->indice);
list_add(&drl->list, &dynamic_rules_tcp);
return 0;
}
Structura dynamic_rules_list contine:
- un indice (intreg)
- o structura fwr ce descrie regula
- un timer (timer_list)
- list_head-ul
Multumesc.
____________________________________________________________________________________Boardwalk for $500? In 2007? Ha! Play Monopoly Here and Now (it's updated for today's economy) at Yahoo! Games.
http://get.games.yahoo.com/proddesc?gamekey=monopolyherenow
More information about the pso
mailing list