]> CyberLeo.Net >> Repos - FreeBSD/stable/10.git/log
FreeBSD/stable/10.git
8 years agoMFC r282245:
kib [Wed, 6 May 2015 09:38:44 +0000 (09:38 +0000)]
MFC r282245:
Remove the #ifdef DEBUG code, which is not compilable on 64bit
architectures.

PR: 199767

git-svn-id: svn://svn.freebsd.org/base/stable/10@282523 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

8 years agoMFC r277396, r278681, r278865, r278924, r279205, r280208,
hselasky [Tue, 5 May 2015 20:58:12 +0000 (20:58 +0000)]
MFC r277396, r278681, r278865, r278924, r279205, r280208,
  r280210, r280764 and r280768:

Update the Linux compatibility layer:
- Add more functions.
- Add some missing includes which are needed when the header files
  are not included in a particular order.
- The kasprintf() function cannot be inlined due to using a variable
  number of arguments. Move it to a C-file.
- Fix problems about 32-bit ticks wraparound and unsigned long
  conversion. Jiffies or ticks in FreeBSD have integer type and are
  not long.
- Add missing "order_base_2()" macro.
- Fix BUILD_BUG_ON() macro.
- Declare a missing symbol which is needed when compiling without -O2
- Clean up header file inclusions in the linux/completion.h, linux/in.h
  and linux/fs.h header files.

Sponsored by: Mellanox Technologies

git-svn-id: svn://svn.freebsd.org/base/stable/10@282513 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

8 years agoMFC r280597:
hselasky [Tue, 5 May 2015 20:04:01 +0000 (20:04 +0000)]
MFC r280597:
Add DA_Q_NO_RC16 quirk for USB mass storage device.

PR: 198647

git-svn-id: svn://svn.freebsd.org/base/stable/10@282512 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

8 years agoMFC r280598:
hselasky [Tue, 5 May 2015 19:59:15 +0000 (19:59 +0000)]
MFC r280598:
Add definition of the ISOCHRONOUS endpoint usage bits.
Refer to the USB v2.0 specification for more information.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282509 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

8 years agoMFC r281881:
hselasky [Tue, 5 May 2015 19:56:23 +0000 (19:56 +0000)]
MFC r281881:
Disable multi process interrupts, because the current code doesn't use
them. Else we can end up in an infinite interrupt loop in USB device
mode.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282508 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

8 years agoMFC r282120:
hselasky [Tue, 5 May 2015 19:47:17 +0000 (19:47 +0000)]
MFC r282120:
The add_bounce_page() function can be called when loading physical
pages which pass a NULL virtual address. If the BUS_DMA_KEEP_PG_OFFSET
flag is set, use the physical address to compute the page offset
instead. The physical address should always be valid when adding
bounce pages and should contain the same page offset like the virtual
address.

Submitted by: Svatopluk Kraus <onwahe@gmail.com>
Reviewed by: jhb@

git-svn-id: svn://svn.freebsd.org/base/stable/10@282506 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

8 years agoUpdate the last svn rev marker.
gjb [Tue, 5 May 2015 15:48:25 +0000 (15:48 +0000)]
Update the last svn rev marker.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@282498 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

8 years agoDocument r282278, wc(1) race when receiving SIGINFO fixed.
gjb [Tue, 5 May 2015 15:16:38 +0000 (15:16 +0000)]
Document r282278, wc(1) race when receiving SIGINFO fixed.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@282497 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

8 years agoBackport some parts of r272200.
np [Tue, 5 May 2015 15:13:59 +0000 (15:13 +0000)]
Backport some parts of r272200.
- a lock to protect indirect register access
- put code that deals with stats in a separate cxgbe_refresh_stats.

This is a direct commit to stable/10.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282486 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

8 years agoMFC r282128:
kib [Tue, 5 May 2015 08:12:24 +0000 (08:12 +0000)]
MFC r282128:
Do not sleep waiting for the MAP_ENTRY_IN_TRANSITION state ending with
the vnode locked.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282456 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

8 years agoMFC r281483:
markj [Tue, 5 May 2015 03:17:32 +0000 (03:17 +0000)]
MFC r281483:
Fix a possible refcount leak in regen_tmpaddr().

git-svn-id: svn://svn.freebsd.org/base/stable/10@282445 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

8 years agoMFC 281701:
markj [Tue, 5 May 2015 03:13:02 +0000 (03:13 +0000)]
MFC 281701:
SDT(9): add a section on SDT providers, mentioning the "sdt" provider.
Add examples demonstrating how one can list available providers and the
DTrace probes provided by a provider.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282444 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

8 years agoMFC r281765:
mav [Mon, 4 May 2015 19:33:51 +0000 (19:33 +0000)]
MFC r281765:
Activate write-only optimization if bpf device opened with O_WRONLY.

dhclient opens bpf as write-only to send packets. It never reads received
packets from that descriptor, but processing them in kernel takes time.
Especially much time takes packet timestamping on systems with expensive
timecounter, such as bhyve guest, where network speed dropped in half.

Sponsored by: iXsystems, Inc.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282427 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

8 years agoMFC r282109:
kib [Mon, 4 May 2015 08:19:12 +0000 (08:19 +0000)]
MFC r282109:
Always do token substitution, do not require -z origin to do it.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282412 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

8 years agoMFC r282085:
kib [Mon, 4 May 2015 08:16:32 +0000 (08:16 +0000)]
MFC r282085:
Partially revert r255986: do not call VOP_FSYNC() when helping
bufdaemon in getnewbuf(), do use buf_flush().  The difference is that
bufdaemon uses TRYLOCK to get buffer locks, which allows calls to
getnewbuf() while another buffer is locked.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282411 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

8 years agoMFC r282084:
kib [Mon, 4 May 2015 08:13:05 +0000 (08:13 +0000)]
MFC r282084:
Fix locking for oshmctl() and shmsys().

git-svn-id: svn://svn.freebsd.org/base/stable/10@282410 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

8 years agoMFC r281763:
kib [Mon, 4 May 2015 08:05:13 +0000 (08:05 +0000)]
MFC r281763:
Remove code to support the top of the stack layout for FreeBSD 1.x/2.x
kernel.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282409 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

8 years agoMFC r272183:
np [Sun, 3 May 2015 18:54:17 +0000 (18:54 +0000)]
MFC r272183:

