Commit Graph

128383 Commits

Author SHA1 Message Date
kientzle
925ac6f1b9 Minor cleanup of the standard read/write I/O modules:
* Use public API, don't access struct archive directly.  (People should be able to copy these into their applications as a template for custom I/O callbacks.)
 * Set "skip" only for regular files.  ("skip" allows the low-level library to catch attempts to add an archive to itself or extract over itself.)
 * Simplify the write_open functions by just calling stat() at the beginning.  Somehow, these functions had acquired some complex logic that tried to avoid the stat() call but never succeeded.

MFC after: 10 days
2006-11-13 00:26:45 +00:00
kientzle
7f111df028 Correctly handle writing very large blocks (>1M) through to a disk
file.  This doesn't happen in normal use, because the file I/O and
decompression layers only pass through smaller blocks.  It can happen
with custom read functions that block I/O in larger blocks.
2006-11-12 23:45:40 +00:00
kmacy
e9b95a7ee6 Unbreak witness 2006-11-12 23:23:38 +00:00
ceri
ef66e595ff Correct typos in comments. 2006-11-12 23:16:31 +00:00
alc
6093953d36 Make pmap_enter() responsible for setting PG_WRITEABLE instead
of its caller.  (As a beneficial side-effect, a high-contention
acquisition of the page queues lock in vm_fault() is eliminated.)
2006-11-12 21:48:34 +00:00
joel
68445c77f7 Change authors e-mail.
Requested by:	Niclas Zeising
2006-11-12 21:43:21 +00:00
andre
855a36d5a0 In kern_sendfile() fix the calculation of sbytes (the total number of bytes
written to the socket).  The rewrite in revision 1.240 got confused by the
FreeBSD 4.x bug compatibility code.

For some reason lighttpd, that was used for testing the new sendfile code,
was not affected by the problem but apache and others using headers/trailers
in the sendfile call received incorrect sbytes values after return from non-
blocking sockets.  This then lead to restarts with wrong offsets and thus
mixed up file contents when the socket was writeable again.  All programs
not using headers/trailers, like ftpd, were not affected by the bug.

Reported by:	Pawel Worach <pawel.worach-at-gmail.com>
Tested by:	Pawel Worach <pawel.worach-at-gmail.com>
2006-11-12 20:57:00 +00:00
keramida
9c9a9d1af8 In revision 1.14 I broke the -4 and -6 options of sockstat(1).
Using either one of the two would result in an empty protos[]
array, and no sockets were actually listed:

  % sockstat -4
  USER     COMMAND    PID   FD PROTO  LOCAL ADDRESS         FOREIGN ADDRESS
  % sockstat -6
  USER     COMMAND    PID   FD PROTO  LOCAL ADDRESS         FOREIGN ADDRESS
  %

Fix this bug by tweaking appropriately the logic of handling opt_4,
opt_6, opt_u and protos_defined.

Submitted by:	des
Pointy hat:	keramida
2006-11-12 19:03:39 +00:00
jkoshy
1d082af7af - Replace the use of DPSRCS with something more appropriate. DPSRCS
is for when you need something in ".depend", but not compiled in.
- Style fixes: Spell ${.OBJDIR} as ".".
- Neaten a comment.

Submitted by:	ru
2006-11-12 18:43:25 +00:00
bz
645d5f3a2d Remove some comments about NetBSD. This in on FreeBSD and we do not
want to confuse people at the very beginning.
Sync TOC/paragraph numbers in the text.

Requested by: Benedikt Stockebrand during his talk at EuroBSDCon 2006
Reviewed by: gnn
2006-11-12 18:38:07 +00:00
ume
123b22cab4 Teach an IPV6CP to pppd(8).
The eui64.[ch] and ipv6cp.[ch] were taken from ppp-2.3.11.
However, our stock pppd(8) doesn't provide option_t nor some
utility functions.  So, I made some hacks to adjust to our
stock pppd(8).
The sys_bsd.c part was taken from NetBSD with some
modifications to adjust to our stock pppd(8).

