]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
20 years agoThis commit was generated by cvs2svn to compensate for changes in r123109,
Brooks Davis [Tue, 2 Dec 2003 18:33:36 +0000 (18:33 +0000)]
This commit was generated by cvs2svn to compensate for changes in r123109,
which included commits to RCS files with non-trunk default branches.

20 years agoThis is a direct commit to the vendor branch with code from the vendor.
Brooks Davis [Tue, 2 Dec 2003 18:33:36 +0000 (18:33 +0000)]
This is a direct commit to the vendor branch with code from the vendor.

Replace the if_name and if_unit members of struct ifnet with new members
if_xname, if_dname, and if_dunit. if_xname is the name of the interface
and if_dname/unit are the driver name and instance.

This change paves the way for interface renaming and enhanced pseudo
device creation and configuration symantics.

Submitted by: darrenr
Approved by: re (scottl)

20 years agoUse parens more reasionably so we match the vendor code. This is part
Brooks Davis [Tue, 2 Dec 2003 18:28:00 +0000 (18:28 +0000)]
Use parens more reasionably so we match the vendor code.  This is part
of the if_xname change.

Submitted by: darrenr
Approved by: re (scottl)

20 years agoUse dynamic instead of static LDT allocation.
Mike Makonnen [Tue, 2 Dec 2003 16:00:26 +0000 (16:00 +0000)]
Use dynamic instead of static LDT allocation.

Approved by: re (scottl)

20 years agoFixed panics in apic interrupt handlers if kernel profiling is turned
Bruce Evans [Tue, 2 Dec 2003 15:02:12 +0000 (15:02 +0000)]
Fixed panics in apic interrupt handlers if kernel profiling is turned
on.  MCOUNT and FAKE_MCOUNT() may clobber all the call-used registers,
and one FAKE_MCOUNT() was placed so that an active %eax was clobbered.
The fix is to move this FAKE_MCOUNT() earlier where it should have
been anyway.

Fixed 3 layers of bitrot in the comment about why this FAKE_MCOUNT()
was where it was by removing the comment.  (mcount() should be called
as early as possible after entering a new level, but an implementation
detail got in the way until 3 layers of changes ago.)

Kernel profiling still gives wrong results because the new interrupt
code rearranged object files too much.  mcount() depends on trap,
syscall and interrupt handlers being between certain magic labels with
interrupt handlers last, and on nothing else being there.  Splitting
up exception.o moved the magic labels to effectively random places
relative to what they are supposed to delimit.  This mainly broke the
call graph; the flat profile is still usable.

20 years agoFixed some minor indentation bugs.
Bruce Evans [Tue, 2 Dec 2003 12:47:08 +0000 (12:47 +0000)]
Fixed some minor indentation bugs.

Approved by: re (scottl)

20 years agoFixed breakage of the pci case of the cy driver by the new interrupt
Bruce Evans [Tue, 2 Dec 2003 12:36:00 +0000 (12:36 +0000)]
Fixed breakage of the pci case of the cy driver by the new interrupt
code.  Both the driver and the new code were wrong.  Driver interrupt
handlers are supposed to take "void *vsc" arg, but some including all
COMPAT_ISA drivers and the pci part of the cy driver want an "int unit"
arg.  They got this using bogus casts of function pointers which should
have kept working despite their bogusness.  However, the new interrupt
code doesn't honor requests to pass an arg of ((void *)0), so things
are very broken if the arg is actually a representation of unit 0.

The fix is to use a normal "void *vsc" arg for the pci case and a
wrapper for the COMPAT_ISA case (of the cy driver).  This cleans up
new-busification of the pci case but takes the COMPAT_ISA case a little
further from new-bus.  The corresponding bug for the COMPAT_ISA case
has already been fixed similarly using a wrapper in compat_isa.c and
we need another wrapper just to undo that.

Fixed some directly related style bugs (mainly by removing compatibility
cruft).

cy.c:
Fixed an indirectly related old bug in cyattach_common().  A wrong status
was returned in the unlikely event that malloc() failed.

Approved by: re (scottl)

20 years agoAfter extensive QA cycles at 3ware, bring the driver in-line with all the
Paul Saab [Tue, 2 Dec 2003 07:57:20 +0000 (07:57 +0000)]
After extensive QA cycles at 3ware, bring the driver in-line with all the
issues which they found and asked to be changed so 3ware can offcially
support the driver.

Summary of the most significant changes:

- TWE_OVERRIDE is no longer supported
- If twe_getparam failed, bogus data would be returned to the caller
- Cache the device unit in the twe_drive structure to aid debugging
- Add the 3ware driver version.
- Proper return error codes for many functions.
- Track the minimum queue length statistics
- 4.x compat: use the cached unit number from the twe_drive structure
  instead of the the cached si_drv2.  3ware found that after many loads
  and unloads that si_drv2 became corrupted.  This did not happen in
  -current.

Submitted by: Vinod Kashyap (with modifications by me)
Approved by: re (rwatson)

20 years agoTrim wi(4) devices from the hardware notes. Also add a listing of the
Bruce A. Mah [Tue, 2 Dec 2003 07:13:03 +0000 (07:13 +0000)]
Trim wi(4) devices from the hardware notes.  Also add a listing of the
various chipsets supported by this driver as there are only a few and
this seems to be useful information.

Approved by: re (implicitly)

