Commit Graph

185360 Commits

Author SHA1 Message Date
Colin Percival
ebc1d19c3c Fix typo in r256646: We want to generate lists of directories in INDEX-OLD
and INDEX-NEW and compare them, not generate the same list of directories
from INDEX-OLD twice...

Pointy hats to:	cperciva & everybody who didn't proofread EN-13:04 enough
2013-11-09 04:50:05 +00:00
Mark Johnston
ee765c2d34 Don't try to use the 32-bit drti.o unless the data model is explicitly set
to ILP32. Otherwise dtrace -G will attempt to use it on amd64 if it can't
determine which data model to use, which happens when -64 is omitted and
no object files are provided, e.g. with

# dtrace -G -n BEGIN

This would result in a linker error, but now works properly.

Also remove an unnecessary #ifdef.

MFC after:	2 weeks
2013-11-09 04:38:16 +00:00
Justin T. Gibbs
4c85fcfa37 On XenServer the "halt" message is used instead of "poweroff", which
makes FreeBSD halt but not poweroff (as expected when issuing a
shutdown from the VM manager). Fix this by using the same handler
for both "halt" and "poweroff".

NB: The "halt" signal seems to be used on XenServer only.  The OSS
    Xen toolstack (xl) uses "poweroff" instead.

Submitted by:	Roger Pau Monné
Sponsored by:	Citrix Systems R&D
Reviewed by:	gibbs
MFC after:	2 days
2013-11-09 03:07:48 +00:00
Sergey Kandaurov
dc211b3d40 Fix extattr(2) MLINKS.
MFC after:	1 week
2013-11-09 00:36:09 +00:00
Ian Lepore
d3109d3971 This change builds kernel tools based on the same assumption as building
the kernel itself:  If building for the same architecture as the build host,
the kernel build assumes that the host toolchain is capable of building the
kernel.  If it's not, "make kernel-toolchain" will bootstrap a new set of
tools that will work.

