]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
18 years agoRemove ifdef notdef SIOCHWADDR vestige.
imp [Sat, 4 Feb 2006 08:16:07 +0000 (08:16 +0000)]
Remove ifdef notdef SIOCHWADDR vestige.

18 years agoRemove ifdef notyet for SIOCGHWADDR
imp [Sat, 4 Feb 2006 08:15:29 +0000 (08:15 +0000)]
Remove ifdef notyet for SIOCGHWADDR
Treat SIOCADDMULTI and SIOCDELMULTI the same, since they had the same code
Remove redundant assignment to error
Convert to using the altq interface completely.

18 years agos/bin/sbin/ for mount_nwfs, mount_portalfs and mount_smbfs. They never
avatar [Sat, 4 Feb 2006 08:07:00 +0000 (08:07 +0000)]
s/bin/sbin/ for mount_nwfs, mount_portalfs and mount_smbfs.  They never
lived in bin since 1994.
Whilst here, also document the removal time of aforementioned utilities
as well.

MFC after: 1 week

18 years agoGive correct definitions to some basic types.
scottl [Sat, 4 Feb 2006 08:01:49 +0000 (08:01 +0000)]
Give correct definitions to some basic types.

18 years agoNever select the PCB that has INP_IPV6 flag and is bound to :: if
ume [Sat, 4 Feb 2006 07:59:17 +0000 (07:59 +0000)]
Never select the PCB that has INP_IPV6 flag and is bound to :: if
we have another PCB which is bound to 0.0.0.0.  If a PCB has the
INP_IPV6 flag, then we set its cost higher than IPv4 only PCBs.

Submitted by: Keiichi SHIMA <keiichi__at__iijlab.net>
Obtained from: KAME
MFC after: 1 week

18 years agoAxe unused code.
davidxu [Sat, 4 Feb 2006 06:36:39 +0000 (06:36 +0000)]
Axe unused code.

18 years agoFix minor inconsistancy between kernel built modules and stand-alone
imp [Sat, 4 Feb 2006 06:22:27 +0000 (06:22 +0000)]
Fix minor inconsistancy between kernel built modules and stand-alone
built buildes.  I believe this gives the same flags on the command
line for both.

18 years agoFix a possible memory leak in asr_attach.
scottl [Sat, 4 Feb 2006 06:08:19 +0000 (06:08 +0000)]
Fix a possible memory leak in asr_attach.

18 years agoi386/PAE defines bus_size_t to be 32-bits when it likely should be 64-bits.
scottl [Sat, 4 Feb 2006 03:41:48 +0000 (03:41 +0000)]
i386/PAE defines bus_size_t to be 32-bits when it likely should be 64-bits.
Fixing it is left for another day, so just hack around it for now.

18 years agoFix calculation of the number of arenas to use on multi-processor systems.
jasone [Sat, 4 Feb 2006 01:11:30 +0000 (01:11 +0000)]
Fix calculation of the number of arenas to use on multi-processor systems.

18 years agoCast pointers to (uintptr_t) before down-casting to (int). This avoids
rwatson [Sat, 4 Feb 2006 00:14:06 +0000 (00:14 +0000)]
Cast pointers to (uintptr_t) before down-casting to (int).  This avoids
an incompatible conversion from a 64-bit pointer to a 32-bit integer on
64-bit platforms.  We will investigate whether Solaris uses a 64-bit
token here, or a new record here, in order to avoid truncating user
pointers that are 64-bit.  However, in the mean time, truncation is fine
as these are rarely/never used fields in audit records.

Obtained from: TrustedBSD Project

18 years agoFix INVARIANTS build on amd64; (unsigned unsigned long) != u_int64_t.
rwatson [Fri, 3 Feb 2006 23:50:26 +0000 (23:50 +0000)]
Fix INVARIANTS build on amd64; (unsigned unsigned long) != u_int64_t.

Submitted by: mlaier

18 years agoProperly initialize args structure before passing it to ipfw_chk(): having
oleg [Fri, 3 Feb 2006 23:03:07 +0000 (23:03 +0000)]
Properly initialize args structure before passing it to ipfw_chk(): having
uninitialized args.inp is unhealthy for uid/gid/jail ipfw rules.

PR: kern/92589
Approved by: glebius (mentor)
MFC after: 1 week