20 years agoAdd a few wi-supported cards to get this manpage caught up with
Bruce A. Mah [Tue, 2 Dec 2003 07:07:45 +0000 (07:07 +0000)]
Add a few wi-supported cards to get this manpage caught up with
the hardware notes.

Reviewed by: imp
Approved by: re (implicitly)

20 years agoIFP4: Update the Early Adopters Guide to bring it up to the state
Bruce A. Mah [Tue, 2 Dec 2003 05:54:35 +0000 (05:54 +0000)]
IFP4:  Update the Early Adopters Guide to bring it up to the state
of the world roughly as of the upcoming 5.2 release.

Approved by: re (implicitly)

20 years agoFix Lucent cards.
Warner Losh [Tue, 2 Dec 2003 04:59:59 +0000 (04:59 +0000)]
Fix Lucent cards.
o Back out workaround for not resetting lucent cards more than once.  With
  these fixes, it appaers they are no longer necessary.
o Set wi_gone when the card goes awol: typically when we get 0xffff back from
  the card.  Also, don't interact with a card that's gone, so we fail in
  seconds rather than minutes.  Also reduce amount of time we wait to .5s
  in wi_cmd.
o clear wi_gone on ifconfig down to give some cards a chance after they wedge
  (this appears to unwedge one of my prism cards with old firmware).  ifconfig
  up will fail quickly enough if the card really is out to lunch.
o Add delay in wi_init of 100ms.
o wi_stop(ifp, 0->1) changes so that we clear sc_enabled so that we
  exit out of the interrupt routine by just acking the interrupt

Submitted by: iedowse
Approved by: re@ (scottl)

# after the freeze I'll fix some of the minor style issues that reviewers
# of this patch have told me about.

20 years agoMajor 186 for sx driver (for Specialix I/O8+) by frank@exit.com
Warner Losh [Tue, 2 Dec 2003 04:40:33 +0000 (04:40 +0000)]
Major 186 for sx driver (for Specialix I/O8+) by frank@exit.com

20 years agoInclude opt_ipsec.h so IPSEC/FAST_IPSEC is defined and the appropriate
Sam Leffler [Tue, 2 Dec 2003 00:23:45 +0000 (00:23 +0000)]
Include opt_ipsec.h so IPSEC/FAST_IPSEC is defined and the appropriate
code is compiled in to support the O_IPSEC operator.  Previously no
support was included and ipsec rules were always matching.  Note that
we do not return an error when an ipsec rule is added and the kernel
does not have IPsec support compiled in; this is done intentionally
but we may want to revisit this (document this in the man page).

PR: 58899
Submitted by: Bjoern A. Zeeb
Approved by: re (rwatson)

20 years agoFixed a bug in sendfile(2) where the sent data would be corrupted due
David Greenman [Mon, 1 Dec 2003 22:12:50 +0000 (22:12 +0000)]
Fixed a bug in sendfile(2) where the sent data would be corrupted due
to sendfile(2) being erroneously automatically restarted after a signal
is delivered. Fixed by converting ERESTART to EINTR prior to exiting.

Updated manual page to indicate the potential EINTR error, its cause
and consequences.

Approved by: re@freebsd.org

20 years agoRename the ELAN_* options to CPU_ELAN_* according the the brucification.
Poul-Henning Kamp [Mon, 1 Dec 2003 20:39:04 +0000 (20:39 +0000)]
Rename the ELAN_* options to CPU_ELAN_* according the the brucification.

This commit was forgotten a few days ago.

Approved by: re@

20 years agoDo something sensible if both -h and -k are given.
David E. O'Brien [Mon, 1 Dec 2003 19:10:29 +0000 (19:10 +0000)]
Do something sensible if both -h and -k are given.

Approved by: re(scottl)

20 years agoUse a mutex to synchronize the driver top and bottom halves instead of
Don Lewis [Mon, 1 Dec 2003 19:03:50 +0000 (19:03 +0000)]
Use a mutex to synchronize the driver top and bottom halves instead of
using critcal_enter() and critical_exit() to attempt to replace spl*()
calls.  The critical section was calling selrecord(), which locks an
MTX_DEF mutex, which is not legal in a critical section.

Tested by: Stefan Ehmann <shoesoft@gmx.net> and "make universe"
Approved by: re (scottl)

20 years agoSpell SSHd as sshd.
Robert Watson [Mon, 1 Dec 2003 18:58:14 +0000 (18:58 +0000)]
Spell SSHd as sshd.

Requested by: jhb
Approved by: re (jhb)

20 years agoWhen clearing /tmp, X11 lock and temporary files are special.
Mike Makonnen [Mon, 1 Dec 2003 16:35:57 +0000 (16:35 +0000)]
When clearing /tmp, X11 lock and temporary files are special.
Remove them unconditionaly.

PR: bin/59065
Approved by: re (scottl)

20 years agoAutomatically generate the CHECKSUM.MD5 file for ISO's.
David E. O'Brien [Mon, 1 Dec 2003 10:46:45 +0000 (10:46 +0000)]
Automatically generate the CHECKSUM.MD5 file for ISO's.

Approved by: scottl

20 years agoSS_FATAL|ENXIO rather than SS_RDEF for illegal track mode.
David E. O'Brien [Mon, 1 Dec 2003 10:13:00 +0000 (10:13 +0000)]
SS_FATAL|ENXIO rather than SS_RDEF for illegal track mode.
This reduces the 90+ lines boot output of spewage GEOM does for my
Plextor SCSI burner.

