emaste [Tue, 22 Jan 2013 18:02:48 +0000 (18:02 +0000)]
Restore Python 2.6+ compatibility
SVN r245536 ported this to Python 3. The major change was the use of the
print function. Unfortunately this is incompatible with Python 2, which
is still the default version in the ports tree.
Use a __future__ import to make this compatible with Python 2.6 and later.
theraven [Tue, 22 Jan 2013 17:49:51 +0000 (17:49 +0000)]
Import new (BSDL) device tree compiler. Now built by default, so that it can't
be used on the host system (and not installed on the device, if required). The
GPL'd one is still available if there are any devices that need it (make
universe passes with it, including kernels that use fdt, but there may be some
out-of-tree ones). WITH_GPL_DTC can be used to select the old one, for now.
Probably won't be MFC'd, but we'll remove the GPL'd version in head after the
new one has had a lot more testing and ship it in 10.0.
nwhitehorn [Tue, 22 Jan 2013 17:06:28 +0000 (17:06 +0000)]
Improve error handling and remove an unnecessary check on geom provider
type. GEOM provider names can't duplicate (or shouldn't -- devfs will either
break or only use the first one if they do) so using the first provider
by that name is a sufficient check. This also lets the scripted partitioner
install onto gmirror and geli and such things.
brooks [Tue, 22 Jan 2013 16:23:08 +0000 (16:23 +0000)]
Make "install -l s[ar]" act like "ln -sfh" as intended. This fixes
installation of symbolic links where the target is a link is to an
existing directory.
lstewart [Tue, 22 Jan 2013 09:44:21 +0000 (09:44 +0000)]
Simplify and fix a bug in cc_ack_received()'s "are we congestion window limited"
logic (refer to [1] for associated discussion). snd_cwnd and snd_wnd are
unsigned long and on 64 bit hosts, min() will truncate them to 32 bits and could
therefore potentially corrupt the result (although under normal operation,
neither variable should legitmately exceed 32 bits).
delphij [Tue, 22 Jan 2013 05:41:34 +0000 (05:41 +0000)]
- Don't include date and time the driver is built, this is useful for
generating binary diffs.
- Constify a few strings used in the driver.
- Style changes to make the driver compile with default clang settings.
Approved by: HighPoint Technologies
MFC after: 3 days
andrew [Tue, 22 Jan 2013 05:39:34 +0000 (05:39 +0000)]
When copying the complement of the string loop to WINT_MAX as we are dealing
with a wint_t. WINT_MAX and WCHAR_MAX are the same on most architectures
except ARM EABI where wint_t is signed and wchar_t is unsigned.
benno [Tue, 22 Jan 2013 04:14:27 +0000 (04:14 +0000)]
Fix linking of loader.efi.
gcc handles -symbolic by passing -Bsymbolic through to ld. clang ignores
-symbolic and thus invokes ld without -Bsymbolic which leads to some symbols
not being properly linked in loader.efi. Fix this by using -Wl,-Bsymbolic which
passes -Bsymbolic to ld in both the gcc and clang cases.
nwhitehorn [Tue, 22 Jan 2013 02:40:06 +0000 (02:40 +0000)]
Document bsdinstall scripting as it currently operates. It may change in
the future depending on feedback from people using it to do unattended
system setup.
brooks [Mon, 21 Jan 2013 23:12:50 +0000 (23:12 +0000)]
Always bootstrap nmtree if it is not available on the host. It is fairly
small and it is quite annoying to get all the way through buildworld
only to discover that you forgot the DB_FROM_SRC (or soon NO_ROOT)
option.
neel [Mon, 21 Jan 2013 22:07:05 +0000 (22:07 +0000)]
Allocate the memory for the MSI-X table dynamically instead of allocating 32KB
statically. In most cases the number of table entries will be far less than
the maximum of 2048 allowed by the PCI specification.
Reuse macros from pcireg.h to interpret the MSI-X capability instead of rolling
our own.
theraven [Mon, 21 Jan 2013 17:37:23 +0000 (17:37 +0000)]
Import new fix from libcxxrt. This fixes the case where you attempt to rethrow
an exception when you haven't caught one. This is largely a cosmetic fix, as
(unless you have a very unusual terminate handler installed) it will print a
nice error and then abort, rather than just aborting.
adrian [Mon, 21 Jan 2013 04:06:04 +0000 (04:06 +0000)]
Migrate CLRDMASK to be a per-node flag, rather than a per-TID flag.
This is easily possible now that the TX is protected by a single
lock, rather than a per-TXQ (and thus per-TID) lock.
Only set CLRDMASK if none of the destinations are filtered.
This likely will need some tuning when it comes time to do UASPD/PS-POLL
TX, however at that point it should be manually set anyway.
Tested:
* AR9280, STA mode
TODO:
* More thorough testing in AP mode
* test other chipsets, just to be safe/sure.
nwhitehorn [Mon, 21 Jan 2013 01:55:54 +0000 (01:55 +0000)]
More automated install support: if a script exists at /etc/installerconfig,
point the installer there and then reboot without asking questions. This
design subject to future change.
The second part of the script (beginning with #!) is run in the newly
installed system after the installation onto ada0 (with default partitioning,
see scriptedpart for more complicated scenarios) is complete.
jilles [Sun, 20 Jan 2013 21:28:05 +0000 (21:28 +0000)]
sh: Move some stackmarks to fix high memory usage in some loops.
If a loop contained certain commands (such as redirected compound commands),
the temporary memory for the redirection was not freed between iterations of
the loop but only after the loop.
Put a stackmark in evaltree(), freeing memory whenever a node has been
evaluated. Some other stackmarks are then redundant; remove them.
avg [Sun, 20 Jan 2013 19:55:49 +0000 (19:55 +0000)]
zfs/sparc64 boot: fix booting after r242230
arch_zfs_probe method is supposed to only probe for ZFS vdevs, but it can
not expect that ZFS data is in a ready state yet.
So, move some code from sparc64_zfs_probe to main to meet the constraints.
Reported by: Chris Ross <cross+freebsd@distal.com>
Tested by: Chris Ross <cross+freebsd@distal.com>
MFC after: 4 days
nwhitehorn [Sun, 20 Jan 2013 03:55:08 +0000 (03:55 +0000)]
Make "Finish" the default choice in the partition editor. This lets you
successfully complete an installation with all defaults by pressing
Enter repeatedly until your machine reboots.
andrew [Sat, 19 Jan 2013 04:03:18 +0000 (04:03 +0000)]
Update the syscall calling convention for ARM EABI. We store the syscall
in r7 and use ip to store the old version of r7 as it is not guaranteed to
be kept when calling a subroutine. The kernel will preserve the register
across system calls.
kan [Sat, 19 Jan 2013 03:19:39 +0000 (03:19 +0000)]
Do not pretend to have autosense data when no such data is available.
Make umass return an error code if SCSI sense retrieval request
has failed. Make sure scsi_error_action honors SF_NO_RETRY and
SF_NO_RECOVERY in all cases, even if it cannot parse sense bytes.
ian [Sat, 19 Jan 2013 00:50:12 +0000 (00:50 +0000)]
Eliminate the need for an intermediate array of indices into the arrays of
interrupt counts and names, by making the names into an array of fixed-length
strings that can be directly indexed. This eliminates extra memory accesses
on every interrupt to increment the counts.
As a side effect, it also fixes a bug that would corrupt the names data
if a name was longer than MAXCOMLEN, which led to incorrect vmstat -i output.
jilles [Fri, 18 Jan 2013 23:08:40 +0000 (23:08 +0000)]
libthr: Always use the threaded rtld lock implementation.
The threaded rtld lock implementation is faster even in the single-threaded
case because it postpones signal handlers via THR_CRITICAL_ENTER and
THR_CRITICAL_LEAVE instead of calling sigprocmask(2).
As a result, exception handling becomes faster in single-threaded
applications linked with libthr.
brooks [Fri, 18 Jan 2013 20:57:50 +0000 (20:57 +0000)]
Introduce six new options from NetBSD:
* -M <metalog> Log metadata in mtree format.
* -D <destdir> Log paths relative to <destdir>.
* -h <hash> Log digest of type <hash>.
* -T <tags> Specify which mtree tags to log.
* -l <linkflag> Create hard or symbolic links (allows logging).
* -U Install without root privileges (owner, group, mode,
and flags can be logged via -M
NOTE: In the interest of compatibility with NetBSD and because it is the
obvious letter, the nearly useless -M option (disable mmap) has been
repurposed.
delphij [Fri, 18 Jan 2013 19:42:08 +0000 (19:42 +0000)]
Make it possible to force async at server side on new NFS server, similar
to the old one's nfs.nfsrv.async.
Please note that by enabling this option (default is disabled), the system
could potentionally have silent data corruption if the server crashes
before write is committed to non-volatile storage, as the client side have
no way to tell if the data is already written.
jhb [Fri, 18 Jan 2013 18:24:40 +0000 (18:24 +0000)]
Include the thread name along with the command name when displaying the
command name of a thread from a multi-threaded process that doesn't have
an available argument list (such as kernel processes) and threads display
is enabled via -H.
brooks [Thu, 17 Jan 2013 23:05:03 +0000 (23:05 +0000)]
In r245571, "rm -rf <foo>; ln -s <bar> <foo>" needed to be replaced with
"ln -sfh <bar> <foo>" or the links would fail when a valid link to a
directly was in place at <foo>.
Reported by: peter
Tested by: peter
Pointy hat to: brooks
luigi [Thu, 17 Jan 2013 22:14:58 +0000 (22:14 +0000)]
add some definition and driver changes in preparation for
two upcoming features:
semi-transparent mode:
when a device is opened in this mode, the
user program will be able to mark slots that must be forwarded
to the "other" side (i.e. from NIC to host stack, or viceversa),
and the forwarding will occur automatically at the next netmap syscall.
This saves the need to open another file descriptor and do
the forwarding manually.
direct-forwarding mode:
when operating with a VALE port, the user can specify in the slot
the actual destination port, overriding the forwarding decision
made by a lookup of the destination MAC. This can be useful to
implement packet dispatchers.
No API changes will be introduced.
No new functionality in this patch yet.
jhb [Thu, 17 Jan 2013 21:32:25 +0000 (21:32 +0000)]
Don't attempt to use clflush on the local APIC register window. Various
CPUs exhibit bad behavior if this is done (Intel Errata AAJ3, hangs on
Pentium-M, and trashing of the local APIC registers on a VIA C7). The
local APIC is implicitly mapped UC already via MTRRs, so the clflush isn't
necessary anyway.
andre [Thu, 17 Jan 2013 21:28:31 +0000 (21:28 +0000)]
Move the mbuf memory limit calculations from init_param2() to
tunable_mbinit() where it is next to where it is used later.
Change the sysinit level of tunable_mbinit() from SI_SUB_TUNABLES
to SI_SUB_KMEM after the VM is running. This allows to use better
methods to determine the effectively available physical and virtual
memory available to the kernel.
Update comments.
In a second step it can be merged into mbuf_init().
csjp [Thu, 17 Jan 2013 21:02:53 +0000 (21:02 +0000)]
Implement the zonename token for jailed processes. If
a process has an auditid/preselection masks specified, and
is jailed, include the zonename (jailname) token as a
part of the audit record.
brooks [Thu, 17 Jan 2013 20:21:30 +0000 (20:21 +0000)]
In preparation for logging metadata about each filesystem object
refactor the link section of distrib-dirs to alwasy install to a full
path (the link contents remain relative as they should).
Eliminate the use of the "rm -r[f] <foo>; ln -s <bar> <foo>" pattern in
favor of "ln -sf <bar> <foo>". None of these links could be directories
on a system installed in the last decade.