Commit Graph

193190 Commits

Author SHA1 Message Date
Nathan Whitehorn
6be7abb3ff We should have an isync after switching MSR[SF] in bootstrap.
Submitted by:	Mark Millard
MFC after:	3 days
2014-09-23 04:13:21 +00:00
Justin Hibbits
a1c1634858 Stage one of multipass suspend/resume
Summary:
Add the beginnings of multipass suspend/resume, by introducing
BUS_SUSPEND_CHILD/BUS_RESUME_CHILD, and move the PCI driver to this.

Reviewers: jhb

Reviewed By: jhb

Differential Revision: https://reviews.freebsd.org/D590
2014-09-23 02:56:40 +00:00
Peter Grehan
5ed6ab5baa Correct display of bhyve SMBIOS UUIDs with dmidecode by bumping the version.
The mixed little/big-endianness of SMBIOS UUIDs was clarified in v2.6
of the SMBIOS spec. dmidecode uses the reported version of SMBIOS to
determine the layout and what to byte-swap.

bhyve's SMBIOS reported as 2.4 though it implemented the 2.6-style of
memory layout. This resulted in dmidecode reporting a different
UUID than one passed in via the -U option.

Fix by exporting a version of 2.6.

Reviewed by:	tychon
Reported by:	julian
MFC after:	1 day
2014-09-23 01:17:22 +00:00
Mark Johnston
527e468fc9 Remove an incorrect close(2) call that was added in r271413.
Reported by:	Coverity
CID:		1238923
X-MFC-With:	r271413
2014-09-22 21:09:30 +00:00
Mark Johnston
f0de463732 Remove some variables that are no longer used as of r271413.
Reported by:	Coverity
CID:		1238924
X-MFC-With:	r271413
2014-09-22 21:02:38 +00:00
John Baldwin
166a4e4701 Switch from timeout(9) to callout(9). In addition, do not teardown the
IRQ handler while resetting the controller and add some missing teardown
actions in detach.

Reviewed by:	delphij
2014-09-22 20:38:01 +00:00
Li-Wen Hsu
e444e04b67 Reflect the chanages in sleepqueue.h and subr_sleepqueue.c
- Priority argument is introduced to sleepq_*wait* in r177085
- sleepq_calc_signal_retval is removed from implementation
- sleepq_catch_signals is internal now

Differential Revision:	https://reviews.freebsd.org/D794
Reviewed by:	jhb
Approved by:	jhb
2014-09-22 19:14:27 +00:00
Sean Bruno
243d6a501a UPDATING: linux-c6 support notes, and how to fall back to linux-f10.
PR:		187786
MFC after:	2 days
Relnotes:	yes
2014-09-22 19:07:27 +00:00
John Baldwin
cd5d81ba41 Fix build for kernels without COMPAT_FREEBSD32. 2014-09-22 17:32:27 +00:00
Sean Bruno
d143d69857 Bump minimum linux compat version to support Centos6 ports updates for linux.
Update linux compat minimum revision to match linux-c6 now in ports.  This
is a candidate for 10.1 R as it matches the current state of supported
linux compat packages in the ports tree.

PR:		187786
Reviewed by:	xmj
MFC after:	2 days
Relnotes:	yes
2014-09-22 17:26:07 +00:00
Marcel Moolenaar
e286914f45 Rename the tests to something more meaningful. I spent way too long
trying to get the test name right, failed, gave up and used a sequence
number instead. When I realized it wasn't because of the number of
underscores in the name that I really started to think. I didn't have
braces around the variable names ...

Thus: test_1 is now called apm_1x1_512_qcow, which gives you all you
need to run mkimg by hand.

Dumb-ass: marcel
2014-09-22 16:52:09 +00:00
Cy Schubert
11eb83e638 Check for NULL before de-refencing; in particular sel is assigned to NULL,
in the default case, and then couple of lines down we do sel->

Approved by:	glebius (mentor)
Obtained from:	NetBSD CVS repo (r1.5)
2014-09-22 16:45:28 +00:00
Marcel Moolenaar
66829acbb3 Don't update the baseline file when the result of the test is identical
to the baseline. Since we don't run gzip with the -n option, the output
of gzip varies for identical result files if and when they are created
at different time. Ouch...

Rather than add -n and commit a 600K+ diff for the changes to all the .uu
files, it's less of a churn to uudecode and gunzip the baseline file and
compare that to the new result file to determine if the baseline file
needs to be updated.

This way, "atf-sh mkimg.sh rebase" can be run as many times as people like
and a subsequent "svn status" will not show unnecessary diffs.
2014-09-22 16:37:37 +00:00
Cy Schubert
24211cc919 #552 destination port not zero after parsing nat rule
Approved by:	glebius (mentor)
Obtained from:	netbsd CVS repo (r1.4), ipfilter CVS repo (r1.38)
2014-09-22 16:35:48 +00:00
Cy Schubert
19455ef7e4 3561691 gethost never returns an ipv6 address
Approved by:	glebius (mentor)
Obtained from:	ipfilter CVS repo (r1.34), netbsd CVS repo (r1.4)
2014-09-22 16:21:25 +00:00
John Baldwin
9696feebe2 Add a new fo_fill_kinfo fileops method to add type-specific information to
struct kinfo_file.
- Move the various fill_*_info() methods out of kern_descrip.c and into the
  various file type implementations.