Submitted by: scottl
Approved by: scottl

20 years agoI forgot about the code freeze, so back this out.
Don Lewis [Mon, 1 Dec 2003 00:33:57 +0000 (00:33 +0000)]
I forgot about the code freeze, so back this out.

20 years agoSwap avgfilesize and avgfpdir order to give better column alignment.
Don Lewis [Mon, 1 Dec 2003 00:32:34 +0000 (00:32 +0000)]
Swap avgfilesize and avgfpdir order to give better column alignment.

20 years agoNew release notes: SA-03.19, tcp_hostcache, compat4x.i386 updates,
Bruce A. Mah [Mon, 1 Dec 2003 00:17:33 +0000 (00:17 +0000)]
New release notes:  SA-03.19, tcp_hostcache, compat4x.i386 updates,
nologin(8) C implementation, no more sysinstall(8) security profiles

Modified release notes: Dynamic /bin and /sbin only apply to non-ia64,
BIND 8.3.7 (+ MFC), add old version information to sendmail update
note.

Approved by: re (implicitly)

20 years agoTrim ncv(4) and nsp(4) devices from the hardware notes and point to
Bruce A. Mah [Sun, 30 Nov 2003 23:54:59 +0000 (23:54 +0000)]
Trim ncv(4) and nsp(4) devices from the hardware notes and point to
on-line manpages via hyperlinks.

Approved by: re (implicitly)

20 years agoIn dounmount(), only call checkdirs() prior to VFS_UNMOUNT() in the
Ian Dowse [Sun, 30 Nov 2003 23:30:09 +0000 (23:30 +0000)]
In dounmount(), only call checkdirs() prior to VFS_UNMOUNT() in the
forced unmount case. Otherwise, a file system that is referenced
only by process fd_cdir/fd_rdir references to the file system root
vnode will be successfully unmounted without the MNT_FORCE flag.

The previous behaviour was not compatible with the unmount semantics
required by amd(8), so file systems could be unexpectedly unmounted
while there were still references to the file system root directory.

Reported by: Erez Zadok <ezk@cs.sunysb.edu>
Approved by: re (scottl)

20 years ago - Make mp_maxid reflect the same meaning as it does on other architectures.
Jeff Roberson [Sun, 30 Nov 2003 22:20:40 +0000 (22:20 +0000)]
 - Make mp_maxid reflect the same meaning as it does on other architectures.
   It is one past the last valid cpuid.  This relied on a different bug in
   UMA to work properly.

Reported/Tested by: phk
Approved by: rwatson

20 years ago - Unbreak UP. mp_maxid is not defined on uni-processor machines, although
Jeff Roberson [Sun, 30 Nov 2003 22:18:14 +0000 (22:18 +0000)]
 - Unbreak UP.  mp_maxid is not defined on uni-processor machines, although
   I believe it and the other MP variables should be.  For now, just define it
   here and wait for jhb to clean it up later.

Approved by: re (rwatson)

20 years ago - Don't forget to unlock the vnode interlock in the LK_NOWAIT case.
Jeff Roberson [Sun, 30 Nov 2003 22:09:58 +0000 (22:09 +0000)]
 - Don't forget to unlock the vnode interlock in the LK_NOWAIT case.

Submitted by: Stephan Uphoff <ups@stups.com>
Approved by: re (rwatson)

20 years ago - Set mp_maxid in a way that is consistent with every other arch. It is
Jeff Roberson [Sun, 30 Nov 2003 22:08:24 +0000 (22:08 +0000)]
 - Set mp_maxid in a way that is consistent with every other arch.  It is
   one more than the last valid 'cpuid'.

Approved by: re (rwatson)

20 years agoUpdate maintainer line. mbr has been maintainer for at least the last
Murray Stokely [Sun, 30 Nov 2003 21:09:58 +0000 (21:09 +0000)]
Update maintainer line.  mbr has been maintainer for at least the last
6 months.

Approved by: re (murray)

20 years agoVersion number bump for 5.2-BETA release documentation.
Bruce A. Mah [Sun, 30 Nov 2003 19:11:59 +0000 (19:11 +0000)]
Version number bump for 5.2-BETA release documentation.

Approved by: re (implicitly)

20 years agoThe new "spec against spec" comparison code was yet another time
Poul-Henning Kamp [Sun, 30 Nov 2003 18:06:02 +0000 (18:06 +0000)]
The new "spec against spec" comparison code was yet another time
victim of the special sort order employed where files come before
directories and alphabetic inside these two groups.

Approved by: re@

20 years agoFix ata-card.
Søren Schmidt [Sun, 30 Nov 2003 16:27:59 +0000 (16:27 +0000)]
Fix ata-card.
The altio resource magic no longer worked probably due to other changes
in the kernel. Redo that part so it also fits better into ATAng.
Fix detach so it doesn't panic the system when a pccard device is
yanked.

Approved by: re@

20 years agoMdoc(7) janitor cleanup.
Simon L. B. Nielsen [Sun, 30 Nov 2003 12:42:01 +0000 (12:42 +0000)]
Mdoc(7) janitor cleanup.

Reviewed and improved by: ru
OK'ed by: phk
Approved by: re (rwatson)

