Commit Graph

185999 Commits

Author SHA1 Message Date
Ed Maste
a4849615b2 Update LLDB to upstream r196322 snapshot
Upstream revisions of note:
r196298 - Fix use of std::lower_bound
r196322 - Fix log message for new invalidation checks

Sponsored by:	DARPA, AFRL
2013-12-03 22:26:38 +00:00
Ed Maste
de889deb2c Import lldb as of SVN r196322 (git 49c127ae)
(A number of files not required for the FreeBSD build have been removed.)

Sponsored by: DARPA, AFRL
2013-12-03 22:13:33 +00:00
Colin Percival
b6ae696fc9 The rc system aggressively caches the contents of /etc/rc.conf in order to
improve boot performance; this produces arguably astonishing (non-)results
if /etc/rc.conf is modified during the boot process.

Since performance considerations make it infeasible to automatically detect
if the cached /etc/rc.conf parameters should be invalidated, provide a
mechanism for explicitly requesting that /etc/rc.conf be reloaded: Catch
SIGALRM and reload /etc/rc.conf if it is received.

Discussed on:	freebsd-rc
MFC after:	3 days
2013-12-03 21:55:57 +00:00
Colin Percival
1cdbb9ed2b Add a new sysctl / loader tunable kern.panic_reboot_wait_time which
defaults to PANIC_REBOOT_WAIT_TIME (a long-existing kernel config
setting).  Use this now-variable value in place of the defined constant
to control how long the system waits after a panic before rebooting.
2013-12-03 21:35:25 +00:00
Ed Maste
04c171520d lldb: Threaded inferior support for FreeBSD
This is in the process of being submitted to the upstream LLDB
repository.  The thread list functionality is modelled in part on
GDBRemoteCommunicationClient.

LLDB bug pr16696 and code review D2267

Sponsored by:	DARPA, AFRL
2013-12-03 21:29:45 +00:00
John Baldwin
d4e3c0a2d7 Various updates and tweaks to the wait(2) manpage.
PR:		docs/183904
Submitted by:	Michael Galassi <michaelgalassi@gmail.com>
Reviewed by:	kib, wblock (earlier version)
2013-12-03 21:00:13 +00:00
Ed Maste
b952cd584f Update LLDB to upstream r196259 snapshot
Sponsored by:	DARPA, AFRL
2013-12-03 19:23:54 +00:00
Ed Maste
86758c7188 Import lldb as of SVN r196259 (git 3be86e5)
(A number of files not required for the FreeBSD build have been removed.)

Sponsored by:	DARPA, AFRL
2013-12-03 18:51:59 +00:00
Navdeep Parhar
05337b80ee cxgbe(4): T4_SET_SCHED_CLASS and T4_SET_SCHED_QUEUE ioctls to program
scheduling classes in the chip and to bind tx queue(s) to a scheduling
class respectively.  These can be used for various kinds of tx traffic
throttling (to force selected tx queues to drain at a fixed Kbps rate,
or a % of the port's total bandwidth, or at a fixed pps rate, etc.).

Obtained from:	Chelsio
2013-12-03 18:34:52 +00:00
Ed Maste
9151c81ccb Workaround lldb issue with main module base address
On FreeBSD lldb sometimes reloads the the main module's (executable's)
symbols at the wrong address.  Work around this for now by explicitly
reloading at base_address=0 when it happens.

A proper fix is needed but early testers have reported this issue so
this workaround should allow them to make further progress.

http://llvm.org/bugs/show_bug.cgi?id=17880
2013-12-03 18:12:51 +00:00
Edward Tomasz Napierala
025a2301f8 Properly report an error instead of panicing when user tries to create
LUN backed by non-disk device, e.g. /dev/null.

Reviewed by:	ken (earlier version)
MFC after:	3 days
Sponsored by:	The FreeBSD Foundation
2013-12-03 18:04:14 +00:00
John Baldwin
5457fa234b Fix an off-by-one error in r228960. The maximum priority delta provided
by SCHED_PRI_TICKS should be SCHED_PRI_RANGE - 1 so that the resulting
priority value (before nice adjustment) is between SCHED_PRI_MIN and
SCHED_PRI_MAX, inclusive.