- Rework the support for kinfo_ofile to generate a suitable kinfo_file object
  for each file and then convert that to a kinfo_ofile structure rather than
  keeping a second, different set of code that directly manipulates
  type-specific file information.
- Remove the shm_path() and ksem_info() layering violations.

Differential Revision:	https://reviews.freebsd.org/D775
Reviewed by:	kib, glebius (earlier version)
2014-09-22 16:20:47 +00:00
Rui Paulo
447666f08b Improvements to asmc(4):
1. changed the code so that 2**16 keys are supported
2. changed the number of possible fans in a system from 2 to 6
3. added write support for some fan sysctls
4. added a new sysctl which shows the ID of the fan
5. added four more apple models with their temperature keys
6. changed the maxnumber of temperature keys from 36 to 80
7. replaced several fixed buf sizes to sizeof buf

Obtained from:	Denis Ahrens denis at h3q.com
MFC after:	4 weeks
2014-09-22 16:20:38 +00:00
Cy Schubert
8a07b9a5c4 #551 ipf.conf address structure not properly zero filled
Approved by:	glebius (mentor)
Obtained from:	ipfilter CVS repo (r1.37), netbsd CVS repo (r1.3)
2014-09-22 16:13:38 +00:00
Cy Schubert
01991654f8 #536 ipnat can try to print rule as dstlist incorrectly
Approved by:	glebius (mentor)
Obtained from:	ipfilter CVS repo (r1.14), netbsd CVS repo (r1.3)
2014-09-22 16:09:18 +00:00
Cy Schubert
3f3423a0ef #553 gethost needs to zero entire IP address structure
Approved by:	glebius (mentor)
Obtained from:	ipfilter CVS repo (r1.11)
2014-09-22 16:06:37 +00:00
Cy Schubert
c5c5a79fce ipv6 address for test.hosts.dots in wrong byte order.
Approved by:	glebius (mentor)
Obtained from:	ipfilter CVS repo (r1.11), netbsd CVS repo (r1.5)
2014-09-22 16:03:29 +00:00
Marcel Moolenaar
c9b97e3bda Don't echo '# $FreeBSD$' as the first line into the .uu file. Keyword
substitution applies to this file, including the echo command. Avoid
the match (and substitution) by breaking the string up into 3 parts.
2014-09-22 15:27:23 +00:00
Marcel Moolenaar
572950ab03 Update the unit tests to include the QCOW (version 1) format.
This is a good safety net for when V2 is added.
2014-09-22 15:08:58 +00:00
Marcel Moolenaar
38501a4664 Add support for QCOW version 1. Version 2 is partially implemented.
And because of that, it's entirely disabled for now. Both versions
are similar enough that a single header definition works for both
of them. The only "diverting" side-effect is that the union of the
two is larger than the official V1 header.

What this means for our V1 support is that we can't put the L1 table
adjacent to the V1 header (i.e. at offset 0x30 in the file), unless
we revert to hackery and klugery. Let's not. Instead, we align the L1
table at the cluster boundary. This is in line with the V2 layout and
perfectly ok for V1 anyway (ok -- as far as I've seen so far).
Due to the alignment, our V1 image seems to be 1 cluster larger than
the V1 image created by qemu-img (on average).

Compression of the clusters is not supported at this time.

MFC after:	2 months
2014-09-22 15:05:28 +00:00
John Baldwin
fadf3fb98c Convert from timeout(9) to callout(9). 2014-09-22 14:27:26 +00:00
Edward Tomasz Napierala
a5b1f2ab54 Add missing mlinks for section 9.
MFC after:	2 weeks
Sponsored by:	The FreeBSD Foundation
2014-09-22 13:04:49 +00:00
Alexander Motin
5b5ad15088 Pretend that we support BYTCHK=1 in WRITE AND VERIFY command.
Technically that is not true, but since we don't implement VERIFY there
at all, doing only WRITE part, this is a minor sin.
2014-09-22 12:40:43 +00:00
Stefan Eßer
0fc950b70a The new naming scheme for keymap files for use with vt(4) introduced a
collision for "no" as a country code with "NO" meaning "do not load any
keymap" (which also has been the default value in etc/defaults/rc.conf
for a long time).

The result of this collision is, that "kbdcontrol -l no" will load the
Norwegian keymap, while "keymap=no" in rc.conf was interpreted as the
lower case spelling of "NO" meaning "no keyboard" (and "no.kbd" was not
loaded).

Fix this by matching only the upper-case spelling "NO" in rc.d/syscons
when deciding whether to load a keymap file.

This will lead to "no.kbd" being loaded, if the until now valid (but
non-default) spelling "no" was used in an individual rc.conf file to mean
"no keyboard". But all alternatives I could think of introduce a larger
violation of POLA ...