20 years agoRemoved the i386 specific bit from title.
Ruslan Ermilov [Sun, 30 Nov 2003 08:50:17 +0000 (08:50 +0000)]
Removed the i386 specific bit from title.

Reviewed by: non
Approved by: re (rwatson)

20 years ago - Replace the local maxcpu with mp_maxid. Previously, if mp_maxid
Jeff Roberson [Sun, 30 Nov 2003 08:04:01 +0000 (08:04 +0000)]
 - Replace the local maxcpu with mp_maxid.  Previously, if mp_maxid
   was equal to MAXCPU, we would overrun the pcpu_mtx array because maxcpu
   was calculated incorrectly.
 - Add some more debugging code so that memory leaks at the time of
   uma_zdestroy() are more easily diagnosed.

Approved by: re (rwatson)

20 years agoAlso export the ARCH variable so that cross-generation of cdrom package
Kris Kennaway [Sun, 30 Nov 2003 01:35:19 +0000 (01:35 +0000)]
Also export the ARCH variable so that cross-generation of cdrom package
lists works as expected.

Approved by: re

20 years agovim-lite can hardly be considered 'lite'. Remove it.
Scott Long [Sat, 29 Nov 2003 23:48:44 +0000 (23:48 +0000)]
vim-lite can hardly be considered 'lite'.  Remove it.

20 years agoAdd a Securelevel sub-menu to the Security configuration menu,
Robert Watson [Sat, 29 Nov 2003 21:44:51 +0000 (21:44 +0000)]
Add a Securelevel sub-menu to the Security configuration menu,
permitting the administrator to select a securelevel top operate
at.  Include a helpfile summarizing some of the information from
init(8).  This allows for explicit configuration of securelevels,
which was previously implicit in Security Profile selection.
Currently, there are no checkboxes for the active securelevel,
because sysinstall's facilities for deriving "current settings"
from rc.conf may use only one variable, not two, and I opted for
the simplest approach at this point.

Approved by: re (scottl)

20 years agocorrect typo in interrupt handling for the 2nd port of 2-port cards
Sam Leffler [Sat, 29 Nov 2003 19:33:01 +0000 (19:33 +0000)]
correct typo in interrupt handling for the 2nd port of 2-port cards

Submitted by: luigi
Reviewed by: checking original openbsd code
Approved by: re (scottl)

20 years agoScheduled sweep using the README guidelines.
Ruslan Ermilov [Sat, 29 Nov 2003 18:22:01 +0000 (18:22 +0000)]
Scheduled sweep using the README guidelines.

Approved by: re (rwatson)

20 years ago- Connect a few forgotten Netgraph manpages.
Ruslan Ermilov [Sat, 29 Nov 2003 18:14:04 +0000 (18:14 +0000)]
- Connect a few forgotten Netgraph manpages.
- Sort.

Approved by: re (rwatson)

20 years agoEliminate two pushl by using call instruction directly, this really
David Xu [Sat, 29 Nov 2003 14:25:43 +0000 (14:25 +0000)]
Eliminate two pushl by using call instruction directly, this really
helps branch predict a lot for INTEL P4.

Approved by: re (scottl)

20 years ago1.Macro optimizing KSE_LOCK_ACQUIRE and THR_LOCK_ACQUIRE to use static fall
David Xu [Sat, 29 Nov 2003 14:22:29 +0000 (14:22 +0000)]
1.Macro optimizing KSE_LOCK_ACQUIRE and THR_LOCK_ACQUIRE to use static fall
through branch predict as suggested in INTEL IA32 optimization guide.

2.Allocate siginfo arrary separately to avoid pthread to be allocated at
2K boundary, which hits L1 address alias problem and causes context
switch to be slow down.

3.Simplify context switch code by removing redundant code, code size is
reduced, so it is expected to run faster.

Reviewed by: deischen
Approved by: re (scottl)

20 years agoRemove surplus mmap() call for stack guard page in init_private, it is done
David Xu [Sat, 29 Nov 2003 14:10:02 +0000 (14:10 +0000)]
Remove surplus mmap() call for stack guard page in init_private, it is done
in init_main_thread. Also don't initialize lock and lockuser again for initial
thread, it is already done by _thr_alloc().

Reviewed by: deischen
Approved by: re (scottl)

20 years ago - In db_stack_trace_cmd() bail out if we get confused about the stack.
Jeff Roberson [Sat, 29 Nov 2003 11:57:02 +0000 (11:57 +0000)]
 - In db_stack_trace_cmd() bail out if we get confused about the stack.

Tested by: kkenn
Approved by: re (scottl)

20 years agoUpdate with the 4.9 libraries, and add libdevstat.so.2 libmp.so.3
David E. O'Brien [Sat, 29 Nov 2003 03:29:18 +0000 (03:29 +0000)]
Update with the 4.9 libraries, and add libdevstat.so.2 libmp.so.3
libskey.so.2 libusbhid.so.0 libutil.so.3 libvgl.so.2 to the mix.

Approved by: scottl

20 years agoo track API change for HAL v0.9.6.1
Sam Leffler [Sat, 29 Nov 2003 01:23:59 +0000 (01:23 +0000)]
o track API change for HAL v0.9.6.1
o fix race condition when processing rx descriptors: because we use
  a self-linked descriptor at the end of the rx descriptor list to
  avoid rx overruns (which can easily happen for 5212 parts that enable
  PHY errors) we must carefully check that a descriptor is "done" by
  looking ahead to the next descriptor before believing the done bit
  in the current descriptor (this is all handled in the HAL since the
  rx descriptor format is chip-specific so we need to pass in two
  additional parameters--the physical address of the current descriptor
  and the virtual address of the next descriptor in the list)