Make sure the adapter's management queue and the event queue are
available before any uppper layer driver (TOE, iWARP, or iSCSI)
registers with the base cxgbe(4) driver.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282367 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

8 years agoMFC r281592, r281918, r282119, r282266:
kevlo [Sun, 3 May 2015 15:09:34 +0000 (15:09 +0000)]
MFC r281592, r281918, r282119, r282266:

- Fix the length of efuse content
- Disable usb aggregation mode by default since it boots performance

git-svn-id: svn://svn.freebsd.org/base/stable/10@282366 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

8 years agoMFC r272051:
np [Sun, 3 May 2015 08:17:37 +0000 (08:17 +0000)]
MFC r272051:

cxgbe(4):  Verify that the addresses in if_multiaddrs really are multicast
addresses.  (The chip doesn't really care, it's just that it needs to be
told explicitly if unicast DMACs are checked for "hits" in the hash that
is used after the TCAM entries are all used up).

git-svn-id: svn://svn.freebsd.org/base/stable/10@282365 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

8 years agoMFC r281738:
mav [Sun, 3 May 2015 07:16:47 +0000 (07:16 +0000)]
MFC r281738:
Change wcommitsize default from one empirical value to another.

The new value is more predictable with growing RAM size:

        hibufspace maxvnodes      old      new
i386:
  256MB   32980992     15800  2198732  2097152
    2GB   94027776    107677   878764  4194304
amd64:
  256MB   32980992     15800  2198732  2097152
    1GB  114114560     68062  1678155  4194304
    4GB  217055232    111807  1955452  4194304
   16GB 1717846016    337308  5097465 16777216
   64GB 1734918144   1164427  1490479 16777216
  256GB 1734918144   4426453   391983 16777216

git-svn-id: svn://svn.freebsd.org/base/stable/10@282362 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

8 years agoMFC r281026, r281108, r281109:
mav [Sun, 3 May 2015 07:13:14 +0000 (07:13 +0000)]
MFC r281026, r281108, r281109:
Make ZFS ARC track both KVA usage and fragmentation.