Submitted by:	kib
Reported by:	pho
MFC after:	1 week
2013-12-03 14:50:12 +00:00
Pawel Jakub Dawidek
3ed6dfa678 Add libcapsicum and libcasper libraries that were moved from /usr/lib/ to /lib/.
Reviewed by:	glebius
2013-12-03 13:38:13 +00:00
Pawel Jakub Dawidek
9a2d4197a7 Initialize cookie before use.
Reported by:	Coverity
Coverity CID:	1135292
2013-12-03 13:28:05 +00:00
Pawel Jakub Dawidek
fecba05b97 Fix comparisons in assertions.
Reported by:	Coverity
Coverity CID:	1130048
2013-12-03 13:26:37 +00:00
Eitan Adler
c9f609a92f Add DragonFly BSD fingerprints to pf.os
Obtained From:	DragonFly BSD (commit 321b0bb006b0857d2c212dc8cd12a36d750bcf9a)
2013-12-03 04:32:02 +00:00
Eitan Adler
326f183e4b Add an autologin entry for the console.
Obtained From:	DragonFly BSD (commit f95025e8c9a4471edb610557263b12acd8e7fb3a)
2013-12-03 04:13:55 +00:00
Eitan Adler
edf06f9a53 Add Veritas NetBackup
Obtained From:	DragonFly BSD
2013-12-03 04:03:19 +00:00
Eitan Adler
67e7600bcc Add the Short Message Peer-to-Peer protocol
PR:		conf/183398
Submitted by:	olgeni
2013-12-03 03:57:22 +00:00
Mark Johnston
33d8425001 Use mkstemp(3) to create the temporary file used in the FreeBSD-specific
portions of dtrace_program_link().
2013-12-03 03:40:47 +00:00
Neel Natu
7a3c80aa55 The 'protection' field in the VM exit collateral for the PAGING exit is not
used - get rid of it.
2013-12-03 01:21:21 +00:00
Neel Natu
2282187475 Rename 'vm_interrupt_hostcpu()' to 'vcpu_notify_event()' because the function
has outgrown its original name. Originally this function simply sent an IPI
to the host cpu that a vcpu was executing on but now it does a lot more than
just that.

Reviewed by:	grehan@
2013-12-03 00:43:31 +00:00
Attilio Rao
3cd260b222 Right now LOCK_DEBUG is enabled if KTR is on.
This is to support LOCK_LOG_* functionality effectively in debugging
environments but it is overkill because really LOCK_DEBUG should be on
only if (KTR_COMPILE & KTR_LOCK) is true.
Fix this by applying the correct logic.
In this process, move the KTR classes to its own header to reduce
namespace pollution.

Sponsored by:	EMC / Isilon storage division
Reviewed by:	jhb
2013-12-02 22:34:47 +00:00
Nathan Whitehorn
c5476f1b8b Fix typo. 2013-12-02 22:00:15 +00:00
Joel Dahl
0947c55b71 mdoc: quote string properly. 2013-12-02 19:49:52 +00:00
Glen Barber
b24db45b3f Fix PKG_ABI detection in bsdconfig(8) after pkg-1.2 is released, since
the format of 'pkg -vv' output has changed.

MFC after:	3 days
Sponsored by:	The FreeBSD Foundation
2013-12-02 19:02:58 +00:00
Glen Barber
f7f650c76a Turn off the dvdrom target by default. dvd1.iso is now built by
specifying 'WITH_DVD=1' during 'make release'.

This caused some problems during the freebsd-update builds for
10.0-BETA4.

MFC after:	3 days
Sponsored by:	The FreeBSD Foundation
2013-12-02 18:47:57 +00:00
Nathan Whitehorn
fa6b4c32ba Remove fdtbus_bs_tag definition, which is now obsolete. The remainder of
this file is also slated for future demolition.
2013-12-02 17:45:43 +00:00
Pawel Jakub Dawidek
0f984a9260 Both libcasper and libcapsicum libraries have to be installed in /lib/,
as they are used by /sbin/casperd.
2013-12-02 17:07:22 +00:00
Pawel Jakub Dawidek
ca9aa9026b Regression tests for existing Casper services.
Sponsored by:	The FreeBSD Foundation
2013-12-02 17:01:01 +00:00
Glen Barber
4e11928ded Provide reproducibility between builds by building pkg(8) from ports,
instead of using pkg-bootstrap.

This should resolve a problem that was discovered during 10.0-BETA4
freebsd-update(8) builds,