o check copyout return status for SIOCGATHSTATS ioctl

Approved by: re (scottl)

20 years agoThis commit was generated by cvs2svn to compensate for changes in r123041,
Sam Leffler [Sat, 29 Nov 2003 01:11:48 +0000 (01:11 +0000)]
This commit was generated by cvs2svn to compensate for changes in r123041,
which included commits to RCS files with non-trunk default branches.

20 years agoVersion 0.9.6.1:
Sam Leffler [Sat, 29 Nov 2003 01:11:48 +0000 (01:11 +0000)]
Version 0.9.6.1:

o support for 5112 and 2112 radios on 5212-based products
o revised interface for ah_procRxDesc needed to handle a race
  condition created with the use of self-linked rx descriptors
o support for setting the MAC address
o remove some unused methods from the public API
o revised diagnostic API (replace dump* methods with getDiagState)
o const'ify set key cache method parameters
o support for optional 32khz sleep clock
o implement ah_setSlotTime for 5211 parts
o ANI improvements for 5212 parts

Approved by:    re (scottl)

20 years agoApply the vendor change to this file, thus resolving the import conflict
Doug Barton [Fri, 28 Nov 2003 22:02:17 +0000 (22:02 +0000)]
Apply the vendor change to this file, thus resolving the import conflict

20 years agoThis commit was generated by cvs2svn to compensate for changes in r123036,
Doug Barton [Fri, 28 Nov 2003 21:58:43 +0000 (21:58 +0000)]
This commit was generated by cvs2svn to compensate for changes in r123036,
which included commits to RCS files with non-trunk default branches.

20 years agoImport of ISC BIND version 8.3.7
Doug Barton [Fri, 28 Nov 2003 21:58:43 +0000 (21:58 +0000)]
Import of ISC BIND version 8.3.7

Approved by: re
Requested by: security-officer

20 years agoCosmetic fix: a message was mixed with a dialog box border line.
Jimmy Olgeni [Fri, 28 Nov 2003 20:44:25 +0000 (20:44 +0000)]
Cosmetic fix: a message was mixed with a dialog box border line.

Approved by: re (rwatson)

20 years agoWorkaround for errata on early versions of the sii3112.
Søren Schmidt [Fri, 28 Nov 2003 19:01:28 +0000 (19:01 +0000)]
Workaround for errata on early versions of the sii3112.

Approved by: re@

20 years agoRemove the call to M_ASSERTVALID from BPF_MTAP; some mbufs passed to
Mike Silbersack [Fri, 28 Nov 2003 18:48:59 +0000 (18:48 +0000)]
Remove the call to M_ASSERTVALID from BPF_MTAP; some mbufs passed to
mpf are allocated on the stack, which causes this check to falsely trigger.

A new check which takes on-stack mbufs into account will be reintroduced
after 5.2 is out the door.

Approved by: re (watson)
Requested by: many

20 years agoRemove security profiles from sysinstall. Currently, security profile
Robert Watson [Fri, 28 Nov 2003 18:47:45 +0000 (18:47 +0000)]
Remove security profiles from sysinstall.  Currently, security profile
selection is used to drive two configuration parameters:

(1) Default enable/disable for sshd
(2) Default enable/disable for securelevels

Replace this with an explicit choice to enable/disable sshd.  A
follow-up commit will add a configuration option to the Security
post-install configuration menu to set the securelevel in rc.conf
explicitly.  This should reduce the level of foot-shooting associated
with accidental enabling of securelevels, make the nature and
implications of the securelevel configuration options more explicit,
as well as make the choice to enable/disable sshd more explicit.

Approved by: re (scottl)

20 years agoDo not adjust to the pagesize at runtime. Besides for the one-time
Marcel Moolenaar [Fri, 28 Nov 2003 18:03:22 +0000 (18:03 +0000)]
Do not adjust to the pagesize at runtime. Besides for the one-time
initialization overhead, there's a problem in that we never call
imalloc() and thus malloc_init() for zero-sized allocations. As a
result, malloc(0) returns NULL when it's the first or only malloc in
the program. Any non-zero allocation will initialize the malloc code
with the side-effect that subsequent zero-sized allocations return a
non-NULL pointer. This is because the pointer we return for zero-
sized allocations is calculated from malloc_pageshift, which needs
to be initialized at runtime on ia64.

The result of the inconsistent behaviour described above is that
configure scripts failed the test for a GNU compatible malloc. This
resulted in a lot of broken ports.

Other, even simpler, solutions were possible as well:
1.  initialize malloc_pageshift with some non-zero value (say 13 for
    8KB pages) and keep the runtime adjustment.
2.  Stop using malloc_pageshift to calculate ZEROSIZEPTR.

Removal of the runtime adjustment was chosen because then ia64 is the
same as any other platform. It is not to say that using a page size
obtained at runtime is bad per se. It's that there's currently a high
level of gratuity for its existence and the moment it causes problems
is the moment you need to get rid of it. Hence, it's not unthinkable
that this commit is (partially) reverted some time in the future when
we do have a good reason for it and a good way to achieve it.

