summaryrefslogtreecommitdiffstats
path: root/lib/libkvm
Commit message (Collapse)AuthorAgeFilesLines
* Make kvm(3) aware of ki_jid field.pjd2005-03-201-1/+17
| | | | | Reviewed by: gad MFC after: 3 days
* Dike out unwarranted reference to si_udev.phk2005-03-151-0/+4
|
* Sort sections.ru2005-01-204-29/+29
|
* In preparation to remove U areas, don't refer to p_uarea in libkvm.das2004-11-201-1/+1
| | | | Reviewed by: arch@
* Remove un-needed call to close(2). The fd that close is beingcsjp2004-11-131-1/+0
| | | | | | called on is invalid and has no use. Reviewed by: smkelly
* Document the fact that kvm_getenvv(3) requires procfs to be mountedcsjp2004-11-131-0/+7
| | | | | | on /proc in order to operate correctly. Reviewed by: simon@, wes@
* Belatedly catch up with the dev_t/cdev changes from a few months back.peter2004-10-111-1/+11
| | | | | | | Extract the struct cdev pointer and the tty device from inside rather than incorrectly casting the 'struct cdev *' pointer to a 'dev_t' int. Not that this was particularly important since it was only used for reading vmcore files.
* - Fix the compile to chase the p_rux changes.jhb2004-10-061-1/+7
| | | | | | | - Add a comment noting that the ru_[us]times values being read aren't actually valid and need to be computed from the raw values. Submitted by: many (1)
* Redefine a PTE as a 64-bit integral type instead of a struct ofmarcel2004-09-231-2/+2
| | | | | bit-fields. Unify the PTE defines accordingly and update all uses.
* The offset argument to mmap(2) is not a pointer. Use 0 instead of NULL.marcel2004-09-221-1/+1
|
* Refactor a bunch of scheduler code to give basically the same behaviourjulian2004-09-051-1/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | but with slightly cleaned up interfaces. The KSE structure has become the same as the "per thread scheduler private data" structure. In order to not make the diffs too great one is #defined as the other at this time. The KSE (or td_sched) structure is now allocated per thread and has no allocation code of its own. Concurrency for a KSEGRP is now kept track of via a simple pair of counters rather than using KSE structures as tokens. Since the KSE structure is different in each scheduler, kern_switch.c is now included at the end of each scheduler. Nothing outside the scheduler knows the contents of the KSE (aka td_sched) structure. The fields in the ksegrp structure that are to do with the scheduler's queueing mechanisms are now moved to the kg_sched structure. (per ksegrp scheduler private data structure). In other words how the scheduler queues and keeps track of threads is no-one's business except the scheduler's. This should allow people to write experimental schedulers with completely different internal structuring. A scheduler call sched_set_concurrency(kg, N) has been added that notifies teh scheduler that no more than N threads from that ksegrp should be allowed to be on concurrently scheduled. This is also used to enforce 'fainess' at this time so that a ksegrp with 10000 threads can not swamp a the run queue and force out a process with 1 thread, since the current code will not set the concurrency above NCPU, and both schedulers will not allow more than that many onto the system run queue at a time. Each scheduler should eventualy develop their own methods to do this now that they are effectively separated. Rejig libthr's kernel interface to follow the same code paths as linkse for scope system threads. This has slightly hurt libthr's performance but I will work to recover as much of it as I can. Thread exit code has been cleaned up greatly. exit and exec code now transitions a process back to 'standard non-threaded mode' before taking the next step. Reviewed by: scottl, peter MFC after: 1 week
* Expand the license referenced indirectly inline.imp2004-07-312-6/+40
|
* Remove stale code protected by #ifdef sparc. GCC 3.4.x adds sparc tokan2004-07-281-9/+0
| | | | predefined symbols on all SPARC platforms and FreeBSD follows the crowd.
* Mechanically kill hard sentence breaks.ru2004-07-027-23/+46
|
* Markup, grammar, punctuation.ru2004-07-011-14/+14
|
* Fix a test of bit-flag "P_SA" by adding parenthesis around the expression.gad2004-06-231-1/+1
| | | | Submitted by: Cyrille Lefevre
* Replace a call to strncpy() with a call to strlcpy()gad2004-06-231-4/+2
| | | | Submitted by: Cyrille Lefevre
* Fill in the some new fields 'struct kinfo_proc', namely ki_childstime,gad2004-06-191-5/+29
| | | | | | | | | | | | | ki_childutime, and ki_emul. Also uses the timeradd() macro to correct the calculation of ki_childtime. That will correct the value returned when ki_childtime.tv_usec > 1,000,000. This also implements a new KERN_PROC_GID option for kvm_getprocs(). It also implements the KERN_PROC_RGID and KERN_PROC_SESSION options which were added to sys/kern/kern_proc.c revision 1.203. PR: bin/65803 (a very tiny piece of the PR) Submitted by: Cyrille Lefevre
* Second half of the dev_t cleanup.phk2004-06-171-1/+1
| | | | | | | | | | | The big lines are: NODEV -> NULL NOUDEV -> NODEV udev_t -> dev_t udev2dev() -> findcdev() Various minor adjustments including handling of userland access to kernel space struct cdev etc.
* This library has to change whenever the kernel process structure changes.julian2004-06-161-1/+1
|
* Avoid assignments to cast expressions.stefanf2004-06-081-3/+3
| | | | | Reviewed by: md5 Approved by: das (mentor)
* Implement crashdump decoding for AMD64 as well, now that I have finallypeter2004-05-191-28/+63
| | | | got a sample to test against.
* Import libkvm MD file for arm.cognet2004-05-141-0/+103
|
* Fix a warning: compare u_long ps_strings to 0 instead of NULL.schweikh2004-03-281-1/+1
|
* Document that kvm_open(3) also accepts "/dev/null" as a specialru2004-03-261-4/+15
| | | | | "corefile" argument, to access the running system via sysctl(3) if possible, thus not requring special setgid privileges.
* Document that libkvm also uses /dev/kmem, to access KVM.ru2004-03-261-3/+7
|
* Update man page to reflect additional flag to allow selection of threads.deischen2004-02-221-0/+3
|
* Teach kvm_getprocs() to recognize a sysctl flag for including threads.deischen2004-02-221-5/+8
|
* Allow to specify a character special device as a core file.simokawa2003-10-291-21/+18
| | | | | | | | | | | | | | This enable us to use /dev/fwmem* as a core file. e.g. ps -M /dev/fwmem0.0 -N kernel.debug dmesg -M /dev/fwmem0.0 -N kernel.debug gdb -k -c /dev/fwmem0.0 kernel.debug You need to set target EUI64 in hw.firewire.fwmem.eui64_hi/lo before opening the device. On the target arch, (PCI) bus address must be equivalent to physical address. (We cannot use this for sparc64 because of IOMMU.) No objection in: -audit
* Fixed some style bugs in the removal of __P(()). Blind removal ofbde2003-10-131-3/+3
| | | | spaces before __P(()) outdented continuation lines to column 0.
* Document KERN_PROC_PROC, update KERN_PROC_ALL description.tjr2003-09-271-2/+4
|
* Use the 3-component version of the KERN_PROC_PROC sysctl.tjr2003-09-271-2/+4
|
* style.Makefile(5)obrien2003-08-181-1/+1
|
* Stage 3 of dynamic root support. Make all the libraries needed to rungordon2003-08-171-0/+1
| | | | | | binaries in /bin and /sbin installed in /lib. Only the versioned files reside in /lib, the .so symlink continues to live /usr/lib so the toolchain doesn't need to be modified.
* Remove unnecssary <vm/swap_pager.h> includes.phk2003-07-313-3/+0
| | | | | These were probably not cleaned up back in whatever murky past these files were split into separate files.
* Remove various unused variables, prototypes and local variables.phk2003-07-311-25/+0
|
* Disable and lobotomize the kvm image reading swapinfo code, the kernelphk2003-07-311-125/+1
| | | | | | layout is about to change. The sysctl based method still returns correct information.
* Retire the SWIF_DUMP_TREE code, this is in the way for a rework ofphk2003-07-312-191/+0
| | | | the swap_pager layout.
* Unifdef -UDEBUG_SWAPINFO The kernel data structures are about to change.phk2003-07-311-79/+0
|
* P_THREADED was renamed to P_SA, follow up.davidxu2003-06-151-2/+2
|
* Revamp of the syscall path, exception and context handling. Themarcel2003-05-161-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | prime objectives are: o Implement a syscall path based on the epc inststruction (see sys/ia64/ia64/syscall.s). o Revisit the places were we need to save and restore registers and define those contexts in terms of the register sets (see sys/ia64/include/_regset.h). Secundairy objectives: o Remove the requirement to use contigmalloc for kernel stacks. o Better handling of the high FP registers for SMP systems. o Switch to the new cpu_switch() and cpu_throw() semantics. o Add a good unwinder to reconstruct contexts for the rare cases we need to (see sys/contrib/ia64/libuwx) Many files are affected by this change. Functionally it boils down to: o The EPC syscall doesn't preserve registers it does not need to preserve and places the arguments differently on the stack. This affects libc and truss. o The address of the kernel page directory (kptdir) had to be unstaticized for use by the nested TLB fault handler. The name has been changed to ia64_kptdir to avoid conflicts. The renaming affects libkvm. o The trapframe only contains the special registers and the scratch registers. For syscalls using the EPC syscall path no scratch registers are saved. This affects all places where the trapframe is accessed. Most notably the unaligned access handler, the signal delivery code and the debugger. o Context switching only partly saves the special registers and the preserved registers. This affects cpu_switch() and triggered the move to the new semantics, which additionally affects cpu_throw(). o The high FP registers are either in the PCB or on some CPU. context switching for them is done lazily. This affects trap(). o The mcontext has room for all registers, but not all of them have to be defined in all cases. This mostly affects signal delivery code now. The *context syscalls are as of yet still unimplemented. Many details went into the removal of the requirement to use contigmalloc for kernel stacks. The details are mostly CPU specific and limited to exception_save() and exception_restore(). The few places where we create, destroy or switch stacks were mostly simplified by not having to construct physical addresses and additionally saving the virtual addresses for later use. Besides more efficient context saving and restoring, which of course yields a noticable speedup, this also fixes the dreaded SMP bootup problem as a side-effect. The details of which are still not fully understood. This change includes all the necessary backward compatibility code to have it handle older userland binaries that use the break instruction for syscalls. Support for break-based syscalls has been pessimized in favor of a clean implementation. Due to the overall better performance of the kernel, this will still be notived as an improvement if it's noticed at all. Approved by: re@ (jhb)
* s/procsig/sigacts/ to catch up to procsig and sigacts changes in the kernel.jhb2003-05-141-10/+6
| | | | Approved by: re (scottl)
* Bandaid for world. jhb gets the pointy hat here and he needs to look atpeter2003-05-141-0/+4
| | | | | | this. Approved by: re (scottl)
* AMD64 support; repocopied from i386peter2003-04-301-3/+3
|
* Add sys/user.h to the list of includes. Without it you lack a definition oftrhodes2003-04-261-0/+1
| | | | | | 'struct kinfo_proc' for calls to kvm_getargv() and kvm_getenvv(). PR: 51322
* Catch up with the kernel. Move the current cpu indicator to the thread.julian2003-04-101-3/+1
|
* - Spell SIGSETOR correctly.jeff2003-04-011-1/+1
|
* - Catch up with kernel signal changes.jeff2003-03-311-1/+2
|
* The .Fn functioncharnier2003-03-245-13/+23
| | | | The .Fa argument
* Catch up to p_tracep -> p_tracevp rename to unbreak world.jhb2003-03-131-1/+1
| | | | Pointy hat to: jhb
OpenPOWER on IntegriCloud