summaryrefslogtreecommitdiff
path: root/lib/libc
Commit message (Collapse)AuthorAgeFilesLines
* Remove stale reference to the deprecated USER_LDT option. The associatedJohn Baldwin2003-06-091-4/+0
| | | | | | | | | | code is always compiled into the kernel now. Submitted by: Hubert Tournier <hubert@frbsd.org> PR: docs/53068 Notes: svn path=/head/; revision=116091
* The .Fn functionPhilippe Charnier2003-06-081-3/+6
| | | | Notes: svn path=/head/; revision=116025
* .Xr p1003_1b moved to .St -p1003.1b-93Philippe Charnier2003-06-082-6/+6
| | | | Notes: svn path=/head/; revision=116023
* .Xr -> .Lb for librairy. There is no manual page corresponding to .Xr.Philippe Charnier2003-06-081-1/+1
| | | | Notes: svn path=/head/; revision=116022
* Add or correct section number in .Xr. Use .Vt or .FnPhilippe Charnier2003-06-088-13/+13
| | | | | | | instead of .Xr when needed Notes: svn path=/head/; revision=116021
* Recognize the magic NODEV value.Poul-Henning Kamp2003-06-051-3/+3
| | | | | | | Format other unknown devices consistently in hex. Notes: svn path=/head/; revision=115881
* Document the new explicit listing API for extended attributes; noteRobert Watson2003-06-041-6/+32
| | | | | | | | | | | | that the old API (passing "" as the attribute name to the _get_ interface) is now deprecated (and was probably a bad idea). Pointed out by: Dominic Giampaolo <dbg@apple.com> Obtained from: TrustedBSD Project Sponsored by: DARPA, Network Associates Laboratories Notes: svn path=/head/; revision=115802
* Document that kldload(2) can also return EEXIST.Hiten Pandya2003-06-031-0/+4
| | | | | | | Approved by: des (mentor) Notes: svn path=/head/; revision=115771
* Cosmetic; record offsets used within jmpbufPeter Wemm2003-06-023-30/+30
| | | | Notes: svn path=/head/; revision=115745
* Fix sigsetjmp(). It helps if we do not try to save the old signal maskPeter Wemm2003-06-021-0/+1
| | | | | | | to a random memory location. Perl works a lot better with this. Notes: svn path=/head/; revision=115738
* Use C99 compatible ASM statements.David E. O'Brien2003-06-022-3/+3
| | | | Notes: svn path=/head/; revision=115665
* o Fix a cut-n-paste bug. We were clobbering rp with gp...Marcel Moolenaar2003-06-021-2/+2
| | | | | | | | | o Make sure the arguments to ctx_wrapper() are loaded from the backing store by forcing an underflow. Do this by making all registers in the register frame local. Notes: svn path=/head/; revision=115657
* Match style of source and headers.Juli Mallett2003-06-011-1/+1
| | | | | | | Submitted by: bde Notes: svn path=/head/; revision=115641
* Assorted mdoc(7) fixes.Ruslan Ermilov2003-06-016-180/+190
| | | | Notes: svn path=/head/; revision=115631
* Add GBK encodingAndrey A. Chernov2003-06-013-2/+121
| | | | | | | | PR: 51504 Submitted by: Statue <statue@freebsd.sinica.edu.tw> Notes: svn path=/head/; revision=115626
* Clarify the code a bit.Poul-Henning Kamp2003-06-011-1/+2
| | | | | | | Submitted by: Nadav Eiron <nadav@TheEirons.org> Notes: svn path=/head/; revision=115610
* Make prototype match code with regard to constness of args to theJuli Mallett2003-06-011-1/+1
| | | | | | | function pointer passed in. Notes: svn path=/head/; revision=115604
* Fix grammar bogons.Jens Schweikhardt2003-05-311-1/+1
| | | | | | | MFC after: 3 days Notes: svn path=/head/; revision=115571
* Rough implement of makecontext() needed to support libthr.Marcel Moolenaar2003-05-312-1/+122
| | | | | | | | | | | | | | | | | o Up to 8 arguments are allowed. This is the number of arguments passed in registers. Subsequent registers are passed on the stack. Trying to deal with this is not easy in C and likely forces us to use assembly code. Let's avoid that for now. There's no indication that more than 8 arguments is a strong requirement (Linux also has an 8 argument limit). o We expect that the stack base is 16-byte aligned and the stack size is a multiple of 16-byte. We bomb out if this is not the case. We probably want to be less strict by enforcing it ourselves. For now it's better to not hide gross alignment bogons by silently correcting it. Notes: svn path=/head/; revision=115518
* Fix a sizeof error in __bt_put: when writing they key and data sizesThomas Moestl2003-05-301-3/+5
| | | | | | | | | | | | | to a buffer in the big key/data case, memmove() was used on pointers to size_ts, but only sizeof(u_int32_t) bytes where copied. This broke on big_endian architectures where sizeof(size_t) > sizeof(u_int32_t). This bug broke portupgrade (by way of ruby_bdb1) on sparc64. Approved by: re (rwatson) Notes: svn path=/head/; revision=115411
* Add an stub for _rtld_thread_init. This is a part I missed inAlexander Kabaev2003-05-301-0/+7
| | | | | | | | | my last commit. Approved by: re (scottl) Notes: svn path=/head/; revision=115401
* Don't return -1 and abort if msg.msg_controllen is 0. ForMartin Blapp2003-05-291-2/+1
| | | | | | | | | | | some strange reason recvmsg() never sets errno to EAGAIN on a non-blocking socket and just returns 0. Reviewed by: jhb Approved by: re Notes: svn path=/head/; revision=115394
* Fix a problem introduced in the last commit. sa and cmMartin Blapp2003-05-291-2/+2
| | | | | | | | | | | | are not initialized at this place. Move the initializing before the non-blocking check. Submitted by: Marius Strobl <marius@alchemy.franken.de> Reviewed by: jhb Approved by: re Notes: svn path=/head/; revision=115385
* If AF_LOCAL is used, we need to use __msgread_withcred() instead ofMartin Blapp2003-05-281-1/+6
| | | | | | | | | | | | just read() in non-blocking mode too. The reason is obvious. NetBSD uses a complete different way to get the credentials so this patch only applies to FreeBSD. Reviewed by: rwatson Approved by: re Notes: svn path=/head/; revision=115364
* Fix amd(8) clients, if a FreeBSD mountd(8) server is used.Martin Blapp2003-05-281-9/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove the special treatment of non-blocking mode in the "look ahead function" xdrrec_eof(). It currently assumes that the last read() in a row of several reads does not have zero lenght. If this is the case, svc_vc_stat() does return XPRT_MOREREQS, and the RPC-request aborts because there is no data to read anymore. To fix this, go back to the original version of the code for non-blocking mode until NetBSD comes up with another possible fix like this one in xdrrec_eof() if (rstrm->last_frag && rstrm->in_finger == rstrm->in_boundry) { return TRUE; } Return always FALSE in set_input_fragment() for non-blocking mode. Since this was not used in FreeBSD, I omitted it at the first time. Now we use this function and we should always return FALSE for it. Reviewed by: rwatson Approved by: re Notes: svn path=/head/; revision=115363
* Fix stripping last path component when only one path component left.Max Khon2003-05-281-2/+2
| | | | | | | | PR: 52686 MFC after: 1 day Notes: svn path=/head/; revision=115362
* mdoc(7) fixes.Ruslan Ermilov2003-05-241-6/+5
| | | | | | | Approved by: re (blanket) Notes: svn path=/head/; revision=115288
* Repair PIC mode. It seems I was a bit too excited about thePeter Wemm2003-05-247-15/+89
| | | | | | | implications of native PC relative addressing. Notes: svn path=/head/; revision=115279
* Assorted mdoc(7) fixes.Ruslan Ermilov2003-05-2213-76/+85
| | | | | | | Approved by: re (blanket) Notes: svn path=/head/; revision=115225
* Fixed troff(1) and mdoc(7) warnings.Ruslan Ermilov2003-05-184-5/+6
| | | | | | | Approved by: re (blanket) Notes: svn path=/head/; revision=115143
* Fix a simple bug that prevents svc_tli_create to bind to the addressMartin Blapp2003-05-181-1/+1
| | | | | | | | | | | | | specified by caller. NetBSD rev. 1.6 Reviewed by: rwatson Approved by: rwatson (re) Obtained from: NetBSD Notes: svn path=/head/; revision=115133
* Revamp of the syscall path, exception and context handling. TheMarcel Moolenaar2003-05-163-12/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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) Notes: svn path=/head/; revision=115084
* Catch up with the renaming of the "union" filesystem to "unionfs".Tim J. Robbins2003-05-161-1/+1
| | | | | | | | | | Fixes a problem where directory entries could show up twice: once on the top layer of the union stack, and once on the bottom layer. Approved by: re (rwatson) Notes: svn path=/head/; revision=115047
* * The copy of the stat struct in the man page has rotted, so remove it.Doug Barton2003-05-131-29/+2
| | | | | | | | | | | Those who really need this information can find it in the include file. * Include a succinct description of the st_birthtime field. Approved by: re (bmah) Notes: svn path=/head/; revision=114969
* Update ldexp.c for amd64.Peter Wemm2003-05-102-7/+1
| | | | Notes: svn path=/head/; revision=114866
* Add a comment describing why it's important for the values in thisDavid Schultz2003-05-086-0/+42
| | | | | | | | | file to be correct, and how to generate them automatically. Caused much pain and suffering for: peter Notes: svn path=/head/; revision=114839
* SIG_SETMASK is 3, not 1. Sigh.Peter Wemm2003-05-081-1/+1
| | | | Notes: svn path=/head/; revision=114835
* Fix an embarresing transcription error from i386 to amd64. Put the argumentsPeter Wemm2003-05-082-13/+12
| | | | | | | | to sigprocmask(2) int the correct order. *blush*. For sigsetjmp(), match up the pushq/popq in the non-savemask case. Notes: svn path=/head/; revision=114829
* Tidy up modf.S and make it actually work. It wasn't extractingPeter Wemm2003-05-081-16/+13
| | | | | | | | the value out of ST(0) before copying it to %xmm0. Also remove bogus stack frame and work in the red zone. Notes: svn path=/head/; revision=114827
* Fix typo, even though this is unused.Peter Wemm2003-05-081-1/+1
| | | | Notes: svn path=/head/; revision=114818
* Like ia64, amd64 has got a 16 byte sized and aligned 'long double'.Peter Wemm2003-05-081-1/+2
| | | | | | | Obtained from: re (blanket amd64) Notes: svn path=/head/; revision=114817
* Turn off alloca.S - it cannot possibly work like this since on AMD64, gccPeter Wemm2003-05-071-1/+1
| | | | | | | | | | doesn't use stack frames. It uses offsets relative to %rsp, not %rbp. So we cannot just change %rsp like this. Approved by: re (blanket amd64) Notes: svn path=/head/; revision=114815
* Actually use the correct values for AMD64. It is a 64 bit platform,Peter Wemm2003-05-071-0/+4
| | | | | | | configure gdtoa as such. Notes: svn path=/head/; revision=114814
* Properly cleanup the stack before jumping to cerror() if rfork(2) fails.John Baldwin2003-05-071-0/+4
| | | | | | | | Submitted by: Igor Sysoev <is@rambler-co.ru> Approved by: re (scottl) Notes: svn path=/head/; revision=114804
* Replace use of a spinlock with a mutex.Daniel Eischen2003-05-042-12/+9
| | | | Notes: svn path=/head/; revision=114681
* Use the .Dl macro.Tom Rhodes2003-05-011-1/+1
| | | | | | | Discussed with: mdoc(7) officer ru Notes: svn path=/head/; revision=114454
* State the fact that the range is twice the traditional RAND_MAX.Tom Rhodes2003-05-011-1/+16
| | | | | | | | | | Add an EXAMPLES section. PR: 48493 Submitted by: Paul Herman <pherman@frenchfries.net> (original version) Notes: svn path=/head/; revision=114444
* Back out the `hiding' of strlcpy and strlcat. Several peopleJacques Vidrine2003-05-0120-71/+51
| | | | | | | vocally objected to this safety belt. Notes: svn path=/head/; revision=114443
* Convert the i386 alloca(3) to the x86-64 ISA.David E. O'Brien2003-05-011-0/+53
| | | | | | | Alignment hack from: NetBSD Notes: svn path=/head/; revision=114430
* Add __amd64__ to the list of things that use IEEEFPPeter Wemm2003-04-301-1/+1
| | | | Notes: svn path=/head/; revision=114322