Go to the source code of this file.
|
Definition at line 175 of file list.h. Referenced by sys_exit_notify(). |
|
Aloca un nodo de la lista. a incluir en las estructuras de datos a colocar en listas ej: typedef struct task_struct_t { word pid; int priority; .... LIST_DATA(task_struct_t) runqueue; LIST_DATA(task_struct_t) zombiequeue; .... } task_struct_t; |
|
Value: type *name; \ ( name = (type *) malloc(sizeof(type)) );
|
|
Definition at line 58 of file list.h. Referenced by actualizar_timers(). |
|
|
|
Value: LIST_NEXT(list,node)=HEADER_NEXT(header); \ if ( HEADER_NEXT(header) != NULL) \ LIST_PREVIOUS( list, LIST_NEXT(list,node) )= node; \ else \ HEADER_PREVIOUS(header)=node; \ LIST_PREVIOUS(list,node)=NULL; \ HEADER_NEXT(header)=node; Definition at line 108 of file list.h. Referenced by cache_read(), sys_exec(), and sys_execve(). |
|
Value: if ( HEADER_PREVIOUS(header) != NULL ) \ LIST_NEXT( list, HEADER_PREVIOUS(header) ) = node; \ else \ HEADER_NEXT(header) = node; \ LIST_NEXT(list,node) = NULL; \ LIST_PREVIOUS(list,node) = HEADER_PREVIOUS(header); \ HEADER_PREVIOUS(header) = node; Definition at line 124 of file list.h. Referenced by cache_read(), insert_timer(), sendrequest(), sys_exec(), sys_execve(), sys_exit_notify(), and sys_fork(). |
|
Value: { type *aux; \ _LIST_FOREACH(ptr, src) { \ aux = LIST_NEXT(src,ptr); \ LIST_ADD_TAIL(dest,dest, ptr); \ ptr = aux; \ } \ }
|
|
Vacia una lista, realiza esto reinicializando el header, no realiza ningun cambio en los puntero de los nodos enlazados.
Definition at line 239 of file list.h. Referenced by cache_read(). |
|
Macro para permitir la inclusión de una estructura en una lista doblemente enlazada. Al colocarlo en una estructura permite la inclusión del nodo como parte de una lista doblemente enlazada, veamos un ejemplo:
el fragmento anterior muestra como las instancias de task_struct_t pueden formar parte de dos listas. |
|
Value: if ( LIST_PREVIOUS(list,node) != NULL ) \ LIST_NEXT( list, LIST_PREVIOUS(list,node) ) = LIST_NEXT(list,node); \ else \ HEADER_NEXT(header) = LIST_NEXT(list,node); \ if ( LIST_NEXT(list,node) != NULL ) \ LIST_PREVIOUS( list, LIST_NEXT(list,node) ) = LIST_PREVIOUS(list,node); \ else \ HEADER_PREVIOUS(header) = LIST_PREVIOUS(list,node); Definition at line 138 of file list.h. Referenced by actualizar_timers(), cache_read(), endrequest(), getfreeblock(), remove_timer(), sys_exec(), sys_execve(), sys_exit_notify(), and sys_waitpid(). |
|
Verifica si una lista está vacía.
|
|
|
|
Devuelve el primero nodo de la lista.
Definition at line 83 of file list.h. Referenced by endrequest(), getfreeblock(), and getrequest(). |
|
Permite recorrer la lista de principio a fin. Utiliza como argumentos un puntero del tipo de los nodos y la lista. ej: task_struct_t *nodotmp; LIST_FOREACH(nodotmp,runqueue_hdr,runqueue) { if ( nodotmp->priority > ... ) .. ... } Definition at line 159 of file list.h. Referenced by cache_read(), insert_timer(), remove_timer(), show_cached_list(), sys_waitpid(), and timer_dump(). |
|
Idem LIST_FOREACH pero desde el fin al ppio de la lista ej: task_struct_t *nodotmp; LIST_FOREACH_REVERSE(nodotmp,runqueue_hdr,runqueue) { if ( nodotmp->priority > ... ) .. ... } |
|
Value: Definition at line 75 of file list.h. Referenced by sys_exec(), sys_execve(), and sys_fork(). |
|
Definition at line 73 of file list.h. Referenced by LIST_NEW(). |
|
Value: LIST_PREVIOUS(list,node)=LIST_PREVIOUS(list,nodebefore); \ LIST_NEXT(list,node)=nodebefore; \ if ( HEADER_NEXT(header)==nodebefore ) \ HEADER_NEXT(header)=node; \ else \ LIST_NEXT(list,LIST_PREVIOUS(list,nodebefore))=node; \ LIST_PREVIOUS(list,nodebefore)=node; Definition at line 182 of file list.h. Referenced by insert_timer(). |
|
Value: struct { \
type *next; \
type *previous; \
}
|
|
Definition at line 55 of file list.h. Referenced by actualizar_timers(), and sys_exit_notify(). |
|
|
|
Value: LIST_NEXT(list, replace) = LIST_NEXT(list, original); \ LIST_PREVIOUS(list, replace) = LIST_PREVIOUS(list, original); \ if (LIST_NEXT(list, replace)) \ LIST_PREVIOUS(list,LIST_NEXT(list, replace)) = replace; \ if (LIST_PREVIOUS(list, replace)) \ LIST_NEXT(list,LIST_PREVIOUS(list, replace)) = replace; |
|
Devuelve el último nodo de la lista.
|