]> Zhao Yanbai Git Server - minix.git/log
minix.git
14 years agosprofile exports kernel sample entries
Tomas Hruby [Thu, 23 Sep 2010 10:49:50 +0000 (10:49 +0000)]
sprofile exports kernel sample entries

- in case of kernel hit while proc_ptr is IDLE, account for idle time
  instead of taking kernel sample

14 years agoInternal 64M buffer for profiling
Tomas Hruby [Thu, 23 Sep 2010 10:49:48 +0000 (10:49 +0000)]
Internal 64M buffer for profiling

- when profiling is compiled in kernel includes a 64M buffer for
  sample

- 64M is the default used by profile tool as its buffer

- when using nmi profiling it is not possible to always copy sample
  stright to userland as the nmi may (and does) happen in bad moments

- reduces sampling overhead as samples are copied out only when
  profiling stops

14 years agoNMI sampling
Tomas Hruby [Thu, 23 Sep 2010 10:49:45 +0000 (10:49 +0000)]
NMI sampling

- if profile --nmi kernel uses NMI watchdog based sampling based on
  Intel architecture performance counters

- using NMI makes kernel profiling possible

- watchdog kernel lockup detection is disabled while sampling as we
  may get unpredictable interrupts in kernel and thus possibly many
  false positives

- if watchdog is not enabled at boot time, profiling enables it and
  turns it of again when done

14 years agoThe profile utility can set the sprofiling mode
Tomas Hruby [Thu, 23 Sep 2010 10:49:42 +0000 (10:49 +0000)]
The profile utility can set the sprofiling mode

- profile --nmi | --rtc sets the profiling mode

- --rtc is default, uses BIOS RTC, cannot profile kernel the presetted
  frequency values apply

- --nmi is only available in APIC mode as it uses the NMI watchdog, -f
  allows any frequency in Hz

- both modes use compatible data structures

14 years agoNew profile protocol
Tomas Hruby [Thu, 23 Sep 2010 10:49:39 +0000 (10:49 +0000)]
New profile protocol

- when kernel profiles a process for the first time it saves an entry
  describing the process [endpoint|name]

- every profile sample is only [endpoint|pc]

- profile utility creates a table of endpoint <-> name relations and
  translates endpoints of samples into names and writing out the
  results to comply with the processing tools

- "task" endpoints like KERNEL are negative thus we must cast it to
  unsigned when hashing

14 years ago32bit process flags
Tomas Hruby [Thu, 23 Sep 2010 10:49:36 +0000 (10:49 +0000)]
32bit process flags

- we are running out of space in 16bit flags

14 years agolibsys: tsc_to_micros support for large TSC delta values
David van Moolenbroek [Thu, 23 Sep 2010 09:26:42 +0000 (09:26 +0000)]
libsys: tsc_to_micros support for large TSC delta values

14 years agoGet rid of erroneous define
Thomas Veerman [Thu, 23 Sep 2010 08:52:49 +0000 (08:52 +0000)]
Get rid of erroneous define

14 years agoincludes - minor compile fixes.
Ben Gras [Wed, 22 Sep 2010 14:31:51 +0000 (14:31 +0000)]
includes - minor compile fixes.

14 years agoenable_fpu_exception() - only write cr0 if bit isn't already on.
Ben Gras [Wed, 22 Sep 2010 14:31:06 +0000 (14:31 +0000)]
enable_fpu_exception() - only write cr0 if bit isn't already on.

(NMI profiling results indicate this both is relatively expensive and
happens a lot unnecessarily if the fpu is in use.)

14 years agoNo need to scan devices in PIC mode
Tomas Hruby [Wed, 22 Sep 2010 08:01:43 +0000 (08:01 +0000)]
No need to scan devices in PIC mode

14 years agoRemove unnecessary TLB flushes
Tomas Hruby [Wed, 22 Sep 2010 08:01:36 +0000 (08:01 +0000)]
Remove unnecessary TLB flushes

