Commit graph

548 commits

Author SHA1 Message Date
Gianluca Guida 4f294c247f Add NBSDLibc Minix specific files.
This patch mainly copies and modifies files existing in
the current libc implementing minix specific functions.

To keep consisten with the NetBSD libc, we remove 
namespace stubs and we use "namespace.h" and weak
links.
2011-02-17 17:11:09 +00:00
Gianluca Guida 3c9575aadc Clean up NetBSD libc Minix port.
This patch add the proper .if/.else/.endif to the Makefiles, add places I forgot #ifdef __minix and remove newlines.
2011-02-15 16:31:16 +00:00
Gianluca Guida ad4dda469f Port NetBSD libc functions to Minix.
This patch contains changes to NetBSD libc code base to make it
compile and work on Minix. Some of them are due to actual NetBSD
libc bugs, as we're compiling it in non-reentrant mode and with
a.out support, something not exactly frequent in NetBSD.
Others are proper fixes to port it to Minix (mostly sa_len
parameter missing in socket and a few mmap from files).
2011-02-15 12:19:40 +00:00
Gianluca Guida b6cbf7203b Import unmodified NetBSD libc in trunk
This patch imports the unmodified current version of NetBSD libc.
The NetBSD includes are in /nbsd_include, while the libc code itself is 
split between lib/nbsd_libc and common/lib/libc.
2011-02-14 19:36:03 +00:00
Erik van der Kouwe b096b323d1 Fix comment mutilated by find/replace 2011-02-02 14:53:49 +00:00
Ben Gras dee29bbd3c some extra math functions from netbsd for netpbm. 2011-01-30 23:40:51 +00:00
Ben Gras dc1cc91df1 <ansi.h> -> <minix/ansi.h> 2011-01-28 11:35:02 +00:00
Erik van der Kouwe 04229f0581 Servers request TSC freq from kernel rather than each one measuring it individually 2011-01-11 11:03:37 +00:00
Arun Thomas 4fe0dfa9aa libc and csu updates for ELF 2010-12-10 23:04:04 +00:00
Arun Thomas d824b54d82 csu/build support for ELF 2010-12-10 22:20:12 +00:00
Arun Thomas 372b873413 VFS/RS support for ELF 2010-12-10 09:27:56 +00:00
Dirk Vogt 9ed280d1ec decouple file system server start/termination from mount/umount 2010-11-23 19:34:56 +00:00
Arun Thomas 7a4149a3f5 For GCC/clang, don't build in ACK int64 routines 2010-11-19 12:36:44 +00:00
Tomas Hruby 504abf4b34 Inlining 64bit integer handling functions
- if gcc/clang is used the C functions that use long long can be
  inlined to get better performance (yes, it makes difference)
2010-11-18 16:37:40 +00:00
Dirk Vogt 6208131459 libdriver without mandatory driver main loop 2010-11-17 15:10:20 +00:00
Dirk Vogt c22564335f Added possibility to inject input events to tty
M    include/Makefile
A    include/minix/input.h
M    include/minix/com.h
M    drivers/tty/keyboard.c
M    drivers/tty/tty.c
M    drivers/tty/tty.h
M    include/minix/syslib.h
M    lib/libsys/Makefile
A    lib/libsys/input.c
2010-11-17 14:53:07 +00:00
Arun Thomas f0ab18377d GCC/clang: int64 routines in C 2010-11-12 18:38:10 +00:00
Arun Thomas aaaad89244 Use int64 functions consistently
Instead of manipulating the u64_t type directly, use the
ex64hi()/ex64lo()/make64() functions.
2010-11-07 23:35:29 +00:00
Arun Thomas 998af6f111 Move minix/paths.h to paths.h
Also, merge in relevant macros from NetBSD
2010-11-06 20:40:15 +00:00
Arun Thomas 40fb96b838 Remove revision IDs from files 2010-11-04 01:13:59 +00:00
Ben Gras efcfaf4b96 stdio: split vsprintf and vsnprintf
- workaround for linking problems
2010-11-02 22:05:40 +00:00
Ben Gras 51d9144e9f stdio/freopen.c: fill __iotab table with stream pointer
- lets fclose()d and then freopen()ed streams be fclose()d again
    without error