Reported by:	secteam (delphij)
MFC after:	3 days
X-MFC-to-10:	possibly immediately, pending freebsd-update(8) builds
Sponsored by:	The FreeBSD Foundation
2013-12-02 14:28:30 +00:00
Zbigniew Bodek
a92a06d31a Enable missing Access Flag for secondary cores on ARMv6/v7
Spotted by:	Wojciech Macek <wma@semihalf.com>
Obtained from:	Semihalf
2013-12-02 13:09:59 +00:00
Pawel Jakub Dawidek
05af64096c Forgot to 'svn add' lib/libcasper/ directory.
Reported by:	glebius
2013-12-02 10:18:25 +00:00
Edward Tomasz Napierala
5292c670c2 Grammar fix.
MFC after:	3 days
Sponsored by:	The FreeBSD Foundation
2013-12-02 09:47:22 +00:00
Edward Tomasz Napierala
5d02cc7ff9 Fix typos.
MFC after:	3 days
Sponsored by:	The FreeBSD Foundation
2013-12-02 09:23:34 +00:00
Kevin Lo
405886883d The RUN_MAX_TXSZ constat is defined as Tx desc + Tx wireless info + MCLBYTES +
max padding.  We were lucky in that run(4) working fine since both
rt2860_rxwi and rt2860_txwi structure sizes are the same.
2013-12-02 09:07:43 +00:00
Pawel Jakub Dawidek
42a8595256 Please welcome casperd daemon. It (and its services) will be responsible for
giving access to functionality that is not available in capability mode
sandbox. The functionality can be precisely restricted.

Start with the following services:
- system.dns - provides API compatible to:
	- gethostbyname(3),
	- gethostbyname2(3),
	- gethostbyaddr(3),
	- getaddrinfo(3),
	- getnameinfo(3),