- this should be only for SMP

14 years agoUPDATING - warning about /usr/gnu/lib
Ben Gras [Tue, 21 Sep 2010 12:46:55 +0000 (12:46 +0000)]
UPDATING - warning about /usr/gnu/lib

14 years agoAdd libmthread and test59 to test the implementation
Thomas Veerman [Tue, 21 Sep 2010 12:22:38 +0000 (12:22 +0000)]
Add libmthread and test59 to test the implementation

14 years agoinclude minix 'all' package.
Ben Gras [Mon, 20 Sep 2010 15:09:32 +0000 (15:09 +0000)]
include minix 'all' package.

14 years agolib/libsys/gcov.c - fix gcc warning
Ben Gras [Mon, 20 Sep 2010 11:36:41 +0000 (11:36 +0000)]
lib/libsys/gcov.c - fix gcc warning

14 years ago . forget obsolete /usr/local/bin in $PATH
Ben Gras [Mon, 20 Sep 2010 11:07:53 +0000 (11:07 +0000)]
  . forget obsolete /usr/local/bin in $PATH
  . update release.sh's notion of where packages are
  . update release.sh's notion of how many files are on root
    as -xdev won't work anymore to separate /usr from /

14 years agoFixed comments in watchdog
Tomas Hruby [Sun, 19 Sep 2010 23:23:44 +0000 (23:23 +0000)]
Fixed comments in watchdog

14 years agofix - forgotten debug print
Tomas Hruby [Sun, 19 Sep 2010 15:54:31 +0000 (15:54 +0000)]
fix - forgotten debug print

14 years agoUserspace scheduling - exporting stats
Tomas Hruby [Sun, 19 Sep 2010 15:52:12 +0000 (15:52 +0000)]
Userspace scheduling - exporting stats

- contributed by Bjorn Swift

- adds process accounting, for example counting the number of messages
  sent, how often the process was preemted and how much time it spent
  in the run queue. These statistics, along with the current cpu load,
  are sent back to the user-space scheduler in the Out Of Quantum
  message.

- the user-space scheduler may choose to make use of these statistics
  when making scheduling decisions. For isntance the cpu load becomes
  especially useful when scheduling on multiple cores.

14 years agopkgsrc: save binary packages in arch- and osversion dependent dir.
Ben Gras [Fri, 17 Sep 2010 14:31:54 +0000 (14:31 +0000)]
pkgsrc: save binary packages in arch- and osversion dependent dir.

14 years agoFix failing unmount attempt at shutdown after running test58
Thomas Veerman [Fri, 17 Sep 2010 09:34:36 +0000 (09:34 +0000)]
Fix failing unmount attempt at shutdown after running test58

14 years agoanother sprofalyze.pl update
David van Moolenbroek [Fri, 17 Sep 2010 09:25:10 +0000 (09:25 +0000)]
another sprofalyze.pl update

14 years agosprofalyze.pl update
Tomas Hruby [Fri, 17 Sep 2010 08:09:04 +0000 (08:09 +0000)]
sprofalyze.pl update

14 years agoFixed FPU for single cpu
Tomas Hruby [Thu, 16 Sep 2010 09:51:45 +0000 (09:51 +0000)]
Fixed FPU for single cpu

14 years agoapic_timer_x
Tomas Hruby [Thu, 16 Sep 2010 07:18:47 +0000 (07:18 +0000)]
apic_timer_x

- set the apic_timer_x factor variable to slowdown apic timer in
  virtual machines

14 years agoFixed unintentionally removed world target in Makefile
Tomas Hruby [Wed, 15 Sep 2010 14:18:39 +0000 (14:18 +0000)]
Fixed unintentionally removed world target in Makefile

14 years agoSMP - all process have pagetables
Tomas Hruby [Wed, 15 Sep 2010 14:11:30 +0000 (14:11 +0000)]
SMP - all process have pagetables

- all processes have private pagetables if CONFIG_SMP is set

