Commit Graph

129950 Commits

Author SHA1 Message Date
Xin LI
7868ee24d3 While we do not expect any change before and after GNU gzip
is replaced with BSD gzip, let's make it possible to
distinguish between the two with a __FreeBSDversion bump,
just in case some developers want it.

Suggested by:	linimon
2007-01-26 14:57:17 +00:00
Craig Rodrigues
37518a88fb If nmount() fails to export a directory, in the syslog() error message,
add the errmsg string returned by nmount().
2007-01-26 13:26:43 +00:00
Xin LI
29e2b723d4 Regen. 2007-01-26 10:20:59 +00:00
Xin LI
9a9ea25f4a Replace the GNU gzip with a slightly modified NetBSD gzip. The
NetBSD version is a feature-to-feature re-implementation of GNU
gzip using the freely-redistributable zlib and this version is
expected to be mostly bug-to-bug compatible with the GNU
implementation.

 - Because this is a piece of mature code and we want to make
   changes so it is added directly rather than importing to
   src/contrib.
 - Connect newly added code to src/usr.bin/ and rescue/rescue
   build.
 - Disconnect the GNU gzip code from build for now, they will
   be eventually removed completely.
 - Provide two new src.conf(5) knobs, WITHOUT_BZIP2_SUPPORT and
   WITHOUT_BZIP2.

Tested by:	kris (full exp-7 pointyhat build)
Approved by:	core (importing a 4-clause BSD licensed file)
Approved by:	re (adding new utility during -HEAD code slush)
2007-01-26 10:19:08 +00:00
Marcel Moolenaar
d62866b236 o Remove screen, created by the unnecessary ofw_console(4)
o  Remove ttyyX, created by the obsolete zs(4)
o  Replace ttydX by ttyuX, which is created by uart(4)
o  Enable ttyu0 as a console to better support the xserve.

MFC after: 1 week
2007-01-26 06:22:34 +00:00
Marcel Moolenaar
500a5696d4 Remove stale header.
MFC after: 3 days
2007-01-26 04:58:31 +00:00
Kevin Lo
27864bcad8 Fix comments.
Approved by: cognet
2007-01-26 01:37:32 +00:00
Jeff Roberson
fc3a97dcb7 - Implement much more intelligent ipi sending. This algorithm tries to
minimize IPIs and rescheduling when scheduling like tasks while keeping
   latency low for important threads.
   1) An idle thread is running.
   2) The current thread is worse than realtime and the new thread is
      better than realtime.  Realtime to realtime doesn't preempt.
   3) The new thread's priority is less than the threshold.
2007-01-25 23:51:59 +00:00
Peter Wemm
45a5e03456 List obsolete objformat files and man pages. This may have to be
revisited if too much stuff breaks.
2007-01-25 23:13:55 +00:00
Peter Wemm
ed0cfa6ecc Bah. Kris says the default-to-a.out knowledge has migrated into the
official gnu configure scripts and a couple of other places.

Add an example noisy, loud and annoying placeholder for /usr/bin/objformat
if it turns out to too much trouble to be gone.  It is not connected to
the build yet.
2007-01-25 23:12:19 +00:00
Peter Wemm
b7696cdf60 Remove unused reference to objformat.h 2007-01-25 22:38:58 +00:00
Peter Wemm
401a7f6f1b Oops, remove an objformat.h reference. 2007-01-25 22:38:04 +00:00
Peter Wemm
1fc6f17a31 Remove getobjformat() from libc's symbol map. It probably should have been
in the private area anyway.  Nothing in FreeBSD uses it any more anyway.
2007-01-25 22:36:36 +00:00
Peter Wemm
8182cee74a Remove more a.out strays, as threatened in 2002. 2007-01-25 22:34:22 +00:00
Peter Wemm
64f133292a Retire objformat(1) as threatened in 2002.
Laughed-at-by:  kris
2007-01-25 22:26:41 +00:00
Peter Wemm
cddf85e01e Retire more remnants of a.out support, as threatened in 2002.
Laughed-at-by:  kris
2007-01-25 22:25:59 +00:00
Gleb Smirnoff
39c14742d9 - Create ng_ppp_bypass() function, that prepares a packet
with bypass header, to send it out to userland.
- Use ng_ppp_bypass() in ng_ppp_proto_recv().
- Use ng_ppp_bypass() in ng_ppp_comp_recv() and in
  ng_ppp_crypt_recv() if compression or encryption is
  disabled, respectively.
