Commit graph

80776 commits

Author SHA1 Message Date
Juli Mallett 5cd192f4b2 When working with sigset_t's, and needing to perform masking operations based
on a process's pending signals, use the signal queue flattener,
ksiginfo_to_sigset_t, on the process, and on a local sigset_t, and then work
with that as needed.
2002-10-01 02:49:28 +00:00
Robert Watson d0bd8ced91 Regen. 2002-10-01 02:37:35 +00:00
Robert Watson 4499985ef2 Reserve system call numbers for the following system calls:
__mac_get_pid		Retrieve MAC label of a process by pid

Similar to __mac_get_proc() except that the target process of
the operation is explicitly specified rather than assuming
curthread.

__mac_get_link		Retrieve MAC label of a path with NOFOLLOW
__mac_set_link		Set MAC label of a path with NOFOLLOW
extattr_set_link	Set EAs on a path with NOFOLLOW
extattr_get_link	Retrieve EAs on a path with NOFOLLOW
extattr_delete_link	Delete EAs on a path with NOFOLLOW

These calls are similar to __mac_get_file(), __mac_set_file(),
extattr_set_file(), extattr_get_file(), and extattr_delete_file(),
except that they do not follow symlinks.  The distinction between
these calls is similar to lchown() vs chown().

Implementations to follow.

Obtained from:	TrustedBSD Project
Sponsored by:	DARPA, Network Associates Laboratories
2002-10-01 02:35:59 +00:00
Tim J. Robbins c515abc535 Remove some kind of profiling support that required the 4.2BSD monitor()
function in libc.
2002-10-01 01:30:33 +00:00
Brooks Davis 13d4f45b18 Use if_printf(ifp, "foo") instead of printf("xe%d: foo", ifp->it_unit). 2002-10-01 01:03:02 +00:00
Brooks Davis deffb46b90 Use if_printf(ifp, "blah") instead of printf("vx%d: blah", ifp->if_unit). 2002-10-01 00:59:40 +00:00
Brooks Davis 091f3945cb Use if_printf(ifp, "blah") instead of printf("sr%d: blah", ifp->if_unit). 2002-10-01 00:58:16 +00:00
Brooks Davis 421f55825b Use if_printf(ifp, "blah") instead of printf("sn%d: blah", ifp->if_unit). 2002-10-01 00:56:39 +00:00
Brooks Davis c10b63ba8d Use if_printf() instead of printf() to print "sbni#: blah". 2002-10-01 00:55:22 +00:00
Tim J. Robbins b1a667509b Remove bits and pieces of support for atty, which was made obsolete by
adding history and vi/emacs-style line editing to the shell itself.
Atty was a user-mode terminal emulator (like screen and window) that did
line editing and history.
2002-10-01 00:54:14 +00:00
Brooks Davis af98feb19c Use if_printf(ifp, "blah") instead of printf("fe%d: blah", ifp->if_unit).
A number of functions in this driver still use the unit number in their
printouts because they pass the unit directly as a function argument
instead of passing a softc or struct ifnet pointer.  This should be
resolved at a future date.
2002-10-01 00:52:58 +00:00
Brooks Davis 38d8969122 Use if_printf() instead of printf() to print "ed#: blah". 2002-10-01 00:49:28 +00:00
Brooks Davis 3a6ceb1592 Use if_printf(ifp, "blah") instead of
printf(CS_NAME"%d: blah", ifp->if_unit);
2002-10-01 00:46:41 +00:00
Brooks Davis ed1e614af3 Use if_printf(ifp, "blah") instead of
printf("%s%d: blah", ifp->if_name, ifp->if_unit);
2002-10-01 00:44:31 +00:00
Eric Melville 3a0f9fbc5e Increment version number for the addition of getopt_long(3) to libc. 2002-10-01 00:44:11 +00:00
Brooks Davis a5d0e57adc Use if_printf(ifp, "blah") instead of printf("ar%d: blah", ifp->if_unit). 2002-10-01 00:42:51 +00:00
Juli Mallett 1340544372 Fix typo, should zero the kinfo_proc's siglist, not the real one's - the real
one doesn't have one.

Submitted by:	jake, scottl
Big pointed hat that lands one in the badcommitters box to:	jmallett
2002-10-01 00:28:14 +00:00
Jake Burkholder c7f73b67b5 Use M_NOWAIT instead of M_WAITOK when allocating dmamaps; the allocations
functions may be called from a device strategy routine when sleeping is
bad.