- this make possible to safely schedule PM, RS, VFS anywhere

14 years agoSMP - lazy FPU
Tomas Hruby [Wed, 15 Sep 2010 14:11:25 +0000 (14:11 +0000)]
SMP - lazy FPU

- when a process is migrated to a different CPU it may have an active
  FPU context in the processor registers. We must save it and migrate
  it together with the process.

14 years agoSMP - can boot even if some cpus fail to boot
Tomas Hruby [Wed, 15 Sep 2010 14:11:21 +0000 (14:11 +0000)]
SMP - can boot even if some cpus fail to boot

- EBADCPU is returned is scheduler tries to run a process on a CPU
  that either does not exist or isn't booted

- this change was originally meant to deal with stupid cpuid
  instruction which provides totally useless information about
  hyper-threading and MPS which does not deal with ht at all. ACPI
  provides correct information. If ht is turned off it looks like some
  CPUs failed to boot.  Nevertheless this patch may be handy for
  testing/benchmarking in the future.

14 years agoSMP - Make sure that VM does not change pt of a process while kernel copies
Tomas Hruby [Wed, 15 Sep 2010 14:11:19 +0000 (14:11 +0000)]
SMP - Make sure that VM does not change pt of a process while kernel copies

14 years agoSMP - Force TLB flush before scheduling a process
Tomas Hruby [Wed, 15 Sep 2010 14:11:17 +0000 (14:11 +0000)]
SMP - Force TLB flush before scheduling a process

- this makes sure that each process always run with updated TLB

- this is the simplest way how to achieve the consistency. As it means
  significant performace degradation when not require, this is nto the
  final solution and will be refined

14 years agoSMP - Process is stopped when VM modifies the page tables
Tomas Hruby [Wed, 15 Sep 2010 14:11:12 +0000 (14:11 +0000)]
SMP - Process is stopped when VM modifies the page tables

- RTS_VMINHIBIT flag is used to stop process while VM is fiddling with
  its pagetables

- more generic way of sending synchronous scheduling events among cpus

- do the x-cpu smp sched calls only if the target process is runnable.
  If it is not, it cannot be running and it cannot become runnable
  this CPU holds the BKL

14 years agoSMP - runctl() can stop across cpus
Tomas Hruby [Wed, 15 Sep 2010 14:11:09 +0000 (14:11 +0000)]
SMP - runctl() can stop across cpus

- if stopping a process that runs on a different CPU we tell the
  remote cpu to do that

14 years agoSMP - Single shot local timer
Tomas Hruby [Wed, 15 Sep 2010 14:11:06 +0000 (14:11 +0000)]
SMP - Single shot local timer

- APIC timer always reprogrammed if expired

- timer tick never happens when in kernel => never immediate return
  from userspace to kernel because of a buffered interrupt

- renamed argument to lapic_set_timer_one_shot()

- removed arch_ prefix from timer functions

14 years agoSMP - Compiles for both single and multi processor again
Tomas Hruby [Wed, 15 Sep 2010 14:11:03 +0000 (14:11 +0000)]
SMP - Compiles for both single and multi processor again

- this patch adds various fixes as some of the previous patches break
  compilations without CONFIG_SMP being set

14 years agoSMP - Print cpu of the process
Tomas Hruby [Wed, 15 Sep 2010 14:11:01 +0000 (14:11 +0000)]
SMP - Print cpu of the process

- adds '4' to print processes assigned to each cpu without printing
  the process it is blocked on (a lightweight '1')

14 years agoSMP - trully idle APs
Tomas Hruby [Wed, 15 Sep 2010 14:10:57 +0000 (14:10 +0000)]
SMP - trully idle APs

- any cpu can use smp_schedule() to tell another cpu to reschedule

- if an AP is idle, it turns off timer as there is nothing to
  preempt, no need to wakeup just to go back to sleep again

- if a cpu makes a process runnable on an idle cpu, it must wake it up
  to reschedule