With this change the same assumptions are made for building kernel tools,
and the existing host toolchain is used to do the build (notably, the build
doesn't link the tools with the legacy libraries, which may not even exist).
If ever for some reason the host toolchain isn't capable of building the
kernel tools, then doing a "make kernel-toolchain" will bootstrap newer
tools to get the job done.

So when built as part of buildworld or kernel-toolchain, the kernel tools
are built using the XMAKE (via BMAKE) commands and environment.  When built
as part of building just the kernel on a same-target host, the tools are
built using the new KTMAKE commands and environment.  What doesn't jump
out at you in the diffs is that the difference between BMAKE and KTMAKE
is that BMAKE contains this magic line which changes how the build is done
because it changes what files get included for .include <bsd.prog.mk> and
other standard includes:

    MAKEFLAGS="-m ${.CURDIR}/tools/build/mk ${.MAKEFLAGS}"

and KTMAKE doesn't, and contains this instead:

    TOOLS_PREFIX=${WORLDTMP}

Hopefully this brings the "how to build aicasm with the right toolchain"
saga to a conclusion that works in all usage scenarios that have
historically been supported.
2013-11-09 00:15:36 +00:00
Joel Dahl
e2defa5278 mdoc: add missing El. 2013-11-08 23:11:04 +00:00
Joel Dahl
13121e810d mdoc: remove superfluous paragraph macro. 2013-11-08 23:08:01 +00:00
Jean-Sébastien Pédron
b0d83b17d6 drm/radeon: Wake up userland after page flip
For instance, this caused issues in KDE, such as stuttered animations
(with desktop effects enabled).
2013-11-08 22:47:43 +00:00
Jean-Sébastien Pédron
f79c35617c drm: Initialize "handle" to 0 before calling drm_gem_handle_create()
This is variable is being checked in drm_gem_name_create() before being
set.
2013-11-08 22:44:46 +00:00
Marko Zec
27dbe10a8b Eliminate duplicated & dead code.
MFC after:	3 days
2013-11-08 22:40:33 +00:00
Hiren Panchasara
16ef0fa833 Fix typo in a comment. 2013-11-08 20:11:15 +00:00
Alfred Perlstein
a91c93ed22 Do not use a sleep lock when protecting the driver flags.
This was causing a locking issue with lagg

Submitted by:	odeds
2013-11-08 18:28:48 +00:00
Alfred Perlstein
d3e98a133b Fix for bad performance when mtu is increased.
Update the auto moderation behavior in the mlxen driver to match
the new LINUX OFED code.

Submitted by:	odeds
2013-11-08 18:26:28 +00:00
Alfred Perlstein
58f91ead4b Use explicit long cast to avoid overflow in bitopts.
This was causing problems with the buddy allocator inside of
ofed.

Submitted by: odeds
2013-11-08 18:20:19 +00:00
Glen Barber
4ef7374618 Remove generate-release.sh from head/.
The release.sh (based heavily on generate-release.sh) has been
used for the 9.2-RELEASE and 10.0-RELEASE cycles, so make sure
there is no confusion on what is currently being used by having
two similar scripts.

A big "thank you" to Nathan Whitehorn, the author of the
generate-release.sh script, for writing this utility.

No objection:	nwhitehorn
MFC after:	never
Sponsored by:	The FreeBSD Foundation
2013-11-08 17:27:38 +00:00
Dimitry Andric
e7d8b7e43f Initialize variable in sys/x86/iommu/busdma_dmar.c, to avoid possible
uninitialized use.

Reviewed by:	kib
2013-11-08 17:27:22 +00:00
Dimitry Andric
1c5ce94f1d Fix typo in include guard, found by clang 3.4.
MFC after:	3 days
2013-11-08 17:23:37 +00:00
Konstantin Belousov
760faf9fdd Fix signal delivery for the iBCS2 binaries. The iBCS2 sysvec uses
current FreeBSD signal trampoline, but does not specifies
sv_sigcode_base, since shared page is not mapped.  This results in the
zero %eip for the signal frame.  Fall back to calculating %eip as
offset from the psstrings when sv_sigcode_base is not initialized.

Reported by:	Rich Naill <rich@enterprisesystems.net>
Sponsored by:	The FreeBSD Foundation
MFC after:	1 week
2013-11-08 16:57:55 +00:00
Alan Cox
647e61eaca Eliminate an unused macro. 2013-11-08 16:56:13 +00:00
Konstantin Belousov
6f8a44a5dd Add bits for the AMD features from CPUID function 0x80000001 ECX,
described in the rev. 3.0 of the Kabini BKDG, document 48751.pdf.

Partially based on the patch submitted by:	Dmitry Luhtionov <dmitryluhtionov@gmail.com>
Sponsored by:	The FreeBSD Foundation
MFC after:	1 week
2013-11-08 16:32:30 +00:00
Ian Lepore
6a101ebe72 Remove 'inline' from ar9300_init_pll(), it's too big to inline.
Submitted by:	adrian@
2013-11-08 16:28:00 +00:00
Alan Cox
c70af4875e As of r257209, all architectures have defined VM_KMEM_SIZE_SCALE. In other
words, every architecture is now auto-sizing the kmem arena.  This revision
changes kmeminit() so that the definition of VM_KMEM_SIZE_SCALE becomes
mandatory and the definition of VM_KMEM_SIZE becomes optional.

Replace or eliminate all existing definitions of VM_KMEM_SIZE.  With
auto-sizing enabled, VM_KMEM_SIZE effectively became an alternate spelling
for VM_KMEM_SIZE_MIN on most architectures.  Use VM_KMEM_SIZE_MIN for
clarity.

Change kmeminit() so that the effect of defining VM_KMEM_SIZE is similar to
that of setting the tunable vm.kmem_size.  Whereas the macros
VM_KMEM_SIZE_{MAX,MIN,SCALE} have had the same effect as the tunables
vm.kmem_size_{max,min,scale}, the effects of VM_KMEM_SIZE and vm.kmem_size
have been distinct.  In particular, whereas VM_KMEM_SIZE was overridden by
VM_KMEM_SIZE_{MAX,MIN,SCALE} and vm.kmem_size_{max,min,scale}, vm.kmem_size
was not.  Remedy this inconsistency.  Now, VM_KMEM_SIZE can be used to set
the size of the kmem arena at compile-time without that value being
overridden by auto-sizing.

Update the nearby comments to reflect the kmem submap being replaced by the
kmem arena.  Stop duplicating the auto-sizing formula in every machine-
dependent vmparam.h and place it in kmeminit() where auto-sizing takes
place.

Reviewed by:	kib (an earlier version)
Sponsored by:	EMC / Isilon Storage Division
2013-11-08 16:25:00 +00:00
Julio Merino
fba3cde907 Build and install the atf tests.
Reviewed by:	freebsd-testing
Approved by:	rpaulo (mentor)
2013-11-08 14:33:41 +00:00
Julio Merino
cc21b86f50 Install category Kyuafiles from their category directories.
Move the installation of /usr/tests/lib/Kyuafile from src/tests/lib/
to src/lib/.  This is to keep the src/tests/ hierarchy unaware of the
rest of the tree, which makes things clearer in general.  In particular:

1) Everything related to the construction of /usr/tests/lib/ is kept
   in src/lib/.  There is no need to think about different directories
   and how they relate to each other.  (The same applies for libexec,
   usr.bin, etc. but these are not yet handled.)

