keramida [Wed, 18 May 2005 17:08:15 +0000 (17:08 +0000)]
The correct copyright notice for manpages that copy material from Open
Group's documentation is `/usr/share/examples/mdoc/POSIX-copyright',
not the one I copied from `/usr/share/examples/etc/bsd-copyright'.
Suggested by: simon
2nd pointy hat of the day: yours truly
which should be ok, since Daniel Eischen had mailed me about Open
Group manpages and the fact that they have granted permission to
FreeBSD to use their material. Any differences from the OG text are
my changes to the original manpage text submitted by Alex Vasylenko:
- In an effort to clean up the part that describes hooks and their
calling order, I used a list instead of a single paragraph for all the three
types of fork() hooks.
- After a short discussion with Dima Dorfman a long long time ago in a
far away galaxy, I changed the RETURN VALUES section to look more
like the rest of the pthread_xxx.3 manpages.
PR: docs/68201
Submitted by: Alex Vasylenko <lxv@omut.org>
harti [Wed, 18 May 2005 14:50:35 +0000 (14:50 +0000)]
Get rid of global variables for argument vectors produced by brk_string()
introduce a struct that holds all the information about an argument
vector and pass that around.
Author: Max Okumoto <okumoto@ucsd.edu>
Obtained from: DragonFlyBSD
keramida [Wed, 18 May 2005 13:48:33 +0000 (13:48 +0000)]
Properly trim the header line too, to fix wrap-around problems that
have been noticed by running top(1) in terminals that are too narrow
(or on systems with usernames that were too long, pushing everything
too far to the right).
Note that this does *not* solve the wrap-around problem of the system
statistics, which is an entirely different matter :-/
Tested on: i386, sparc64 (panther), amd64 (sledge)
Approved by: davidxu (in principle)
keramida [Wed, 18 May 2005 13:42:51 +0000 (13:42 +0000)]
(1) Revert unnecessary indentation changes I committed as part of the
last version and (2) remove a disabled debugging fprintf() that I
accidentally committed here.
keramida [Wed, 18 May 2005 13:30:08 +0000 (13:30 +0000)]
Merge the CPU and WCPU columns in a single %6.2f column, add a new 'C'
command that toggles between the two and update the ORDER_PCTCPU()
macro to sort correctly by the visible "cpu" value.
This saves 6 more columns in 80-column terminals, making things a lot
better for the COMMAND column.
Tested on: i386, sparc64 (panther), amd64 (sledge)
Approved by: davidxu (in principle)
harti [Wed, 18 May 2005 06:50:39 +0000 (06:50 +0000)]
Get rid of the ReturnStatus obscuration that was anyway used only
in two places. While here don't bother returning anything from
Lst_Replace - nobody ever checks the return code.
kan [Wed, 18 May 2005 05:24:08 +0000 (05:24 +0000)]
Unbreak r1.11 by delhij. Blind change from unsigned to signed char
pointer causes problems with sign extension and leads to compress(1)
dumping core on any non-trivial incoming data.
keramida [Tue, 17 May 2005 17:52:27 +0000 (17:52 +0000)]
Add manpages for devfs.conf and devfs.rules. These have been
initially written by Roland, but hacked for a while by me. Any
good parts are the results of Roland's hard work. Any typos or
style mistakes are mine.
Submitted by: Roland Smith <rsmith@xs4all.nl>
PR: docs/63808, docs/75433, docs/80458, docs/80459
MFC after: 2 weeks
le [Tue, 17 May 2005 16:38:30 +0000 (16:38 +0000)]
When a drive dies, don't call g_wither_geom() directly, but instead
post an event to the geom event queue that will take care of it,
letting outstanding bios finish, and closing the consumers.
ru [Tue, 17 May 2005 14:54:33 +0000 (14:54 +0000)]
Add temporary patches to make one-true-awk respect locale's collating order
in [a-z] bracket expressions, until a more complete fix (like handing BREs)
is ready.
glebius [Tue, 17 May 2005 12:18:13 +0000 (12:18 +0000)]
- Unwind NG_SEND_MSG_PATH() macro and merge it with already unwinded
version under TRACE_MESSAGES.
- Pass NG_WAITOK flag to ng_package_data() in unwinded macro.
des [Tue, 17 May 2005 11:14:11 +0000 (11:14 +0000)]
Add a zless script which invokes less using the lesspipe script. This is
similar to the zmore script that comes with gzip (and in fact, in most
Linux distros, zless is a symlink to that very same zmore script) but has
the advantage that you get the correct file name on the less status line,
and can use :n and :p to navigate back and forth between multiple files.
mikeh [Tue, 17 May 2005 03:11:29 +0000 (03:11 +0000)]
Import latest NetBSD version...changes:
* Whitespace and gcc 4.x fixes.
* Fix deallocation bug in fetch.c.
* Implement timeouts for accept(2) and connect(2),
which accept timeout values with '-q quittime'.
(intended to help with active mode through firewalls)
* Fix bin/77158 by Ryoji Kanai <rkanai@eeye.com>.
glebius [Mon, 16 May 2005 18:50:26 +0000 (18:50 +0000)]
- Fix build with TRACE_MESSAGES on.
- Reformat code under TRACE_MESSAGES to make it more readable.
- Move linker hackery out of #ifdef.
- Break long lines in linker hackery block.
obrien [Mon, 16 May 2005 18:17:38 +0000 (18:17 +0000)]
Hardcode username to 8 characters. This makes top(1) output sane when
there are users on the system (even if not running a single process)
with a login > 8 chars.
I'm not all that happy limiting the username width like this, but it
restores sanity to top(1) output.
glebius [Mon, 16 May 2005 17:07:03 +0000 (17:07 +0000)]
- Extend interface of ng_getqblk(), so that malloc wait flags are
specified by caller.
- Change ng_send_item() interface - use 'flags' argument instead of
boolean 'queue'.
- Extend ng_send_fn(), ng_package_data() and ng_package_msg()
interface - add possibility to pass flags. Rename ng_send_fn() to
ng_send_fn1(). Create macro for ng_send_fn().
- Update all macros, that use ng_package_data() and ng_package_msg().
wpaul [Mon, 16 May 2005 15:29:21 +0000 (15:29 +0000)]
Correct some problems with workitem usage. NdisScheduleWorkItem() does
not use exactly the same workitem sturcture as ExQueueWorkItem() like
I originally thought it did.
sos [Mon, 16 May 2005 13:07:27 +0000 (13:07 +0000)]
Change the way ioctls are issue to ATA.
The most prominent part is that its now possible to issue ata_requests
directly to say acd0, instead of going through the cumbersome /dev/ata
device.
imp [Mon, 16 May 2005 05:37:32 +0000 (05:37 +0000)]
cleanup a danging reference to cleaning up /etc/fstab. Since we don't
support 4->6 upgrades, this is moot. Most 4.x installations even,
have things compatible with 5 at thsi point, but some don't, so I'll
leave it in the branch...
gad [Mon, 16 May 2005 04:32:41 +0000 (04:32 +0000)]
A second attempt to adjust option-parsing on a shell command, for the
benefit of scripts start out as: #!/bin/sh -- # -*- perl -*-
With this fix in place, we can commit a change to kern/imgact_shell.c
so FreeBSD will process the `#!' line in shell-scripts in a more
standard fashion.
ume [Sun, 15 May 2005 20:15:15 +0000 (20:15 +0000)]
- The ai_addrlen of a struct addrinfo used to be a size_t, per
RFC 2553. In XNS5.2, and subsequently in POSIX-2001 and RFC
3493, it was changed to a socklen_t. And, the n_net of a
struct netent used to be an unsigned long integer. In XNS5,
and subsequently in POSIX-2001, it was changed to an uint32_t.
To accomodate for this while preserving ABI compatibility with
the old interface, we need to prepend or append 32 bits of
padding, depending on the (LP64) architecture's endianness.
- Correct 1st argument of getnetbyaddr() to uint32_t on 32
bit arch. Stay as is on 64 bit arch for ABI backward
compatibility for now.
marcel [Sun, 15 May 2005 06:26:59 +0000 (06:26 +0000)]
o Add option -n. The -n option takes a count and breaks the line
after that many values have been printed. The line length is not
considered anymore.
o Add option -x. The -x option will cause the byte values to be
printed in hexadecimal instead of decimal.
o Bump WARNS to 6.
o Update the manpage accordingly.
wpaul [Sun, 15 May 2005 04:27:59 +0000 (04:27 +0000)]
Add support for NdisMEthIndicateReceive() and MiniportTransferData().
The Ralink RT2500 driver uses this API instead of NdisMIndicateReceivePacket().
Drivers use NdisMEthIndicateReceive() when they know they support
802.3 media and expect to hand their packets only protocols that want
to deal with that particular media type. With this API, the driver does
not manage its own NDIS_PACKET/NDIS_BUFFER structures. Instead, it
lets bound protocols have a peek at the data, and then they supply
an NDIS_PACKET/NDIS_BUFFER combo to the miniport driver, into which
it copies the packet data.
Drivers use NdisMIndicateReceivePacket() to allow their packets to
be read by any protocol, not just those bound to 802.3 media devices.
To make this work, we need an internal pool of NDIS_PACKETS for
receives. Currently, we check to see if the driver exports a
MiniportTransferData() method in its characteristics structure,
and only allocate the pool for drivers that have this method.
This should allow the RT2500 driver to work correctly, though I
still have to fix ndiscvt(8) to parse its .inf file properly.
Also, change kern_ndis.c:ndis_halt_nic() to reap timers before
acquiring NDIS_LOCK(), since the reaping process might entail sleeping
briefly (and we can't sleep with a lock held).
darrenr [Sun, 15 May 2005 03:34:17 +0000 (03:34 +0000)]
Enable IPFilter to correctly determine if BPF has been optioned into the
kernel it is being compiled against and subsequently enable using BPF for
packet matching in ipf rules.
glebius [Sun, 15 May 2005 01:44:26 +0000 (01:44 +0000)]
- When carp interface is destroyed, and it affects global preemption
suppresion counter, decrease the latter. [1]
- Add sysctl to monitor preemption suppression.
dd [Sat, 14 May 2005 23:23:10 +0000 (23:23 +0000)]
Add an interface to the lchflags(2) syscall. The new -h option is
analogous to chmod(1)'s -h. It allows setting flags on symbolic links,
which *do* exist in 5.x+ despite a claim to the contrary in the
chflags(1) man page.
Fix the matchlen() function so that it handles the IPv4 (AF_INET)
case correctly. Until now it has been treating IPv4 addresses
as if they were IPv6 which could lead to corruption errors.
delphij [Sat, 14 May 2005 14:03:21 +0000 (14:03 +0000)]
Revert to old ttyname_r behavior that when _ioctl() returns 0 (SUCCEEDED),
return the buffer immediately. This will permit ssh and/or PAM logins
broken by previous commit.
The (potential) underlying problem is still under investigation.