hselasky [Sun, 25 May 2014 18:15:37 +0000 (18:15 +0000)]
MFC r266541:
- Fix a bug where the TLBPC value was forced to being odd for IN
direction isochronous transfers.
- Remove setting of fields which does not belong to the respective
TRBs. These fields are currently set as zero and this is more a
cosmetic change.
gjb [Sun, 25 May 2014 18:07:23 +0000 (18:07 +0000)]
MFC r266553, r266554:
r266553:
Add forward-compatibility glue with pkg-1.3:
- Use ASSUME_ALWAYS_YES=YES instead of ASSUME_ALWAYS_YES=1
since pkg-1.3 expects "yes" or "true" values.
- Before exporting PKG_ABI, strip extra characters from what
is parsed from 'pkg -vv'. This causes problems further down
when creating the packages directory for inclusion on the
dvd1.iso. Previously PKG_ABI would be 'freebsd:9:x86:64',
but now is '"freebsd:9:x86:64";' in pkg-1.3.
r266554:
Disable the main FreeBSD pkg(7) repositories in the dvd
repository configuration to avoid fetching from upstream
in case there may be conflicts.
Approved by: re (marius)
Sponsored by: The FreeBSD Foundation
gavin [Thu, 22 May 2014 20:59:38 +0000 (20:59 +0000)]
Merge r266111 from head:
Fix typo. Note that although this file is under contrib, it has diverged
sufficiently from upstream (including a full whitespace commit and large
portions rewritten) that this change does not move us further from the
upstream.
ken [Thu, 22 May 2014 16:36:01 +0000 (16:36 +0000)]
MFC mpr(4) changes: r265484, r265485, r265709 and r265712
------------------------------------------------------------------------
r265484 | ken | 2014-05-06 23:11:16 -0600 (Tue, 06 May 2014) | 5 lines
Remove some debugging code.
Submitted by: Steve McConnell <stephen.mcconnell@avagotech.com>
------------------------------------------------------------------------
------------------------------------------------------------------------
r265485 | ken | 2014-05-06 23:14:48 -0600 (Tue, 06 May 2014) | 9 lines
Hold the SIM lock when calling xpt_create_path() and xpt_action() in
mprsas_SSU_to_SATA_devices().
This fixes an assertion on shutdown with INVARIANTS enabled with SATA
drives present on an IR firmware controller.
Reviewed by: Steve McConnell <stephen.mcconnell@avagotech.com>.
------------------------------------------------------------------------
------------------------------------------------------------------------
r265709 | ken | 2014-05-08 14:28:22 -0600 (Thu, 08 May 2014) | 15 lines
Fix TLR (Transport Layer Retry) support in the mps(4) and mpr(4) drivers.
TLR is necessary for reliable communication with SAS tape drives.
This was broken by change 246713 in the mps(4) driver. It changed the
cm_data field for SCSI I/O requests to point to the CCB instead of the data
buffer. So, instead, look at the CCB's data pointer to determine whether
or not we're talking to a tape drive.
Also, take the residual into account to make sure that we don't go off the
end of the request.
Sponsored by: Spectra Logic Corporation
------------------------------------------------------------------------
------------------------------------------------------------------------
r265712 | ken | 2014-05-08 14:46:46 -0600 (Thu, 08 May 2014) | 10 lines
Add #ifdefs in the mpr(4) driver so that versions of stable/9 that
have implemented the PIM_NOSCAN rescan functionality will have it
enabled.
truckman [Thu, 22 May 2014 00:44:14 +0000 (00:44 +0000)]
MFC r266426
Slightly restructure the final loop in rman_reserve_resource_bound().
Replace with the existing loop termination test with a similar
condition from the nested "if" that may terminate the loop a bit
sooner, but still not too early. This condition can then be removed
from the nested "if". Relocate an operator to be style(9) compliant.
pho [Wed, 21 May 2014 15:17:22 +0000 (15:17 +0000)]
MFC r265534:
msync(2) must return ENOMEM and not EINVAL when the address is outside the
allowed range or when one or more pages are not mapped. This according to
The Open Group Base Specifications Issue 7.
rmacklem [Mon, 19 May 2014 16:15:27 +0000 (16:15 +0000)]
MFC: r227809
This patch enables the new/default NFS server's use of shared
vnode locking for read, readdir, readlink, getattr and access.
It is hoped that this will improve server performance for these
operations, since they will no longer be serialized for a given
file/vnode.
thomas [Mon, 19 May 2014 11:17:44 +0000 (11:17 +0000)]
MFC rev. 265926:
(NANO_CONFIG): New variable containing path of config file, so that
the configuration can reference additional files relative to its own
location.
(NANO_MODULES): If set to "default", install all built modules.
Also update mergeinfo for past MFC of rev. 265260.
marius [Mon, 19 May 2014 09:26:32 +0000 (09:26 +0000)]
MFC: r253654
Set the device description after we call uart_probe(). In uart_probe()
we call device-specific probe functions, which can (and typically will)
set the device description based on low-level device probe information.
In the end we never actually used the device description that we so
carefully maintained in the PCI match table. By setting the device
description after we call uart_probe(), we'll print the more user-
friendly description by default.
jhb [Sun, 18 May 2014 15:29:00 +0000 (15:29 +0000)]
MFC 264765,264766:
- Don't claim the adapter is idle if it is clearing a drive.
- Fix an off by one error when checking for the stop event. This
resulted in not showing the most recent event by default.
- When the stop even is hit, break out of the outer loop to stop
fetching more events.
dim [Sat, 17 May 2014 12:47:11 +0000 (12:47 +0000)]
MFC r266053:
Use the new -d option that was added to tblgen between llvm/clang 3.3
and 3.4 to generate dependency files for the '.inc.h' files generated
from .td files, and .sinclude those dependency files in clang.build.mk.
This will make future incremental builds of lib/clang and usr.bin/clang
work correctly, whenever any of the .td files get modified.
Note that this will not fix any problems with incremental builds from
*before* this revision, since there will not yet be any generated
dependency files. A quick workaround is to run the following:
find /usr/obj -type f -name '*.inc.h' | xargs rm
and then a regular incremental buildworld (e.g. with -DNO_CLEAN).
bdrewery [Sat, 17 May 2014 03:28:27 +0000 (03:28 +0000)]
MFC r265267:
Fix width/alignment of JID column. Make it support up to the maximum 7-wide
JIDs. On a system using jails for common tasks the JID can quickly increase.
bdrewery [Sat, 17 May 2014 03:23:45 +0000 (03:23 +0000)]
MFC r265249,r265250,r265251:
- Add -J command/flag to filter by jail name/jid. This will automatically
display the JID as well (the -j command/flag).
- Add a hint for 'u' and 'J' command that '+' displays all.
- Add J command to help.
cperciva [Fri, 16 May 2014 19:28:22 +0000 (19:28 +0000)]
Add xenhvm.ko, which can be loaded along with a !XENHVM kernel in order to
provide support for the Xen/HVM environment.
This code is compiled with XENHVM defined; since this would result in the
(no longer used) "last processed" values being included in PCPU data
structures, an additional MODXENHVM define is used to exclude those. This
allows KBI to be retained for both GENERIC and XENHVM kernel configurations
(which are not KBI compatible with each other).
This is a direct commit to stable/9, since stable/10 and HEAD have XENHVM
merged into the GENERIC kernel configuration (but the changes in stable/10
and HEAD cannot be MFCed as-is).
Discussed with: royger, gjb
Relnotes: FreeBSD 9.3-RELEASE can run in Xen/HVM environments,
including Amazon EC2, using GENERIC + xenhvm.ko.
cperciva [Fri, 16 May 2014 19:15:03 +0000 (19:15 +0000)]
Change Xen event channel "last processed" values from per-CPU to global.
In FreeBSD 9.x we only run this code on (virtual) CPU #0, so there is no
need for these to be per-CPU values. Retain the values in the per-CPU
data structure (when compiled with options XENHVM) for KBI compatibility.
This is a direct commit to stable/9, since the relevant code has been
substantially changed (in ways which cannot be easily MFCed) in HEAD and
stable/10.
ambrisko [Fri, 16 May 2014 15:46:28 +0000 (15:46 +0000)]
MFC 265555/MFS 265922
dd mrsas(4) driver from LSI official support of newer MegaRAID SAS
cards. LSI has been maintaining this driver outside of the FreeBSD
tree. It overlaps support of ThunderBolt and Invader cards that mfi(4)
supports. By default mfi(4) will attach to cards. If the tunable:
hw.mfi.mrsas_enable=1
is set then mfi(4) will not probe and attach to these newer cards and
allow mrsas(4) to attach. So by default this driver will not effect
a FreeBSD system unless mfi(4) is removed from the kernel or the
tunable is enabled.
mrsas(4) attaches disks to the CAM layer so it depends on CAM and devices
show up as /dev/daX. mfiutil(8) does not work with mrsas. The FreeBSD
version of MegaCli and StorCli from LSI do work with mrsas. It appears
that StorCli only works with mrsas. MegaCli appears to work with mfi(4)
and mrsas(4).
It would be good to add mfiutil(4) support to mrsas, emulations modes,
kernel logging, device aliases to ease the transition between mfi(4)
and mrsas(4).
Style issues should be resolved by LSI when they get committers approved.
The plan is get this driver in FreeBSD 9.3 to improve HW support.
Thanks to LSI for developing, testing and working with FreeBSD to
make this driver co-exist in FreeBSD. This improves the overall
support of MegaRAID SAS.
yongari [Fri, 16 May 2014 05:11:15 +0000 (05:11 +0000)]
MFC r265943:
Disable TX IP/TCP/UDP checksum offloading for RTL8168C/RTL8168CP.
Previously only TX IP checksum offloading was disabled but it's
reported that TX checksum offloading for UDP datagrams with IP
options also generates corrupted frames. Reporter's controller is
RTL8168CP but I guess RTL8168C also have the same issue since it
shall share the same core.
tuexen [Thu, 15 May 2014 20:27:57 +0000 (20:27 +0000)]
MFC r265691, r265713:
For some UDP packets (for example with 200 byte payload) and IP options,
the IP header and the UDP header are not in the same mbuf.
Add code to in_delayed_cksum() to deal with this case.
tuexen [Thu, 15 May 2014 20:24:51 +0000 (20:24 +0000)]
MFC r265455:
Remove unused code. This is triggered by the bugreport of Sylvestre Ledru
which deal with useless code in the user land stack:
https://bugzilla.mozilla.org/show_bug.cgi?id=1003929
tuexen [Thu, 15 May 2014 20:21:19 +0000 (20:21 +0000)]
MFC r264838:
Don't free an mbuf twice. This only happens in very rare error
cases where the peer sends illegal sequencing information in
DATA chunks for an existing association.
tuexen [Thu, 15 May 2014 20:06:29 +0000 (20:06 +0000)]
MFC r263922:
Handle an edge case of address management similar to TCP.
This needs to be reconsidered when the address handling
will be reimplemented.
The patch is from rrs@.
tuexen [Thu, 15 May 2014 20:01:21 +0000 (20:01 +0000)]
MFC r263237:
* Provide information in error causes in ASCII instead of
proprietary binary format.
* Add support for a diagnostic information error cause.
The code is sysctlable and the default is 0, which
means it is not sent.
cperciva [Thu, 15 May 2014 18:14:19 +0000 (18:14 +0000)]
MFC r265876:
In cf_get_method, when we don't already know what clock speed the CPU is
running at, guess the nearest value instead of looking for a value within
25 MHz of the observed frequency.
Prior to this change, if a system booted with Intel Turbo Boost enabled,
the dev.cpu.0.freq sysctl is nonfunctional, since the ACPI-reported
frequency for Turbo Boost states does not match the actual clock frequency
(and thus no levels are within 25 MHz of the observed frequency) and the
current performance level is read before a new level is set.
Relnotes: Bug fix in power management on CPUs with Intel Turbo Boost
tuexen [Wed, 14 May 2014 19:00:01 +0000 (19:00 +0000)]
MFC r263096:
Put the offset of the CRC32C in csum_data instead of 0.
The virtio driver needs the offset to be stored in csum_data,
like in the case for UDP and TCP.
The virtio problem was reported by
Niu Zhixiong <kaiaixi@gmail.com>, who helped in debugging
and testing the patch.
tuexen [Wed, 14 May 2014 18:23:57 +0000 (18:23 +0000)]
MFC r260257:
Fix several bugs in sctp_bindx():
* Set errno to EAFNOSUPPORT if an address is provided which is neither
AF_INET nor AF_INET6.
* Don't modify the arguments.
* Don't smash the stack when provided with a non-zero port.
* Handle the case correctly where the first address provided is
an IPv6 address.
tuexen [Wed, 14 May 2014 18:20:35 +0000 (18:20 +0000)]
MFC r258765:
In
http://svnweb.freebsd.org/changeset/base/258221
I introduced a bug which initialized global locks
whenever the SCTP stack initialized. This was fixed in
http://svnweb.freebsd.org/changeset/base/258574
by rodrigc@. He just initialized the locks for
the default vnet. This fix reverts to the old
behaviour before r258221, which explicitly makes
sure it is only called once, because this works also on
other platforms.
tuexen [Wed, 14 May 2014 18:18:16 +0000 (18:18 +0000)]
MFC r258574 from rodrigc@
Only initialize some mutexes for the default VNET.
In r208160, sctp_it_ctl was made a global variable, across all VNETs.
However, sctp_init() is called for every VNET that is created. This results
in the same global mutexes which are part of sctp_it_ctl being initialized. This can result
in crashes if many jails are created.
To reproduce the problem:
(1) Take a GENERIC kernel config, and add options for: VIMAGE, WITNESS,
INVARIANTS.
(2) Run this command in a loop:
jail -l -u root -c path=/ name=foo persist vnet && jexec foo ifconfig lo0 127.0.0.1/8 && jail -r foo
(see http://lists.freebsd.org/pipermail/freebsd-current/2010-November/021280.html )
Witness will warn about the same mutex being initialized.
Fix the problem by only initializing these mutexes in the default VNET.
tuexen [Wed, 14 May 2014 18:01:44 +0000 (18:01 +0000)]
MFC r258221:
Cleanups which result in fixes which have been made upstream
and where partially suggested by Andrew Galante.
There is no functional change in FreeBSD.
tuexen [Wed, 14 May 2014 16:57:08 +0000 (16:57 +0000)]
MFC r256556
Remove a buggy comparision when setting manually the path MTU.
After fixing, the comparision would have become redundant.
Thanks to Andrew Galante for reporting the issue.
marius [Wed, 14 May 2014 13:48:02 +0000 (13:48 +0000)]
MFC: r265454
- Allow foot shooting with the resetconfig command via the -f option.
- Fix typos preventing -f to actually work with the create command.
- Initialize flags to zero rather than using stack garbage when handling
the grow command.
Sponsored by: Bally Wulff Games & Entertainment GmbH