Commit Graph

7986 Commits

Author SHA1 Message Date
markm
a49e54ca91 ANSIfy, WARNSify, CONSTify. Bit of style(9)-ify. 2003-10-18 10:04:16 +00:00
markm
5a46529dd9 Remove a GCC specifig CFLAG. We should be using WARNS=? for this.
WARNS=? is not added here at this point, because I've not tested
it on enough platforms, and I don't want to break builds.
2003-10-18 09:58:39 +00:00
kensmith
9d5a2dcec9 - fix to UID test description, non-zero -> zero
PR:		docs/57799
Reviewed by:	des
Approved by:	blackend (mentor)
2003-10-17 17:03:38 +00:00
peter
4fa19ad320 Update context code for my last ABI breakage of mcontext. I'm worried
about the fpu code here.  It should be using fxsave/fxrstor instead of
saving/restoring the control word.  The SSE registers are used a lot in
gcc generated code on amd64.  I'm not sure how this all fits together
though.
2003-10-17 16:30:09 +00:00
peter
9063a633f0 Explicitly specify an alignment for abitag. Without it, gcc specifies a
section alignnment of 16 bytes for amd64 and this breaks file(1).
Before:
./cp: ELF 64-bit LSB executable, AMD x86-64, version 1 (FreeBSD), for \
  FreeBSD 127.7.9, statically linked, stripped
after:    ^^^^^^^
./ls: ELF 64-bit LSB executable, AMD x86-64, version 1 (FreeBSD), for \
  FreeBSD 5.0.1, dynamically linked (uses shared libs), stripped

The reason for this is that the NOTE sections are not contiguous
internally.  If the note section has an alignment of 16, then anything
that looks for the data is supposed to round up the payload start to
the next multiple of the alignment.  But FreeBSD/amd64 broke because the
structure is declared as a single structure, not a (header,payload) group,
where the payload had an explicit alignment roundup.

The alternative is to change things like file(1) to ignore the ELF payload
alignment rules for the PT_NOTE section only for FreeBSD.
2003-10-17 15:43:13 +00:00
alc
1b38ceb3c1 Add rfork_thread(3). 2003-10-13 20:32:33 +00:00
ume
f4517f9a06 - support AES counter mode for ESP.
- use size_t as return type of schedlen(), as there's no error
  check needed.
- clear key schedule buffer before freeing.

Obtained from:	KAME
2003-10-13 14:57:41 +00:00
bde
32020aab54 Include <nlist.h> for nlist-related declarations instead of depending on
namespace pollution in <kvm.h>.
2003-10-13 05:30:20 +00:00
ume
7dd5a14621 - support AES XCBC MAC for AH
- correct SADB_X_AALG_RIPEMD160HMAC to 8

Obtained from:	KAME
2003-10-13 04:54:51 +00:00
bde
8dcb924fbb Fixed some style bugs in the removal of __P(()). Blind removal of
spaces before __P(()) outdented continuation lines to column 0.
2003-10-13 04:44:55 +00:00
emax
b655606c42 Update Bluetooth code.
Reviewed by: M. Warner Losh <imp@bsdimp.com>; John Hay <jhay@freebsd.org>
Approved by: M. Warner Losh <imp@bsdimp.com> (mentor)
2003-10-12 22:04:24 +00:00
deischen
53599db414 Don't forget to initialize the fake tcb when the kcb is allocated. 2003-10-12 16:50:45 +00:00
ume
c9ac7566f1 - RIPEMD160 support
- pass size arg to ah->result (avoid assuming result buffer size)