Approved by: re@ (rwatson)
Reported by: kris (portmgr@) -- may the ports be with you

20 years agoFix some minor nits in netstat whereby large interface names would be
Bruce M Simpson [Fri, 28 Nov 2003 17:34:23 +0000 (17:34 +0000)]
Fix some minor nits in netstat whereby large interface names would be
truncated. In environments where many tunnel or vlan interfaces are created,
interface names have high numbers which overflow the field width.

PRs: bin/52349, bin/35838
Submitted by: Mike Tancsa, Scot W. Hetzel
Approved by: re (rwatson)

20 years agoAdd a means of starting an IKE daemon from the rc system at an appropriate
Bruce M Simpson [Fri, 28 Nov 2003 17:28:42 +0000 (17:28 +0000)]
Add a means of starting an IKE daemon from the rc system at an appropriate
time during the boot process. This is needed in the case where NFS mounts
from servers reachable only via IPSEC are in /etc/fstab.

PR: conf/42497
Submitted by: Volker Stolz
Approved by: re (rwatson)

20 years agoFix an optimization where I made an ifdef'd out section to broad.
Andre Oppermann [Fri, 28 Nov 2003 16:33:03 +0000 (16:33 +0000)]
Fix an optimization where I made an ifdef'd out section to broad.

When the hostcache bucket limit is reached the last bucket wasn't
removed from the bucket row but inserted a few lines later at the
bucket row head again.  This leads to infinite loop when the same
bucket row is accessed the next time for a lookup/insert or purge
action.

Tested by: imp, Matt Smith
Approved by: re (rwatson)

20 years agomissing splx.
Hajimu UMEMOTO [Fri, 28 Nov 2003 14:34:42 +0000 (14:34 +0000)]
missing splx.
this is a NOOP change, and primarily merged for consistency with
-STABLE.

Approved by: re (rwatson)

20 years agoUnderstand the old pseudo-device config(8) file directive, for 4.x.
Ruslan Ermilov [Fri, 28 Nov 2003 08:58:44 +0000 (08:58 +0000)]
Understand the old pseudo-device config(8) file directive, for 4.x.

20 years agoSometimes cardbus attachments don't attach, so while we track down
Warner Losh [Fri, 28 Nov 2003 05:28:29 +0000 (05:28 +0000)]
Sometimes cardbus attachments don't attach, so while we track down
this problem put these lines back in.  While they should be
unnecessary, they appear to be sometimes necessary.

Reviewed in concept: dfr
Approved by: re (scottl@)

20 years agoEliminate a duplicate free when deleting an interface address. This
Sam Leffler [Fri, 28 Nov 2003 04:19:41 +0000 (04:19 +0000)]
Eliminate a duplicate free when deleting an interface address.  This
caused crashes, typically during shutdown, because the second free
referenced a mutex that had been destroyed.

Tested by: several
Approved by: re (scottl)

20 years agoClarify that the encrypted device is called foo.bde and mention that
Poul-Henning Kamp [Thu, 27 Nov 2003 20:54:51 +0000 (20:54 +0000)]
Clarify that the encrypted device is called foo.bde and mention that
unmounting it before detaching GBDE is a good idea.

Insisted on by: Flemming Jacobsen <fj@batmule.dk>
Approveed by: re@

20 years agoAdd manual page for CPU_ELAN, CPU_SOEKRIS and related options for the
Poul-Henning Kamp [Thu, 27 Nov 2003 20:28:25 +0000 (20:28 +0000)]
Add manual page for CPU_ELAN, CPU_SOEKRIS and related options for the
Elan 520 CPU chip.

Approved by: re@

20 years agoRefactor AMD Elan 520 CPU support.
Poul-Henning Kamp [Thu, 27 Nov 2003 20:27:29 +0000 (20:27 +0000)]
Refactor AMD Elan 520 CPU support.

Make it possible to configure GPIO pins as led(4) devices, PPS inputs
and PPS-echo outputs with a sysctl.  Led(4) and PPS-echo can be configured
for active-high or active-low.

Be more complete in initialization of timecounter hardware.

Approved by: re@

20 years agoImprove semantics of the 'sequence' command to led(4) devices:
Poul-Henning Kamp [Thu, 27 Nov 2003 20:23:32 +0000 (20:23 +0000)]
Improve semantics of the 'sequence' command to led(4) devices:
use lowercase for off and upper case for on.

Approved by: re@

20 years agoFix a panic due to holding a lock over calls to uiomove.
Mathew Kanner [Thu, 27 Nov 2003 19:51:44 +0000 (19:51 +0000)]
Fix a panic due to holding a lock over calls to uiomove.

Pointed out by: Artur Poplawski
Explained by: Don Lewis (truckman)
Approved by: tanimura (mentor)
Approved by: scottl (re)

20 years agoMention that floppy based installs are not supported on amd64 systems
Peter Wemm [Thu, 27 Nov 2003 18:38:39 +0000 (18:38 +0000)]
Mention that floppy based installs are not supported on amd64 systems
rather than leaving the section blank.  This was left out of the last
commit by accident.

Approved by: bmah

20 years agoUpdate for amd64 so that the devices list is a bit more complete and there
Peter Wemm [Thu, 27 Nov 2003 18:24:44 +0000 (18:24 +0000)]
Update for amd64 so that the devices list is a bit more complete and there
are not quite so many blank sections.