- system.grp - provides getgrent(3)-compatible API,
- system.pwd - provides getpwent(3)-compatible API,
- system.random - allows to obtain entropy from /dev/random,
- system.sysctl - provides sysctlbyname(3-compatible API.

Sponsored by:	The FreeBSD Foundation
2013-12-02 08:21:28 +00:00
Adrian Chadd
352c016bc1 * Sort the copyright lines by date
* Ok ok, I've touched this enough to claim part of it.
2013-12-02 05:45:11 +00:00
Pyun YongHyeon
67129934a9 Add support for BCM57764, BCM57767, BCM57782, BCM57786 and BCM57787.
Submitted by:	jhb
PR:	184304
2013-12-02 05:21:54 +00:00
Adrian Chadd
fee842aa2a Overhaul the iwn(4) scan infrastructure to be slightly more "correct"
for these chipsets.

* Correctly set the active/passive flag in the scan request - this is
  NOT a "is the channel active|passive"; it's to do with whether we
  have an SSID to actively scan for or not.  The firmware takes care
  of the active/passive setup of the channel.

* Calculate the active/passive dwell time based on the beacon interval
  and the channel mode, rather than using a hard coded value.

* For now, hardcode the scan service_time.  It's defined as:

  31:22 - number of beacon intervals to come back onto the home channel
          for;
  0:21  - time (microseconds) to come back onto the home channel for.

  When doing an active scan when the NIC is active (whether we're associated
  or not - it only matters if we've setup the NIC to a destination or not)
  this determines how much time to stay on the home channel for when
  scanning.  We can tune this based on the amount of active traffic.

  For now it's 4 beacon intervals and 100 microseconds.

* Fix the "good crc threshold" setting.  It differs based on the NIC
  firmware.  Some older firmware required a workaround; the later
  firmware instead treats the field as a flag.

* Enforce that we are not sending a scan command if one is already
  pending.  Any time this is done is a bug and it absolutely needs
  to be fixed - so be very loud.

* Add the SCAN flag to a few debug messages that are scan related but
  only occuring under STATE.

Now, this does get noisy when you're scanning in an actively busy 2GHz
network as the firmware (for reason I don't quite yet understand) seems
hell bent on staying on some passive channels longer than it should.
However, it should eventually recover and complete the scan.

This is a work in progress; please let me know if things get stuck or
if things improve!

Tested:

* intel centrino 2200
* intel centrino 2230
* intel 6200
* intel 5100
* intel 4965 (gets upset, but that's a known issue)

Obtained from:	linux iwlwifi
2013-12-02 03:59:45 +00:00
Ian Lepore
f32d80bf1f Add a nand flash controller driver for Atmel at91 family. Tested only
on at91rm9200 so far.

The files.at91 has listed a nand driver for ages, but it never existed.
2013-12-02 03:52:40 +00:00
Adrian Chadd
d27bb17b9c Log the rx ring offset as part of the debug message. 2013-12-02 03:49:33 +00:00
Pedro F. Giffuni
51e28103da libcpp: Merge fixes from upstream
GCC preprocessor/29966:
* macro.c (lex_expansion_token): Save and restore cpp_reader's
cur_token.
(_cpp_create_definition): Don't restore cur_token here.
* lex.c (_cpp_lex_token): Added assertion.

GCC preprocessor/28709:
* macro.c (paste_tokens): Remove PASTE_LEFT from the old lhs.

GCC c/31924
* expr.c (interpret_float_suffix): Check for invalid suffix.

GCC preprocessor/14331
* lex.c (_cpp_get_fresh_line):  Don't warn if no newline at EOF.

Fixup whitespacing

Obtained from:	gcc per-4.3 (rev. 121340, 124356, 124358, 124730,
				  125212, 125255 ; GPLv2)
MFC after:	3 weeks
2013-12-02 03:47:08 +00:00
Adrian Chadd
30ca148cf7 Oops - fix bad indent. Sorry! 2013-12-02 03:43:37 +00:00
Adrian Chadd
9d8e8cd665 Add some sanity checks to the TLV fetch.
Obtained from:	Linux iwlwifi
2013-12-02 03:42:39 +00:00
Adrian Chadd
c6f810c6a4 Add some code to double-check whether we're correctly populating the
TX ring according to what the firmware requires.

The firmware requires A-MPDU sub-frames to be at a very specific ring
offset - that is, the ring slot offset should be (seqno % 256.)

This holds for every NIC I've tested thus far except the 4965,
which starts erroring out here shortly before the firmware panics.
Which is good, it's doing what it's supposed to (read: capture that
we've screwed up somewhere.)

The specifics about getting this stuff right:

* the initial seqno allocation should match up with the ringid.
* .. yes, this means we can start at a ring offset that isn't zero.
* .. because we program the start seqno in the firmware message
  to setup the AC.
* The initial seqno allocation may be non-zero _and_ frames may be
  being transmitted during a-mpdu negotiation.  I faced similar
  issues on ath(4) and had to software queue frames to that node+TID
  during A-MPDU negotiation.
* seqno allocation should be in lockstep with ring increments.
* If we fail to transmit some segment, no, we shouldn't reuse that
  ring slot.  We should just transmit a BAR (which we aren't yet
  doing, sigh) and move onto the next seqno.
* In theory there shouldn't be any holes in the seqno space when
  we are transmitting frames.

Tested:

* 4965 (throws problems, so yes we have to fix this);
* 5100 (seems ok);
* 6200 (seems ok);
* 2200 (seems ok);
* 2230 (seems ok).
2013-12-02 03:40:51 +00:00
Eitan Adler
2526f9d725 Partial revert of r258779 and r258780:
The directory sys/dev/drm2/i915 is apperently contributed code.
	Revert to the broken version of this file to make future imports easier.

Requested by:	kib
2013-12-02 03:36:44 +00:00
Eitan Adler
5f30ec9b63 In a situation where:
- The remote host sends a FIN
	- in an ACK for a sequence number for which an ACK has already
	  been received
	- There is still unacked data on route to the remote host
	- The packet does not contain a window update

The packet may be dropped without processing the FIN flag.

PR:		kern/99188
Submitted by:	Staffan Ulfberg <staffan@ulfberg.se>
Discussed with:	andre
MFC after:	never
2013-12-02 03:11:25 +00:00
Ian Lepore
ca38150ce3 Add definitions for the additional PIO pins found on recent AT91 SoCs. 2013-12-02 02:33:03 +00:00
Nathan Whitehorn
3cb6654d23 Add new sysctl, kern.supported_abis, containing the list of FreeBSD
MACHINE_ARCH values whose binaries this kernel can run. This patch provides
a feature requested for implementing pkgng ABI identifiers in a robust
way.

The list is designed to indicate whether, say, an i386 package can be run on
the current system. If kern.supported_abis contains "i386", then the answer
is yes. Otherwise, the answer is no.

At the moment, this only supports MACHINE_ARCH and MACHINE_ARCH32. As we
gain support for more interesting combinations, this needs to become more
flexible, possibily through the sysent framework, along with the
hw.machine_arch emulation immediately preceding this code in kern_mib.c.

Reviewed by:	imp
MFC after:	3 days
2013-12-02 00:44:36 +00:00