- idle task becomes a pseudo task which is never scheduled. It is never put on
any run queue and never enters userspace. An entry for this task still remains
in the process table for time accounting
- Instead of panicing if there is not process to schedule, pick_proc() returns
NULL which is a signal to put the cpu in an idle state and set everything in
such a way that after receiving and interrupt it looks like idle task was
preempted
- idle task is set non-preemptible to avoid handling in the timer interrupt code
which make userspace scheduling simpler as idle task does not need to be
handled as a special case.
- the gnu .S are compiled with __ASSEMBLY__ macro set which allows us to
conditionaly remove C stuff from the proc.h file when included in assembly
files
- new proc_is_runnable() macro to test whether process is runnable. All tests
whether p_rts_flags == 0 converted to use this macro
- pick_proc() calls removed from enqueue() and dequeue()
- removed the test for recursive calls from pick_proc() as it certainly cannot
be called recursively now
- PREEMPTED flag to mark processes that were preempted by enqueueuing a higher
priority process in enqueue()
- enqueue_head() to enqueue PREEMPTED processes again at the head of their
current priority queue
- NO_QUANTUM flag to block and dequeue processes preempted by timer tick with
exceeded quantum. They need to be enqueued again in schedcheck()
- next_ptr global variable removed
- after a trap to kernel, the code automatically switches to kernel
stack, in the future local to the CPU
- k_reenter variable replaced by a test whether the CS is kernel cs or
not. The information is passed further if needed. Removes a global
variable which would need to be cpu local
- no need for global variables describing the exception or trap
context. This information is kept on stack and a pointer to this
structure is passed to the C code as a single structure
- removed loadedcr3 variable and its use replaced by reading the %cr3
register
- no need to redisable interrupts in restart() as they are already
disabled.
- unified handling of traps that push and don't push errorcode
- removed save() function as the process context is not saved directly
to process table but saved as required by the trap code. Essentially
it means that save() code is inlined everywhere not only in the
exception handling routine
- returning from syscall is more arch independent - it sets the retger
in C
- top of the x86 stack contains the current CPU id and pointer to the
currently scheduled process (the one right interrupted) so the mode
switch code can find where to save the context without need to use
proc_ptr which will be cpu local in the future and therefore
difficult to access in assembler and expensive to access in general
- some more clean up of level0 code. No need to read-back the argument
passed in
%eax from the proc structure. The mode switch code does not clobber
%the general registers and hence we can just call what is in %eax
- many assebly macros in sconst.h as they will be reused by the apic
assembly
- preemption handled in the clock timer interrupt handler, not in the clock task
- more achitecture independent clock timer handling code
- smp ready as each CPU can have its own timer
- fixes a problem in inodes truct definitions. The original definitions use
posix types. These types don't have well defined size. Therefore when
compiling mkfs on a different system natively the inodes sizes do not match.
This patch replaces the posix types with interger types of the same size and
signedness as the original types in use.
- The primary reason is that mkfs and installboot need to run natively during
the cross compilation (host and target versions are compiled). There is a
collision of include files though. E.g. a.out.h is very minix-specific.
Therefore some files we moved and replaced by stubs that include the original
file if compiling on or for Minix :
include/a.out.h -> include/minix/a.out.h
include/sys/dir.h -> include/minix/dir.h
include/dirent.h -> include/minix/dirent.h
include/sys/types.h -> include/minix/types.h
- This does not break any native compilation on Minix. Other headers that were
including the original files are changed according to include directly the
new, minix specific location not to pick up the host system includes while
cross-compiling.
- role of this patch is to make rebasing of the build branch simpler until the
new build system is merged
- the PIC master and slave irq handlers don't pass the irq hook pointer but just
the irq number. It gives a little bit more information to the C handler as the
irq number is not lost
- the irq code path is more achitecture independent. i386 hw interrupts are
called irq and whereever the code is arch independent enough hw_intr_
functions are called to mask/unmask interrupts
- the legacy PIC is not the only possible interrupt controller in the x86 world,
therefore the intr_(un)mask functions were renamed to signal their
functionality explicitly. APIC will add their own.
- masking and unmasking PIC interrupt lines is removed from assembler and all
the functionality is rewriten in C and moved to i8259.c
- interrupt handlers have to unmask the interrupt line if all irq handlers are
done. Assembler does not do it anymore
told to kernel
- makes VM ask the kernel if a certain process is allowed
to map in a range of physical memory (VM rounds it to page
boundaries afterwards - but it's impossible to map anything
smaller otherwise so I assume this is safe, i.e. there won't
be anything else in that page; certainly no regular memory)
- VM permission check cleanup (no more hardcoded calls, less
hardcoded logic, more readable main loop), a loose end left
by GQ
- remove do_copy warning, as the ipc server triggers this but
it's no more harmful than the special cases already excluded
explicitly (VFS, PM, etc).
IS:
- do not use p_getfrom_e for a process that is sending
- register with TTY only function keys that are used
- various header and formatting fixes
- proper shutdown code
TTY:
- restore proper Ctrl+F1 dump contents
isofs:
- don't even try to call sys_exit()
- an asmconv based tool for conversion from GNU ia32 assembly to ACK assembly
- in contrast to asmconv it is a one way tool only
- as the GNU assembly in Minix does not prefix global C symbols with _ gas2ack
detects such symbols and prefixes them to be compliant with the ACK convention
- gas2ack preserves comments and unexpanded macros
- bunch of fixes to the asmconv GNU->ACK direction
- support of more instructions that ACK does not know but are in use in Minix
- it is meant as a temporary solution as long as ACK will be a supported
compiler for the core system
- MFS and mkfs(1) now perform extra sanity checks
- fsck(1) can now deal with inode tables extending beyond the file
system's first 4GB
- badblocks(8) no longer writes out the superblock for no reason
- mkfs(1) no longer crashes when given no parameters
- more(1) no longer crashes when standard output is redirected
that some hardware had
- clear DMA_ST_INT after DMA - fixes infinite number of interrupts
that some hardware had
- initial ATAPI DMA implementation, doesn't actually increase performance
on my test hardware so possibly not right yet, disabled by default