2010-11-02 22:02:50 +00:00
Ben Gras 09569d399f stdio/fclose.c: reset _buf
- if the stream gets freopen()ed, avoid buffer being seen as valid
2010-11-02 22:01:47 +00:00
Erik van der Kouwe 470a185909 Add libdriver support for async ioctl replies 2010-10-08 09:33:18 +00:00
Erik van der Kouwe ada0b4ca04 Fix warnings due to missing __dead attribute on exit 2010-10-05 07:25:47 +00:00
Erik van der Kouwe 591201c1a0 Fix warnings in libmthread 2010-10-04 20:19:40 +00:00
Erik van der Kouwe b0eaf0bc27 make system server vprintf check for NULL 2010-10-04 17:53:18 +00:00
Ben Gras 68de328ac1 make the asynsend table size NPROCS-dependent.
this is a fix for e.g. the situation where lots of processes die
instantly, and PM has to send an asyn msg for each one to VFS, and
panics if there are too many. there are likely more situations in
which this table should be dependent on the no. of processes.

reported by pikpik on #minix3.
2010-10-01 14:39:04 +00:00
Thomas Veerman a7072a5e1c Revamp the mthread library and update test59
Before, the 'main thread' of a process was never taken into account anywhere in
the library, causing mutexes not to work properly (and consequently, neither
did the condition variables). For example, if the 'main thread' (that is, the
thread which is started at the beginning of a process; not a spawned thread by
the library) would lock a mutex, it wasn't actually locked.
2010-09-30 13:44:13 +00:00
Tomas Hruby 74c5cd7668 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
2010-09-23 10:49:42 +00:00
David van Moolenbroek adbc4e4ea7 libsys: tsc_to_micros support for large TSC delta values 2010-09-23 09:26:42 +00:00
Thomas Veerman 12e167f672 Add libmthread and test59 to test the implementation 2010-09-21 12:22:38 +00:00
Ben Gras 250fb23dc0 lib/libsys/gcov.c - fix gcc warning 2010-09-20 11:36:41 +00:00
Tomas Hruby 06b6e5624a 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
2010-09-15 14:10:42 +00:00
David van Moolenbroek 354da24f5b make getsysinfo() a system-land call 2010-09-14 21:50:05 +00:00
David van Moolenbroek d7b10963c2 make library calls use ProcFS 2010-09-14 21:28:34 +00:00
Ben Gras a5a8c57fe7 add EHOSTDOWN errno. 2010-09-14 11:51:41 +00:00
Ben Gras 23311d9819 lib: fixes to make clang not error 2010-09-13 15:50:54 +00:00
Arun Thomas 7c3cfbde1a Update PATHs for llvm and X11 2010-09-12 17:56:53 +00:00
David van Moolenbroek d29833c5aa remove hardcoding of system.conf path in various service calls 2010-09-10 09:22:22 +00:00
Erik van der Kouwe 5cc29a6c7e Make realpath deal with double slashes 2010-09-06 07:45:32 +00:00
Thomas Veerman e8ddc0f46e - Add support for file descriptor passing to PFS.
- For security reasons move some libc code to PFS.
- Fix a few bugs in PFS.
Contributed by Thomas Cort.
2010-08-30 13:46:44 +00:00
Thomas Veerman 2297e26660 Prepare headers to support file descriptor passing over UNIX Domain Sockets.
Contributed by Thomas Cort.
2010-08-30 13:41:22 +00:00
Ben Gras c81f201c8c added missing sef_gcov.c 2010-08-25 13:23:32 +00:00
Ben Gras 5d6c2aae0a gcov support, based on work contributed by Anton Kuijsten. 2010-08-25 13:06:43 +00:00
Ben Gras d8466ce31f libaudiodriver <minix/audio_fw.h> fixes 2010-08-25 11:18:38 +00:00
Ben Gras 1c359afad4 connect libaudiodriver. 2010-08-25 11:07:36 +00:00
Ben Gras 0f4eda33eb new base libaudiodriver out of -lcommon in drivers/audio.
- this lets the drivers that used that library be compiled easily with
   different compilers.
2010-08-25 11:03:53 +00:00
Erik van der Kouwe a2647a4181 Fix buffer overflow in libarchive if a UTF-8 encoded string has codepoints that require two UTF-16 words 2010-08-23 16:32:05 +00:00
Erik van der Kouwe d743c5c6f3 Solve buffer overflow on tab completion in ash 2010-08-23 16:30:58 +00:00