Andre Oppermann [Wed, 4 May 2005 13:48:44 +0000 (13:48 +0000)]
If we don't get a suggested MTU during path MTU discovery
look up the packet size of the packet that generated the
response, step down the MTU by one step through ip_next_mtu()
and try again.
Hajimu UMEMOTO [Wed, 4 May 2005 12:02:10 +0000 (12:02 +0000)]
- add $FreeBSD$.
- do service lookup.
- add options to use gethostbyname(3) or getipnodebyname(3) instead
of getaddrinfo(3).
- add option to do reverse lookup.
Document the fact that accept(2) may return EINVAL when addrlen is
negative (in addition to returning EINVAL when called on a descriptor
that is not a socket).
Submitted by: Arne H Juul <arnej@europe.yahoo-inc.com>
PR: docs/80587
Robert Watson [Wed, 4 May 2005 10:39:15 +0000 (10:39 +0000)]
Introduce MAC Framework and MAC Policy entry points to label and control
access to POSIX Semaphores:
mac_init_posix_sem() Initialize label for POSIX semaphore
mac_create_posix_sem() Create POSIX semaphore
mac_destroy_posix_sem() Destroy POSIX semaphore
mac_check_posix_sem_destroy() Check whether semaphore may be destroyed
mac_check_posix_sem_getvalue() Check whether semaphore may be queried
mac_check_possix_sem_open() Check whether semaphore may be opened
mac_check_posix_sem_post() Check whether semaphore may be posted to
mac_check_posix_sem_unlink() Check whether semaphore may be unlinked
mac_check_posix_sem_wait() Check whether may wait on semaphore
Update Biba, MLS, Stub, and Test policies to implement these entry points.
For information flow policies, most semaphore operations are effectively
read/write.
The correct description for mode "w" is
(((truncate to zero length) or (create)) (text file)) (for writing)
and not
((truncate file to zero length) or (create text file)) (for writing)
Robert Watson [Tue, 3 May 2005 20:21:24 +0000 (20:21 +0000)]
Move definitions of 'struct kuser' and 'struct ksem' from uipc_sem.c
to ksem.h so that they are accessible from the MAC Framework for the
purposes of labeling and enforcing additional protections. #error
if these are included without _KERNEL, since they are not intended
(nor installed) for user application use.
Xin LI [Tue, 3 May 2005 16:20:03 +0000 (16:20 +0000)]
Cleanup for getgrouplist(3):
- Use /*- instead of /* for copyright section
- Include unistd.h for prototype of it
- Sort and separate includes as described in style(9)
- ANSIfy the function defination
- Use const for the traversing iterator
Peter Grehan [Tue, 3 May 2005 11:56:05 +0000 (11:56 +0000)]
- move to SCHED_4BSD per jeffr's comments on SCHED_ULE's state
- enable MSDOSFS
- ehci is stable on the powerbook
- modules have been working for a long time.
Jeff Roberson [Tue, 3 May 2005 11:11:26 +0000 (11:11 +0000)]
- Add a new object flag "OBJ_NEEDSGIANT". We set this flag if the
underlying vnode requires Giant.
- In vm_fault only acquire Giant if the underlying object has NEEDSGIANT
set.
- In vm_object_shadow inherit the NEEDSGIANT flag from the backing object.
Jeff Roberson [Tue, 3 May 2005 11:05:33 +0000 (11:05 +0000)]
- Set the v_object pointer after a successful VOP_OPEN(). This isn't a
perfect solution as the lower vm object can change at unpredictable times
if our lower vp happens to be on another unionfs, etc.
Jeff Roberson [Tue, 3 May 2005 11:03:29 +0000 (11:03 +0000)]
- Don't restrict the softdep stats to DEBUG kernels, they cost nothing to
export. This was happening anyway since this file manually sets DEBUG.
- Add a sysctl for the number of items on the worklist.
- Use a more canonical loop restart in softdep_fsync_mountdev, it saves
some code at the expense of a goto and makes me worry less about
modifying a variable that should be private to the TAILQ_FOREACH_SAFE
macro.
Jeff Roberson [Tue, 3 May 2005 10:58:05 +0000 (10:58 +0000)]
- Remove two mtx_asserts that can incorrectly trigger if
devstat_end_transaction is called from a fast interrupt. Presently
there is no way for mtx_assert to determine that we're not executing
in a real thread context.
Jeff Roberson [Tue, 3 May 2005 10:56:00 +0000 (10:56 +0000)]
- A vnode may have made its way onto the free list while it was being
vgone'd. We must remove it from the freelist before returning in
vtryrecycle() or we may get a duplicate free.
Jeff Roberson [Tue, 3 May 2005 10:55:05 +0000 (10:55 +0000)]
- Use namei to acquire Giant for VFS if it is necessary. Drop the explicit
Giant acquisition.
- Remove GIANT_REQUIRED in the few remaining cases; the vm and vfs have
both been locked.
Søren Schmidt [Tue, 3 May 2005 07:55:07 +0000 (07:55 +0000)]
Reshape the dma code to be a bit more flexible so it can cope with
new HW that has new and different demands.
Fix a few nits in former commit in this cleanup crusade.
Scott Long [Tue, 3 May 2005 07:11:19 +0000 (07:11 +0000)]
Properly mask off the status bits when checking to see if the ccb is still
valid to process. This was causing deferred commands to be rejected due
to their extra status flag.
Scott Long [Tue, 3 May 2005 05:44:42 +0000 (05:44 +0000)]
The driver looks like it can create valid 64-bit scatter-gather lists, so
don't restrict it to a 32-bit address space. Also use the correct busdma
flags for the SRB memory area.
Remove only the packages sub-directory before recreating it. Do not
remove the whole disc treei structure. This allows one to specify the
disc trees created by a prior release build (under R/cdrom) as the
destination without destroying the contents. This better integrates
with release building and makes further automation easier.
Allow specifying which INDEX file to use by setting PKG_INDEX. By default
the INDEX file is taken from the package source tree as defined by the
PKG_TREE variable. This change allows using the (possibly incomplete)
packages on pointyhat.
Ian Dowse [Mon, 2 May 2005 15:57:10 +0000 (15:57 +0000)]
Don't copy the NFSMNT_* flags into struct statfs's f_flags field,
as they have no connection with the expected MNT_* flags. This bug
was exposed 18 months ago when the assignments to f_flags in
vfs_syscalls.c were moved to before the VFS_STATFS() call. It was
fixed in the CSRG source 10 years ago, but we never picked up that
change.
Hajimu UMEMOTO [Mon, 2 May 2005 11:19:52 +0000 (11:19 +0000)]
add targets for ipnodes.byname and ipnodes.byaddr which carries
IPv6 addresses. these targets are off by default, and these
are built when there is /var/yp/ipnodes.
Since it is not possible for curthread to be NULL in this context,
drop the check+initialization for a straight initialization. Also
assert that curthread will never be NULL just to be sure.
Joseph Koshy [Sun, 1 May 2005 14:11:49 +0000 (14:11 +0000)]
Add convenience APIs pmc_width() and pmc_capabilities() to -lpmc.
Have pmcstat(8) and pmccontrol(8) use these APIs.
Return PMC class-related constants (PMC widths and capabilities)
with the OP GETCPUINFO call leaving OP PMCINFO to return only the
dynamic information associated with a PMC (i.e., whether enabled,
owner pid, reload count etc.).
Allow pmc_read() (i.e., OPS PMCRW) on active self-attached PMCs to
get upto-date values from hardware since we can guarantee that the
hardware is running the correct PMC at the time of the call.
Bug fixes:
- (x86 class processors) Fix a bug that prevented an RDPMC
instruction from being recognized as permitted till after the
attached process had context switched out and back in again after
a pmc_start() call.
Tighten the rules for using RDPMC class instructions: a GETMSR
OP is now allowed only after an OP ATTACH has been done by the
PMC's owner to itself. OP GETMSR is not allowed for PMCs that
track descendants, for PMCs attached to processes other than
their owner processes.
- (P4/HTT processors only) Fix a bug that caused the MI and MD
layers to get out of sync. Add a new MD operation 'get_config()'
as part of this fix.
- Allow multiple system-mode PMCs at the same row-index but on
different CPUs to be allocated.
- Reject allocation of an administratively disabled PMC.
Misc. code cleanups and refactoring. Improve a few comments.
Søren Schmidt [Sun, 1 May 2005 12:24:45 +0000 (12:24 +0000)]
Update on the last commit, the dma* funciton needs to be called with
a channel device, not an ata device, or we'll be out of luck in
reset/timeout where we dont have a device.
Jeff Roberson [Sun, 1 May 2005 12:00:36 +0000 (12:00 +0000)]
- All buffers should either be clean or dirty. If neither of these flags
are set when we attempt to remove a buffer from a queue we should panic.
Hopefully this will catch the source of the wrong bufobj panics.
Robert Watson [Sun, 1 May 2005 11:11:38 +0000 (11:11 +0000)]
Slide unlocking of the tcbinfo lock earlier in tcp_usr_send(), as it's
needed only for implicit connect cases. Under load, especially on SMP,
this can greatly reduce contention on the tcbinfo lock.
NB: Ambiguities about the state of so_pcb need to be resolved so that
all use of the tcbinfo lock in non-implicit connection cases can be
eliminated.
Submited by: Kazuaki Oda <kaakun at highway dot ne dot jp>