14 years agoSMP - BSP halts APs before shutting down
Tomas Hruby [Wed, 15 Sep 2010 14:10:54 +0000 (14:10 +0000)]
SMP - BSP halts APs before shutting down

14 years agoSMP - Balancing run queues for SMP
Tomas Hruby [Wed, 15 Sep 2010 14:10:51 +0000 (14:10 +0000)]
SMP - Balancing run queues for SMP

- it preempts running processes though :( this is not the final
  solution

14 years agoSMP - Changed prototype of sys_schedule()
Tomas Hruby [Wed, 15 Sep 2010 14:10:42 +0000 (14:10 +0000)]
SMP - Changed prototype of sys_schedule()

- sys_schedule can change only selected values, -1 means that the
  current value should be kept unchanged. For instance we mostly want
  to change the scheduling quantum and priority but we want to keep
  the process at the current cpu

- RS can hand off its processes to scheduler

- service can read the destination cpu from system.conf

- RS can pass the information farther

14 years agoSMP - BKL statistics
Tomas Hruby [Wed, 15 Sep 2010 14:10:37 +0000 (14:10 +0000)]
SMP - BKL statistics

- pressing 'B' on the serial cnsole prints statistics for BKL per cpu.

- 'b' resets the counters

- it presents number of cycles each CPU spends in kernel, how many
  cycyles it spends spinning while waiting for the BKL

- it shows optimistic estimation in how many cases we get the lock
  immediately without spinning. As the test is not atomic the lock may
  be already held by some other cpu before we actually try to acquire
  it.

14 years agoSMP - Free PDE slots are split among CPU
Tomas Hruby [Wed, 15 Sep 2010 14:10:36 +0000 (14:10 +0000)]
SMP - Free PDE slots are split among CPU

- cross-address space copies use these slots to map user memory for
  kernel. This avoid any collisions between CPUs

- well, we only have a single CPU running at a time, this is just to
  be safe for the future

14 years agoSMP - Scheduler can assign process to a cpu
Tomas Hruby [Wed, 15 Sep 2010 14:10:33 +0000 (14:10 +0000)]
SMP - Scheduler can assign process to a cpu

- machine information contains the number of cpus and the bsp id

- a dummy SMP scheduler which keeps all system processes on BSP and
  all other process on APs. The scheduler remembers how many processes
  are assigned to each CPU and always picks the one with the least
  processes for a new process.

14 years agoSMP - APs are fully enabled
Tomas Hruby [Wed, 15 Sep 2010 14:10:30 +0000 (14:10 +0000)]
SMP - APs are fully enabled

- apic_send_ipi() to send inter-processor interrupts (IPIs)

- APIC IPI schedule and halt handlers to signal x-cpu that a cpu shold
  reschedule or halt

- various little changes to let APs run

- no processes are scheduled at the APs and therefore they are idle
  except being interrupted by a timer time to time

14 years agoSMP - CPU local cycles accounting
Tomas Hruby [Wed, 15 Sep 2010 14:10:27 +0000 (14:10 +0000)]
SMP - CPU local cycles accounting

- tsc_ctr_switch is made cpu local

- although an x86 specific variable it must be declared globaly as the
  cpulocal implementation does not allow otherwise

14 years agoSMP - proc_ptr and bill_ptr initialization
Tomas Hruby [Wed, 15 Sep 2010 14:10:24 +0000 (14:10 +0000)]
SMP - proc_ptr and bill_ptr initialization

- they should point somewhere

14 years agoSMP - CPU local idle stub
Tomas Hruby [Wed, 15 Sep 2010 14:10:21 +0000 (14:10 +0000)]
SMP - CPU local idle stub

- each CPU has its own pseudo idle process and its structure

- idle cycles accounting is agregated when exporting to userspace

14 years agoSMP - CPU local run queues
Tomas Hruby [Wed, 15 Sep 2010 14:10:18 +0000 (14:10 +0000)]
SMP - CPU local run queues

- each CPU has its own runqueues

- processes on BSP are put on the runqueues later after a switch to
  the final stack when cpuid works to avoid special cases

- enqueue() and dequeue() use the run queues of the cpu the process is
  assigned to

- pick_proc() uses the local run queues

- printing of per-CPU run queues ('2') on serial console

14 years agoSMP - CPU and CPU mask for processes
Tomas Hruby [Wed, 15 Sep 2010 14:10:16 +0000 (14:10 +0000)]
SMP - CPU and CPU mask for processes

- each process has associated information about the cpu it is currently
  scheduled on and the mask of cpus it is allowed to use.

14 years agoSMP - BSP waits until the APs finish their booting
Tomas Hruby [Wed, 15 Sep 2010 14:10:12 +0000 (14:10 +0000)]
SMP - BSP waits until the APs finish their booting

- APs configure local timers

- while configuring local APIC timer the CPUs fiddle with the interrupt
  handlers. As the interrupt table is shared the BSP must not run

14 years agoSMP - Only a single APIC timer handler
Tomas Hruby [Wed, 15 Sep 2010 14:10:09 +0000 (14:10 +0000)]
SMP - Only a single APIC timer handler

- bsp_timer_int_handler() and ap_timer_int_handler() unified into
  timer_int_handler()

- global realtime updated only on BSP

14 years agoSMP - The slave CPUs turn paging on
Tomas Hruby [Wed, 15 Sep 2010 14:10:07 +0000 (14:10 +0000)]
SMP - The slave CPUs turn paging on

- APs wait until BSP turns paging on, it is not possible to safely
  execute any code on APs until we can turn paging on as well as it
  must be done synchronously everywhere

- APs turn paging on but do not continue and wait

14 years agoSMP - Big kernel lock (BKL)
Tomas Hruby [Wed, 15 Sep 2010 14:10:03 +0000 (14:10 +0000)]
SMP - Big kernel lock (BKL)

- to isolate execution inside kernel we use a big kernel lock
  implemented as a spinlock

- the lock is acquired asap after entering kernel mode and released as
  late as possible. Only one CPU as a time can execute the core kernel
  code

- measurement son real hw show that the overhead of this lock is close
  to 0% of kernel time for the currnet system

- the overhead of this lock may be as high as 45% of kernel time in
  virtual machines depending on the ratio between physical CPUs
  available and emulated CPUs. The performance degradation is
  significant

14 years agoSMP - Kernel is loaded above 1M by default
Tomas Hruby [Wed, 15 Sep 2010 14:10:00 +0000 (14:10 +0000)]
SMP - Kernel is loaded above 1M by default

- the 16-bit trampoline must be within the first megabyte of physical
  memory thus the smp trampoline is copied explicitly below 1M

14 years agoSMP - We boot APs
Tomas Hruby [Wed, 15 Sep 2010 14:09:52 +0000 (14:09 +0000)]
SMP - We boot APs

- kernel detects CPUs by searching ACPI tables for local apic nodes

- each CPU has its own TSS that points to its own stack. All cpus boot
  on the same boot stack (in sequence) but switch to its private stack
  as soon as they can.

- final booting code in main() placed in bsp_finish_booting() which is
  executed only after the BSP switches to its final stack

- apic functions to send startup interrupts

- assembler functions to handle CPU features not needed for single cpu
  mode like memory barries, HT detection etc.

- new files kernel/smp.[ch], kernel/arch/i386/arch_smp.c and
  kernel/arch/i386/include/arch_smp.h

- 16-bit trampoline code for the APs. It is executed by each AP after
  receiving startup IPIs it brings up the CPUs to 32bit mode and let
  them spin in an infinite loop so they don't do any damage.

- implementation of kernel spinlock

- CONFIG_SMP and CONFIG_MAX_CPUS set by the build system

14 years agoSMP - Cpu local variables
Tomas Hruby [Wed, 15 Sep 2010 14:09:46 +0000 (14:09 +0000)]
SMP - Cpu local variables

- most global variables carry information which is specific to the
  local CPU and each CPU must have its own copy

- cpu local variable must be declared in cpulocal.h between
  DECLARE_CPULOCAL_START and DECLARE_CPULOCAL_END markers using
  DECLARE_CPULOCAL macro

- to access the cpu local data the provided macros must be used

get_cpu_var(cpu, name)
get_cpu_var_ptr(cpu, name)

get_cpulocal_var(name)
get_cpulocal_var_ptr(name)

- using this macros makes future changes in the implementation
  possible

- switching to ELF will make the declaration of cpu local data much
  simpler, e.g.

  CPULOCAL int blah;

  anywhere in the kernel source code

14 years agoproc_init()
Tomas Hruby [Wed, 15 Sep 2010 14:09:43 +0000 (14:09 +0000)]
proc_init()

- code that initializes proc.c structures removed from main() and placed in
  proc_init() function

14 years agoEnable paging - some more code reshuffling
Tomas Hruby [Wed, 15 Sep 2010 14:09:41 +0000 (14:09 +0000)]
Enable paging - some more code reshuffling

14 years agoarch proto.h renamed to arch_proto.h
Tomas Hruby [Wed, 15 Sep 2010 14:09:36 +0000 (14:09 +0000)]
arch proto.h renamed to arch_proto.h

- the file moved to the arch include dir

14 years agobump trunk version to 3.1.9
Ben Gras [Wed, 15 Sep 2010 08:47:42 +0000 (08:47 +0000)]
bump trunk version to 3.1.9

make issue.install not include version

14 years agoinclude - minor compile fixes (including <ansi.h> in files that use it)
Ben Gras [Wed, 15 Sep 2010 08:47:10 +0000 (08:47 +0000)]
include - minor compile fixes (including <ansi.h> in files that use it)

workaround for kernel/debug.h that causes <ansi.h> to be included in mpx.S
indirectly.

14 years agomake getsysinfo() a system-land call
David van Moolenbroek [Tue, 14 Sep 2010 21:50:05 +0000 (21:50 +0000)]
make getsysinfo() a system-land call

14 years agomake all other commands use ProcFS
David van Moolenbroek [Tue, 14 Sep 2010 21:31:56 +0000 (21:31 +0000)]
make all other commands use ProcFS

14 years agomake top(1) use ProcFS
David van Moolenbroek [Tue, 14 Sep 2010 21:30:23 +0000 (21:30 +0000)]
make top(1) use ProcFS

14 years agomake ps(1) use ProcFS
David van Moolenbroek [Tue, 14 Sep 2010 21:29:40 +0000 (21:29 +0000)]
make ps(1) use ProcFS

14 years agomake library calls use ProcFS
David van Moolenbroek [Tue, 14 Sep 2010 21:28:34 +0000 (21:28 +0000)]
make library calls use ProcFS

14 years agoProcFS integration
David van Moolenbroek [Tue, 14 Sep 2010 21:27:31 +0000 (21:27 +0000)]
ProcFS integration

14 years agoProcFS server, by Alen Stojanov and David van Moolenbroek
David van Moolenbroek [Tue, 14 Sep 2010 21:25:25 +0000 (21:25 +0000)]
ProcFS server, by Alen Stojanov and David van Moolenbroek

14 years agoVM: expose secondary cache size
David van Moolenbroek [Tue, 14 Sep 2010 21:22:56 +0000 (21:22 +0000)]
VM: expose secondary cache size

14 years agoPM: save process frame length
David van Moolenbroek [Tue, 14 Sep 2010 21:21:54 +0000 (21:21 +0000)]
PM: save process frame length

14 years agoadd EHOSTDOWN errno.
Ben Gras [Tue, 14 Sep 2010 11:51:41 +0000 (11:51 +0000)]
add EHOSTDOWN errno.

14 years agomake, lib changes to make gcc/clang format libraries in /usr/lib instead of /usr...
Ben Gras [Mon, 13 Sep 2010 16:37:02 +0000 (16:37 +0000)]
make, lib changes to make gcc/clang format libraries in /usr/lib instead of /usr/gnu/lib.

14 years agolib: fixes to make clang not error
Ben Gras [Mon, 13 Sep 2010 15:50:54 +0000 (15:50 +0000)]
lib: fixes to make clang not error

14 years agoMakefiles: remove -D__minix for assembly invocations.
Ben Gras [Mon, 13 Sep 2010 13:36:29 +0000 (13:36 +0000)]
Makefiles: remove -D__minix for assembly invocations.

They seem to be redundant (for gcc+ack+clang) and produce
very messy warnings (for clang, due to it already being defined).

14 years agoUpdate PATHs for llvm and X11
Arun Thomas [Sun, 12 Sep 2010 17:56:53 +0000 (17:56 +0000)]
Update PATHs for llvm and X11

14 years agoRemove packit/packman from Makefile
Arun Thomas [Sun, 12 Sep 2010 16:53:45 +0000 (16:53 +0000)]
Remove packit/packman from Makefile

14 years agoRemove packman and packit manpages
Arun Thomas [Sun, 12 Sep 2010 13:55:00 +0000 (13:55 +0000)]
Remove packman and packit manpages

14 years agoUpdate release script for pkgsrc
Arun Thomas [Fri, 10 Sep 2010 17:00:30 +0000 (17:00 +0000)]
Update release script for pkgsrc

14 years agoremove hardcoding of system.conf path in various service calls
David van Moolenbroek [Fri, 10 Sep 2010 09:22:22 +0000 (09:22 +0000)]
remove hardcoding of system.conf path in various service calls

14 years agomemory driver: propagate data copy error to caller
David van Moolenbroek [Thu, 9 Sep 2010 16:13:02 +0000 (16:13 +0000)]
memory driver: propagate data copy error to caller

14 years agoshutdown(8): buffer accessed beyond end during option parsing
David van Moolenbroek [Thu, 9 Sep 2010 08:48:47 +0000 (08:48 +0000)]
shutdown(8): buffer accessed beyond end during option parsing

14 years agoIS: delete obsolete is.h
David van Moolenbroek [Thu, 9 Sep 2010 08:47:39 +0000 (08:47 +0000)]
IS: delete obsolete is.h

14 years agoAPIC mode uses IO APICs
Tomas Hruby [Tue, 7 Sep 2010 07:18:11 +0000 (07:18 +0000)]
APIC mode uses IO APICs

- kernel turns on IO APICs if no_apic is _not_ set or is equal 0

- pci driver must use the acpi driver to setup IRQ routing otherwise
  the system cannot work correctly except systems like KVM that use
  only legacy (E)ISA IRQs 0-15

14 years agoMake realpath deal with double slashes
Erik van der Kouwe [Mon, 6 Sep 2010 07:45:32 +0000 (07:45 +0000)]
Make realpath deal with double slashes

14 years agoasm.h not installed
Tomas Hruby [Fri, 3 Sep 2010 17:01:18 +0000 (17:01 +0000)]
asm.h not installed

14 years agoMake hexdump ACK-compilable and add it to the base system
Erik van der Kouwe [Fri, 3 Sep 2010 07:37:31 +0000 (07:37 +0000)]
Make hexdump ACK-compilable and add it to the base system

14 years agoNo more packman, easypack, packit
Arun Thomas [Fri, 3 Sep 2010 07:27:39 +0000 (07:27 +0000)]
No more packman, easypack, packit

-Create a dummy packman script that tells users about pkgin

14 years agoPCI driver uses ACPI if APIC is used.
Tomas Hruby [Thu, 2 Sep 2010 15:44:38 +0000 (15:44 +0000)]
PCI driver uses ACPI if APIC is used.

-  PCI must query ACPI, if (IO)APIC is in use, for the routing
   information and change the ILR (interrupt line register) of each
   device accordingly so drivers use the right IRQ.

14 years agoACPI driver loaded at boot time
Tomas Hruby [Thu, 2 Sep 2010 15:44:36 +0000 (15:44 +0000)]
ACPI driver loaded at boot time

- the acpi driver is part of the ramdisk and if present the rc script
  starts it before pci is started as pci needs if APIC mode is turned
  on.

14 years agoACPI driver
Tomas Hruby [Thu, 2 Sep 2010 15:44:04 +0000 (15:44 +0000)]
ACPI driver

- 99% of the code is Intel's ACPICA. The license is compliant with BSD
  and GNU and virtually all systems that use ACPI use this code, For
  instance it is part of the Linux kernel.

- The only minix specific files are

  acpi.c
  osminixxf.c
  platform/acminix.h

  and

  include/minix/acpi.h

- At the moment the driver does not register interrupt hooks which I
  believe is mainly for handling PnP, events like "battery level is
  low" and power management. Should not be difficult to add it if need
  be.

- The interface to the outside world is virtually non-existent except
  a trivial message based service for PCI driver to query which device
  is connected to what IRQ line. This will evolve as more components
  start using this driver. VM, Scheduler and IOMMU are the possible
  users right now.

- because of dependency on a native 64bit (long long, part of c99) it
  is compiled only with a gnu-like compilers which in case of Minix
  includes gcc llvm-gcc and clang

14 years agopci_*.h headers moved from drivers/pci to include/machine
Tomas Hruby [Thu, 2 Sep 2010 15:43:59 +0000 (15:43 +0000)]
pci_*.h headers moved from drivers/pci to include/machine

14 years agoKernel exports DSDP and apic_enabled in machine structure
Tomas Hruby [Thu, 2 Sep 2010 15:43:56 +0000 (15:43 +0000)]
Kernel exports DSDP and apic_enabled in machine structure

- kernel exports DSDP (the root pointer where ACPI parsing starts) and
  apic_enabled in the machine structure.

- ACPI driver uses DSDP to locate ACPI in memory. acpi_enabled tell
  PCI driver to query ACPI for IRQ routing information.

14 years agoKernel supports up to 64 IRQs
Tomas Hruby [Thu, 2 Sep 2010 15:43:54 +0000 (15:43 +0000)]
Kernel supports up to 64 IRQs

- enough for 2 io apics (usually with 24 pins)

14 years agoACPI in kernel
Tomas Hruby [Thu, 2 Sep 2010 15:43:51 +0000 (15:43 +0000)]
ACPI in kernel

- the ability for kernel to use ACPI tables to detect IO APICs. It is
  the bare minimum the kernel needs to know about ACPI tables.

- it will be used to find out about processors as the MPS tables are
  deprecated by ACPI and not all vendorsprovide them.

14 years agoClean up the created temp file after running the test.
Thomas Veerman [Thu, 2 Sep 2010 09:33:37 +0000 (09:33 +0000)]
Clean up the created temp file after running the test.

14 years agoremoved redundant includes dependency from gnu-libraries.
Ben Gras [Wed, 1 Sep 2010 18:48:47 +0000 (18:48 +0000)]
removed redundant includes dependency from gnu-libraries.

14 years agoalso make gcc includes before compiling gcc libraries.
Ben Gras [Wed, 1 Sep 2010 18:28:55 +0000 (18:28 +0000)]
also make gcc includes before compiling gcc libraries.

14 years ago- Return ENOENT when trying to add files to removed (but open) directories.
Thomas Veerman [Wed, 1 Sep 2010 09:07:18 +0000 (09:07 +0000)]
- Return ENOENT when trying to add files to removed (but open) directories.
- Add test58 to test this behavior.

14 years agotools/Makefile uses padtext only when building with ack
Tomas Hruby [Wed, 1 Sep 2010 07:46:51 +0000 (07:46 +0000)]
tools/Makefile uses padtext only when building with ack