- Any LCP packet goes directly to ng_ppp_bypass(), instead
  of passing through PPP stack.
- Any non-LCP packet on disabled link is discarded. This
  is behavior defined in RFC.

Submitted by:	Alexander Motin <mav alkar.net>
2007-01-25 21:16:50 +00:00
Maksim Yevmenkin
0a314f7c39 Add "server mode" to rfcomm_sppd(1).
Submitted by:	Dave Eckhardt, bms
Tested by:	Dave Eckhardt, Eric Anderson, bms
2007-01-25 20:54:59 +00:00
Pawel Jakub Dawidek
b20669bdef MFp4: - When new object is created, it's group ID can be set to process'
effective group ID or to group ID of its parent directory.
	- Add some comments from POSIX.
	- Verify that after successful O_TRUNC open, size is equal to 0.
2007-01-25 20:50:02 +00:00
Pawel Jakub Dawidek
33e0d352b2 MFp4: When user is not a member of the group which owns a file, even if
he is the file's owner, he can't set set-gid bit.
	POSIX requires to return 0 and clear the bit, but FreeBSD returns
	EPERM for UFS in such case. For now do the same in ZFS.
2007-01-25 20:48:14 +00:00
Mike Pritchard
d3caf029b5 Bump .Dd. 2007-01-25 19:54:03 +00:00
Jeff Roberson
1461899028 - Get rid of the unused DIDRUN flag. This was really only present to
support sched_4bsd.
 - Rename the KTR level for non schedgraph parsed events.  They take event
   space from things we'd like to graph.
 - Reset our slice value after we sleep.  The slice is simply there to
   prevent starvation among equal priorities.  A thread which had almost
   exhausted it's slice and then slept doesn't need to be rescheduled a
   tick after it wakes up.
 - Set the maximum slice value to a more conservative 100ms now that it is
   more accurately enforced.
2007-01-25 19:14:11 +00:00
Gleb Smirnoff
3cf0d02480 Make it possible that carpdetach() unlocks on return. Then, in
carp_clone_destroy() we are on a safe side, we don't need to
unlock the cif, that can me already non-existent at this point.

Reported by:	Anton Yuzhaninov <citrin rambler-co.ru>
2007-01-25 18:03:40 +00:00
Matt Jacob
325bba15cc Whoops- #ifdef problem caused uninitialized transport. Not horribly
a problem, but caused annoying messages.
2007-01-25 18:02:23 +00:00
Gleb Smirnoff
62dae1e917 Spacing. 2007-01-25 17:58:16 +00:00
Bill Paul
e2bcb489ef The TCP checksum offload handling in the 8111B/8168B and 8101E PCIe can
apparently be confused by short TCP segments that have been manually
padded to the minimum ethernet frame size. The driver does short frame
padding in software as a workaround for a bug in the 8169 PCI devices
that causes short IP fragments to be corrupted due to an apparent
conflict between the hardware autopadding and hardware IP checksumming.

To fix this, we avoid software padding for short TCP segments, since
the hardware seems to autopad and checksum these correctly (even the
older 8169 NICs get these right). Short UDP packets appear to be
handled correctly in all cases. This should work around the IP header
checksum bug in the 8169 while not tripping the TCP checksum bug in
the 8111B/8168B and 8101E.
2007-01-25 17:30:30 +00:00
Bruce Evans
63cb891e8b Rename some functions and variables from nfs_* to nfs4_* to avoid
collisions with nfsclient's names.  Even static names should have a
unique prefix so that they can be debugged easily.

Hide the unused colliding variable nfsv3_commit_on_close in "#if 0"
together with other unused sysctl variables.  Duplicating the nfs sysctl
under nfs4 is probably just a bug.

Fix some nearby style bugs.

Remove duplicate $FreeBSD$.
2007-01-25 14:33:13 +00:00
Bruce Evans
8754c03a11 Rename some functions and variables (mainly vfsops entry points) from
nfs_* to nfs4_* to avoid collisions with nfsclient's names.   Even
static names should have a unique prefix so that they can be debugged
easily.