18 years agoAdd a comment.
jhb [Fri, 3 Feb 2006 21:09:40 +0000 (21:09 +0000)]
Add a comment.

18 years agoFix compilation with -Wundef (NBPF is undefined on FreeBSD >4).
ru [Fri, 3 Feb 2006 20:55:30 +0000 (20:55 +0000)]
Fix compilation with -Wundef (NBPF is undefined on FreeBSD >4).

18 years agoHandle NO_INCS solely inside bsd.incs.mk.
ru [Fri, 3 Feb 2006 16:50:32 +0000 (16:50 +0000)]
Handle NO_INCS solely inside bsd.incs.mk.

18 years agoFix a markup glitch.
ru [Fri, 3 Feb 2006 16:41:13 +0000 (16:41 +0000)]
Fix a markup glitch.

18 years agoSort includes.
jhb [Fri, 3 Feb 2006 16:37:55 +0000 (16:37 +0000)]
Sort includes.

18 years agoAdd AUDIT to NOTES, as it's probably ready to get regular build testing
rwatson [Fri, 3 Feb 2006 15:53:37 +0000 (15:53 +0000)]
Add AUDIT to NOTES, as it's probably ready to get regular build testing
by the tinderboxes.

18 years agoRemove user.h include in audit.h, it is unneeded, and also can cause
rwatson [Fri, 3 Feb 2006 15:49:07 +0000 (15:49 +0000)]
Remove user.h include in audit.h, it is unneeded, and also can cause
build problems for other components that include audit.h.

18 years agoIn fchdir(), Giant must be separately acquired and dropped if the old
rwatson [Fri, 3 Feb 2006 15:42:16 +0000 (15:42 +0000)]
In fchdir(), Giant must be separately acquired and dropped if the old
vnode is from a file system that is not MPSAFE, as vrele() expects
Giant to be held when it is called on a non-MPSAFE vnode.

Spotted by: kris
Tested by: glebius

18 years agoMake UDF endian-safe.
will [Fri, 3 Feb 2006 15:25:52 +0000 (15:25 +0000)]
Make UDF endian-safe.

Submitted by: Pedro Martelletto <pedro@ambientworks.net> (via scottl)
Tested on: sparc64

18 years agoDocument carp(4) arguments.
jcamou [Fri, 3 Feb 2006 14:41:41 +0000 (14:41 +0000)]
Document carp(4) arguments.

PR: docs/92653
Submitted by: Jeremy C. Reed <reed@reedmedia.net>
Reviewed by: ru
Approved by: trhodes (mentor)
MFC after: 5 days

18 years ago- Don't shift the clock frequency in MHz left by 8 before assigning it
marius [Fri, 3 Feb 2006 12:35:42 +0000 (12:35 +0000)]
- Don't shift the clock frequency in MHz left by 8 before assigning it
  to sbus_mdvec.dv_clock as sbus_mdvec.dv_clock is meant to be specified
  in MHz. While this was a bug it shouldn't have affected FreeBSD/sparc64
  as sbus_mdvec.dv_clock is used to limit the clock rate of chips when
  a machine isn't able to support them at maximum speed which isn't the
  case for sun4u machines.
- Remove the code that checks whether the clock frequency returned by
  sbus_get_clockfreq() is 0 and falls back to 25MHz if it is as that's
  already done in sbus(4).

Approved by: mjacob
MFC after: 3 days

18 years agoRegenerate.
rwatson [Fri, 3 Feb 2006 11:51:19 +0000 (11:51 +0000)]
Regenerate.

18 years agoAssign audit event identifiers to many system calls.
rwatson [Fri, 3 Feb 2006 11:48:37 +0000 (11:48 +0000)]
Assign audit event identifiers to many system calls.

Much work by: wsalamon
Obtained from: TrustedBSD Project

18 years agoDropping the lock in the transmit_event() is not safe, because we
glebius [Fri, 3 Feb 2006 11:38:19 +0000 (11:38 +0000)]
Dropping the lock in the transmit_event() is not safe, because we
store some pipe pointers on stack. If user reconfigures dummynet
in the interlock gap, we can work with freed pipes after relock.

To fix this, we decided not to send packets in transmit_event(),
but fill a queue. At the end of dummynet() and dummynet_io(),
after the lock is dropped, if there is something in the queue
we run dummynet_send() to process the queue.

