Hola a todos,estoy haciendo una práctica de MINIX sobre planificacion de procesos, lo que quiero hacer es pasar de ROUND-ROBIN a uno con prioridad no apropiativo, me gustaria saber que hace esta funcion ,.¿alguien me lo puede explicar?MUCHAS GRACIAS.
/*================================================= ======
* sched *
*================================================= ==*/
PRIVATE void sched()
{int n;
/* The current process has run too long. If another low priority (user)
* process is runnable, put the current process on the end of the user queue,
* possibly promoting another user to head of the queue.
*/
if (rdy_head[USER_Q] == NIL_PROC) return;
n = proc_number(rdy_head[USER_Q]);
if(count[n]==0) {
/* One or more user processes queued. */
rdy_tail[USER_Q]->p_nextready = rdy_head[USER_Q];
rdy_tail[USER_Q] = rdy_head[USER_Q];
rdy_head[USER_Q] = rdy_head[USER_Q]->p_nextready;
rdy_tail[USER_Q]->p_nextready = NIL_PROC;
count[n] = priority[n];
} else count[n]--;
pick_proc();
}