Approved by:  bmah

20 years agoFix i386 apic support merge botch. sizeof(long) is 8, not 4. This fixes
Peter Wemm [Thu, 27 Nov 2003 17:20:44 +0000 (17:20 +0000)]
Fix i386 apic support merge botch.  sizeof(long) is 8, not 4.  This fixes
the annoying 'sysctl: hw.intrcnt: out of memory' error message in systat.

Approved by:  re (rwatson)

20 years ago* If a processor's softc is NULL, use C1 since there is no ACPI
Nate Lawson [Thu, 27 Nov 2003 16:32:46 +0000 (16:32 +0000)]
* If a processor's softc is NULL, use C1 since there is no ACPI
  processor object for this CPU.  This occurs for logical CPUs which
  do not have an associated processor object (e.g., HTT).

Approved by: re (rwatson)

20 years agoFix verify_rev_path() function. The author of this function tried to
Andre Oppermann [Thu, 27 Nov 2003 09:40:13 +0000 (09:40 +0000)]
Fix verify_rev_path() function.  The author of this function tried to
cut corners which completely broke down when the routing table locking
was introduced.

Reviewed by: sam (mentor)
Approved by: re (rwatson)

20 years agoServeRaid (at least 5i) didn't initialize correctly. To get
Martin Blapp [Thu, 27 Nov 2003 08:37:36 +0000 (08:37 +0000)]
ServeRaid (at least 5i) didn't initialize correctly. To get
them working (cache, automatic rebuild and hotswap) the FFDC
info (First Failure Data Capture) on the adapter must be
initialised.

Logical drives in critical/degraded states weren't added to
the drive list. FreeBSD was not able to see a degraded array
after a reboot. Degraded drives are now also added to the drivelist
and the state of the logical drive is given at boottime.

The adapter type is detected from informations in nvram page 5
and displayed at boottime.

Change IPS_OS_FREEBSD definition from 10 to 8 according to IBM
specs.

Submitted by:   <Patrick Guelat> pgfb@imp.ch
Reviewed by:    mbr, scottl
Approved by:    re

20 years agoFix whitespace error in previous commit.
Wes Peters [Thu, 27 Nov 2003 01:19:23 +0000 (01:19 +0000)]
Fix whitespace error in previous commit.

Approved by: RE@ (Robert Watson)

20 years agoMake sure all uses of stack allocated struct route's are properly
Andre Oppermann [Wed, 26 Nov 2003 20:31:13 +0000 (20:31 +0000)]
Make sure all uses of stack allocated struct route's are properly
zeroed.  Doing a bzero on the entire struct route is not more
expensive than assigning NULL to ro.ro_rt and bzero of ro.ro_dst.

Reviewed by: sam (mentor)
Approved by: re  (scottl)

20 years ago* Add acpi_pcpu_get_id(idx, *acpi_id, *cpu_id) which fetches the
Nate Lawson [Wed, 26 Nov 2003 19:01:33 +0000 (19:01 +0000)]
* Add acpi_pcpu_get_id(idx, *acpi_id, *cpu_id) which fetches the
  idx'th present CPU with pc_acpi_id equal to *acpi_id.  If *acpi_id
  does not match that processor's pc_acpi_id, return the value for
  ProcId derived from the MADT in *acpi_id.  If pc_acpi_id is 0xffffffff,
  always override it with the value of *acpi_id.  Finally, return
  pc_cpuid in *cpu_id and use that as our primary key.

* Use pc_cpuid as our unique key because we know it is valid since
  MD code set it.  The values for ProcId in the ASL and MADT don't
  match up on some machines (!), forcing us to fall back to ordered
  probing in that case.

* Remove some #ifdef SMP since the refcount doesn't hurt performance
  and will be needed for dynamic _CST objects.  Only one #ifdef SMP
  (for smp_rendezvous) remains.

* Hook up SMP in the compile flags in the Makefile.

Tested by: marcel, truckman
Approved by: re (scottl)

20 years agoLearn about new world order
Alexey Zelkin [Wed, 26 Nov 2003 10:43:05 +0000 (10:43 +0000)]
Learn about new world order

20 years agoGrammar, spelling and punctuation sweep.
Christian Brueffer [Wed, 26 Nov 2003 08:38:32 +0000 (08:38 +0000)]
Grammar, spelling and punctuation sweep.

Approved by: re (rwatson)

20 years agoSplit the "inp" mutex class into separate classes for each of divert,
Sam Leffler [Wed, 26 Nov 2003 01:40:44 +0000 (01:40 +0000)]
Split the "inp" mutex class into separate classes for each of divert,
raw, tcp, udp, raw6, and udp6 sockets to avoid spurious witness
complaints.

Reviewed by: rwatson
Approved by: re (rwatson)

20 years agoRestructure a too broad ifdef which was disabling the setting of the
Andre Oppermann [Tue, 25 Nov 2003 20:58:59 +0000 (20:58 +0000)]
Restructure a too broad ifdef which was disabling the setting of the
tcp flightsize sysctl value for local networks in the !INET6 case.

Approved by: re (scottl)

20 years agoworkaround LOR in rt_setgate
Sam Leffler [Tue, 25 Nov 2003 19:52:12 +0000 (19:52 +0000)]
workaround LOR in rt_setgate

Reviewed by: andre
Approved by: re (rwatson)