In collaboration with: ru

18 years agoFix a sentence.
brueffer [Fri, 3 Feb 2006 11:10:50 +0000 (11:10 +0000)]
Fix a sentence.

18 years agoUse -O2 on RELENG_6 as well
des [Fri, 3 Feb 2006 10:55:00 +0000 (10:55 +0000)]
Use -O2 on RELENG_6 as well

18 years agoAxe unused function.
glebius [Fri, 3 Feb 2006 10:42:28 +0000 (10:42 +0000)]
Axe unused function.

18 years agoMFp4: Small cleanup of cpu messages at boot.
imp [Fri, 3 Feb 2006 06:39:57 +0000 (06:39 +0000)]
MFp4: Small cleanup of cpu messages at boot.

18 years agoMerge from p4: minor formatting nits.
imp [Fri, 3 Feb 2006 06:27:51 +0000 (06:27 +0000)]
Merge from p4: minor formatting nits.

18 years agoAllow newer config versions to config older versions with the same
imp [Fri, 3 Feb 2006 06:12:10 +0000 (06:12 +0000)]
Allow newer config versions to config older versions with the same
major number.

Reviewed by: ru@, jhb@, arch@ (a few months ago)

# this is subject to refinement based on experience.

18 years agoMFi386:
davidxu [Fri, 3 Feb 2006 02:49:14 +0000 (02:49 +0000)]
MFi386:
Clear carry flag in get_mconetxt so that setcontext does not
return a bogus error.

18 years agoClear carry flag in get_mcontext so that setcontext does not
davidxu [Fri, 3 Feb 2006 02:33:01 +0000 (02:33 +0000)]
Clear carry flag in get_mcontext so that setcontext does not
return a bogus error.

PR: misc/92110

18 years ago- Add a startup script for hostapd.
flz [Fri, 3 Feb 2006 01:35:36 +0000 (01:35 +0000)]
- Add a startup script for hostapd.
- Document associated variable in rc.conf(5).

Approved by: dougb
MFC after: 1 week

