Pseudo FIFO working along with Quanta printing

This commit is contained in:
BAREEDU SAI SANDEEP SANDEEP 2020-03-07 19:08:08 +05:30
parent 90255207d6
commit e5f31deb41
6 changed files with 3 additions and 3 deletions

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -100,7 +100,7 @@ int do_noquantum(message *m_ptr)
rmp = &schedproc[proc_nr_n];
if (rmp->priority < MIN_USER_Q) {
rmp->priority += 1; /* lower priority */
rmp->priority -= 1;
}
if ((rv = schedule_process_local(rmp)) != OK) {
@ -322,7 +322,7 @@ static int schedule_process(struct schedproc * rmp, unsigned flags)
//processors are swapped here
if (rmp->priority >= 7 && rmp->max_priority == 7)
{
printf("MINIX: PID %d swapped in\n", _ENDPOINT_P(rmp->endpoint));
printf("Minix: PID %d swapped in\n", _ENDPOINT_P(rmp->endpoint));
}
@ -365,7 +365,7 @@ static void balance_queues(minix_timer_t *tp)
for (proc_nr=0, rmp=schedproc; proc_nr < NR_PROCS; proc_nr++, rmp++) {
if (rmp->flags & IN_USE) {
if (rmp->priority > rmp->max_priority) {
rmp->priority -= 1; /* increase priority */
schedule_process_local(rmp);
}
}

Binary file not shown.