20 years agoCorrect the name of the make(1) knob to disable dynamic root
Simon L. B. Nielsen [Tue, 25 Nov 2003 14:11:02 +0000 (14:11 +0000)]
Correct the name of the make(1) knob to disable dynamic root
(s/WITHOUT_DYNAMICROOT/NO_DYNAMICROOT/).

Approved by: re (scottl)
Noticed by: Matthias Schndehtte <Matthias.Schuendehuette@siemens.com>

20 years agoMove mly, plip, and slip back into the kernel so floppy 3 can fit again. I'm
Scott Long [Tue, 25 Nov 2003 04:51:35 +0000 (04:51 +0000)]
Move mly, plip, and slip back into the kernel so floppy 3 can fit again.  I'm
not sure why it exploded in the last 10 days, though I suspect nfsclient.ko.

Approved by: re (rwatson)

20 years agoTurns out that building modules with the kernel opt files is
Warner Losh [Tue, 25 Nov 2003 04:12:43 +0000 (04:12 +0000)]
Turns out that building modules with the kernel opt files is
uncovering some interesting problems.  Be conservative and effecitvely
disable this by default.  Interested parties may still define
KERNBUILDDIR by hand to achive the same effect.

I plan on referting this change after 5.2 is released, or sooner if
the issues with building releases are resolved and re@ approves.

Approved by: re@ (scottl, marcel)

20 years agoWrite the correct value to `td_be' for the second and further
Ian Dowse [Tue, 25 Nov 2003 02:23:29 +0000 (02:23 +0000)]
Write the correct value to `td_be' for the second and further
transfer descriptors when a large request needs to be split into
more than one 8k chunk. The bug was that the calculation did not
take into account the offset of the chunk within the overall request.
This is reported to fix crashes and data corruption on ohci
controllers.

Submitted by: green
Approved by: re

20 years agoAdd nsp(4) man page for nsp PC-Card SCSI host adapter device driver,
Noriaki Mitsunaga [Mon, 24 Nov 2003 23:57:59 +0000 (23:57 +0000)]
Add nsp(4) man page for nsp PC-Card SCSI host adapter device driver,
and attach it to the build.

Submitted by: non, rushani
Approved by: re (rwatson)

20 years agoo Add HISTORY and AUTHORS section
Noriaki Mitsunaga [Mon, 24 Nov 2003 23:47:24 +0000 (23:47 +0000)]
o Add HISTORY and AUTHORS section
o Add scsi.4 in the SEE ALSO section

Reviewed by: rushani
Approved by: re (rwatson)

20 years agoCorrect iov_len values passed to nmount(2) syscall. More accurate
Alexander Kabaev [Mon, 24 Nov 2003 16:14:32 +0000 (16:14 +0000)]
Correct iov_len values passed to nmount(2) syscall. More accurate
parameter checking introduced in vfs_mount.c r1.113 rejects them
otherwise.

Submitted by: R. Imura <imura at ryu16 dot org>
Approved by: re (scottl,rwatson)

20 years ago - Drop down to one snapshots FTP site since that's all we have now
Ken Smith [Mon, 24 Nov 2003 15:27:20 +0000 (15:27 +0000)]
- Drop down to one snapshots FTP site since that's all we have now
- Adjust names of IPv6 FTP hosts a bit
- Sync list of FTP sites with reality

Approved by: rwatson (re@)

20 years agoCorrect the former patch, I accidently committed the wrong version.
Søren Schmidt [Mon, 24 Nov 2003 14:54:41 +0000 (14:54 +0000)]
Correct the former patch, I accidently committed the wrong version.

Approved by: re@

20 years agoFix panic on certain failed configs.
Søren Schmidt [Mon, 24 Nov 2003 14:22:30 +0000 (14:22 +0000)]
Fix panic on certain failed configs.

Approved by: re@

20 years agoBe less noisy when GEOM probes around during boot if drive contains
Søren Schmidt [Mon, 24 Nov 2003 14:20:19 +0000 (14:20 +0000)]
Be less noisy when GEOM probes around during boot if drive contains
invalid media (ie empty CD/DVD)

Approved by: re@

20 years agoInitalize buffer headers correctly for current version of bio subsystem.
Greg Lehey [Mon, 24 Nov 2003 04:06:56 +0000 (04:06 +0000)]
Initalize buffer headers correctly for current version of bio subsystem.

Not mentioned by: phk
Approved by:   re (scottl)

This makes Vinum work again, at least in my testing.

20 years agoCorrect a problem where ipfw-generated packets were being returned
Sam Leffler [Mon, 24 Nov 2003 03:57:03 +0000 (03:57 +0000)]
Correct a problem where ipfw-generated packets were being returned
for ipfw processing w/o an indication the packets were generated
by ipfw--and so should not be processed (this manifested itself
as a LOR.)  The flag bit in the mbuf that was used to mark the
packets was not listed in M_COPYFLAGS so if a packet had a header
prepended (as done by IPsec) the flag was lost.  Correct this by
defining a new M_PROTO6 flag and use it to mark packets that need
this processing.

Reviewed by: bms
Approved by: re (rwatson)
MFC after: 2 weeks

20 years agopktopt may be null.
Hajimu UMEMOTO [Mon, 24 Nov 2003 01:53:36 +0000 (01:53 +0000)]
pktopt may be null.

Approved by: re (rwatson)