Even on Illumos, with its much larger KVA, ZFS ARC steps back if KVA usage
reaches certain threshold (3/4 on i386 or 16/17 otherwise).  FreeBSD has
even less KVA, but had no such limit on archs with direct map as amd64.
As result, on machines with a lot of RAM, during load with very small user-
space memory pressure, such as `zfs send`, it was possible to reach state,
when there is enough both physical RAM and KVA (I've seen up to 25-30%),
but no continuous KVA range to allocate even single 128KB I/O request.

Address this situation from two sides:
 - restore KVA usage limitations in a way the most close to Illumos;
 - introduce new requirement for KVA fragmentation, specifying that we
should have at least one sequential KVA range of zfs_max_recordsize bytes.

Experiments show that first limitation done alone is not sufficient.  On
machine with 64GB of RAM it is sometimes needed to drop up to half of ARC
size to get at leats one 1MB KVA chunk.  Statically limiting ARC to half
of KVA/RAM is too strict, so second limitation makes it to work in cycles:
accumulate trash up to certain critical mass, do massive spring-cleaning,
and then start littering again.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282361 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

8 years agoMFC: r281962
rmacklem [Sat, 2 May 2015 12:18:28 +0000 (12:18 +0000)]
MFC: r281962
Fix the NFS server's handling of a bogus NFSv2 ROOT RPC.
The ROOT RPC is deprecated in the NFSv2 RFC, RFC-1094
and should never be used by a client.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282340 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281923, r281924: Add link to mvs(4).
mav [Fri, 1 May 2015 17:35:10 +0000 (17:35 +0000)]
MFC r281923, r281924: Add link to mvs(4).

git-svn-id: svn://svn.freebsd.org/base/stable/10@282310 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281782: Don't set bits that should be zero for SATA devices.
mav [Fri, 1 May 2015 17:33:17 +0000 (17:33 +0000)]
MFC r281782: Don't set bits that should be zero for SATA devices.

Old value made Linux think that it is PATA device with SATA bridge.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282308 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281700:
mav [Fri, 1 May 2015 17:30:59 +0000 (17:30 +0000)]
MFC r281700:
Workaround bhyve virtual disks operation on top of GEOM providers.

GEOM does not support scatter/gather lists in its I/Os.  Such requests
are cut in pieces by physio(), that may be problematic, if those pieces
are not multiple of provider's sector size.  If such case is detected,
move the data through temporary sequential buffer.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282307 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281666: Make virtual AHCI more careful with I/O lengths.
mav [Fri, 1 May 2015 17:29:45 +0000 (17:29 +0000)]
MFC r281666: Make virtual AHCI more careful with I/O lengths.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282306 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r282148:
gjb [Fri, 1 May 2015 00:31:40 +0000 (00:31 +0000)]
MFC r282148:
  Fix CROCHETBRANCH.

PR: 199760
Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@282292 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281617:
bdrewery [Thu, 30 Apr 2015 18:07:48 +0000 (18:07 +0000)]
MFC r281617:

  wc: Fix SIGINFO race causing final results to be lost to stderr.

Relnotes: yes

git-svn-id: svn://svn.freebsd.org/base/stable/10@282278 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r275805:
tijl [Thu, 30 Apr 2015 16:08:47 +0000 (16:08 +0000)]
MFC r275805:

Fix incorrect type of "invalids" argument in __iconv() prototype.

MFC r281550,281591:

Remove the const qualifier from iconv(3) to comply with POSIX:
http://pubs.opengroup.org/onlinepubs/9699919799/functions/iconv.html

Adjust all code that calls iconv.

PR: 199099

git-svn-id: svn://svn.freebsd.org/base/stable/10@282275 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC: r281628
rmacklem [Thu, 30 Apr 2015 12:44:20 +0000 (12:44 +0000)]
MFC: r281628
mav@ has found that NFS servers exporting ZFS file systems
can perform better when using a 128K read/write data size.
This patch changes NFS_MAXDATA from 64K to 128K so that
clients can use 128K for NFS mounts to allow this.
The patch also renames NFS_MAXDATA to NFS_SRVMAXIO so
that it is clear that it applies to the NFS server side
only. It also avoids a name conflict with the NFS_MAXDATA
defined in rpcsvc/nfs_prot.h, that is used for userland RPC.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282271 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC: r281562
rmacklem [Thu, 30 Apr 2015 12:39:24 +0000 (12:39 +0000)]
MFC: r281562
File systems that do not use the buffer cache (such as ZFS) must
use VOP_FSYNC() to perform the NFS server's Commit operation.
This patch adds a mnt_kern_flag called MNTK_USES_BCACHE which
is set by file systems that use the buffer cache. If this flag
is not set, the NFS server always does a VOP_FSYNC().
This should be ok for old file system modules that do not set
MNTK_USES_BCACHE, since calling VOP_FSYNC() is correct, although
it might not be optimal for file systems that use the buffer cache.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282270 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r282116:
gjb [Thu, 30 Apr 2015 00:35:45 +0000 (00:35 +0000)]
MFC r282116:
  Add the cw-ec2-portinstall target to always install the
  net/bsdec2-image-upload port.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@282263 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r282112:
gjb [Thu, 30 Apr 2015 00:34:41 +0000 (00:34 +0000)]
MFC r282112:
  Fix a comment.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@282262 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 280721:
jhb [Wed, 29 Apr 2015 18:57:19 +0000 (18:57 +0000)]
MFC 280721:
Allow additional flags to be passed to netstat -i in the daily status check.
In particular, this allows an administrator to specify "-h" for human
readable output if that is preferred.

The default setting passes "-d", so that can be excluded by using a custom
setting.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282243 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoDocument r282199, drm update to match Linux 3.8.13.
gjb [Wed, 29 Apr 2015 16:15:38 +0000 (16:15 +0000)]
Document r282199, drm update to match Linux 3.8.13.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@282233 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoDocument r280632, kern.osreldate now configurable jail(8) parameters.
gjb [Wed, 29 Apr 2015 16:15:36 +0000 (16:15 +0000)]
Document r280632, kern.osreldate now configurable jail(8) parameters.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@282232 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoDocument r278608, bcm2835_cpufreq driver addition.
gjb [Wed, 29 Apr 2015 16:15:34 +0000 (16:15 +0000)]
Document r278608, bcm2835_cpufreq driver addition.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@282231 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoDocument r277592, file(1) update to version 5.22.
gjb [Wed, 29 Apr 2015 16:15:32 +0000 (16:15 +0000)]
Document r277592, file(1) update to version 5.22.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@282230 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281857:
pfg [Wed, 29 Apr 2015 15:33:07 +0000 (15:33 +0000)]
MFC r281857:
_pthread_cleanup_push: fix allocator sizeof operand mismatch

Same fix appears to be in DragonFly's libthread_xu.

Found by: Clang Static Analyzer

git-svn-id: svn://svn.freebsd.org/base/stable/10@282224 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281875:
pfg [Wed, 29 Apr 2015 15:26:58 +0000 (15:26 +0000)]
MFC r281875:
libgeom: plug memory leak in EndElement.

CID: 1016696
Found by: Clang static checker

git-svn-id: svn://svn.freebsd.org/base/stable/10@282222 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agodrm: Allow parallel builds of drivers and firmwares
dumbbell [Wed, 29 Apr 2015 12:54:21 +0000 (12:54 +0000)]
drm: Allow parallel builds of drivers and firmwares

Submitted by: hps@
MFC of: r279600

git-svn-id: svn://svn.freebsd.org/base/stable/10@282217 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281780: Update usage statement; align with post-r279624.
dteske [Tue, 28 Apr 2015 22:32:52 +0000 (22:32 +0000)]
MFC r281780: Update usage statement; align with post-r279624.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282204 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoDocument r281255, devfs(5) read/write update timestamp
gjb [Tue, 28 Apr 2015 21:58:11 +0000 (21:58 +0000)]
Document r281255, devfs(5) read/write update timestamp
precision.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@282203 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agodrm: Update the device-independent code to match Linux 3.8.13
dumbbell [Tue, 28 Apr 2015 19:35:05 +0000 (19:35 +0000)]
drm: Update the device-independent code to match Linux 3.8.13

This update brings few features:
    o  Support for the setmaster/dropmaster ioctls. For instance, they
       are used to run multiple X servers simultaneously.
    o  Support for minor devices. The only user-visible change is a new
       entry in /dev/dri but it is useless at the moment. This is a
       first step to support render nodes [1].

The main benefit is to greatly reduce the diff with Linux (at the
expense of an unreadable commit diff). Hopefully, next upgrades will be
easier.

No updates were made to the drivers, beside adapting them to API
changes.

[1] https://en.wikipedia.org/wiki/Direct_Rendering_Manager#Render_nodes

r280814 is merged at the same time to avoid a short window where RANDR
might be broken:

drm: Import Linux commit 9bc3cd5673d84d29272fa7181a4dfca83cbb48c1

Author: Ville Syrjälä <ville.syrjala@linux.intel.com>
Date:   Fri May 31 12:17:08 2013 +0000

    drm: Sort connector modes based on vrefresh

    Keeping the modes sorted by vrefresh before the pixel clock makes the
    mode list somehow more pleasing to the eye.

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
PR: 198936 (r280814)
Tested by: Many people
MFC of: r280183, r280187 (original commit by glebius), r280814
Relnotes: yes

git-svn-id: svn://svn.freebsd.org/base/stable/10@282199 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoFix a whitespace nit.
gjb [Tue, 28 Apr 2015 18:12:10 +0000 (18:12 +0000)]
Fix a whitespace nit.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@282197 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoUpdate svn revision marker.
gjb [Tue, 28 Apr 2015 18:12:08 +0000 (18:12 +0000)]
Update svn revision marker.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@282196 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoDocument r281957, hptnr(4) driver updated to version 1.1.1.
gjb [Tue, 28 Apr 2015 18:12:05 +0000 (18:12 +0000)]
Document r281957, hptnr(4) driver updated to version 1.1.1.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@282195 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoDocument r281936, disallow ar(1) directory traversal.
gjb [Tue, 28 Apr 2015 18:12:03 +0000 (18:12 +0000)]
Document r281936, disallow ar(1) directory traversal.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@282194 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoDocument r281843, GELI passphrase prompt support in loader.
gjb [Tue, 28 Apr 2015 18:12:01 +0000 (18:12 +0000)]
Document r281843, GELI passphrase prompt support in loader.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@282193 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoDocument r281687, ACPI update to 20150410.
gjb [Tue, 28 Apr 2015 18:11:59 +0000 (18:11 +0000)]
Document r281687, ACPI update to 20150410.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@282192 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoDocument r281161, '-R' flag added to netstat(8).
gjb [Tue, 28 Apr 2015 18:11:56 +0000 (18:11 +0000)]
Document r281161, '-R' flag added to netstat(8).
Add Limelight Networks to sponsors.ent.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@282191 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoDocument r281075, ACPICA update to version 20150204.
gjb [Tue, 28 Apr 2015 18:11:54 +0000 (18:11 +0000)]
Document r281075, ACPICA update to version 20150204.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@282190 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoDocument r281044, fix directory inclusion when '--one-file-system'
gjb [Tue, 28 Apr 2015 18:11:51 +0000 (18:11 +0000)]
Document r281044, fix directory inclusion when '--one-file-system'
is specified.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@282189 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoDocument r280392, make sure that setmode sets errno on failure.
gjb [Tue, 28 Apr 2015 18:11:49 +0000 (18:11 +0000)]
Document r280392, make sure that setmode sets errno on failure.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@282188 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoDocument r280370, DSM TRIM support for virtual AHCI disks.
gjb [Tue, 28 Apr 2015 18:11:47 +0000 (18:11 +0000)]
Document r280370, DSM TRIM support for virtual AHCI disks.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@282187 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoDocument r280304, OpenSSL update to version 1.0.1m.
gjb [Tue, 28 Apr 2015 18:11:45 +0000 (18:11 +0000)]
Document r280304, OpenSSL update to version 1.0.1m.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@282186 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r277877: Use zero register instead of immediate 0x0 in MIPS assembly
emaste [Tue, 28 Apr 2015 12:52:08 +0000 (12:52 +0000)]
MFC r277877: Use zero register instead of immediate 0x0 in MIPS assembly

  It seems GAS makes the substitution automatically, but Clang's
  integrated assembler does not (yet). It fails with "invalid operand for
  instruction."

git-svn-id: svn://svn.freebsd.org/base/stable/10@282143 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281107: MIPS rtld: report missing symbol rather than segfaulting
emaste [Tue, 28 Apr 2015 12:48:30 +0000 (12:48 +0000)]
MFC r281107: MIPS rtld: report missing symbol rather than segfaulting

  This is only an interim fix; MIPS should be using the MI code instead,
  which does not have this issue.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282142 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoDRM2: fix off-by-one overflow in ioctl processing
dumbbell [Tue, 28 Apr 2015 12:37:09 +0000 (12:37 +0000)]
DRM2: fix off-by-one overflow in ioctl processing

Call to the driver-specific ioctl used to process ioctl number
that will lead to the out-of-bounds access to the ioctl handler
array.

PR:             193367
Approved by:    kib
MFC of: r275209 (original commit by rea)

git-svn-id: svn://svn.freebsd.org/base/stable/10@282141 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agodrm: Import Linux commit b7ea85a4fed37835eec78a7be3039c8dc22b8178
dumbbell [Tue, 28 Apr 2015 12:02:24 +0000 (12:02 +0000)]
drm: Import Linux commit b7ea85a4fed37835eec78a7be3039c8dc22b8178

Author: Huacai Chen <chenhc@lemote.com>
Date:   Tue May 21 06:23:43 2013 +0000

    drm: fix a use-after-free when GPU acceleration disabled

    When GPU acceleration is disabled, drm_vblank_cleanup() will free the
    vblank-related data, such as vblank_refcount, vblank_inmodeset, etc.
    But we found that drm_vblank_post_modeset() may be called after the
    cleanup, which use vblank_refcount and vblank_inmodeset. And this will
    cause a kernel panic.

    Fix this by return immediately if dev->num_crtcs is zero. This is the
    same thing that drm_vblank_pre_modeset() does.

    Call trace of a drm_vblank_post_modeset() after drm_vblank_cleanup():
    [   62.628906] [<ffffffff804868d0>] drm_vblank_post_modeset+0x34/0xb4
    [   62.628906] [<ffffffff804c7008>] atombios_crtc_dpms+0xb4/0x174
    [   62.628906] [<ffffffff804c70e0>] atombios_crtc_commit+0x18/0x38
    [   62.628906] [<ffffffff8047f038>] drm_crtc_helper_set_mode+0x304/0x3cc
    [   62.628906] [<ffffffff8047f92c>] drm_crtc_helper_set_config+0x6d8/0x988
    [   62.628906] [<ffffffff8047dd40>] drm_fb_helper_set_par+0x94/0x104
    [   62.628906] [<ffffffff80439d14>] fbcon_init+0x424/0x57c
    [   62.628906] [<ffffffff8046a638>] visual_init+0xb8/0x118
    [   62.628906] [<ffffffff8046b9f8>] take_over_console+0x238/0x384
    [   62.628906] [<ffffffff80436df8>] fbcon_takeover+0x7c/0xdc
    [   62.628906] [<ffffffff8024fa20>] notifier_call_chain+0x44/0x94
    [   62.628906] [<ffffffff8024fcbc>] __blocking_notifier_call_chain+0x48/0x68
    [   62.628906] [<ffffffff8042d990>] register_framebuffer+0x228/0x260
    [   62.628906] [<ffffffff8047e010>] drm_fb_helper_single_fb_probe+0x260/0x314
    [   62.628906] [<ffffffff8047e2c4>] drm_fb_helper_initial_config+0x200/0x234
    [   62.628906] [<ffffffff804e5560>] radeon_fbdev_init+0xd4/0xf4
    [   62.628906] [<ffffffff804e0e08>] radeon_modeset_init+0x9bc/0xa18
    [   62.628906] [<ffffffff804bfc14>] radeon_driver_load_kms+0xdc/0x12c
    [   62.628906] [<ffffffff8048b548>] drm_get_pci_dev+0x148/0x238
    [   62.628906] [<ffffffff80423564>] local_pci_probe+0x5c/0xd0
    [   62.628906] [<ffffffff80241ac4>] work_for_cpu_fn+0x1c/0x30
    [   62.628906] [<ffffffff802427c8>] process_one_work+0x274/0x3bc
    [   62.628906] [<ffffffff80242934>] process_scheduled_works+0x24/0x44
    [   62.628906] [<ffffffff8024515c>] worker_thread+0x31c/0x3f4
    [   62.628906] [<ffffffff802497a8>] kthread+0x88/0x90
    [   62.628906] [<ffffffff80206794>] kernel_thread_helper+0x10/0x18

Signed-off-by: Huacai Chen <chenhc@lemote.com>
Signed-off-by: Binbin Zhou <zhoubb@lemote.com>
Cc: <stable@vger.kernel.org>
Reviewed-by: Michel Dänzer <michel.daenzer@amd.com>
Acked-by: Paul Menzel <paulepanter@users.sourceforge.net>
Signed-off-by: Dave Airlie <airlied@gmail.com>
Reported by:    J.R. Oldroyd <fbsd@opal.com>
MFC of: r279599

git-svn-id: svn://svn.freebsd.org/base/stable/10@282140 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281005: Make die available as rtld_die for use by MD relocation code
emaste [Tue, 28 Apr 2015 01:15:17 +0000 (01:15 +0000)]
MFC r281005: Make die available as rtld_die for use by MD relocation code

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@282118 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r280299, r280840, r280846, r280879, r280881, r280884, r280928,
gjb [Mon, 27 Apr 2015 19:41:40 +0000 (19:41 +0000)]
MFC r280299, r280840, r280846, r280879, r280881, r280884, r280928,
r281783, r281809, r281832:

 r280299 (cperciva):
  When creating VM images, copy the contents of the created filesystem
  into a new filesystem before packaging it into a disk image.  This
  prevents "remnants" of deleted files from showing up in the VM images,
  and reduces their compressed size (by about 10% for the cloudware
  images) as a result.

 r280840 (cperciva):
  Clean up filesystem unmounting in vmimage builds:
  - Remove vm_umount_base function which is currently unused.
  - Add umount_loop function which loops attempting to unmount one
    filesystem.
  - Replace calls to umount with calls to umount_loop.
  - Don't attempt to unmount ${DESTDIR}/dev if it isn't mounted.

  The looping is necessary because sometimes umount fails due to
  filesystems being busy.  The most common cause of such busyness is
  periodic(8) jobs running `find / ...`.

 r280846 (cperciva):
  Improve check for whether ${DESTDIR}/dev is mounted.

 r280879 (cperciva):
  Add bits for building EC2 disk images.

 r280881 (cperciva):
  Partially revert r278118 now that the required logic for deciding
  whether freebsd-update can be useful has moved into the
  firstboot_freebsd_update script.

 r280884 (cperciva):
  Fix pkg(8) command line in vm_extra_pre_umount().

 r280928 (cperciva):
  Add code for creating an EC2 AMI.

 r281783:
  When building VM disk images, vm_copy_base() uses tar(1) to copy
  the userland from one md(4)-mounted filesystem to a clean filesystem
  to prevent remnants of files that were added and removed from
  resulting in an unclean filesystem.  When newfs(8) creates the first
  filesystem with journaled soft-updates enabled, the /.sujournal file
  in the new filesystem cannot be overwritten by the /.sujournal in the
  original filesystem.

  To avoid this particular error case, do not enable journaled
  soft-updates when creating the md(4)-backed filesystems, and instead
  use tunefs(8) to enable journaled soft-updates after the new
  filesystem is populated in vm_copy_base().

  While here, fix a long standing bug where the build environment /boot
  files were used by mkimg(1) when creating the VM disk images by using
  the files in .OBJDIR.

 r281809:
  Simplify variable expansion in attempt to fix the vm-image build.

 r281832:
  Fix locating the /boot files.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@282111 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281769:
pfg [Mon, 27 Apr 2015 14:59:31 +0000 (14:59 +0000)]
MFC r281769:
g_uncompress_taste: prevent a double free.

Found by: Clang Static Analyzer

git-svn-id: svn://svn.freebsd.org/base/stable/10@282094 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r272290 (by mjg):
kib [Mon, 27 Apr 2015 12:54:04 +0000 (12:54 +0000)]
MFC r272290 (by mjg):
Use bzero instead of explicitly zeroing stuff in do_execve.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282090 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281762:
kib [Mon, 27 Apr 2015 08:06:33 +0000 (08:06 +0000)]
MFC r281762:
Remove duplicate definitions of MWAIT_CX hints.  Identical defines in
specialreg.h are enough.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282066 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281495:
kib [Mon, 27 Apr 2015 08:02:12 +0000 (08:02 +0000)]
MFC r281495:
Add config option PAE_TABLES for the i386 kernel.  It switches pmap to
use PAE format for the page tables, but does not incur other
consequences of the full PAE config.  In particular, vm_paddr_t and
bus_addr_t are left 32bit, and max supported memory is still limited
by 4GB.

The option allows to have nx permissions for memory mappings on i386
kernel, while keeping the usual i386 KBI and avoiding the kernel data
sizing problems typical for the PAE config.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282065 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281500,281540,281626:
delphij [Mon, 27 Apr 2015 05:49:18 +0000 (05:49 +0000)]
MFC r281500,281540,281626:

Sync with NetBSD:
 - Mention xz(1) in gzip(1).
 - Strip away path from header name when decompressing.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282052 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281502:
delphij [Mon, 27 Apr 2015 05:42:14 +0000 (05:42 +0000)]
MFC r281502:

Sync with OpenBSD: Use volatile instead of __volatile__.

git-svn-id: svn://svn.freebsd.org/base/stable/10@282050 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281712:
kib [Sat, 25 Apr 2015 08:14:08 +0000 (08:14 +0000)]
MFC r281712:
Make wait6(2), waitid(3) and ppoll(2) cancellation points.

git-svn-id: svn://svn.freebsd.org/base/stable/10@281981 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281696:
kib [Sat, 25 Apr 2015 08:06:21 +0000 (08:06 +0000)]
MFC r281696:
Initialize td_sel in the thread_init().

PR: 199518

git-svn-id: svn://svn.freebsd.org/base/stable/10@281979 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281883:
kib [Sat, 25 Apr 2015 08:03:36 +0000 (08:03 +0000)]
MFC r281883:
Handle incorrect ELF images specifying size for PT_GNU_STACK not being
multiple of page size.

git-svn-id: svn://svn.freebsd.org/base/stable/10@281978 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281698:
mav [Sat, 25 Apr 2015 06:49:18 +0000 (06:49 +0000)]
MFC r281698:
Do not report stripe size if it is equal to sector size.

git-svn-id: svn://svn.freebsd.org/base/stable/10@281976 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r261550,r281354,r281355,r281356,r281358,r281359,r281360,r281361,r281362,r281391...
ngie [Sat, 25 Apr 2015 05:31:52 +0000 (05:31 +0000)]
MFC r261550,r281354,r281355,r281356,r281358,r281359,r281360,r281361,r281362,r281391,r281392,r281393,r281394,r281395,r281397,r281398,r281399,r281400,r281401,r281402,r281403,r281404,r281407,r281408,r281409,r281410,r281411:

r261550 (by glebius):

Add test case for kern/181741. Right now test fails.

PR: 181741
Sponsored by: Nginx, Inc.

r281354:

Fix warnings, fix a typo in a testcase description, bump WARNS to 3

- Remove argc/argv (-Wunused)
- Cast len in comparison to size_t (-Wsign-compare)

Sponsored by: EMC / Isilon Storage Division

r281355:

Fix -Wunused warnings, bump WARNS to 6

The testcase fails today on subtest # 9

The output is still broken if prove -rv is run and the testcase aborts
prematurely (the testcase doesn't really conform to TAP protocol properly,
except when it completes fully)

Sponsored by: EMC / Isilon Storage Division

r281356:

Fix -Wunused warnings, bump WARNS to 6

The output is still broken if prove -rv is run and the testcase aborts
prematurely with fail_assertion (the testcase doesn't really conform to TAP
protocol properly, except when it completes fully)

Sponsored by: EMC / Isilon Storage Division

r281358:

- Parameterize out the number of accept/connect attempts
- Randomize the bind port to allow 2+ consecutive calls in < 10 minutes, and
  to also not fail if (for instance) there's a server already listening on port
  8080
- Don't leak the listening socket / fds into the child process
- Fix warnings:
-- Remove argc/argv (-Wunused)
-- Mark sig __unused (-Wunused)
-- Mark quit static (-Wmissing-variable-declarations)

Sponsored by: EMC / Isilon Storage Division

r281359:

Remove argc/argv (-Wunused)

Sponsored by: EMC / Isilon Storage Division

r281360:

Fix warnings

- Remove argc/argv (-Wunused)
- Mark some parameters to socket_listen_update __unused (-Wunused)

Sponsored by: EMC / Isilon Storage Division

r281361:

Remove argc/argv (-Wunused)

Sponsored by: EMC / Isilon Storage Division

r281362:

Use _exit, not exit in forked process

Sponsored by: EMC / Isilon Storage Division

r281391:

- Use static buffers for temporary file paths instead of strdup of constant strings
- Don't use /tmp because it's outside ATF's prescribed sandbox
- Use mkstemp instead of mktemp to eliminate warning

Sponsored by: EMC / Isilon Storage Division

r281392:

- Garbage collect argc/argv (-Wunused)
- Bump WARNS to 6

Sponsored by: EMC / Isilon Storage Division

r281393:

Fix warnings and bump WARNS to 6
- Garbage collect argc/argv (-Wunused)
- sleep(3) will always return an unsigned int; don't check for return codes <0
  (-Wsign-compare)

Sponsored by: EMC / Isilon Storage Division

r281394:

- Don't use /tmp because it's outside ATF's prescribed sandbox
- Replace a hardcoded PATH_MAX value with sizeof(path)
- Use path like an array, not a pointer, and always try to unlink it in cleanup

Sponsored by: EMC / Isilon Storage Division

r281395:

Fix a -Wuninitialized warning by setting the socket to -1 and bump WARNS to 6

Sponsored by: EMC / Isilon Storage Division

r281397:

Mark signum unused in signal_handler; bump WARNS to 6

Sponsored by: EMC / Isilon Storage Division

r281398:

Garbage collect argc/argv and bump WARNS to 6

Sponsored by: EMC / Isilon Storage Division

r281399:

Fix warnings and bump WARNS to 6
- Staticize variables as needed
- Garbage collect argc/argv
- Fix -Wsign-compare warnings by casting small sizeof to (int)

Sponsored by: EMC / Isilon Storage Division

r281400:

- Garbage collect argc/argv; bump WARNS to 6
- Make the socket path random and move it out of /tmp as that's outside ATF's
  prescribed path

Sponsored by: EMC / Isilon Storage Division

r281401:

- Garbage collect argc/argv
- Use random paths instead of one in /tmp

Sponsored by: EMC / Isilon Storage Division

r281402:

Garbage collect argc/argv and bump WARNS to 6

Sponsored by: EMC / Isilon Storage Division

r281403:

Garbage collect argc/argv and bump WARNS to 6

Sponsored by: EMC / Isilon Storage Division

r281404:

Generate temporary files with mkstemp instead of mktemp

Sponsored by: EMC / Isilon Storage Division

r281407:

Fix the knob twiddling to work properly per src.opts.mk

Sponsored by: EMC / Isilon Storage Division

r281408:

- Remove the .t wrapper and put the "magic" of determining the number of
  testcases into the .c file
- Require root for now because it fails with SOCK_RAW without root privileges
- Increment the test count properly on socket create failure

Sponsored by: EMC / Isilon Storage Division

r281409:

Fix warnings, bump WARNS to 6, and use a temporary socket instead of one in /tmp

Sponsored by: EMC / Isilon Storage Division

r281410:

Fix more warnings I didn't catch in the first go-around

Sponsored by: EMC / Isilon Storage Division

r281411:

Fix even more warnings..

Sponsored by: EMC / Isilon Storage Division

git-svn-id: svn://svn.freebsd.org/base/stable/10@281974 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r280893:
ngie [Sat, 25 Apr 2015 04:49:45 +0000 (04:49 +0000)]
MFC r280893:

Cleanup and do minor refactoring before converting testcases to ATF

- Convert errx(-1, ..) to errx(1, ..)
- Move the aio(4) checks to a single function (aio_available); use modfind(2)
  instead of depending on SIGSYS (doesn't work when aio(4) support is missing,
  not documented in the aio syscall manpages).
- Use aio_available liberally in the testcase functions
- Use mkstemp(3) + unlink(2) instead of mktemp(3)
- Fix some -Wunused warnings
- Bump WARNS to 6

Submitted by: mjohnston [*]
Sponsored by: EMC / Isilon Storage Division

git-svn-id: svn://svn.freebsd.org/base/stable/10@281969 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r280475:
ngie [Sat, 25 Apr 2015 04:40:08 +0000 (04:40 +0000)]
MFC r280475:

The number of commands added when ddb(4) is enabled is 3, not 2

Sponsored by: EMC / Isilon Storage Division

git-svn-id: svn://svn.freebsd.org/base/stable/10@281968 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281704:
rpaulo [Sat, 25 Apr 2015 01:23:29 +0000 (01:23 +0000)]
MFC r281704:
  Synaptics: don't report the middle button when clickPad is used.

git-svn-id: svn://svn.freebsd.org/base/stable/10@281964 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281544:
rpaulo [Sat, 25 Apr 2015 01:11:33 +0000 (01:11 +0000)]
MFC r281544:
  snd_hda: add support for the Lenovo X1 20BS model.

  This requires a patch to redirect the output to a separate DAC when
  the headphones are used.  While there, add device strings for Intel
  Broadwell HDA controllers and Realtek ALC292 codecs.

git-svn-id: svn://svn.freebsd.org/base/stable/10@281963 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281795:
pfg [Sat, 25 Apr 2015 00:58:19 +0000 (00:58 +0000)]
MFC r281795:
scsi_parse_transportid_rdma(): fix mismatch in memory access size.

Independently found by Coverity and gcc49.

CID: 1230006
Reviewed by: ken

git-svn-id: svn://svn.freebsd.org/base/stable/10@281961 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281667:
delphij [Sat, 25 Apr 2015 00:36:43 +0000 (00:36 +0000)]
MFC r281667:

Remove vfs.zfs.snapshot_list_prefetch, the corresponding code was
gone in r248571 already.

git-svn-id: svn://svn.freebsd.org/base/stable/10@281958 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281387:
delphij [Sat, 25 Apr 2015 00:32:47 +0000 (00:32 +0000)]
MFC r281387:

Merge changes from vendor driver version 1.1.1:

v1.1.1 2015-03-26
 * Support 4Kn drive.
 * Change the SCSI target ID of the disk to be the index of physical
   connetion to the HBA.
 * Support staggered drive spin up.
 * Fix a bug that command would be timeout because of improper
   interrupt service routine.
 * Error handling to avoid scsi command lost which caused system
   hang up.
 * Fix a bug that fail to get the devcie's serial number via
   FreeNAS WebGUI.

Many thanks to HighPoint for continued support of FreeBSD!

Relnotes: yes

git-svn-id: svn://svn.freebsd.org/base/stable/10@281957 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r275358 r275483 r276982 - Removing M_FLOWID by hps@
hiren [Fri, 24 Apr 2015 23:26:44 +0000 (23:26 +0000)]
MFC r275358 r275483 r276982 - Removing M_FLOWID by hps@

r275358:
Start process of removing the use of the deprecated "M_FLOWID" flag
from the FreeBSD network code. The flag is still kept around in the
"sys/mbuf.h" header file, but does no longer have any users. Instead
the "m_pkthdr.rsstype" field in the mbuf structure is now used to
decide the meaning of the "m_pkthdr.flowid" field. To modify the
"m_pkthdr.rsstype" field please use the existing "M_HASHTYPE_XXX"
macros as defined in the "sys/mbuf.h" header file.

This patch introduces new behaviour in the transmit direction.
Previously network drivers checked if "M_FLOWID" was set in "m_flags"
before using the "m_pkthdr.flowid" field. This check has now now been
replaced by checking if "M_HASHTYPE_GET(m)" is different from
"M_HASHTYPE_NONE". In the future more hashtypes will be added, for
example hashtypes for hardware dedicated flows.

"M_HASHTYPE_OPAQUE" indicates that the "m_pkthdr.flowid" value is
valid and has no particular type. This change removes the need for an
"if" statement in TCP transmit code checking for the presence of a
valid flowid value. The "if" statement mentioned above is now a direct
variable assignment which is then later checked by the respective
network drivers like before.

r275483:
Remove M_FLOWID from SCTP code.

r276982:
Remove no longer used "M_FLOWID" flag from mbuf.h and update the netisr
manpage.

Note: The FreeBSD version has been bumped.

Reviewed by:    hps, tuexen
Sponsored by:   Limelight Networks

git-svn-id: svn://svn.freebsd.org/base/stable/10@281955 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r279393:
ngie [Fri, 24 Apr 2015 22:18:50 +0000 (22:18 +0000)]
MFC r279393:

Pad RX copy alignment calculation to avoid illegal memory accesses

The optimization made in r239940 is valid for struct mbuf's current structure
and size in FreeBSD, but hardcodes assumptions about sizes of struct mbuf,
which are unfortunately broken if additional data is added to the beginning of
struct mbuf

X-MFC note (discussed with rwatson):

This change requires the MPKTHSIZE definition, which is only available after
head@r277203 and will not be MFCed as it breaks mbuf(9) KPI.

A direct commit to stable/10 and merges to other branches to add the necessary
definitions to work with the code as-is will be done to facilitate this MFC

PR: 194314
Approved/Reviewed by: erj, jfv
Sponsored by: EMC / Isilon Storage Division

git-svn-id: svn://svn.freebsd.org/base/stable/10@281954 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoBackport MHSIZE/MPKTHSIZE equivalents from head
ngie [Fri, 24 Apr 2015 21:38:18 +0000 (21:38 +0000)]
Backport MHSIZE/MPKTHSIZE equivalents from head

These macros are equivalent to the ones on head, except they are only exposed
when _KERNEL is defined, i.e. to kernel code, whereas the code on head is exposed
to userland as well

This is for improved forwards compatibility with mbuf(9) macros in head@r277203+,
and is required for a clean MFC of r279393

This is a direct commit to stable/10

MFC after: 3 days
Differential Revision: https://reviews.freebsd.org/D2126
Reviewed by: glebius, rwatson
Sponsored by: EMC / Isilon Storage Division

git-svn-id: svn://svn.freebsd.org/base/stable/10@281951 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoRevert r281543. It causes a panic/hang early in boot for a number of
scottl [Fri, 24 Apr 2015 17:05:18 +0000 (17:05 +0000)]
Revert r281543.  It causes a panic/hang early in boot for a number of
users, myself included.  The original code is likely papering over a
larger bug that needs to be explored, but for now get things back to
a working state.

Obtained from: Netflix, Inc.

git-svn-id: svn://svn.freebsd.org/base/stable/10@281943 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r277464: Add missing R_X86_64_ constants to elf_common.h
emaste [Fri, 24 Apr 2015 15:58:41 +0000 (15:58 +0000)]
MFC r277464: Add missing R_X86_64_ constants to elf_common.h

PR: 196918
Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@281937 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281311: ar: Disallow directory traversal
emaste [Fri, 24 Apr 2015 15:48:23 +0000 (15:48 +0000)]
MFC r281311: ar: Disallow directory traversal

  Set ARCHIVE_EXTRACT_SECURE_SYMLINKS and ARCHIVE_EXTRACT_SECURE_NODOTDOT
  as in bsdtar to prevent extraction of archive entries whose pathnames
  contain .. or whose target directory would be altered by a symlink.
  Also disallow absolute pathnames.

  We don't currently provide an option to disable this behaviour (as
  bsdtar's -P does). It is unlikely to be a problem in practice for ar(1),
  but the -P option is not currently used and available if we want to
  consider it for this purpose.

Obtained from: ELF tool chain ar, Ticket #474
Relnotes: Yes
Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@281936 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281537: Increase vt font limits to allow use of GNU Unifont
emaste [Fri, 24 Apr 2015 15:32:12 +0000 (15:32 +0000)]
MFC r281537: Increase vt font limits to allow use of GNU Unifont

PR: 199438
Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@281933 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r280786:
bz [Fri, 24 Apr 2015 07:52:21 +0000 (07:52 +0000)]
MFC r280786:

  Try to unbreak !SMP kernels  broken in r280785 (head), r281657 by using
  the proper macros to access cc_cpu.

Requested by: jmallett
Pointyhat to: rrs

git-svn-id: svn://svn.freebsd.org/base/stable/10@281921 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281756:
pfg [Fri, 24 Apr 2015 02:14:01 +0000 (02:14 +0000)]
MFC r281756:
nfsrpc_createv4: fix double free.

Reported by: Oliver Pinter, clang static checker
Obtained from: HardenedBSD (63cac77c42c0c3fc67da62f97d5ab651d52ae707)
Reviewed by: rmacklem

git-svn-id: svn://svn.freebsd.org/base/stable/10@281912 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281380:
ae [Fri, 24 Apr 2015 02:12:25 +0000 (02:12 +0000)]
MFC r281380:
  Fix the IPV6_MULTICAST_IF sockopt handling. RFC 3493 says when the
  interface index is specified as zero, the system should select the
  interface to use for outgoing multicast packets. Even the comment
  for the in6p_set_multicast_if() function says about index of zero.
  But in fact for zero index the function just returns EADDRNOTAVAIL.

  I.e. if you first set some interface and then will try reset it
  with zero ifindex, you will get EADDRNOTAVAIL.

  Reset im6o_multicast_ifp to NULL when interface index specified as
  zero. Also return EINVAL in case when ifnet_byindex() returns NULL.
  This will be the same behaviour as when ifindex is bigger than
  V_if_index. And return EADDRNOTAVAIL only when interface is not
  multicast capable.

git-svn-id: svn://svn.freebsd.org/base/stable/10@281911 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 281159:
jhb [Thu, 23 Apr 2015 22:39:32 +0000 (22:39 +0000)]
MFC 281159:
Move the message complaining about failed system resource allocations
under bootverbose.  Every example I've seen to date has been due to
an ACPI system resource device reserving a range that overlaps with
system memory (which ram0 attempts to reserve) or a local or I/O APIC
(which apic0 attempts to reserve).  These are always harmless but look
scary to users.

git-svn-id: svn://svn.freebsd.org/base/stable/10@281910 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281775:
dim [Thu, 23 Apr 2015 22:06:02 +0000 (22:06 +0000)]
MFC r281775:

Pull in r229911 from upstream llvm trunk (by Benjamin Kramer):

  MC: Allow multiple comma-separated expressions on the .uleb128 directive.

  For compatiblity with GNU as. Binutils documents this as
  '.uleb128 expressions'. Subtle, isn't it?

Reported by: sbruno
PR: 199554

MFC r281777:

Add llvm patch corresponding to r281775.

git-svn-id: svn://svn.freebsd.org/base/stable/10@281908 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281582:
bdrewery [Thu, 23 Apr 2015 15:24:33 +0000 (15:24 +0000)]
MFC r281582:

  Remove extra flags from r250462.

git-svn-id: svn://svn.freebsd.org/base/stable/10@281896 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r280999:
bdrewery [Thu, 23 Apr 2015 15:19:56 +0000 (15:19 +0000)]
MFC r280999:

  Use proper CHAN_TCP_PACKET_DEFAULT for agent forwarding when HPN disabled.

git-svn-id: svn://svn.freebsd.org/base/stable/10@281893 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoRegen for r281891
bdrewery [Thu, 23 Apr 2015 15:18:43 +0000 (15:18 +0000)]
Regen for r281891

git-svn-id: svn://svn.freebsd.org/base/stable/10@281892 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281053:
bdrewery [Thu, 23 Apr 2015 15:15:45 +0000 (15:15 +0000)]
MFC r281053:

  Remove specific reference to g++(1) for WITH_CXX as it may be clang.

git-svn-id: svn://svn.freebsd.org/base/stable/10@281891 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281003:
kib [Thu, 23 Apr 2015 07:32:28 +0000 (07:32 +0000)]
MFC r281003:
Speed up symbol lookup for the amd64 kernel modules.

git-svn-id: svn://svn.freebsd.org/base/stable/10@281880 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r281745:
kevlo [Thu, 23 Apr 2015 01:52:07 +0000 (01:52 +0000)]
MFC r281745:
Add new USB ID.

PR: 199522

git-svn-id: svn://svn.freebsd.org/base/stable/10@281878 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r274988 (with modification):
ae [Wed, 22 Apr 2015 20:42:17 +0000 (20:42 +0000)]
MFC r274988 (with modification):
  Skip L2 addresses lookups for tunneling interfaces.

PR: 197286

git-svn-id: svn://svn.freebsd.org/base/stable/10@281868 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f