Most of the renamed functions can probably be shared.  nfs4_cmount()
and nfs4_sync() are identical to the nfs_* versions, and all the others
except nfs4_vfsops() seem to be idendentical except for style bugs,
missing support for mountroot, and bugs.

Fix some nearby style bugs.

Remove duplicate $FreeBSD$.
2007-01-25 14:18:40 +00:00
Bruce Evans
e43982a801 Unstaticize nfs_iosize() in nfsclient and use it in nfs4client instead
of duplicating it except for larger style bugs in the copy.

Fix some nearby style bugs (including a harmless type mismatch)
in and near the remaining copy.

This is part of fixing collisions of the 2 nfs*client's names.  Even
static names should have a unique prefixes so that they can be debugged
easily.
2007-01-25 13:07:25 +00:00
Mike Pritchard
4ae90ca534 Add a BUGS section that shows that ids that appear to be
negative are now ignored by the quota system and that extremely
large ids may make quotacheck run for a very long time.

Also mention that "options QUOTA" is required for the kernel
to provide quota support.
2007-01-25 12:42:18 +00:00
Pawel Jakub Dawidek
eeefa1fa7e When the following conditions are meet:
- First configured key is based only on keyfile (no passphrase).
- Device is attached.
- User changes first key (setkey) from keyfile to passphrase and doesn't
  specify number of iterations (with -i option).
...geli(8) won't store calculated number of iterations in metadata.
This result in device beeing unaccesable after detach.

One can recover from this situation by guessing number of iterations
generated, storing it in metadata and trying to attach device.
Recovery procedure isn't nice, but one's data is not lost.

Reported by:	Thomas Nickl <T.Nickl@gmx.net>
MFC after:	1 week
2007-01-25 11:44:03 +00:00
Pawel Jakub Dawidek
1378624c2e Implement gctl_change_param() function, which changes value of existing
parameter.

MFC after:	1 week
2007-01-25 11:35:27 +00:00
Craig Rodrigues
c4b1628e07 Try to avoid a possible infinite loop when parsing an invalid kernel dump file.
PR:		108229
Submitted by:	Jessica Han <jessicah juniper net>
Reviewed by:	marcel
MFC after:	1 week
2007-01-25 06:39:25 +00:00
Mohan Srinivasan
6c125b8df6 Fix for problems that occur when all mbuf clusters migrate to the mbuf packet
zone. Cluster allocations fail when this happens. Also processes that may have
blocked on cluster allocations will never be woken up. Thanks to rwatson for
an overview of the issue and pointers to the mbuma paper and his tool to dump
out UMA zones.

Reviewed by: andre@
2007-01-25 01:05:23 +00:00
Mike Pritchard
fd7b77628d Display the name of the quota data file in verbose mode. 2007-01-24 22:52:32 +00:00
Mohan Srinivasan
7738029183 Fix for a bug where only one process (of multiple) blocked on
maxpages on a zone is woken up, with the rest never being woken up as
a result of the ZFLAG_FULL flag being cleared. Wakeup all such blocked
procsses instead. This change introduces a thundering herd, but since
this should be relatively infrequent, optimizing this (by introducing
a count of blocked processes, for example) may be premature.

Reviewd by: ups@
2007-01-24 22:49:11 +00:00
Doug Barton
1d8be4bade Update birth entry for Warren Zevon with his birthplace, and add an
entry for his death. Both per Wikipedia.
2007-01-24 21:21:38 +00:00
Jeff Roberson
0482a607bc - Add a horrible bit of code to detect tsc differences between processors.
This only works if there is no significant drift and all processors are
   running at the same frequency.  Fortunately, schedgraph traces on MP
   machines tend to cover less than a second so drift shouldn't be an issue.
 - KTRFile::synchstamp() iterates once over the whole list to determine the
   lowest tsc value and syncs adjusts all other values to match.  We assume
   that the first tick recorded on all cpus happened at the same instant to
   start with.
 - KTRFile::monostamp() iterates again over the whole file and checks for
   a cpu agnostic monotonically increasing clock.  If the time ever goes
   backwards the cpu responsible is adjusted further to fit.  This will
   make the possible incorrect delta between cpus as small as the shortest
   time between two events.  This time can be fairly large due to sched_lock
   essentially protecting all events.
 - KTRFile::checkstamp() now returns an adjusted timestamp.
 - StateEvent::draw() detects states that occur out of order in time and
   draws them as 0 pixels after printing a warning.
