sheldonh [Sun, 5 Aug 2001 11:15:23 +0000 (11:15 +0000)]
Clean up previous delta:
* Fix typo (defautls).
* Don't use hard sentence breaks in new text.
* Don't introduce the use of the second person (you).
* Use the standard "IMPLEMENTATION NOTES" section name instead of the
non-standard "TUNING".
scottl [Sun, 5 Aug 2001 07:26:31 +0000 (07:26 +0000)]
Once again throw out the calculation of si_iosize_max and set it to 64K.
Although it can go higher, it is not safe to so do on arrays with many
members. Compromise by adding a tunable, "hw.aac.iosize_max" that can be
set at boottime. Also document in the aac(4) manpage.
imp [Sun, 5 Aug 2001 07:02:42 +0000 (07:02 +0000)]
Now that we are setting a bit in the PCIC_INT_GEN (0x3) register, we
can't blindly write zero into it to disable the card. We must
preserve this bit. This changes pcic_disable to only clear the bits
we know we need to clear on card disable, thus preserving the magic
bit for many TI bridges.
This appears to have fixed the problems that people are reporting
about the system failing to recognize cards being inserted or removed
(or both). Greg: This may fix your problem too :-).
scottl [Sun, 5 Aug 2001 06:20:13 +0000 (06:20 +0000)]
Bugfixes. Close a race and logic bug in the timeout handling, don't call the
interrupt handler from the upper half, etc. This fixes some serious stability
problems that we were seeing on our production server. These patches have
been tested for almost 6 months and are a highly recommended MFC candidate.
Reviewed by: gibbs, merry, msmith
MFC after: 4 days
tmm [Sun, 5 Aug 2001 03:55:02 +0000 (03:55 +0000)]
Add a missing semicolon to unbreak the kernel build with INVARIANTS
(which was unfortunately turned off in the confguration I used for the
last test build).
It's bad enough to capitalize the name of the executable at the
beginning of the sentence, but at the very least it shouldn't be done
in the middle of a sentence!
tmm [Sat, 4 Aug 2001 20:17:05 +0000 (20:17 +0000)]
Add a zdestroy() function to the zone allocator. This is needed for the
unload case of modules that use their own zones.
It has been tested with the nfs module.
tmm [Sat, 4 Aug 2001 18:30:54 +0000 (18:30 +0000)]
Make use of the new features of libdevstat to allow iostat to work on
crash dumps, and make it use sysctl for all data retrievals in the
"live" case (i.e. when not using iostat on a crash dump).
Remove setgid kmem for the iostat executable, it is not needed any
more after these changes.
tmm [Sat, 4 Aug 2001 18:25:48 +0000 (18:25 +0000)]
Add some features to libdevstat, and overhaul the interface a bit:
1.) prefix all functions in the library with devstat_ (compatability
functions are available for all functions that were chaned in an
incompatible way, but are deprecated).
2.) Add a pointer to a kvm_t as the first argument to functions that
used to get their information via sysctl; they behave the same
as before when NULL is passed as this argument, otherwise, the
information is obtained via libkvm using the supplied handle.
3.) Add a new function, devstat_compute_statistics(), that is intended
to replace the old compute_stats() function. It offers more
statistics data, and has a more flexible interface.
libdevstat does now require libkvm; a library depedency is added, so
that libkvm only needs to be explicitely specified for statically linked
programs.
The library major version number is bumped.
Submitted by: Sergey A. Osokin <osa@freebsd.org.ru>, ken (3)
Reviewed by: ken
ume [Sat, 4 Aug 2001 17:10:14 +0000 (17:10 +0000)]
When running aplication joined multicast address,
removing network card, and kill aplication.
imo_membership[].inm_ifp refer interface pointer
after removing interface.
When kill aplication, release socket,and imo_membership.
imo_membership use already not exist interface pointer.
Then, kernel panic.
bde [Fri, 3 Aug 2001 22:28:25 +0000 (22:28 +0000)]
Link to libcipher in the usual way. `bdes' depended on a nonexistent
library. This only worked because of the undocmented feature of make(1)
that targets named foo.a are always up to date.
rwatson [Fri, 3 Aug 2001 18:21:06 +0000 (18:21 +0000)]
Anton kindly pointed out (and fixed) a bug in the Jail handling of the
bind() call on IPv4 sockets:
Currently, if one tries to bind a socket using INADDR_LOOPBACK inside a
jail, it will fail because prison_ip() does not take this possibility
into account. On the other hand, when one tries to connect(), for
example, to localhost, prison_remote_ip() will silently convert
INADDR_LOOPBACK to the jail's IP address. Therefore, it is desirable to
make bind() to do this implicit conversion as well.
Apart from this, the patch also replaces 0x7f000001 in
prison_remote_ip() to a more correct INADDR_LOOPBACK.
This is a 4.4-RELEASE "during the freeze, thanks" MFC candidate.
Submitted by: Anton Berezin <tobez@FreeBSD.org>
Discussed with at some point: phk
MFC after: 3 days
rwatson [Fri, 3 Aug 2001 17:20:34 +0000 (17:20 +0000)]
Collapse a Pmem case in with the other debugging files case for procfs,
as there are now "unusual" protection properties to Pmem that differ
from the other files. While I'm at it, introduce proc locking for
the other files, which was previously present only in the Pmem case.
rwatson [Fri, 3 Aug 2001 17:13:23 +0000 (17:13 +0000)]
Prior to support for almost all ps activity via sysctl, ps used procfs,
and so special-casing was introduced to provide extra procfs privilege
to the kmem group. With the advent of non-setgid kmem ps, this code
is no longer required, and in fact, can is potentially harmful as it
allocates privilege to a gid that is increasingly less meaningful.
Knowledge of specific gid's in kernel is also generally bad precedent,
as the kernel security policy doesn't distinguish gid's specifically,
only uid 0.
This commit removes reference to kmem in procfs, both in terms of
access control decisions, and the applying of gid kmem to the
/proc/*/mem file, simplifying the associated code considerably.
Processes are still permitted to access the mem file based on
the debugging policy, so ps -e still works fine for normal
processes and use.
fenner [Fri, 3 Aug 2001 16:51:53 +0000 (16:51 +0000)]
Don't terminate the uiomove() loop on a zero-length mbuf. It's not
particularly nice that IPSEC inserts a zero-length mbuf into the
chain, and that bug should be fixed too, but interfaces should be
robust to bad input.
Print the interface name when TUNDEBUG()ing about dropping an mbuf.
markm [Fri, 3 Aug 2001 16:03:26 +0000 (16:03 +0000)]
Revamp and diff-reduce the various secure telnets. Make sure that
Kerberos5 has _a_ telnet (which is not currently K5 enabled).
Incorporate BDE's static linking fixes.
msmith [Fri, 3 Aug 2001 09:52:53 +0000 (09:52 +0000)]
Reverse the logic here again with regards to "trusted" ACPI timer
implementations. More of them seem to be broken, so only "trust"
timers we know work.
bmilekic [Fri, 3 Aug 2001 05:05:32 +0000 (05:05 +0000)]
Rename mb_init() mbuf subsystem initialization routine to mbuf_init(), in
order to avoid namespace collision with subr_mchain.c's mb_init(). This
wasn't "fatal" as the mbuf initialization routine mb_init() was local to
subr_mbuf.c which in turn didn't pull in subr_mchain.c's mb_init()
declaration, but it should deffinately be changed now before it creates
headache.
jake [Fri, 3 Aug 2001 03:31:45 +0000 (03:31 +0000)]
Remove some code that appears to have endian problems with INVARIANTS.
This is #if BIG_ENDIAN, but is only necessary if malloc types are shorts,
not struct malloc_type * like they are now.
jake [Fri, 3 Aug 2001 01:21:24 +0000 (01:21 +0000)]
Fix a bug translating virtual translation table entry addresses to physical
addresses. It helps to use the physical address that the virtual address
actually maps to (doh!). Comment out some code that crashes.
jake [Fri, 3 Aug 2001 01:09:10 +0000 (01:09 +0000)]
Add a Makefile, ldscript, and config magic for sparc64. This is tailored
to build with a cross compiler alongside the standard compiler; it would be
more desirable to build in a chroot.
peter [Fri, 3 Aug 2001 00:07:54 +0000 (00:07 +0000)]
Further Makefile.* sync (from Makefile.ia64). The lint target has been
commented out in the entire life of the 2.x+ branch and given the amount
of gcc-specific code we have and the warning checks that gcc does I'm not
sure that it is going to get us much for some time.
greid [Thu, 2 Aug 2001 22:13:10 +0000 (22:13 +0000)]
Set up the via_chinfo structures properly so we write to the correct
registers later on; this fixes the VIA82C686 sound problems recently
reported by a number of people.
iedowse [Thu, 2 Aug 2001 21:46:21 +0000 (21:46 +0000)]
Fix a few bugs, some of which I introduced in recent commits:
- clean_mtab():
Actually use the strdup'd version of the host that we go to the
trouble of creating.
- do_umntall/do_umount:
Don't return success if clnt_create() fails.
Don't access a client pointer after it has been destroyed.
Remember to destroy the authentication information we created.
iedowse [Thu, 2 Aug 2001 21:31:21 +0000 (21:31 +0000)]
In getclnthandle(), if the address is found in the cache we need
to strdup() the address string before returning it via *targaddr
because the caller will free the string.
Change the comment at the top of getclnthandle() to clarify that
the caller is responsible for freeing *targaddr.
sobomax [Thu, 2 Aug 2001 15:47:03 +0000 (15:47 +0000)]
Fix a cryptoless world by disconnecting libmp from the build when there is no
crypto bits installed and/or NOCRYPTO/NO_OPENSSL is defined. This unfortunately
meants that usr.bin/chkey, usr.bin/newkey and usr.sbin/keyserv have also to
be disconnected.
IMO it is merely a workaround, the proper solution is to move libmp to
src/crypto where it belongs and use libgmp for the cryptoless builds instead.
sobomax [Thu, 2 Aug 2001 12:38:29 +0000 (12:38 +0000)]
Usability tweak:
Use '' quotes instead of `' to delimit names of files and packages in
warning and error messages, because it is easier to cut-n-paste name in
question that way (single click) without confusing the shell. And yes,
I know that it is less eye-candy...
sobomax [Thu, 2 Aug 2001 12:19:32 +0000 (12:19 +0000)]
When there is a file that can't be deleted due to checksum mismatch print name
of that file to stdout to simplify debugging. IMO it was a mistake to print
this warning only when `verbose' mode is on.
When talking about new versions, use the word "updated" instead of
"upgraded" for consistency. Prior to this commit, 9 of the entires
used the latter, and 51 used the former.
Note MFC or Binutils 2.11.2 (what we have is close enough to that
version that there's no need to talk about the snapshot business; all
it would do is serve to confuse).
sobomax [Thu, 2 Aug 2001 10:19:13 +0000 (10:19 +0000)]
- Deny detaching requests until device is still open, otherwise it is possible
to hang or panic kernel by detaching disk from which fs is mounted;
- replace "md" with MD_NAME in yet another place.
sheldonh [Thu, 2 Aug 2001 09:22:18 +0000 (09:22 +0000)]
When building a debugging kernel with modules, build modules with
debugging support as well. Debugging module support is handled
identically to kernel debugging support, right down to poor
choice of make variable names.
alfred [Thu, 2 Aug 2001 07:54:58 +0000 (07:54 +0000)]
Fixups for the initial allocation by dillon:
1) allocate fewer buckets
2) when failing to allocate swap zone, keep reducing the zone by
a third rather than a half in order to reduce the chance of
allocating way too little.
imp [Thu, 2 Aug 2001 07:06:32 +0000 (07:06 +0000)]
Only try to allocated properly aligned I/O segments. This should stop
some of the config problems that we've been seeing (where wi0 tries to
allocate 0x138-0x198, for example).
Use err(1,"foo") rather than perror + exit while I'm here.