Submitted by:	phk
Reviewed by:	tmm
2002-10-01 00:17:39 +00:00
Juli Mallett a88b260a86 Back out code changes that snuck into the previous forced commit. 2002-10-01 00:16:17 +00:00
Juli Mallett 226e1171e1 (Forced commit, to clarify previous commit of ksiginfo/signal queue code.)
I've added a structure, kernel-private, to represent a pending or in-delivery
signal, called `ksiginfo'.  It is roughly analogous to the basic information
that is exported by the POSIX interface 'siginfo_t', but more basic.  I've
added functions to allocate these structures, and further to wrap all signal
operations using them.

Once the operations are wrapped, I've added a TailQ (see queue(3)) of these
structures to 'struct proc', and all pending signals are in that TailQ.  When
a signal is being delivered, it is dequeued from the list.  Once I finish
the spreading of ksiginfo throughout the tree, the dequeued structure will be
delivered to the process in question, whereas currently and normally, the
signal number is what is used.
2002-10-01 00:07:28 +00:00
Juli Mallett fc256ea463 The list of queued signals is not, can not, and will not be exported to the
userland.  If someone wants to implement a backup p_siglist in the kernel
for compatability and to export one could.  For now, just tell KVM to hand
an empty signal set off to the userland.
2002-09-30 21:40:33 +00:00
Juli Mallett f4430f22b8 Lock access to the signal queue, and related structures, with PROC_LOCK.
Submitted by:	jhb
2002-09-30 21:15:33 +00:00
John Baldwin dc183990ca - Add a new per-process flag PS_XCPU to indicate that at least one thread
has exceeded its CPU time limit.
- In mi_switch(), set PS_XCPU when the CPU time limit is exceeded.
- Perform actual CPU time limit exceeded work in ast() when PS_XCPU is set.

Requested by:	many
2002-09-30 21:13:54 +00:00
John Baldwin f4cd8f9ff4 Change p_cpulimit to be in seconds instead of microseconds. Since
p_runtime now is a bintime, it is no longer an optimization to store
p_cpulimit as microseconds.

Suggested by:	phk
2002-09-30 21:08:38 +00:00
Robert Watson 0626774f08 Move vnode MAC label initialization to after the release of the vnode
interlock in getnewvnode() to avoid possible sleeps while holding
the mutex.  Note that the warning from Witness is a slight false
positive since we know there will be no contention on the interlock
since we haven't made the vnode available for use yet, but the theory
is not a bad one.

Obtained from:	TrustedBSD Project
Sponsored by:	DARPA, Network Associates Laboratories
2002-09-30 20:51:48 +00:00
Robert Watson c031391bd5 Add tunables for the existing sysctl twiddles for pipe and vm
enforcement so they can be disabled prior to kernel start.

Obtained from:	TrustedBSD Project
Sponsored by:	DARPA, Network Associates Laboratories
2002-09-30 20:50:00 +00:00
Juli Mallett 70d4d0c0f5 Convert use of p_siglist and old SIG*() macros to use <sys/ksiginfo.h>
prototyped functions to get a sigset_t, and further to check for any
queued signals, rather than an empty signal set, to go with the move
to signal queues rather than signal sets.
2002-09-30 20:48:29 +00:00
Peter Wemm 425f8660a7 Use as's --defsym switch to compensate for the loss of the M4 substitution
of SIOPRT which broke kgzldr and therefore make release.

Pointed out by:	 murray
2002-09-30 20:37:58 +00:00
Juli Mallett 1226f694e6 First half of implementation of ksiginfo, signal queues, and such. This
gets signals operating based on a TailQ, and is good enough to run X11,
GNOME, and do job control.  There are some intricate parts which could be
more refined to match the sigset_t versions, but those require further
evaluation of directions in which our signal system can expand and contract
to fit our needs.

After this has been in the tree for a while, I will make in kernel API
changes, most notably to trapsignal(9) and sendsig(9), to use ksiginfo
more robustly, such that we can actually pass information with our
(queued) signals to the userland.  That will also result in using a
struct ksiginfo pointer, rather than a signal number, in a lot of
kern_sig.c, to refer to an individual pending signal queue member, but
right now there is no defined behaviour for such.

CODAFS is unfinished in this regard because the logic is unclear in
some places.

Sponsored by:	New Gold Technology
Reviewed by:	bde, tjr, jake [an older version, logic similar]
2002-09-30 20:20:22 +00:00
Justin T. Gibbs 655a5ce411 Remove a left over '&' from the conversion to using our
softc referenced seeprom store.

MFC after:	1 day
2002-09-30 19:55:42 +00:00
Poul-Henning Kamp 50c2233141 Plug memory leaks.
Detected by:	FlexeLint
Approved by:	jhb
2002-09-30 19:19:47 +00:00
Josef Karthauser 854add2319 Gremlins ate my comment!
Submitted by:	Clive Lin <clive@tongi.org>
2002-09-30 19:12:43 +00:00
Dima Dorfman 7537d97865 Note MFCs of lock(1) -v and vidcontrol(1) -S. 2002-09-30 19:04:59 +00:00
Matthew Dillon a84db8f49e Guido found another bug. There is a situation with
timestamped TCP packets where FreeBSD will send DATA+FIN and
A W2K box will ack just the DATA portion.  If this occurs
after FreeBSD has done a (NewReno) fast-retransmit and is
recovering it (dupacks > threshold) it triggers a case in
tcp_newreno_partial_ack() (tcp_newreno() in stable) where
tcp_output() is called with the expectation that the retransmit
timer will be reloaded.  But tcp_output() falls through and
returns without doing anything, causing the persist timer to be
loaded instead.  This causes the connection to hang until W2K gives up.
This occurs because in the case where only the FIN must be acked, the
'len' calculation in tcp_output() will be 0, a lot of checks will be
skipped, and the FIN check will also be skipped because it is designed
to handle FIN retransmits, not forced transmits from tcp_newreno().

The solution is to simply set TF_ACKNOW before calling tcp_output()
to absolute guarentee that it will run the send code and reset the
retransmit timer.  TF_ACKNOW is already used for this purpose in other
cases.

For some unknown reason this patch also seems to greatly reduce
the number of duplicate acks received when Guido runs his tests over
a lossy network.  It is quite possible that there are other
tcp_newreno{_partial_ack()} cases which were not generating the expected
output which this patch also fixes.

X-MFC after:	Will be MFC'd after the freeze is over
2002-09-30 18:55:45 +00:00
John Baldwin 92ceafffd0 - Give legacy an identify routine that always adds 'legacy0' at an order
of 1 so that it is not probed until after acpi0 is probed and attached.
- In legacy_probe(), return ENXIO if acpi0 is around and alive.
- nexus_attach() is now much simpler and just lets its child drivers do
  all the work.
2002-09-30 18:47:11 +00:00
John Baldwin 31a51bf683 Trash the PnPBIOStable pointer later on when we know that the acpi probe
and attach routines have succeeded so that if they fail we can still use
the PnP BIOS to find ISA on-board devices.  The fact that we do this here
is gross but fixing it properly involves a lot more work.
2002-09-30 18:45:20 +00:00
Josef Karthauser fe74650816 In rev 1.51 of usb_port.h I switched over to using the USB_USE_SOFTINTR
code path to fix a bug in the non USB_USE_SOFTINTR path that caused
the usb bus to hang and generally misbehave when devices were unplugged.
In the process though it also reduced the throughput of usb devices because
of a less than optimal implementation under FreeBSD.

This commit fixes the non USB_USE_SOFTINTR code in uhci and ohci
so that it works again, and switches back to using this code path.

The uhci code has been tested, but the ohci code hasn't.  It's
essentially the same anyway and so I don't envisage any difficulties.

Code for uhci submitted by:	Maksim Yevmenkin <myevmenk@exodus.net>
2002-09-30 17:50:18 +00:00
Mike Barcroft 793afc3a5b Don't install mqueue.h, since it only makes things harder for porting
software when you provide prototypes for non-existent functions.
2002-09-30 17:14:26 +00:00
Bruce A. Mah fc45d6c664 Modified release notes: atapicam wording tweaks, dhclient 3.0.1RC9.
Submitted by:	thomas (atapicam)
2002-09-30 17:01:19 +00:00
Yoshihiro Takahashi a92b303976 Call bus_set_resource() to set the ioport resource. 2002-09-30 16:41:47 +00:00
Sebastien Gioria c90aa1d19e Grammars fixs and typos fixs 2002-09-30 16:04:59 +00:00
David E. O'Brien dbe57134ec Turn back on the "SMP: AP CPU #N Launched!" message on normal boots.
Peter's rev 1.189 should fix the lost console on SCSI-based systems due
to this message.
2002-09-30 15:39:57 +00:00
Poul-Henning Kamp c91a63aa2c Add support for DIOCGMEDIASIZE and DIOCGSECTORSIZE.
Remove all traces of disklabel.

Sponsored by:	DARPA & NAI Labs.
2002-09-30 13:53:22 +00:00
Poul-Henning Kamp 150b2bdfb2 If GEOM is in the kernel, take these three out. I have no way of
testing any modifications to them, they shouldn't even bother with
disklabels in the first place and they are just plain obsolete old
hardware which should be axed entirely before 5.0-R IMO.

Sponsored by:	DARPA & NAI Labs.
2002-09-30 13:49:20 +00:00
Poul-Henning Kamp 419f39ce0f Prefix private BIO commands with "FD" so people get a hint that they
are in fact private.

Sponsored by:	DARPA & NAI Labs.
2002-09-30 13:42:06 +00:00
Tim J. Robbins abe2dc6158 Callers of error() don't need to supply a program name prefix in the
error message. Stops ulimit giving error messages like "ulimit: ulimit: xyz".
2002-09-30 13:29:32 +00:00
Tim J. Robbins f7a9b7fe3a Allow a left parenthesis before patterns in case blocks. POSIX requires
us to accept this, but I've never seen a script that uses it.
2002-09-30 13:25:00 +00:00
Jacques Vidrine a5573db3bf This commit was generated by cvs2svn to compensate for changes in r104204,
which included commits to RCS files with non-trunk default branches.
2002-09-30 11:48:23 +00:00
Jacques Vidrine 1b3f4135a5 Fix an annoying bug that causes a spurious error message when changing
passwords, even when the operation actually succeeded.

    % k5passwd
    luser@REA.LM's Password: **************
    New password: **************
    Verifying password - New password: **************
    k5passwd: krb5_change_password: unable to reach any changepw server  in realm REA.LM

[In reality, the password was changed.]

Obtained from:	Heimdal CVS
2002-09-30 11:48:23 +00:00
Ruslan Ermilov b660485bd4 Pass our idea of a manpage's locale from man(1) down to mdoc(7). 2002-09-30 11:00:04 +00:00