MFC after:	1 week
2006-11-12 17:36:58 +00:00
ume
ec7b0d883d This commit was generated by cvs2svn to compensate for changes in r164219,
which included commits to RCS files with non-trunk default branches.
2006-11-12 17:13:45 +00:00
ume
d2ffeffe58 Import eui64.[ch] and ipv6cp.[ch] of ppp-2.3.11 2006-11-12 17:13:45 +00:00
ache
0f6ab68217 Back out 1.120, it was premature. 2006-11-12 12:02:34 +00:00
davidxu
c2eeccb29d Copy base user priority in NO_KSE case. 2006-11-12 11:48:37 +00:00
kmacy
fd154b4735 GRRRRR - missed this in the last commit 2006-11-12 05:16:28 +00:00
trhodes
892aec9079 Fix mispatch of includes list; allows my kernel to build successfully. 2006-11-12 03:34:03 +00:00
kmacy
b082a8c58a show lock class in profiling output for default case where type is not specified when initializing the lock
Approved by: scottl (standing in for mentor rwatson)
2006-11-12 03:30:01 +00:00
davidxu
0c1c40362e Use mi_switch, this should fix loadavg calculation problem in NO_KSE case. 2006-11-12 03:18:22 +00:00
kmacy
edb2ddd470 Support up to 4 nucleus mappings to workaround issue hit by jb@ when booted
off of CD
2006-11-12 01:21:15 +00:00
flz
4de66d3a13 Fix USB printer Xerox WorkCentre M15 adding a quirk to bypass
reported bidirectional functionality.