2) src/tests becomes the place to keep cross-functional test programs
   and nothing else, which also helps in simplifying things.

Reviewed by:	freebsd-testing
Approved by:	rpaulo (mentor)
2013-11-08 14:29:06 +00:00
Julio Merino
14de84e74a Handle the removal of the test suite when WITHOUT_TESTS=yes.
Add all files from /usr/tests to the obsoleted files list when the
build of the tests is disabled via the WITHOUT_TESTS knob.  Do this
automatically so that we do not have to suffer the pain of maintaining
such list by hand.

Reviewed by:	freebsd-testing
Approved by:	rpaulo (mentor)
2013-11-08 14:26:52 +00:00
Julio Merino
e01d128a42 Subsume the functionality of MK_ATF into MK_TESTS.
There is no reason to keep the two knobs separate: if tests are
enabled, the ATF libraries are required; and if tests are disabled,
the ATF libraries are not necessary.  Keeping the two just serves
to complicate the build.

Reviewed by:	freebsd-testing
Approved by:	rpaulo (mentor)
2013-11-08 14:24:47 +00:00
Julio Merino
ee695f67a6 Add libatf-c++ to the prebuild libs.
Some tests may require C++ so we must ensure this library exists as part
of the bootstrap process or else they will fail to build.  Do this by
just depending on lib/atf as part of the bootstrap libraries instead of
using lib/atf/libatf-c.

Submitted by:	Garrett Cooper <yaneurabeya at gmail dot com>
Approved by:	rpaulo (mentor)
2013-11-08 14:22:16 +00:00
Julio Merino
57028ca47f Fix buildworld when WITH_TESTS is enabled.
The addition of the TESTS knob and its enabling of the build of tests in
lib/libcrypt/tests/ broke the build.  The reason is that we cannot descend
into tests/ subdirectories until all prerequisites have been built, which
in the case of tests may be "a lot of things" (libatf-c in this case).

Ensure that we do not walk tests/ directories during the bootstrapping of
the libraries as part of buildworld.

Reviewed by:	freebsd-testing
Approved by:	rpaulo (mentor)
2013-11-08 14:20:22 +00:00
Achim Leubner
3fea9c0d26 Update aacraid to version 3.2.5.
Full MSI-X interrupt support added.
Timeout and reset handling reworked, firmware flash update test added.
Support for drives with 4KB block size added.
Changes made to avoid exposure of phys. array components by default.

Approved by:	scottl (mentor), emaste (co-mentor)
2013-11-08 13:23:26 +00:00
Gleb Smirnoff
2f3eb7f4d8 Make TCP_KEEP* socket options readable. At least PostgreSQL wants
to read the values.

Reported by:	sobomax
2013-11-08 13:04:14 +00:00
Devin Teske
cd28e9c5e0 I often forget that debugFile can begin with a + for deciding that debug
should be sent to both the file (minus the leading +) and stdout.
2013-11-08 10:19:48 +00:00
Devin Teske
66fd321403 Copy the install log to the deployed /var/log directory so that we have
post-mortem data on how the machine was configured/installed.
2013-11-08 10:14:32 +00:00
Devin Teske
9e513d3179 Semi-revert this one file out of r257842. The ttys(5) stuff, as we
discussed on -current, was not supposed to go in but get solved in
a different way -- e.g., init(8) logic).