Reported by:    Gyrd Thane Lange (gyrd-se at thanelange.no)
MFC after:	3 days
2014-09-22 11:54:13 +00:00
Alexander Motin
228e6f4296 Fix read overrun handling, broken by using wrong variable.
MFC after:	3 days
2014-09-22 11:35:06 +00:00
Alexander Motin
227b3b9229 Deny ANCHOR flag set without UNMAP flag set in WRITE SAME commands. 2014-09-22 10:46:06 +00:00
Hans Petter Selasky
090817577b Some XHCI hardware requires dropping the endpoint context before
adding it again.

MFC after:	3 days
Submitted by:	Kohji Okuno <okuno.kohji@jp.panasonic.com>
2014-09-22 10:21:42 +00:00
Alexander Motin
9a9fbc3dbd Don't try to continue aborted commands if status was not set. 2014-09-22 10:05:36 +00:00
Julio Merino
1ed3631a02 Register /usr/tests/lib/libproc to fix build.
Missed in r271937, reviewed in D710.
2014-09-22 09:54:48 +00:00
Alexander Motin
4a6d9c740a Fix UNMAP stuck if the last block descriptor in the list is empty.
MFC after:	3 days
2014-09-22 09:22:58 +00:00
Hans Petter Selasky
9fd573c39d Improve transmit sending offload, TSO, algorithm in general.
The current TSO limitation feature only takes the total number of
bytes in an mbuf chain into account and does not limit by the number
of mbufs in a chain. Some kinds of hardware is limited by two
factors. One is the fragment length and the second is the fragment
count. Both of these limits need to be taken into account when doing
TSO. Else some kinds of hardware might have to drop completely valid
mbuf chains because they cannot loaded into the given hardware's DMA
engine. The new way of doing TSO limitation has been made backwards
compatible as input from other FreeBSD developers and will use
defaults for values not set.

Reviewed by:	adrian, rmacklem
Sponsored by:	Mellanox Technologies
MFC after:	1 week
2014-09-22 08:27:27 +00:00
Alexander Motin
2f872218e7 Simplify legacy reservation handling. Drop it on I_T nexus loss. 2014-09-22 07:59:25 +00:00
Sean Bruno
7c51714e0a svn revisions r269964 and r269963 seemed to have impaired small memory
footprint systems(32M/64M) and didn't leave enough free memory to load modules
when it was setting up page tables that for sizes that are never used on
these smallish boards.

Set kmem_zmax to PAGE_SIZE on these smaller systems (< 128M) to keep this
from happening. Verified on mips32 h/w.

PR:             193465
Submitted by:   delphij
Reviewed by:    adrian
2014-09-22 05:07:22 +00:00
Alexander Motin
b0737f1a67 Don't report unsupported FUA_NV bit set in READ/WRITE commands as error.
While this bit is obsolete in SBC-3, SBC-2 allowed to silently ignore it.
2014-09-22 01:17:48 +00:00
Alexander Motin
d69a1908fc Report proper errors codes for unsupported SERVICE ACTION values. 2014-09-22 01:04:27 +00:00
Alexander Motin
2db9b8b5a0 Polish INQUIRY command fields validation. 2014-09-22 00:40:20 +00:00
Mark Johnston
211d5708c9 Ignore a test program which doesn't compile at the moment. It will be
addresed properly when integrating the DTrace tests with Kyua.
2014-09-21 21:31:16 +00:00
Mark Johnston
9351ac6d69 Add some ATF tests for libproc.
Differential Revision:	D710
Reviewed by:	jmmv, ngie, rpaulo
2014-09-21 21:25:41 +00:00
Jilles Tjoelker
000dda7b47 sh(1): Clarify that assignments before commands do not affect expansions.
PR:		193759
MFC after:	1 week
2014-09-21 20:34:54 +00:00
Steven Hartland
137a165dd3 Output boot code warning when zpool upgrade -a is used to add features.
In the case where new features where enabled by a zpool upgrade -a the
boot code warning wasn't output.

Submitted by:	Jan Kokemueller
MFC after:	3 days
2014-09-21 19:31:19 +00:00
Dimitry Andric
819c857f10 Add a few missing llvm/clang patches, update the other ones to be able
to apply with the same patch options onto a fresh upstream llvm/clang
3.4.1 checkout, and use approximately the same header tempate for them.

MFC after:	3 days
2014-09-21 15:37:39 +00:00
Alexander Motin
c7a7dbbc0b Allow SUBPAGE CODE field in MODE SENSE commands. 2014-09-21 14:39:31 +00:00
Edward Tomasz Napierala
31a4b1aa03 Turns out -1 is a perfectly valid error number, ERESTART. Remove useless
code written under assumption that it wasn't.

Sponsored by:	The FreeBSD Foundation
2014-09-21 10:34:15 +00:00
Alexander Motin
b81577dd23 Mention read_ahead tunables/sysctls.
MFC after:	1 month
2014-09-21 10:05:27 +00:00
Konstantin Belousov
060cd4d500 Update and clarify comments. Remove the useless counter for impossible, but
seen in wild situation (on buggy hypervisors).

In collaboration with:	bde
MFC after:	1 week
2014-09-21 09:06:50 +00:00
Hiroki Sato
9f21b0b8b2 Fix build. 2014-09-21 07:16:51 +00:00