cperciva [Wed, 28 Nov 2007 23:24:07 +0000 (23:24 +0000)]
Back out previous commit; i.e., turn hyperthreading back on by default.
Newer Intel processors have better hyperthreading implementations than
the original ones, and FreeBSD's SMP and scheduler code has greatly
improved between 6.x and 7.x; so hyperthreading now provides a
non-trivial performance win.
Note that security issues involving shared caches and other
microarchitectural features (e.g., dynamic branch prediction tables)
still exist; consequently, it is recommended that hyperthreading be
turned off on systems with untrusted local users. This can be
performed by setting machdep.hyperthreading_allowed=0 in
/boot/loader.conf.
Hyperthreading will continue to be disabled by default on FreeBSD 6.x.
Requested by: core
Approved by: re (kensmith)
Security: See FreeBSD-SA-05:09.htt for background information.
alc [Wed, 28 Nov 2007 22:23:35 +0000 (22:23 +0000)]
MFC revision 1.360
When reactivating a cached page, reset the page's pool to the default
pool. (Not doing this before was a performance pessimization but not
a cause for panic.)
ariff [Tue, 27 Nov 2007 23:37:48 +0000 (23:37 +0000)]
* Fix support for followings:
o Acer Aspire 4520 laptop
- jack sensing / automute
o Toshiba Satellite A135-S4527 laptop
- jack sensing / automute
Tested by: lioux
o Apple Macbook 3 (is it?)
- require gpio0 (for speakers) and ovref50 (for headphone)
to make it works
- jack sensing / automute
Tested by: Ed Schouten
* Add Nvidia MCP67 controller ids.
* Be sensible about simmilar controller with multiple pci ids.
* Connect unused DAC/ADC to stream#0 rather than forcing each of them
managing their own stream.
rwatson [Tue, 27 Nov 2007 12:22:17 +0000 (12:22 +0000)]
Merge tcp_subr.c:1.302 from HEAD to RELENG_7:
More carefully handle various cases in sysctl_drop(), such as unlocking
the inpcb when there's an inpcb without associated timewait state, and
not unlocking when the inpcb has been freed. This avoids a kernel panic
when tcpdrop(8) is run on a socket in the TIMEWAIT state.
rwatson [Tue, 27 Nov 2007 12:20:58 +0000 (12:20 +0000)]
Merge nfs_vnops.c:1.277 from HEAD to RELENG_7:
Remove hacks from the NFSv2/3 client intended to handle a lack of a
server-side RPC retranmission cache for non-idempotent operations: these
hacks substituted 0 (success) for the expected EEXIST in the event that
a target name already existed for LINK, SYMLINK, and MKDIR operations,
under the assumption that EEXIST represented a second application of the
original RPC rather than a true failure.
Background: certain NFS operations (in this case, LINK, SYMLINK, and
MKDIR) are not idempotent, as they leave behind persisting state on the
server that prevents them from being replayed without an error;if an UDP
RPC reply is lost leading to a retransmission by theclient, the second
reply will return EEXIST rather than success, asthe new object has
already been created. The NFS client previouslysilently mapped the
EEXIST return into success to paper over thisproblem.
However, in all modern NFS server implementations, a reply cache is kept
in order to retransmit the original reply to a retransmitted request,
rather than performing the operation a second time, allowing this hack
to be avoided. This allows link()-based filelocking over NFS to operate
correctly, as an application requestingthe creation of a new link for a
file to tell if it succeededatomically or not.
Other NFS clients, including Solaris and Linux, generally follow this
behavior for the same reasons. Most clients also now default to TCP,
which also helps avoid the issue of retransmitted but non-idempotent
requests in most cases.
Reported by: Adam McDougall <mcdouga9 at egr dot msu dot edu>,
Timo Sirainen <tss at iki dot fi>
Reviewed by: mohans
Let sunkbd(4) emulate an AT keyboard by default.
This has the following benefits:
- allows to use the AT keyboard maps in share/syscons/keymaps with
sunkbd(4),
- allows to use kbdmux(4) with sunkbd(4),
- allows Sun RS232 keyboards to be configured and used the same
way as Sun USB keyboards driven by ukbd(4) (which also does AT
keyboard emulation) with X.Org, putting an end to the problem
of native support for the former in X.Org being broken over and
over again.
jkim [Mon, 26 Nov 2007 17:37:24 +0000 (17:37 +0000)]
MFC: 1.356
Make VPD register access more robust:
- Implement timing out of VPD register access.
- Fix an off-by-one error of freeing malloc'd space when checksum is invalid.
- Fix style(9) bugs, i.e., sizeof cannot be followed by space.
- Retire now obsolete 'hw.pci.enable_vpd' tunable.
jkim [Mon, 26 Nov 2007 17:33:28 +0000 (17:33 +0000)]
MFC: 1.199
Do not report MAC, TX, and RX stats via sysctl(8) with BCM5705+.
The register layout is little different from memory-mapped stats
in the previous generation chips. In fact, it is bad because
registers in this range are cleared after reading them.
delphij [Mon, 26 Nov 2007 06:46:44 +0000 (06:46 +0000)]
MFC MFp4: Several fixes to tmpfs which makes it to survive from pho@'s
strees2 suite, to quote his letter, this change:
1. It removes the tn_lookup_dirent stuff. I think this cannot be fixed,
because nothing protects vnode/tmpfs node between lookup is done, and
actual operation is performed, in the case the vnode lock is dropped.
At least, this is the case with the from vnode for rename.
For now, we do the linear lookup in the parent node. This has its own
drawbacks. Not mentioning speed (that could be fixed by using hash), the
real problem is the situation where several hardlinks exist in the dvp.
But, I think this is fixable.
2. The patch restores the VV_ROOT flag on the root vnode after it became
reclaimed and allocated again. This fixes MPASS assertion at the start
of the tmpfs_lookup() reported by many.
mlaier [Sun, 25 Nov 2007 19:26:46 +0000 (19:26 +0000)]
MFC pf.c 1.51, pf_ioctl.c 1.30 and pf_if.c 1.13-1.14:
Reloop OpenBSD rev. 1.563:
In pf_test_fragment(), ignore protocol-specific criteria for packets of
different protocols.
Cleanup pf interface mangement - esp. remove EVENTHANDLER before
unloading the coresponding code. This was lost during 4.1 import.
Bring back pf_if.c revs 1.8 and 1.6 also lost during last import:
- Use correct time for tzero when compiled in
- Don't use bogus interface addresses on ptp-interfaces with :0
rwatson [Sun, 25 Nov 2007 19:15:53 +0000 (19:15 +0000)]
Merge nfs.h:1.83, nfs_srvsubs.c:1.150 from HEAD to RELENG_7:
Garbage collect now-unused nfsrv_setcred() -- it's not only unused, but
also a purveyor of unfortunate (and now unsupported) direct frobbing of
struct ucred.
dumbbell [Sun, 25 Nov 2007 11:11:28 +0000 (11:11 +0000)]
MFC 1.193:
The kernel uses two ways to write data on a pipe:
o buffered write, for chunks smaller than PIPE_MINDIRECT bytes
o direct write, for everything else
A call to writev(2) may receive struct iov of various size and the
kernel may have to switch from one solution to the other. Before doing
this, it must wake reader processes and any select/poll/kqueue up.
This commit fixes a bug where select/poll/kqueue are not triggered
when switching from buffered write to direct write. It adds calls to
pipeselwakeup().
I give more details on freebsd-arch@:
http://lists.freebsd.org/pipermail/freebsd-arch/2007-September/006790.html
This should fix issues with Erlang (lang/erlang) and kqueue.
Reported by: Rickard Green (Erlang)
Approved by: re (kensmith)
delphij [Thu, 22 Nov 2007 01:33:08 +0000 (01:33 +0000)]
MFC revision 1.342
date: 2007/10/18 08:41:52; author: delphij; state: Exp; lines: +2 -2
Do not bail out for cleanworld target just because
chflags is failed.
cperciva [Wed, 21 Nov 2007 14:37:03 +0000 (14:37 +0000)]
MFC revisions 1.11,1.12: Unbreak "freebsd-update rollback" applied to
minor version upgrades, by being more careful about the order in which
files are rolled back to their old versions.
glebius [Wed, 21 Nov 2007 12:14:00 +0000 (12:14 +0000)]
MFC:
- Merge all the ng_send_fn2* functions into one - ng_send_fn2(),
removing some copy&pasted code.
- Reduce copy and paste in ng_apply_item().
- Resurrect ng_send_fn() as a valid symbol, not a define.
luigi [Wed, 21 Nov 2007 07:20:11 +0000 (07:20 +0000)]
MFC 2007-11-14 05:42:54 UTC
Fix picobsd builds. Changes include:
- use proper make configuration for the build, using
${BINMAKE} as evaluated by ${VERSION}/src/Makefile
- remove -lmytinfo from crunch.conf
- remove support for login_access in tinyware/login
- remove "machine i386" from the kernel config file
It might actually be interesting to extend the script to do
a cross build for !i386 ...
avatar [Wed, 21 Nov 2007 06:37:40 +0000 (06:37 +0000)]
MFC(if_an.c:1.85, if_anreg.h:1.24): Trying to eliminate a racing as well as
reducing the chance of device removal(PCCARD) panic by replacing the
timeout(9) with callout(9) APIs.
Tested by: dhw
Approved by: re (kensmith)
MFC after: 3 days
delphij [Wed, 21 Nov 2007 01:47:08 +0000 (01:47 +0000)]
MFC revision 1.12
date: 2007/11/12 18:57:33; author: delphij; state: Exp; lines: +1 -1
Correct a stack overflow which will trigger panics when
mode= is specified, caused by incorrect format string
specified to vfs_scanopt() and subsequently vsscanf().
Pointed out by: kib
Submitted by: des
Approved by: re (kensmith)
kensmith [Tue, 20 Nov 2007 20:48:01 +0000 (20:48 +0000)]
MFC of library version bump. From original commit:
> While checking over the libraries for 7.0-REL Kris found the following
> libraries had not had their versions bumped relative to 6.3-REL but
> had indeed been changed. We need to bump their version so they can be
> properly added to the compat6x port:
>
> libasn1.so.8 libgssapi.so.8 libhdb.so.8 libkadm5clnt.so.8
> libkadm5srv.so.8 libkafs5.so.8 libkrb5.so.8 libobjc.so.2
silby [Tue, 20 Nov 2007 15:26:18 +0000 (15:26 +0000)]
MFC rev 1.134: Comment out the syncache's test which ensures that hosts which
negotiate TCP timestamps in the initial SYN packet actually use them in the
rest of the connection.
bz [Tue, 20 Nov 2007 09:35:15 +0000 (09:35 +0000)]
MFC: rev. 1.20 sys/netipsec/keysock.c
Move the priv check before the malloc call for so_pcb.
In case attach fails because of the priv check we leaked the
memory and left so_pcb as fodder for invariants.
kensmith [Fri, 16 Nov 2007 13:33:38 +0000 (13:33 +0000)]
Insta-MFC of v1.927 so it can be part of 7.0-BETA3 build. Shift i386
(and pc98, it's over disc1 size target as well) over to having a separate
livefs iso image.
ariff [Thu, 15 Nov 2007 16:59:29 +0000 (16:59 +0000)]
MFC (revision 1.54):
Limit total playback channels to just 1, for ALi M5451.
The reliability of it's multi DAC / playback channels is
not that good. Enabling vchans make the bug more visible
since playback allocation will look for possible free
hardware channels first (i.e: the next DAC, the very first
has been consumed by vchan mixer) which in this case has
been proven faulty.
Reported / Tested by: Sascha Klauder
Approved by: re (kensmith)
kensmith [Thu, 15 Nov 2007 15:46:35 +0000 (15:46 +0000)]
MFC another adjustment to the X related distributions based on xorg-7.3
layout. xorg-printserver still exists in the ports tree but it's marked
as depreciated and scheduled for removal.
rrs [Thu, 15 Nov 2007 15:03:17 +0000 (15:03 +0000)]
- Fixes a bug in rwnd handling that would cause an incorrect rwnd
advertisement during low mem conditions.
- Fixes a compile error on mac-os (signedness stuff).
- Touches up some comments.
grehan [Wed, 14 Nov 2007 16:41:31 +0000 (16:41 +0000)]
MFC:
Split decr_init() into two, with the section that reads the timebase
frequency from OpenFirmware moved out and into a routine that is called
from cpu_startup().
This allows correct reporting of the CPU clockspeed when printing out
CPU information at boot time.
kan [Mon, 12 Nov 2007 16:09:45 +0000 (16:09 +0000)]
MFC revisions
1.75: Make ukbd_getc respect non-blocking behavior if one is requested;
1.76: Do not pass an address of local stack variable to
usbd_set_report_async.