Discussed on:   -current
2013-11-08 10:09:34 +00:00
Devin Teske
bc4a673f89 A series of changes tested together as a whole:
+ Add a `-D FILE" command-line option for overriding the path to the
  bsdinstall log file (BSDINSTALL_LOG env var).
+ Document new `-D FILE' in the man page for bsdinstall.
+ If FILE in `-D FILE' begins with a +, debug output goes to stdout
  (interleaved between dialog(1) invocations/output) as well as to FILE
  (minus the leading + of course).
+ If BSDINSTALL_LOG cannot be written, then debugging is disabled (except in
  the case of a leading + in the pathname, wherein debug will still be
  printed to stdout).
+ Update source code formatting style.
+ Fix a dangling participle ("Begun ..." -> "Began ...")
+ Rewrite the docsinstall script (was necessary to abate direct dependency
  on BSDINSTALL_LOG (instead, use fault-tolerant bsdconfig framework which
  displays appropriate errors for package management).
NB: docsinstall is still using pkg(8) after this change.
+ Add additional debug output for dhclient/rtsol/wpa_cliscan
+ Display script errors in a textbox rather than just on stdout
+ Update many coments.
+ Add new f_show_err() API call (like f_show_msg but changes the dialog
  title to "Error")(see bsdconfig's `common.subr').
+ Add new f_eval_catch() API call for executing a command via eval but not
  before logging the command to debug. Several example cases documented in
  API header for function in bsdconfig's `common.subr'.
+ Fix dialog auto-sizing when launched as an rvalue to a pipe for indirected
  scripts (previously would default to 24x80 sizing in this case, now it can
  autosize to full size even when in a pipe chain).
+ Fix bug in f_snprintf if $format argument began with "-"; printf would
  misinterpret as a flag. (this is in bsdcofig's `strings.subr').
+ Add accompanying f_sprintf() and f_vsprintf() to go along with already
  existing f_snprintf() and f_vsnprintf() (see bsdconfig's `strings.subr').
+ Remove some unnecessary default ZFS datasets from the automatic "zfsboot"
  script. Such as: /usr/ports/distfiles /usr/ports/packages /usr/obj /var/db
  /var/empty /var/mail and /var/run (these can all be created as-needed once
  the system is installed).
+ Remove setuid=off for /usr/home (as discussed from last round of CFT).
+ Fix some i18n string violations in "zfsboot".
+ Bolster debugging output in "zfsboot".
+ Fix some string quoting issues in "zfsboot".
+ Fix some variable scope issues in "zfsboot".
+ Change "Create" to "Install" in "zfsboot" main menu.
+ Increase error checking in "zfsboot" (type-check arguments and such).
+ Add call to "graid destroy" killing automatic metadata (part of the series
  of pedantic destructions we do when bootstrapping a new/naked disk).
+ Make judicious use of new f_eval_catch() in "zfsboot".
+ Fixup some variable names for consistency (zfsboot).
+ Fix an underride syntax parameter expansion folly (zfsboot).
+ Confirm layout if not explicitly chosen when blindly proceeding (no
  longer have to touch anything on the ZFS menu if it scares you, just
  choose the omnibus "Install" option at the top and you'll be prompted to
  select vdev type and disks in the layout confirmation dialog).
+ Change numbered menu items to alphabetic for more efficient navigation.
+ Consolidate vdev selection and disk selection into a single stateful
  menu which performs validation and allows backing out to each previous
  menu as you go deeper.
+ Redesign the ``Last Chance'' dialog (still using the same colors, but
  make it conform to a tolerable width and make disks appear in a block-
  quote style indented region).
+ Fix a bug wherein we used the a lowercase variable name by accident
  (actual variable name declared as all-uppercase) at the time of
  initializing fstab(5) (not believed to cause any issues though).
+ Update the geli setup infobox for each provider being initialized
  (not just at the onset -- since each ``geli init'' causes kernel messages
  to push our infobox off-screen).

Reviewed by:	Allan Jude <freebsd@allanjude.com>
Discussed on:	-current
MFC after:	3 days
2013-11-08 09:57:03 +00:00
Gleb Smirnoff
09c7b5a460 Catch up with sb_timeo type change in r255138. This fixes
smbfs operation.