18 years ago!$(*&!($!&$(!&$&(!$(&!&($!($
mjacob [Fri, 3 Feb 2006 00:36:19 +0000 (00:36 +0000)]
!$(*&!($!&$(!&$&(!$(&!&($!($

Forget to commit this.

18 years agoMake PV entries dynamic on amd64. i386 has a pre-reserved block of kva
peter [Fri, 3 Feb 2006 00:16:36 +0000 (00:16 +0000)]
Make PV entries dynamic on amd64.  i386 has a pre-reserved block of kva
dedicated to storing pv entries, originally so that kva didn't have to be
allocated at inconvenient times.  For amd64, we can get the same effect by
using the direct map area.  Allocating pages is the same as with the object
backed method, but now we can just lookup the page in the direct map area.
Thus, no more pageable kva is reserved.  This is the single largest
consumer of kva on our work machines and this change should help conserve
the fixed size 2GB pageable kva on the amd64 kernel.

There are a pair of sysctl nodes introduced, named the same as their
tunable counterparts.  vm.pmap.shpgperproc and vm.pmap.pv_entry_max
They work just like the tunables of the same path, except the values are
linked.  The pv entry cap is now dynamically changeable.

I didn't make them totally unlimited because we need some sort of safety
limit still.  One could consume all physical memory without a cap.

18 years agoIf the device has a PNPID, don't bother to attach. There were some
imp [Thu, 2 Feb 2006 23:57:31 +0000 (23:57 +0000)]
If the device has a PNPID, don't bother to attach.  There were some
instances where the probe that was here would falsely grab a device.

18 years agoRemove devices acpi & mem, as they are in defaults already.
marcel [Thu, 2 Feb 2006 23:41:08 +0000 (23:41 +0000)]
Remove devices acpi & mem, as they are in defaults already.

18 years agoIn vlan_config() first call vlan_inithash(), then lock mutex, because
glebius [Thu, 2 Feb 2006 22:11:38 +0000 (22:11 +0000)]
In vlan_config() first call vlan_inithash(), then lock mutex, because
vlan_inithash() calls malloc(M_WAITOK).

18 years agoAdjust old comment (present in rev 1.1) to match changes in rev 1.82.
tegge [Thu, 2 Feb 2006 21:55:38 +0000 (21:55 +0000)]
Adjust old comment (present in rev 1.1) to match changes in rev 1.82.

PR: kern/92509
Submitted by:   "Bryan Venteicher" <bryanv@daemoninthecloset.org>

18 years agoFor low memory situations, non-VMIO buffers didnt't release pages back to
tegge [Thu, 2 Feb 2006 21:37:39 +0000 (21:37 +0000)]
For low memory situations, non-VMIO buffers didnt't release pages back to
the system when brelse() was called with B_RELBUF set on the buffer.  This
could be a problem when the system was low on memory, had many buffers on
QUEUE_EMPTYKVA and started to traverse directories.  For each getnewbuf(),
pages were allocated from the system, driving the free reserve downwards.
For each brelse(), the system put the buffer on QUEUE_CLEAN, with B_INVAL
set.

This commit changes the semantics of B_RELBUF to also free pages from
non-VMIO buffers.

Reviewed by: alc

18 years agoRemove use of inlines and use the functions as a library.
mjacob [Thu, 2 Feb 2006 21:31:34 +0000 (21:31 +0000)]
Remove use of inlines and use the functions as a library.

Larger code space, possibly performance hit, but more portable.
Certainly less questionable use of inlining.

Suggested by: des

18 years agoDon't destroy the slave /dev entry until someone figures out why devfs seems
cognet [Thu, 2 Feb 2006 20:35:45 +0000 (20:35 +0000)]
Don't destroy the slave /dev entry until someone figures out why devfs seems
to behave badly when we do so.

18 years agodefine lock.h before rwlock.h for DEBUG_LOCKS
csjp [Thu, 2 Feb 2006 20:33:10 +0000 (20:33 +0000)]
define lock.h before rwlock.h for DEBUG_LOCKS

18 years agoWhitespace fix.
jhb [Thu, 2 Feb 2006 20:14:52 +0000 (20:14 +0000)]
Whitespace fix.

Submitted by: Wojciech A. Koszek <dunstan at zsno ids czest pl>

18 years agoImplement SIOCGIFCONF for 32bit binaries.
ps [Thu, 2 Feb 2006 19:58:37 +0000 (19:58 +0000)]
Implement SIOCGIFCONF for 32bit binaries.

18 years agoEnable 64bit SGL's on PERC 4/DC
ps [Thu, 2 Feb 2006 17:51:47 +0000 (17:51 +0000)]
Enable 64bit SGL's on PERC 4/DC

18 years ago- Move the command setup from amr_start1 into the card specific submit
ps [Thu, 2 Feb 2006 17:50:59 +0000 (17:50 +0000)]
- Move the command setup from amr_start1 into the card specific submit
  routines.
- Add or replace cpu_spinwait() with DELAY(1) to a few of the busy
  loops when reading from the controller to work around firmware bugs
  which can crash the controller.

18 years agoUse PFIL_HOOKED macros in if_bridge and pass the right argument to
csjp [Thu, 2 Feb 2006 16:41:20 +0000 (16:41 +0000)]
Use PFIL_HOOKED macros in if_bridge and pass the right argument to
rw_assert. This un-breaks the build.

Submitted by: Kostik Belousov
Pointy hat to: csjp

18 years agoCorrect and improve the description of le(4) vs. pcn(4); apparently I
marius [Thu, 2 Feb 2006 14:57:00 +0000 (14:57 +0000)]
Correct and improve the description of le(4) vs. pcn(4); apparently I
was thinking from the pcn(4) perspective instead of the le(4) one when
writing the former version as le(4) supports a superset of the chips
supported by pcn(4) and not the other way round.

18 years agoUnder verbose mode, correctly report L2 cache information
davidxu [Thu, 2 Feb 2006 12:44:09 +0000 (12:44 +0000)]
Under verbose mode, correctly report L2 cache information
for CPU which supports CPUID function 8000_0006h.

Tested on: Pentum-M 750

18 years agoFix bug in L2 cache size detection code for CPU which supports CPUID
davidxu [Thu, 2 Feb 2006 11:54:40 +0000 (11:54 +0000)]
Fix bug in L2 cache size detection code for CPU which supports CPUID
function 8000_0006h.

Tested on: Pentum-M 750

18 years agomake IPV6_V6ONLY socket option work for UDP as well.
ume [Thu, 2 Feb 2006 11:46:05 +0000 (11:46 +0000)]
make IPV6_V6ONLY socket option work for UDP as well.

PR: ports/92620
Reported by: Kurt Miller <kurt__at__intricatesoftware.com>
MFC after: 1 week

18 years agoRemove reference to auditon(8), this tool has been superseded by
rwatson [Thu, 2 Feb 2006 11:14:35 +0000 (11:14 +0000)]
Remove reference to auditon(8), this tool has been superseded by
auditd(8), and was committed in error.

Obtained from: TrustedBSD Project

18 years agoMFi386: Enable the ce(4).
nyan [Thu, 2 Feb 2006 11:14:13 +0000 (11:14 +0000)]
MFi386: Enable the ce(4).

18 years agoAdd audit.4 man page, providing basic documentation for configuring the
rwatson [Thu, 2 Feb 2006 10:32:27 +0000 (10:32 +0000)]
Add audit.4 man page, providing basic documentation for configuring the
kernel audit facility, warnings about the experimental nature of this
implementation, and pointers at a large number of other audit related
man pages.

Obtained from: TrustedBSD Project

18 years agoEnable building of OpenBSM command line tools:
rwatson [Thu, 2 Feb 2006 10:15:30 +0000 (10:15 +0000)]
Enable building of OpenBSM command line tools:

- audit(8) - audit subsystem management tool
- auditd(8) - audit trail and subsystem management daemon
- auditreduce(1) - audit trail reduction tool
- praudit(1) - audit trail printing tool

Could probably use a NO_AUDIT make.conf flag.

Obtained from: TrustedBSD Project

18 years agoAdd libbsm to the library build.
rwatson [Thu, 2 Feb 2006 10:05:39 +0000 (10:05 +0000)]
Add libbsm to the library build.

Obtained from: TrustedBSD Project

18 years agoDefine $LIBBSM.
rwatson [Thu, 2 Feb 2006 10:04:32 +0000 (10:04 +0000)]
Define $LIBBSM.

Obtained from: TrustedBSD Project

18 years agoInstall /etc/security configuration files from OpenBSM.
rwatson [Thu, 2 Feb 2006 10:03:43 +0000 (10:03 +0000)]
Install /etc/security configuration files from OpenBSM.

Obtained from: TrustedBSD Project

18 years agoAdd auditd rc.d script.
rwatson [Thu, 2 Feb 2006 10:02:55 +0000 (10:02 +0000)]
Add auditd rc.d script.

Submitted by: trhodes
Obtained from: TrustedBSD Project

18 years agoAdd auditd_enable and auditd_flags rc.d scripts.
rwatson [Thu, 2 Feb 2006 10:02:19 +0000 (10:02 +0000)]
Add auditd_enable and auditd_flags rc.d scripts.

Obtained from: TrustedBSD Project

18 years agoEnable 'complete' rx checksum offloading (i.e. let chip calculate checksums
oleg [Thu, 2 Feb 2006 09:58:31 +0000 (09:58 +0000)]
Enable 'complete' rx checksum offloading (i.e. let chip calculate checksums
with pseudo header for tcp/udp packets). This could save one in_pseudo() call
per incoming tcp/udp packet.

Approved by: glebius (mentor)
MFC after: 3 weeks

18 years agoMake sure we don't pick up a loopid that's larger than our
mjacob [Thu, 2 Feb 2006 09:02:16 +0000 (09:02 +0000)]
Make sure we don't pick up a loopid that's larger than our
current portdb max (MAX_FC_TARG == 256) now that we support
2K Login f/w.

MFC after: 3 days

18 years ago - textvp may have been from a different mountpoint than ndp->ni_vp and
jeff [Thu, 2 Feb 2006 08:39:39 +0000 (08:39 +0000)]
 - textvp may have been from a different mountpoint than ndp->ni_vp and
   we may need to acquire giant to vrele it.

Found by: mjacob
MFC After: 3 days

18 years agoCorrectly report L2 cache size according to its code comment.
davidxu [Thu, 2 Feb 2006 06:35:50 +0000 (06:35 +0000)]
Correctly report L2 cache size according to its code comment.
Tested on my Dual PIII machine.

18 years agoSomewhat re-factor the read/write locking mechanism associated with the packet
csjp [Thu, 2 Feb 2006 03:13:16 +0000 (03:13 +0000)]
Somewhat re-factor the read/write locking mechanism associated with the packet
filtering mechanisms to use the new rwlock(9) locking API:

- Drop the variables stored in the phil_head structure which were specific to
  conditions and the home rolled read/write locking mechanism.
- Drop some includes which were used for condition variables
- Drop the inline functions, and convert them to macros. Also, move these
  macros into pfil.h
- Move pfil list locking macros intp phil.h as well
- Rename ph_busy_count to ph_nhooks. This variable will represent the number
  of IN/OUT hooks registered with the pfil head structure
- Define PFIL_HOOKED macro which evaluates to true if there are any
  hooks to be ran by pfil_run_hooks
- In the IP/IP6 stacks, change the ph_busy_count comparison to use the new
  PFIL_HOOKED macro.
- Drop optimization in pfil_run_hooks which checks to see if there are any
  hooks to be ran, and returns if not. This check is already performed by the
  IP stacks when they call:

        if (!PFIL_HOOKED(ph))
                goto skip_hooks;

- Drop in assertion which makes sure that the number of hooks never drops
  below 0 for good measure. This in theory should never happen, and if it
  does than there are problems somewhere
- Drop special logic around PFIL_WAITOK because rw_wlock(9) does not sleep
- Drop variables which support home rolled read/write locking mechanism from
  the IPFW firewall chain structure.
- Swap out the read/write firewall chain lock internal to use the rwlock(9)
  API instead of our home rolled version
- Convert the inlined functions to macros

Reviewed by: mlaier, andre, glebius
Thanks to: jhb for the new locking API

18 years agoRegenerate.
rwatson [Thu, 2 Feb 2006 01:45:01 +0000 (01:45 +0000)]
Regenerate.

18 years agoMap audit-related system calls to audit event identifiers.
rwatson [Thu, 2 Feb 2006 01:44:30 +0000 (01:44 +0000)]
Map audit-related system calls to audit event identifiers.

Much work by: wsalamon
Obtained from: TrustedBSD Project

18 years agoHook up audit to fork() and exit() events. These changes manage the
rwatson [Thu, 2 Feb 2006 01:32:58 +0000 (01:32 +0000)]
Hook up audit to fork() and exit() events.  These changes manage the
audit state on processes, not auditing of these events.

Much work by: wsalamon
Obtained from: TrustedBSD Project

18 years agoAdd /var/audit, mode 750, which will hold audit trail files.
rwatson [Thu, 2 Feb 2006 01:19:31 +0000 (01:19 +0000)]
Add /var/audit, mode 750, which will hold audit trail files.

Obtained from: TrustedBSD Project

18 years agoHook up audit to the initial process creation events (proc0, proc1).
rwatson [Thu, 2 Feb 2006 01:16:31 +0000 (01:16 +0000)]
Hook up audit to the initial process creation events (proc0, proc1).

Much help from: wsalamon
Obtained from: TrustedBSD Project

18 years agoAdd new fields to process-related data structures:
rwatson [Thu, 2 Feb 2006 00:37:05 +0000 (00:37 +0000)]
Add new fields to process-related data structures:

- td_ar to struct thread, which holds the in-progress audit record during
  a system call.

- p_au to struct proc, which holds per-process audit state, such as the
  audit identifier, audit terminal, and process audit masks.

In the earlier implementation, td_ar was added to the zero'd section of
struct thread.  In order to facilitate merging to RELENG_6, it has been
moved to the end of the data structure, requiring explicit
initalization in the thread constructor.

Much help from: wsalamon
Obtained from: TrustedBSD Project

18 years agoAdd 'options AUDIT' and associate various .c files with the AUDIT
rwatson [Wed, 1 Feb 2006 21:00:16 +0000 (21:00 +0000)]
Add 'options AUDIT' and associate various .c files with the AUDIT
option.  We always build audit_syscalls.c so that the system call
stubs can return ENOSYS rather than the system call code
generating SIGSYS for the system calls.  We are not yet ready to
add AUDIT to LINT, as the prototypes for system call arguments
won't be there until after the system calls for audit are added.

Much work from: wsalamon
Obtained from: TrustedBSD Project

18 years agoXref rwlock(9).
glebius [Wed, 1 Feb 2006 20:30:55 +0000 (20:30 +0000)]
Xref rwlock(9).

Reviewed by: ru

18 years agoImport kernel audit framework:
rwatson [Wed, 1 Feb 2006 20:01:18 +0000 (20:01 +0000)]
Import kernel audit framework:

- Management of audit state on processes.
- Audit system calls to configure process and system audit state.
- Reliable audit record queue implementation, audit_worker kernel
  thread to asynchronously store records on disk.
- Audit event argument.
- Internal audit data structure -> BSM audit trail conversion library.
- Audit event pre-selection.
- Audit pseudo-device permitting kernel->user upcalls to notify auditd
  of kernel audit events.

Much work by: wsalamon
Obtained from: TrustedBSD Project, Apple Computer, Inc.

18 years agoUpdate src/sys/bsm include files to match OpenBSM (albeit with a
rwatson [Wed, 1 Feb 2006 19:54:22 +0000 (19:54 +0000)]
Update src/sys/bsm include files to match OpenBSM (albeit with a
couple of FreeBSD-specific modifications that may be merged out
later).  These include files define the basic audit data
structures, types, and definitions use by the kernel, or shared
by the kernel and user space.

Obtained from: TrustedBSD Project, Apple Computer, Inc.

18 years agoDocument read/write locks.
glebius [Wed, 1 Feb 2006 19:39:25 +0000 (19:39 +0000)]
Document read/write locks.

Reviewed by: jhb, ru

18 years agoDon't add an agp child in vgapci's attach routine if the PCIY_AGP
jhb [Wed, 1 Feb 2006 15:45:29 +0000 (15:45 +0000)]
Don't add an agp child in vgapci's attach routine if the PCIY_AGP
capability is present as not all devices supported by the agp_i810 driver
(such as i915) have the AGP capability.  Instead, add an identify routine
to the agp_i810 driver that uses the PCI ID to determine if it should
create an agp child device.

18 years agoAdd regression tests which will verify that giving no key components for
pjd [Wed, 1 Feb 2006 15:17:45 +0000 (15:17 +0000)]
Add regression tests which will verify that giving no key components for
init/attach/setkey subcommands is really impossible.

MFC after: 3 days

18 years agoOptimize bge_rxeof() & bge_txeof(): return immediately if there are no packets
oleg [Wed, 1 Feb 2006 15:16:03 +0000 (15:16 +0000)]
Optimize bge_rxeof() & bge_txeof(): return immediately if there are no packets
to process. It could give us [significant?] perfomance increase if there is big
difference between RX/TX flows.

Submitted by: Mihail Balikov <mihail.balikov AT interbgc DOT com>
Approved by: glebius (mentor)
MFC after: 3 days

18 years agoDeny init/attach/setkey subcommands when no key components are given.
pjd [Wed, 1 Feb 2006 15:01:55 +0000 (15:01 +0000)]
Deny init/attach/setkey subcommands when no key components are given.

MFC after: 3 days
Tested with: prove /usr/src/tools/regression/geom_eli

18 years agoSince bge_rxeof() & bge_txeof() depends on status block data it should be
oleg [Wed, 1 Feb 2006 14:41:08 +0000 (14:41 +0000)]
Since bge_rxeof() & bge_txeof() depends on status block data it should be
synchronized on every call of bge_poll_locked().

Suggested by: Mihail Balikov <mihail.balikov AT interbgc DOT com>
Approved by: glebius (mentor)
MFC after: 3 days

18 years agoExpand contractions.
joel [Wed, 1 Feb 2006 14:33:14 +0000 (14:33 +0000)]
Expand contractions.

18 years ago1) Fix link state detection for cards operating in TBI mode (fiber ones)
oleg [Wed, 1 Feb 2006 14:26:35 +0000 (14:26 +0000)]
1) Fix link state detection for cards operating in TBI mode (fiber ones)
2) add missing bus_dmamap_sync() call in bge_intr()

Tested by: Husnu Demir <hdemir AT metu DOT edu DOT tr>
Approved by: glebius (mentor)
MFC after: 3 days

18 years agoMove the IPSEC related code blocks to their own file to unclutter
andre [Wed, 1 Feb 2006 13:55:03 +0000 (13:55 +0000)]
Move the IPSEC related code blocks to their own file to unclutter
and signifincantly improve the readability of ip_input() and
ip_output() again.

The resulting IPSEC hooks in ip_input() and ip_output() may be
used later on for making IPSEC loadable.

This move is mostly mechanical and should preserve current IPSEC
behaviour as-is.  Nothing shall prevent improvements in the way
IPSEC interacts with the IPv4 stack.

Discussed with: bz, gnn, rwatson; (earlier version)

18 years agoRecord the change in vnone_create_vobject() argument size,
yar [Wed, 1 Feb 2006 13:04:52 +0000 (13:04 +0000)]
Record the change in vnone_create_vobject() argument size,
which broke kernel ABI to filesystem modules on i386, where
sizeof(size_t) != sizeof(off_t).

18 years agoUse off_t for file size passed to vnode_create_vobject().
yar [Wed, 1 Feb 2006 12:43:13 +0000 (12:43 +0000)]
Use off_t for file size passed to vnode_create_vobject().
The former type, size_t, was causing truncation to 32 bits on i386,
which immediately led to undersizing of VM objects backed by
files >4GB.  In particular, sendfile(2) was broken for such files.

PR: kern/92243
MFC after: 5 days

18 years agoRemove trailing spaces.
pjd [Wed, 1 Feb 2006 12:11:37 +0000 (12:11 +0000)]
Remove trailing spaces.

18 years agoRemove trailing spaces.
pjd [Wed, 1 Feb 2006 12:06:01 +0000 (12:06 +0000)]
Remove trailing spaces.

18 years agoRemove unsupported hardware.
nyan [Wed, 1 Feb 2006 11:10:38 +0000 (11:10 +0000)]
Remove unsupported hardware.

X-MFC after: soon

18 years agoSetting IFF_ALLMULTI on a running interface didn't call bge_setmulti()
ru [Wed, 1 Feb 2006 10:11:24 +0000 (10:11 +0000)]
Setting IFF_ALLMULTI on a running interface didn't call bge_setmulti()
as intended, resulting in a non-working multicast routing.  Fix it.

MFC after: 3 days

18 years ago - Install a temporary bandaid in vm_object_reference() that will stop
jeff [Wed, 1 Feb 2006 09:47:02 +0000 (09:47 +0000)]
 - Install a temporary bandaid in vm_object_reference() that will stop
   mtx_assert()s from triggering until I find a real long-term solution.

18 years ago - Solve a problem where a vput could be called on an outgoing directory
jeff [Wed, 1 Feb 2006 09:34:32 +0000 (09:34 +0000)]
 - Solve a problem where a vput could be called on an outgoing directory
   without Giant held.  Do this by tracking the vfslocked state for
   the directory seperate from the child.  This is only important
   in the case where we cross a mountpoint.

Sponsored by: Isilon Systems, Inc.
MFC After: 3 days

18 years ago - chroot and chdir need to lock giant as appropriate for the outgoing vp
jeff [Wed, 1 Feb 2006 09:30:44 +0000 (09:30 +0000)]
 - chroot and chdir need to lock giant as appropriate for the outgoing vp
   as well as the new vp.

Sponsored by: Isilon Systems, Inc.
MFC After: 3 days

18 years agoBrain-o (use standard int types now).
ru [Wed, 1 Feb 2006 06:15:37 +0000 (06:15 +0000)]
Brain-o (use standard int types now).

18 years agoFix another compile problem. If I find any more, this file is going in the
scottl [Wed, 1 Feb 2006 04:18:07 +0000 (04:18 +0000)]
Fix another compile problem.  If I find any more, this file is going in the
Attic until it is properly fixed.

18 years ago - Solve a race where we could lose a call to VOP_INACTIVE. If vget() waiting
jeff [Wed, 1 Feb 2006 00:30:05 +0000 (00:30 +0000)]
 - Solve a race where we could lose a call to VOP_INACTIVE.  If vget() waiting
   on a lock held the last usecount ref on a vnode and the lock failed we
   would not call INACTIVE.  Solve this by only holding a holdcnt to prevent
   the vnode from disappearing while we wait on vn_lock.  Other callers
   may now VOP_INACTIVE while we are waiting on the lock, however this race
   is acceptable, while losing INACTIVE is not.

Discussed with: kan, pjd
Tested by: kkenn
Sponsored by: Isilon Systems, Inc.
MFC After: 1 week