2007-01-24 21:19:56 +00:00
Jeff Roberson
9a93305a2e - With a sleep time over 2097 seconds hzticks and slptime could end up
negative.  Use unsigned integers for sleep and run time so this doesn't
   disturb sched_interact_score().  This should fix the invalid interactive
   priority panics reported by several users.
2007-01-24 18:18:43 +00:00
Randall Stewart
6dbde03086 Fixes the MSG_PEEK for sctp_generic_recvmsg() the msg_flags
were not being copied in properly so PEEK and any other
msg_flags input operation were not being performed right.
Approved by:	gnn
2007-01-24 12:59:56 +00:00
Ceri Davies
c4758f8e7f Bump .Dd for r1.313. 2007-01-24 09:22:56 +00:00
John Baldwin
f0ac0f92fb Document LD_UTRACE.
MFC after:	3 days
2007-01-23 22:38:39 +00:00
Jeff Roberson
4a2e6a080b - Print clock information so we know if something is not reported correctly
from the tsc.
 - Set skipnext = 1 for yielding and preempted events so we don't show the
   event that adds us back to the run queue.  It used to be 2 so we would
   skip the ksegrp run queue addition and the system run queue addition
   but the ksegrp run queue has gone away.
 - Don't display down to nanosecond resolution for scheduling events right
   now.  This can sometimes cause a division by zero.
2007-01-23 22:19:27 +00:00
Mike Pritchard
781cf91bcd Document new quota knobs. 2007-01-23 21:27:07 +00:00
Bruno Ducrot
8867dfa953 o introduce a flags 'errata' for HW bugs onto the softc.
o remove errata_a0 and introduce the corresponding flags into 'errata'.
o introduce a new errata for K8, namely some platform might set the
  PENDING_BIT but aren't able to unset it, also don't loop forever
  waiting PENDING_BIT being cleared.
o try to introduce a workaround for the PENDING_BIT stuck problem,
o support now half multipliers for K8.

Tested by:	Abdullah Al-Marrie

Approved by:	njl
2007-01-23 19:20:30 +00:00
Warner Losh
8bd73484dc Use the more specific 'EM732X' designation rather than * to disable sync
cache commands, per request from njl@.
2007-01-23 17:29:31 +00:00
Konstantin Belousov
2cc7d26f7f Cylinder group bitmaps and blocks containing inode for a snapshot
file are after snaplock, while other ffs device buffers are before
snaplock in global lock order. By itself, this could cause deadlock
when bdwrite() tries to flush dirty buffers on snapshotted ffs. If,
during the flush, COW activity for snapshot needs to allocate block
and ffs_alloccg() selects the cylinder group that is being written
by bdwrite(), then kernel would panic due to recursive buffer lock
acquision.

Avoid dealing with buffers in bdwrite() that are from other side of
snaplock divisor in the lock order then the buffer being written. Add
new BOP, bop_bdwrite(), to do dirty buffer flushing for same vnode in
the bdwrite(). Default implementation, bufbdflush(), refactors the code
from bdwrite(). For ffs device buffers, specialized implementation is
used.

Reviewed by:	tegge, jeff, Russell Cattelan (cattelan xfs org, xfs changes)
Tested by:	Peter Holm
X-MFC after:	3 weeks (if ever: it changes ABI)
2007-01-23 10:01:19 +00:00
Craig Rodrigues
1f294570c0 Remove mount_nfs4 from SUBDIR list. The mount_nfs Makefile
links mount_nfs to mount_nfs4 now.
2007-01-23 09:18:25 +00:00
Craig Rodrigues
0d27250907 Link mount_nfs -> mount_nfs4, and mount_nfs.8 -> mount_nfs4.8.
Suggested by:	rees
2007-01-23 09:14:33 +00:00
Jeff Roberson
7a5e5e2a59 - Catch up to setrunqueue/choosethread/etc. api changes.
- Define our own maybe_preempt() as sched_preempt().  We want to be able
   to preempt idlethread in all cases.
 - Define our idlethread to require preemption to exit.
 - Get the cpu estimation tick from sched_tick() so we don't have to worry
   about errors from a sampling interval that differs from the time
   domain.  This was the source of sched_priority prints/panics and
   inaccurate pctcpu display in top.
2007-01-23 08:50:34 +00:00