Obtained from:	KAME
2003-10-12 09:41:42 +00:00
dds
4065e819ad Changed EINVAL constant reference from UIO_MAXIOV to IOV_MAX.
The former is a kernel-only visible constant, the latter the
POSIX-specified userland constant defined by including limits.h.
2003-10-11 20:47:44 +00:00
hmp
a49fc7ba02 Assorted mdoc(7) fixes:
- fix hard sentence breaks
	- sprinkle a few .Vt's where neccessary
	- remove incorrect use of `\-'
	- proper quoting using .Dq, instead of manual ``...''

Approved by:	des@ (mentor)
Reviewed by:	ru@
2003-10-09 23:06:06 +00:00
deischen
4d56950c49 Reverse the order of the first two arguments to _sparc64_enter_uts().
The first argument is the UTS function, the second argument is the
first argument to the UTS function.  Who's on first.
2003-10-09 20:52:17 +00:00
deischen
3746a5ee24 Convert a couple of hardcoded values to constants. Make thr_getcontext()
return 0 when called the first time, and return 1 when resumed by
thr_setcontext().
2003-10-09 14:48:09 +00:00
hmp
af5d93a608 Remove unneccessary include of sys/types.h in the SYNOPSIS
header.

Sys/param.h includes sys/types.h internally unless LOCORE is
defined.

Approved by:	des (mentor)
2003-10-09 09:45:20 +00:00
deischen
5c8f912f90 Add preliminary sparc64 support to libpthread. This does not
yet work, but hopefully someone familiar with the sparc64
port can pick up the reins.

Submitted by:	jake
With mods by:	deischen
2003-10-09 02:32:28 +00:00
davidxu
270b1cdd32 Fix some comments for last commit. 2003-10-08 00:30:38 +00:00
davidxu
ee8841d457 Complete cancellation support for M:N threads, check cancelling flag when
thread state is changed from RUNNING to WAIT state and do some cancellation
operations for every cancellable state.

Reviewed by: deischen
2003-10-08 00:20:50 +00:00
davidxu
9134d50921 Use thread lock instead of scheduler lock to eliminate lock contention
for all wrapped syscalls under SMP.

Reviewed by: deischen
2003-10-08 00:17:13 +00:00
phk
5f5cfc9be8 Add XXX'ed temporary bounce-buffering. 2003-10-07 07:12:22 +00:00
bms
7b987f7a47 Correct .Xr's in kiconv.3.
Submitted by:	osa
2003-10-05 13:39:28 +00:00
deischen
3970d19678 Fix a logic error; use beq to check for a register being NULL, not bne. 2003-10-02 20:51:30 +00:00
ru
7b267b13bd Correct the library name. 2003-10-02 19:19:07 +00:00
kensmith
e0676951c4 - Remove error code that can't be returned (and original description
was not proper English)

PR:             docs/57434
Approved:       blackend (mentor)
Reviewed by:    deischen
2003-10-02 18:30:15 +00:00
davidxu
ed0abb4e08 Only generate code for _LCK_ASSERT if _LCK_DEBUG is defined. 2003-10-02 03:24:26 +00:00
tjr
03a7afc8c9 Cite the published version of "Engineering a Sort Function" instead of
an email address.  Spell McIlroy correctly.
2003-09-30 07:05:46 +00:00
deischen
538f423c87 If __sys_write() returns 0, allow that to exit the loop in libc_r's
wrapped version of write().

Submitted by:	dan@langille.org
2003-09-29 13:41:26 +00:00
davidxu
d5d471e11b When concurrency level is reduced and a kse is exiting, make sure no other
threads are still referencing the kse by migrating them to initial kse.

Reviewed by: deischen
2003-09-29 06:25:04 +00:00
davidxu
7d57e54c87 Remove unused variable. 2003-09-28 13:47:29 +00:00
marcel
e8648b41a1 Relink libc_r.a, libc_r.so and libc_r_p.so from libthr to libkse.
On ia64, where there's no libc_r at all, libkse is now the default
thread library by virtue of these links.

The reasons for this change are:
1. libkse is slated to become the default thread library anyway,
2. active development and maintenance is only present for libkse,
3. GNOME and KDE, both in the process of being supported on ia64,
   work better with KSE; even on ia64.
2003-09-27 23:27:19 +00:00
phk
fe0e97f849 More style fixes to improve diffability with OpenBSD.
Pull 'A' evilness for realloc(3) from OpenBSD.
2003-09-27 18:58:26 +00:00
rwatson
6f94b8e6ae Disable #define DEBUG in libdisk by default: since libdisk is primarily
there to support sysinstall, and enabling DEBUG creates spurious
console output that can't be read anyway...  This slightly cleans up
the visual impression of the system install by not spamming the console
during the labeling of the disks.
2003-09-27 17:44:41 +00:00
phk
ebbf74a5d9 Style changes to improve diffability against OpenBSD version. 2003-09-27 17:29:03 +00:00
tjr
afe7565c55 Document KERN_PROC_PROC, update KERN_PROC_ALL description. 2003-09-27 08:22:23 +00:00
tjr
4d68b1381f Use the 3-component version of the KERN_PROC_PROC sysctl. 2003-09-27 08:14:37 +00:00
fjoe
a672193cd8 - Support for multibyte charsets in LIBICONV.
- CD9660_ICONV, NTFS_ICONV and MSDOSFS_ICONV kernel options
(with corresponding modules).
- kiconv(3) for loadable charset conversion tables support.

Submitted by:	Ryuichiro Imura <imura@ryu16.org>
2003-09-26 20:26:25 +00:00
davidxu
6e4004647c Add __volatile keyword. 2003-09-26 11:59:04 +00:00
marcel
ebc8c00a97 s/ia64/alpha/g 2003-09-26 06:53:54 +00:00
peter
f018c61d56 Fix fabs(). This commit brought to you by the letter 'l'.
(fstp stores a mem32 value, fstpl stores a mem64 value)

This fixes ghostscript for 'make release' on amd64.  Ghostscript for some
reason thinks it is a good idea to use -fno-builtin, which means it is
vulnerable to bugs in libc that are normally hidden by the builtin gcc
functions.  Oops.
2003-09-26 01:49:48 +00:00
davidxu
97f89f5eb1 pthread API should return error code in return value not in errno.
Reviewed by: deischen
2003-09-25 13:53:49 +00:00
davidxu
680ab8905d If syscall failed, restore old sigaction and return error to thread. 2003-09-25 06:23:40 +00:00
davidxu
325b5ebdea As comments in _mutex_lock_backout state, only current thread
can clear the pointer to mutex, not the thread doing mutex
handoff. Because _mutex_lock_backout does not hold scheduler
lock while testing THR_FLAGS_IN_SYNCQ and then reading mutex
pointer, it is possible mutex owner begin to unlock and
handoff the mutex to the current thread, and mutex pointer
will be cleared to NULL before current thread reading it, so
current thread will end up with deferencing a NULL pointer,
Fix the race by making mutex waiters to clear their mutex pointers.
While I am here, also save inherited priority in mutex for
PTHREAD_PRIO_INERIT mutex in mutex_trylock_common just like what
we did in mutex_lock_common.
2003-09-24 12:52:57 +00:00
marcus
1598bfd0f5 Grrr...add the Skinny alias code forgotten in the last commit. 2003-09-23 07:42:33 +00:00
marcus
429e15dea7 Add Cisco Skinny Station protocol support to libalias, natd, and ppp.
Skinny is the protocol used by Cisco IP phones to talk to Cisco Call
Managers.  With this code, one can use a Cisco IP phone behind a FreeBSD
NAT gateway.

Currently, having the Call Manager behind the NAT gateway is not supported.
More information on enabling Skinny support in libalias, natd, and ppp
can be found in those applications' manpages.

PR:		55843
Reviewed by:	ru
Approved by:	ru
MFC after:	30 days
2003-09-23 07:41:55 +00:00
davidxu
4fb7f47253 Free thread name memory if there is. 2003-09-23 04:02:23 +00:00
davidxu
dfbbf3ec80 Save and restore timeout field for signal frame just like what we did
for interrupted field.
Also in _thr_sig_handler, retrieve current signal mask from kernel not
from ucp, the later is pre-unioned mask, not current signal mask.
2003-09-22 14:40:36 +00:00
davidxu
a70d9fb2c2 Fix FPU state restoring bug by jumping to right position. 2003-09-22 14:34:02 +00:00