PR:		usb/104704
Submitted by:	Eygene <rea-fbsd@codelabs.ru>
X-MFC after:	6.2-RELEASE
2006-11-11 23:53:25 +00:00
ru
67baed290f More MUTEX_PROFILING -> LOCK_PROFILING. 2006-11-11 23:37:52 +00:00
des
c2c5b4471a Back out 1.122, it was poorly thought out. 2006-11-11 23:26:08 +00:00
ru
00ea8ac1d7 Enforce RELEASENOUPDATE if EXTSRCDIR is used.
Suggested by:	jb
2006-11-11 23:18:28 +00:00
rrs
fb5651e047 In a true restart case, the send_lock was
not being aquired. This meant that when we cleanup
the outbound we may have one in transit to be
added with the old sequence number. This is bad
since then we loose a message :(

Also the report_outbound needed to have the right
lock when its called which it did not.. I added
the lock with of course a flag since we want to
have the lock before we call it in the restart
case.

This also fixed the FIX ME case where, in the cookie
collision case, we mark for retransmit any that
were bundled with the cookie that was dropped.
This also means changes to the output routine
so we can assure getting the COOKIE-ACK sent
BEFORE we retransmit the Data.

Approved by:	gnn
2006-11-11 22:44:12 +00:00
kris
26d0f2fab6 Request pre-commit review of BSD.{local,x11*}.dist by portmgr, since these
files interface with ports and we have policies for how/when they should be
updated.
2006-11-11 22:24:10 +00:00
des
e013709c26 Back out 1.121, it was premature. 2006-11-11 22:23:49 +00:00
keramida
e996b3d302 Add support for filtering sockets by protocol type. The default
behavior of sockstat(1) will still be to show "udp", "tcp" and
"divert" protocols, but we can now provide a (comma-separated)
list of protocols, as in:

    % sockstat -P tcp

to list only TCP sockets, or we can filter more than one protocol
by separating the protocol names with a comma:

    % sockstat -P tcp,udp

Protocol names are parsed with getprotobyname(3), so any protocol
whose name is listed in `/etc/protocols' should work fine.

Submitted by:	Josh Carroll <josh.carroll@psualum.com>
Approved by:	des
2006-11-11 22:11:54 +00:00
ru
75b8db1b1a Regen (cosmetics in sys/sysproto.h). 2006-11-11 22:01:25 +00:00
ru
855678e70f Regen.
Forgotten by:	trhodes
2006-11-11 21:49:08 +00:00
alc
760248140c Eliminate unused global variables. 2006-11-11 20:57:52 +00:00
bmah
5f23105869 New release note: ping(8) -W (+MFC).
MFCs noted:  fsdb(8) btime, zlib 1.2.3.
2006-11-11 19:12:52 +00:00
brueffer
fadcaca7d2 New release notes:
if_bridge(4) RSTP support.
2006-11-11 19:06:30 +00:00
maxim
90c11a6b82 o Indent by tab. 2006-11-11 18:45:20 +00:00
maxim
42ff530d83 o Add several regression tests for dup(2), dup2(2) and fcntl(F_DUPFD).
Obtained from:	OpenBSD
2006-11-11 18:32:50 +00:00
jkoshy
62913629e6 MFP4: Add an implementation of the ELF(3) and GELF(3) API set.
Bump __FreeBSD_version.

Reviewed by:	jb
2006-11-11 17:16:35 +00:00
trhodes
c51a2c2df9 Re-enable module build for POSIX semaphores.
Update the manual page describe loading the sem module.

Approved by:	silence on -arch and -standards
2006-11-11 16:49:29 +00:00
trhodes
e4ae9746ec Update includes for sys/posix4 move.
Approved by:	silence on -arch and -standards
2006-11-11 16:46:31 +00:00
bmah
e427fa9d2c New release notes: SCTP, TSO, sun4v, ppp(4) IPv6 support, KSE a
kernel option.

Updated release notes:  OpenSSH 4.5p1.
2006-11-11 16:36:03 +00:00
trhodes
6b2b9d447d These files have been repo-copied to the "normal" kernel hierarchy. 2006-11-11 16:29:38 +00:00
trhodes
9023317312 Merge sys/posix4/sched.h into sys/sched.h.
Approved by:	silence on -arch and -standards
2006-11-11 16:27:52 +00:00
trhodes
58cca8458a Merge posix4/* into normal kernel hierarchy.
Reviewed by:	glanced at by jhb
Approved by:	silence on -arch@ and -standards@
2006-11-11 16:26:58 +00:00
trhodes
2d45fdc244 Update #includes list. 2006-11-11 16:19:12 +00:00
trhodes
de549f2a95 Forced commit to note that these files have been repo-copied from
src/sys/posix4/.

Repo-copy done by:	kuriyama
2006-11-11 16:15:35 +00:00
rrs
e0c50feae8 Turns out we would reset the TSN seq counter during
a colliding INIT. This if fine except when we have
data outstanding... we basically reset it to the
previous value it was.. so then we end up assigning
the same TSN to two different data chunks.
This patch:

1) Finds a missing lock for when we change the stream
   numbers during COOKIE and INIT-ACK processing.. we
   were NOT locking the send_buffer.. which COULD cause
   problems (found by inspection looking for <2>)

2) Fixes a case during a colliding INIT where we incorrectly
   reset the sending Sequence thus in some cases duplicately
   assigning a TSN.

3) Additional enhancments to logging so we can see strm/tsn in
   the receiver AND new tracking to watch what the sender
   is doing with TSN and STRM seq's.

Approved by:	gnn
2006-11-11 15:59:01 +00:00
ume
0100d343f4 Teach an IPv6 to ppp(4).
Obtained from:	NetBSD
MFC after:	1 week
2006-11-11 15:02:04 +00:00
davidxu
01440ba848 define UMUTEX_CONTESTED as an unsigned integer. 2006-11-11 14:00:39 +00:00
davidxu
cc0840138e Move code calculating new inherited priority into single function. 2006-11-11 13:33:47 +00:00
davidxu
8cc5d384d8 Unbreak userland priority inheriting in NO_KSE case. 2006-11-11 13:11:29 +00:00
ceri
899b88ba12 Remove a warning regarding disk entries in /dev.
Approved by:	ru (mentor)
MFC after:	4 days
2006-11-11 12:59:59 +00:00