PR:		kern/182963
Submitted by:	Tomoaki AOKI <junchoon dec.sakura.ne.jp>
2013-11-08 08:44:09 +00:00
Ian Lepore
6abd71b021 Build kernel tools along with other tools during world build, as well as
during kernel build (if they didn't get done with world).  This will make
-DMODULES_WITH_WORLD work, and it ensures the kernel tools are built
as part of 'make kernel-toolchain'.
2013-11-08 05:11:32 +00:00
Steven Hartland
e2b8af8404 Corrected definition for old_rate to match d_rotation_rate
MFC after:	2 Days
X-MFC-With:	r256956
2013-11-07 23:21:52 +00:00
Devin Teske
f913e67483 Document SYSRC_VERBOSE enviroment variable in the manual. 2013-11-07 23:05:17 +00:00
Devin Teske
379cb6ba59 Fix a bug with -e' that broke sometime around when I added -F'. Also,
revamp the `-e' output to truly be sh(1) compatible syntax (even if
passed in `-v' for verbose output).
2013-11-07 23:04:40 +00:00
Devin Teske
671d0e72a7 Comments and whitespace. 2013-11-07 23:01:41 +00:00
Devin Teske
4cc57221da Add a -c' option for check only' to determine if a value is set
(get command) or if the current value is the same as what is desired
(set command). In those cases, the return status is success.
Otherwise, if the variable is unset (get command) or set to a different
value that what is desired (set command), returns with error status.
This is useful for puppet integration as well as everyday scripting.
2013-11-07 23:00:11 +00:00
Devin Teske
3e74984c3a Add new `--version' long option for getting the version (good for
comparing against the ports revision).
2013-11-07 22:52:10 +00:00
Ian Lepore
ed39dd91b1 Instead of modeling the kernel-tools build after the bootstrap tools, build
kernel tools the way cross-tools get built.  This seems to result in the
tool getting installed in the right place.  It also seems more correct in
retrospect, because if a tool emitted code or binary data as part of
building the kernel, it should do so in target-specific ways (endianess,
architecture, whatever).  That issue is moot for aicasm, our only current
tool, but it still seems to be more correct in principle.
2013-11-07 22:50:42 +00:00
Devin Teske
bb28b8697d Fix a bug that prevented `-d' from working as-documented in sysrc(8).
Rather, prevent a bunch of debugging information from spewing onto the
screen when using the `describe' flag (misinterpreted as `debug' by
the automatatic initialization routines).
2013-11-07 22:47:52 +00:00
Steve Kargl
30a919dde7 Yet, another attempt to fix the libm breakage due to the
changes in s_roundl.c to use bit twiddling.

Reported by:	ian
2013-11-07 22:46:13 +00:00
Devin Teske
546b5aacde Extend loader_delay as-documented in beastie.4th(8) and delay.4th(8), making it available to architectures that do not use or load the beastie
menu. This is reported to save headaches on some PPC systems where unload
followed by load does not produce the desired results wherein if-given
the opportunicy to abort the initial loading sequence, you can customize
the first load.

Reviewed by:    nwhitehorn, kan
Discussed on:   -current
2013-11-07 21:52:04 +00:00
Sean Bruno
ee7a2acac5 Add support for controlling mfi(4) controller properties:
allow user control of rebuild rate
allow user control of silence/enable alarm

MFC after:	2 weeks
Sponsored by:	Yahoo! Inc.
2013-11-07 21:47:59 +00:00
Devin Teske
29b5dbe844 Use `pkg -vv' to obtain ABI for validating a chosen media server (done
prior to diving head-long into a pkg-update(8), et. al). This should
also be more future-proof than what was being done just before this.
2013-11-07 21:38:46 +00:00
Steve Kargl
0e9dcedc67 Fix bulding libm on platforms with LDBL_MANT_DIG == 53.
Reported by:	ian
2013-11-07 21:20:34 +00:00
Devin Teske
6451dd7e0f Fix cosmetic typos (since the typo's in the variable names were copied
and pasted, it wasn't noticed).
2013-11-07 21:16:32 +00:00