]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
9 years agoAdd -p parameter to list PCI device to pass through to the guest.
Gleb Smirnoff [Thu, 12 Mar 2015 15:58:07 +0000 (15:58 +0000)]
Add -p parameter to list PCI device to pass through to the guest.

Reviewed by: neel

9 years agoFix 'make depend' by moving the LDSCRIPT dependency into DPADD.
John Baldwin [Thu, 12 Mar 2015 15:25:22 +0000 (15:25 +0000)]
Fix 'make depend' by moving the LDSCRIPT dependency into DPADD.

Sponsored by: Cisco Systems, Inc.

9 years agoRevert r279381. The EFI loader needs to use a separate libstand that
John Baldwin [Thu, 12 Mar 2015 15:20:05 +0000 (15:20 +0000)]
Revert r279381.  The EFI loader needs to use a separate libstand that
is compiled against the ABI EFI expects (specifically, no stack
redzone) so it cannot share libstand with userboot (which must use
the System V ABI).

9 years agoAdd if_input_default() method, that will be used for if_input
Andrey V. Elsukov [Thu, 12 Mar 2015 14:55:33 +0000 (14:55 +0000)]
Add if_input_default() method, that will be used for if_input
initialization, when no input method specified before if_attach().

This prevents panics when if_input() method called directly e.g.
from bpf(4) code.

PR: 192426
Reviewed by: glebius
MFC after: 1 week

9 years agoUsing parent DMA tag in drm_pci_alloc(). This can allow drm2 devices to work with...
Jason A. Harmening [Thu, 12 Mar 2015 14:18:36 +0000 (14:18 +0000)]
Using parent DMA tag in drm_pci_alloc().  This can allow drm2 devices to work with Intel DMAR enabled for the system, as long as DMAR is disabled for the drm2 device.

Approved by: kib (mentor)
MFC after: 1 week

9 years agoMake "automount -LL -o whatever" present options in the same order
Edward Tomasz Napierala [Thu, 12 Mar 2015 12:36:08 +0000 (12:36 +0000)]
Make "automount -LL -o whatever" present options in the same order
as used by automountd(8).

MFC after: 1 month
Sponsored by: The FreeBSD Foundation

9 years agoMake concat() accept NULL arguments.
Edward Tomasz Napierala [Thu, 12 Mar 2015 12:17:15 +0000 (12:17 +0000)]
Make concat() accept NULL arguments.

MFC after: 1 month
Sponsored by: The FreeBSD Foundation

9 years agoOptions from auto_master must be appended to options from maps,
Edward Tomasz Napierala [Thu, 12 Mar 2015 12:14:11 +0000 (12:14 +0000)]
Options from auto_master must be appended to options from maps,
not prepended.

MFC after: 1 month
Sponsored by: The FreeBSD Foundation

9 years agoFix couple BIO_DELETE bugs in geom_mirror.
Alexander Motin [Thu, 12 Mar 2015 10:20:53 +0000 (10:20 +0000)]
Fix couple BIO_DELETE bugs in geom_mirror.

Do not report GEOM::candelete if none of providers support BIO_DELETE.
If consumer still requests BIO_DELETE, report error instead of hanging.

MFC after: 2 weeks

9 years agoReset mbuf pointer to NULL in fastroute case to indicate that mbuf was
Andrey V. Elsukov [Thu, 12 Mar 2015 08:57:24 +0000 (08:57 +0000)]
Reset mbuf pointer to NULL in fastroute case to indicate that mbuf was
consumed by filter. This fixes several panics due to accessing to mbuf
after free.

Submitted by: Kristof Provost
MFC after: 1 week

9 years agoAdd aarch64 (arm64) #define for jemalloc
Ed Maste [Thu, 12 Mar 2015 08:52:00 +0000 (08:52 +0000)]
Add aarch64 (arm64) #define for jemalloc

Sponsored by: The FreeBSD Foundation

9 years agoProvide automatic cross-binutils path if no BINUTILS_BOOTSTRAP
Ed Maste [Thu, 12 Mar 2015 08:40:32 +0000 (08:40 +0000)]
Provide automatic cross-binutils path if no BINUTILS_BOOTSTRAP

The in-tree binutils does not support arm64, so will not work for the
forthcoming FreeBSD arm64 port. BROKEN_OPTIONS will include
BINUTILS_BOOTSTRAP, so provide a default CROSS_BINUTILS_PREFIX for this
case.

Reviewed by: imp
Sponsored by: The FreeBSD Foundation

9 years agoTARGET_* shouldn't be used here. Use MACHINE_* instead.
Warner Losh [Thu, 12 Mar 2015 08:32:24 +0000 (08:32 +0000)]
TARGET_* shouldn't be used here. Use MACHINE_* instead.

9 years agoThese local variables are unused. gc them.
Warner Losh [Thu, 12 Mar 2015 08:32:22 +0000 (08:32 +0000)]
These local variables are unused. gc them.

9 years agoIt appears that xlint isn't used in the build process, so it certainly
Warner Losh [Thu, 12 Mar 2015 08:32:20 +0000 (08:32 +0000)]
It appears that xlint isn't used in the build process, so it certainly
doesn't need to be a build tool.

9 years agoAdd RTL8211F gigabit PHY support.
Pyun YongHyeon [Thu, 12 Mar 2015 07:05:28 +0000 (07:05 +0000)]
Add RTL8211F gigabit PHY support.

PR: 197265
MFC after: 2 weeks

9 years agoFile names with commas in them cause issues for freebsd-update. We
Warner Losh [Thu, 12 Mar 2015 06:43:58 +0000 (06:43 +0000)]
File names with commas in them cause issues for freebsd-update. We
don't actually use these files at the moment, so eliminate them until
we actually do. In the mean time, freebsd-update will be updated
to eliminate the issues.

Requested by: cperciva

9 years ago- Include commas in valid file-name chars freebsd-update will support
Kris Moore [Thu, 12 Mar 2015 06:41:01 +0000 (06:41 +0000)]
- Include commas in valid file-name chars freebsd-update will support

Approved by: cperciva

9 years agoCategorize certain kernel builds as being broken in certain places.
Warner Losh [Thu, 12 Mar 2015 03:57:19 +0000 (03:57 +0000)]
Categorize certain kernel builds as being broken in certain places.

Differential Revision: https://reviews.freebsd.org/D2010

9 years agoAdd support for specifying unsupported / broken options that override
Warner Losh [Thu, 12 Mar 2015 03:57:00 +0000 (03:57 +0000)]
Add support for specifying unsupported / broken options that override
any defaults or user specified actions on the command line. This would
be useful for specifying features that are always broken or that
cannot make sense on a specific architecture, like ACPI on pc98 or
EISA on !i386 (!x86 usage of EISA is broken and there's no supported
hardware that could have it in any event). Any items in
BROKEN_OPTIONS are forced to "no" regardless of other settings.
Clients are expected change BROKEN_OPTIONS with +=. It will not
be unset, so other parts of the build system can have visibility
into the options that are broken on this platform, though this
should be very rare.

Differential Revision: https://reviews.freebsd.org/D2009

9 years agoDocument m_collapse().
Mark Johnston [Thu, 12 Mar 2015 01:05:54 +0000 (01:05 +0000)]
Document m_collapse().

Reported by: kmacy
Reviewed by: kmacy
MFC after: 1 week
Sponsored by: EMC / Isilon Storage Division

9 years agoYou need to have the capabilities and not skip it if you are
Randall Stewart [Wed, 11 Mar 2015 20:15:49 +0000 (20:15 +0000)]
You need to have the capabilities and not skip it if you are
not on head.. otherwise the file pointer will be NULL and when
you try to do something with it you will crash. Make the #else
be the old capabilites, and then remove the erroneous ifdefs for
11.

MFC after: 1 week (with the other MFC I was going to do until the panic)

9 years agoResize receive socket buffers that support autosizing when receiving
John Baldwin [Wed, 11 Mar 2015 17:35:07 +0000 (17:35 +0000)]
Resize receive socket buffers that support autosizing when receiving
TCP data via direct data placement.

Sponsored by: Chelsio
MFC after: 1 week

9 years agoFactor out mbuf hashing code from LAGG driver so that other network
Hans Petter Selasky [Wed, 11 Mar 2015 16:02:24 +0000 (16:02 +0000)]
Factor out mbuf hashing code from LAGG driver so that other network
drivers can use it. This avoids some code duplication. Add missing
default case to all switch statements while at it. Also move the
hashing of the IPv6 flow field to layer 4 because the IPv6 flow field
is constant on a per L4 connection basis and not on a per L3 network.

Differential Revision: https://reviews.freebsd.org/D1987
Sponsored by: Mellanox Technologies
MFC after: 1 month

9 years agoUpdate a comment to get it aligned with the code change.
Michael Tuexen [Wed, 11 Mar 2015 15:40:29 +0000 (15:40 +0000)]
Update a comment to get it aligned with the code change.

Reported by: brueffer@

9 years agoIt seems that sb_acc is a better replacement for sb_cc than sb_ccc. At
Michael Tuexen [Wed, 11 Mar 2015 15:21:39 +0000 (15:21 +0000)]
It seems that sb_acc is a better replacement for sb_cc than sb_ccc. At
least it unbreaks the use of select() for SCTP sockets.

MFC after: 3 days

9 years agoFix the adaptation of the path state when thresholds are changed
Michael Tuexen [Wed, 11 Mar 2015 14:25:23 +0000 (14:25 +0000)]
Fix the adaptation of the path state when thresholds are changed
using the SCTP_PEER_ADDR_THLDS socket option.

MFC after: 3 days

9 years agoAdding myself (jah) to committers-src.dot
Jason A. Harmening [Wed, 11 Mar 2015 12:57:07 +0000 (12:57 +0000)]
Adding myself (jah) to committers-src.dot

Approved by: kib (mentor)

9 years agoFix a typo and update the date in the man page.
Scott Long [Wed, 11 Mar 2015 08:08:54 +0000 (08:08 +0000)]
Fix a typo and update the date in the man page.

Submitted by: emax
Obtained from: Netflix, Inc.
MFC after: 3 days

9 years agoWhen copying a type from a source CTF container to a destination container,
Mark Johnston [Wed, 11 Mar 2015 00:01:39 +0000 (00:01 +0000)]
When copying a type from a source CTF container to a destination container,
ctf_add_type() first performs a by-name lookup of the type in the
destination container. If this lookup returns a forward declaration for an
enum, struct, or union, reset dst_type back to CTF_ERR, indicating that the
source type is not in fact present in the destination container. This
ensures that ctf_add_type() will also search the destination container's
dynamic type list for the source type.

Without this change, a pair of mutually recursive struct definitions could
cause infinite recursion in ctf_add_type() if the destination container
only contained forward declarations for the struct types: ctf_add_type()
recursively calls itself on each struct member's type, and the forward
declarations meant that the dynamic type list search would be skipped.

MFC after: 2 weeks
Sponsored by: EMC / Isilon Storage Division

9 years agoFix SR-IOV passthrough devices to allow ppt to attach
Ryan Stone [Tue, 10 Mar 2015 23:27:13 +0000 (23:27 +0000)]
Fix SR-IOV passthrough devices to allow ppt to attach

A late change to the SR-IOV infrastructure broke passthrough of
VFs.  device_set_devclass() was being used to try to force the
ppt driver to attach to the device, but this didn't work because
the DF_FIXEDCLASS flag wasn't being set on the device, so the
ppt driver probe routine would not match when it returned
BUS_NOWILDCARD.  Fix this by adding a new device function that
both sets the devclass and sets the DF_FIXEDCLASS flag, and use
that to force the ppt driver to attach to VFs.

Differential Revision: https://reviews.freebsd.org/D2041
Reviewed by: jhb
MFC after: 3 weeks

9 years agoKeep track on the socket lock state. This fixes a bug showing up on
Michael Tuexen [Tue, 10 Mar 2015 22:38:10 +0000 (22:38 +0000)]
Keep track on the socket lock state. This fixes a bug showing up on
Mac OS X.

MFC after: 3 days

9 years agoEnsure setting promiscious mode when a network interface is up, is
Hans Petter Selasky [Tue, 10 Mar 2015 21:17:10 +0000 (21:17 +0000)]
Ensure setting promiscious mode when a network interface is up, is
always non-blocking by not locking a SX type of mutex.

Sponsored by: Mellanox Technologies
MFC after: 3 days

9 years agoCTF containers use the ctf_dtoldid field as a threshold type index which
Mark Johnston [Tue, 10 Mar 2015 21:08:58 +0000 (21:08 +0000)]
CTF containers use the ctf_dtoldid field as a threshold type index which
indicates the range of type indices which have been committed to the
container by ctf_update(). However, the top bit of the dtd_type field is
not part of the type index; rather, it is a flag used to indicate that the
corresponding CTF container is a parent. This is why the maximum CTF type
index is 2^15 - 1 rather than 2^16 - 1. Therefore, this flag must be masked
off (using the CTF_TYPE_TO_INDEX macro) when comparing a type index with the
ctf_dtoldid field of a container.

This bug was causing libctf to erroneously free committed type definitions
in ctf_discard(). libdtrace holds some references to such types, resulting
in a use-after-free.

MFC after: 2 weeks
Sponsored by: EMC / Isilon Storage Division

9 years agoUnlock the stcb when using setsockopt() for the SCTP_PEER_ADDR_THLDS option.
Michael Tuexen [Tue, 10 Mar 2015 21:05:17 +0000 (21:05 +0000)]
Unlock the stcb when using setsockopt() for the SCTP_PEER_ADDR_THLDS option.

MFC after: 3 days

9 years agoctf_discard(): fetch the next list element before restarting the loop. If
Mark Johnston [Tue, 10 Mar 2015 20:52:03 +0000 (20:52 +0000)]
ctf_discard(): fetch the next list element before restarting the loop. If
we end up skipping a dynamic type because it has already been committed to
the container, we would previously either set the loop variable to an
uninitialized local variable, or set it to itself, resulting in an infinite
loop.

MFC after: 2 weeks
Sponsored by: EMC / Isilon Storage Division

9 years agoMFV r279822:
Mark Johnston [Tue, 10 Mar 2015 20:43:16 +0000 (20:43 +0000)]
MFV r279822:

This merge is effectively a no-op since parts of it are already present
in FreeBSD, and the rest is incorrect since gelf_newehdr(3) and
gelf_newphdr(3) return pointers on FreeBSD rather than integers.

Illumos issue:
    5589 improper use of NULL in tools/ctf

MFC after: 3 days

9 years agoReplace the DEV_NETMAP code that accidentally got removed in the
Jack F Vogel [Tue, 10 Mar 2015 19:55:43 +0000 (19:55 +0000)]
Replace the DEV_NETMAP code that accidentally got removed in the
last commit.

MFC after: 1 week

9 years agoAdd a SCTP socket option to limit the cwnd for each path.
Michael Tuexen [Tue, 10 Mar 2015 19:49:25 +0000 (19:49 +0000)]
Add a SCTP socket option to limit the cwnd for each path.

MFC after: 1 month

9 years agoThis delta introduces SRIOV support, thanks to Ryan Stone of Sandvine for
Jack F Vogel [Tue, 10 Mar 2015 19:17:40 +0000 (19:17 +0000)]
This delta introduces SRIOV support, thanks to Ryan Stone of Sandvine for
adding this major feature to the driver. Secondly, this updates the base
driver with new 20G device support, and with the new firmware levels some
changes to link handling and initialization were required.

MFC after: 1 week

9 years agoAdd myself to the src committers graph, with kib as my mentor.
Eric van Gyzen [Tue, 10 Mar 2015 17:45:46 +0000 (17:45 +0000)]
Add myself to the src committers graph, with kib as my mentor.

Approved by:    kib (mentor)

9 years agoAccording to POSIX.1-2008, the Bessel functions of second kind
Steve Kargl [Tue, 10 Mar 2015 17:10:54 +0000 (17:10 +0000)]
According to POSIX.1-2008, the Bessel functions of  second kind
should raise a divide-by-zero floating point exception for x = +-0
and an invalid floating point exception for x < 0 including x = -Inf.
Update the code to raise the exception and update the documentation
with hopefully better description of the behavior.

Reviewed by: bde (code only)

9 years agoLet unchangeable 8-bit frame buffers have vaguely correct colors.
Nathan Whitehorn [Tue, 10 Mar 2015 17:04:11 +0000 (17:04 +0000)]
Let unchangeable 8-bit frame buffers have vaguely correct colors.

MFC after: 2 weeks

9 years agoLock softc before clearing bits.
Hans Petter Selasky [Tue, 10 Mar 2015 16:06:07 +0000 (16:06 +0000)]
Lock softc before clearing bits.

Found by: Dmitry Luhtionov <dmitryluhtionov@gmail.com>
MFC after: 1 week

9 years agoAllow PowerMac systems to be booted from an FDT as well as Open Firmware.
Nathan Whitehorn [Tue, 10 Mar 2015 16:01:43 +0000 (16:01 +0000)]
Allow PowerMac systems to be booted from an FDT as well as Open Firmware.
This is not complete yet: the gem(4) interface on my laptop seems to
disappear from the PCI bus as a result of quiescing Open Firmware in the
boot loader.

9 years agoFix off-by-one bugs.
Luiz Otavio O Souza [Tue, 10 Mar 2015 14:55:05 +0000 (14:55 +0000)]
Fix off-by-one bugs.

Spotted by: rpaulo (on another review)

9 years agoFix typo.
Edward Tomasz Napierala [Tue, 10 Mar 2015 14:43:07 +0000 (14:43 +0000)]
Fix typo.

MFC after: 1 month
Sponsored by: The FreeBSD Foundation

9 years agoRemove MODULES_OVERRIDE="" for Marvel-based armv5 systems.
Ian Lepore [Tue, 10 Mar 2015 14:36:51 +0000 (14:36 +0000)]
Remove MODULES_OVERRIDE="" for Marvel-based armv5 systems.

Also add some #NO_UNIVERSE to configs that essentially duplicate DB-88F6XXX.

9 years agoAdd OpenBSD copyright for reallocarray
Baptiste Daroussin [Tue, 10 Mar 2015 14:22:28 +0000 (14:22 +0000)]
Add OpenBSD copyright for reallocarray

Move the function at the bottom of the misc.c file to clearly state the
copyright only stand for this function

PR: 198484
Submitted by: logan@elandsys.com

9 years agoFix function name in comment.
Gleb Smirnoff [Tue, 10 Mar 2015 13:06:54 +0000 (13:06 +0000)]
Fix function name in comment.

9 years agoProperly pass options for direct maps.
Edward Tomasz Napierala [Tue, 10 Mar 2015 12:25:05 +0000 (12:25 +0000)]
Properly pass options for direct maps.

MFC after: 1 month
Sponsored by: The FreeBSD Foundation

9 years agoFix handling of direct maps, broken in r275756. Previously, running
Edward Tomasz Napierala [Tue, 10 Mar 2015 11:59:33 +0000 (11:59 +0000)]
Fix handling of direct maps, broken in r275756.  Previously, running
automount(8) would unmount direct map trigger nodes every second time.

MFC after: 1 month
Sponsored by: The FreeBSD Foundation

9 years agoRefactor.
Edward Tomasz Napierala [Tue, 10 Mar 2015 09:53:15 +0000 (09:53 +0000)]
Refactor.

MFC after: 1 month
Sponsored by: The FreeBSD Foundation

9 years agoImplement basic cpuset reporting in procstat via the -S flag.
Scott Long [Tue, 10 Mar 2015 09:41:48 +0000 (09:41 +0000)]
Implement basic cpuset reporting in procstat via the -S flag.

Obtained from: Netflix, Inc.
MFC after: 3 days

9 years agoFix a typo.
Michael Tuexen [Tue, 10 Mar 2015 09:16:31 +0000 (09:16 +0000)]
Fix a typo.

MFC after: 1 week

9 years agoRemove MODULES_OVERRIDE="" and WITHOUT_MODULES="ahc" from armv6 configs.
Ian Lepore [Tue, 10 Mar 2015 02:33:51 +0000 (02:33 +0000)]
Remove MODULES_OVERRIDE="" and WITHOUT_MODULES="ahc" from armv6 configs.

These are left over from long ago when there was no way to load modules
on early armv6 platforms, and when there was a build problem with ahc
that has long since been fixed, and they just keep getting copy-pasted
into new configs.

9 years agoAdd missing counter definitions
Ryan Stone [Tue, 10 Mar 2015 01:24:16 +0000 (01:24 +0000)]
Add missing counter definitions

Differential Revision: https://reviews.freebsd.org/D1591
MFC after: 1 month
Sponsored by: Sandvine Inc

9 years agoFix Ivy Bridge+ MEM_UOPS_RETIRED counters
Ryan Stone [Tue, 10 Mar 2015 01:24:08 +0000 (01:24 +0000)]
Fix Ivy Bridge+ MEM_UOPS_RETIRED counters

The MEM_UOPS_RETIRED actually work the same way as the Sandy
Bridge counters, but the counters were documented in a different
way and that seemed to cause the Ivy Bridge counters to be
implemented incorrectly.  Use the same counter definitions as
Sandy Bridge.  While I'm here, rename the counters to match
what's documented in the datasheet.

Differential Revision: https://reviews.freebsd.org/D1590
MFC after: 1 month
Sponsored by: Sandvine Inc.

9 years agoSupport architectural events on Haswell/Ivy Bridge
Ryan Stone [Tue, 10 Mar 2015 01:24:02 +0000 (01:24 +0000)]
Support architectural events on Haswell/Ivy Bridge

Differential Revision: https://reviews.freebsd.org/D1589
MFC after: 1 month
Sponsored by: Sandvine Inc

9 years agoUse the correct event table for Haswell Xeon events
Ryan Stone [Tue, 10 Mar 2015 01:23:55 +0000 (01:23 +0000)]
Use the correct event table for Haswell Xeon events

Differential Revision: https://reviews.freebsd.org/D1588
MFC after: 1 month
Sponsored by: Sandvine Inc.

9 years agoFix Sandy Bridge+ hwpmc branch counters
Ryan Stone [Tue, 10 Mar 2015 01:23:47 +0000 (01:23 +0000)]
Fix Sandy Bridge+ hwpmc branch counters

On Sandy Bridge and later, to count branch-related events you
have to or together a mask indicating the type of branch
instruction to count (e.g. direct jump, branch, etc) and a bits
indicating whether to count taken and not-taken branches.  The
current counter definitions where defining this bits individually,
so the counters never worked and always just counted 0.

Fix the counter definitions to instead contain the proper
combination of masks.  Also update the man pages to reflect the
new counters.

Differential Revision: https://reviews.freebsd.org/D1587
MFC after: 1 month
Sponsored by: Sandvine Inc.

9 years agoFix pmc unit restrictions to match documentation
Ryan Stone [Tue, 10 Mar 2015 01:23:40 +0000 (01:23 +0000)]
Fix pmc unit restrictions to match documentation

A couple of pmc counters did not work because there were being
restricted to the wrong PMC unit.  I've verified that these
counters now work and match the documented restrictions.

Differential Revision: https://reviews.freebsd.org/D1586
MFC after: 1 month
Sponsored by: Sandvine Inc

9 years agoFix various bugs in Haswell counter definitions
Ryan Stone [Tue, 10 Mar 2015 01:23:34 +0000 (01:23 +0000)]
Fix various bugs in Haswell counter definitions

1) The "WALK_COMPLETED_2M_4M" event incorrectly referenced 4K pages.
2) The umask for RING0 and RING123 events was reversed.

Differential Revision: https://reviews.freebsd.org/D1585
MFC after: 1 month
Sponsored by: Sandvine Inc

9 years agoAdd manpage for Haswell Xeon pmc implementation
Ryan Stone [Tue, 10 Mar 2015 01:22:43 +0000 (01:22 +0000)]
Add manpage for Haswell Xeon pmc implementation

Differential Revision: https://reviews.freebsd.org/D1584
Reviewed by: gnn
MFC After: 1 month
Sponsored by: Sandvine Inc

9 years agoUse the new ifnet API. Also, allocate bus_dma_maps as needed instead of
Ian Lepore [Mon, 9 Mar 2015 22:39:58 +0000 (22:39 +0000)]
Use the new ifnet API.  Also, allocate bus_dma_maps as needed instead of
pre-allocating them all at start-up.  Also fix a bug in cgem_stop(); before,
it wasn't properly unloading dma maps due to a cut-and-paste error.

9 years agoRevert accidentally commited file from r279824. We're not quite ready to
Ian Lepore [Mon, 9 Mar 2015 22:01:57 +0000 (22:01 +0000)]
Revert accidentally commited file from r279824.  We're not quite ready to
enable dtrace module building on all arm platforms yet.

9 years agoChange the name of the dmtimer pps device from /dev/ppsN to /dev/dmtppsN.
Ian Lepore [Mon, 9 Mar 2015 21:58:41 +0000 (21:58 +0000)]
Change the name of the dmtimer pps device from /dev/ppsN to /dev/dmtppsN.

ntpd is hard-coded to use /dev/ppsN, and typically when multiple PPS sources
are available the sysadmin will symlink the right one(s) to /dev/ppsN, so
it's best to not usurp those names directly.

9 years agoRemove the static DTB config and instead build modules/dtb/am335x.
Ian Lepore [Mon, 9 Mar 2015 21:54:27 +0000 (21:54 +0000)]
Remove the static DTB config and instead build modules/dtb/am335x.

Also, remove WITHOUT_MODULES="ahc" which was added long ago to work around
build problems that have long since been fixed correctly.

PR: 198460

9 years agoAdd a dtb module for AM335x systems (just Beaglebone right now).
Ian Lepore [Mon, 9 Mar 2015 21:50:10 +0000 (21:50 +0000)]
Add a dtb module for AM335x systems (just Beaglebone right now).

9 years ago5589 improper use of NULL in tools/ctf
Mark Johnston [Mon, 9 Mar 2015 20:43:14 +0000 (20:43 +0000)]
5589 improper use of NULL in tools/ctf
Reviewed by: David Höppner <0xffea@gmail.com>
Reviewed by: Josef "Jeff" Sipek <jeffpc@josefsipek.net>
Approved by: Dan McDonald <danmcd@omniti.com>
Author: Richard PALO <richard@NetBSD.org>

illumos/illumos-gate@ad0b1ea5d69a45fe23c434277599e315f29a5fca

9 years agoIn TCP, connect() can return incorrect error code EINVAL
Julien Charbon [Mon, 9 Mar 2015 20:29:16 +0000 (20:29 +0000)]
In TCP, connect() can return incorrect error code EINVAL
instead of EADDRINUSE or ECONNREFUSED

PR: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=196035
Differential Revision: https://reviews.freebsd.org/D1982
Reported by: Mark Nunberg <mnunberg@haskalah.org>
Submitted by: Harrison Grundy <harrison.grundy@astrodoggroup.com>
Reviewed by: adrian, jch, glebius, gnn
Approved by: jhb
MFC after: 2 weeks

9 years agoFix a typo in comment and explain the reason.
Jung-uk Kim [Mon, 9 Mar 2015 20:26:42 +0000 (20:26 +0000)]
Fix a typo in comment and explain the reason.

9 years agoFix CARP when in use in a HyperV environment:
Xin LI [Mon, 9 Mar 2015 20:11:16 +0000 (20:11 +0000)]
Fix CARP when in use in a HyperV environment:

 - Bump link state when stopping or starting the interface;
 - Don't handle SIOCGIFADDR specially, similar to r277103.

This change is based on a previous revision from Andy Zhang
(Microsoft) who did the diagnostic work and many thanks to
them for their help in supporting the HyperV work.

PR: kern/187203
MFC after: 2 weeks

9 years agoAttach the prcm clock driver early, so it can set the mpcore timer frequency.
Ian Lepore [Mon, 9 Mar 2015 15:54:14 +0000 (15:54 +0000)]
Attach the prcm clock driver early, so it can set the mpcore timer frequency.

Submitted by: Svatopluk Kraus

9 years agoErm, revert chunk committed by mistake.
Edward Tomasz Napierala [Mon, 9 Mar 2015 15:44:36 +0000 (15:44 +0000)]
Erm, revert chunk committed by mistake.

MFC after: 1 month
Sponsored by: The FreeBSD Foundation

9 years agoAdd the DTrace modules to the build, rather than only build the dtrace
Warner Losh [Mon, 9 Mar 2015 15:43:33 +0000 (15:43 +0000)]
Add the DTrace modules to the build, rather than only build the dtrace
modules.

9 years agoMake things more readable; no functional changes.
Edward Tomasz Napierala [Mon, 9 Mar 2015 15:31:33 +0000 (15:31 +0000)]
Make things more readable; no functional changes.

MFC after: 1 month
Sponsored by: The FreeBSD Foundation

9 years agoRemove some particularly bad code; no functional changes.
Edward Tomasz Napierala [Mon, 9 Mar 2015 15:20:12 +0000 (15:20 +0000)]
Remove some particularly bad code; no functional changes.

MFC after: 1 month
Sponsored by: The FreeBSD Foundation

9 years agoAdd minimum cache line sizes to struct cpuinfo, use them in the new cache
Ian Lepore [Mon, 9 Mar 2015 14:46:10 +0000 (14:46 +0000)]
Add minimum cache line sizes to struct cpuinfo, use them in the new cache
maintenance routines.  Also add a routine to invalidate the branch cache.

Submitted by: Michal Meloun

9 years agoClean data cache before instruction cache in armv7_icache_sync_range().
Ian Lepore [Mon, 9 Mar 2015 14:42:25 +0000 (14:42 +0000)]
Clean data cache before instruction cache in armv7_icache_sync_range().
Also ensure dsb precedes isb in all icache maintenance routines (first
do a data sync, then stall the instruction stream until it finishes).

Submitted by: Michal Meloun

9 years agoFix memory leak.
Edward Tomasz Napierala [Mon, 9 Mar 2015 13:21:00 +0000 (13:21 +0000)]
Fix memory leak.

MFC after: 1 month
Sponsored by: The FreeBSD Foundation

9 years agoImprove separated_concat() to properly handle the case of concatenating
Edward Tomasz Napierala [Mon, 9 Mar 2015 13:00:59 +0000 (13:00 +0000)]
Improve separated_concat() to properly handle the case of concatenating
"/" and "/foo".

MFC after: 1 month
Sponsored by: The FreeBSD Foundation

9 years agoMinor optimization/cleanup in node_path(); no functional changes.
Edward Tomasz Napierala [Mon, 9 Mar 2015 11:59:58 +0000 (11:59 +0000)]
Minor optimization/cleanup in node_path(); no functional changes.

MFC after: 1 month
Sponsored by: The FreeBSD Foundation

9 years agoFix style(9) from my previous commit r279803.
Marcelo Araujo [Mon, 9 Mar 2015 10:29:15 +0000 (10:29 +0000)]
Fix style(9) from my previous commit r279803.

Spotted by: kevlo

9 years agoNow ifconfig(8) can set the media option as 10Gbase-T for ixgbe(4).
Marcelo Araujo [Mon, 9 Mar 2015 08:43:27 +0000 (08:43 +0000)]
Now ifconfig(8) can set the media option as 10Gbase-T for ixgbe(4).

Differential Revision: D823
Reviewed by: jfvogel
Approved by: jfvogel
Sponsored by: QNAP Systems Inc.

9 years agoFix the media detected for copper cables NIC based on chipset X540T.
Marcelo Araujo [Mon, 9 Mar 2015 08:22:11 +0000 (08:22 +0000)]
Fix the media detected for copper cables NIC based on chipset X540T.

Phabric:        D811
Reviewed by:    jfvogel
Approved by: jfvogel
Sponsored by:   QNAP Systems Inc.

9 years agoDon't specify a function name in the example SDT(9) probe. As with the
Mark Johnston [Mon, 9 Mar 2015 04:00:46 +0000 (04:00 +0000)]
Don't specify a function name in the example SDT(9) probe. As with the
module component, it is a bug that the SDT(9) KPI allows one to specify the
function component of an SDT probe. Currently, the module component is
filled in automatically if left unset; this is not yet true for the function
component, but will be addressed by some ongoing work.

MFC after: 3 days

9 years agoReimplement support for userland core dump compression using a new interface
Mark Johnston [Mon, 9 Mar 2015 03:50:53 +0000 (03:50 +0000)]
Reimplement support for userland core dump compression using a new interface
in kern_gzio.c. The old gzio interface was somewhat inflexible and has not
worked properly since r272535: currently, the gzio functions are called with
a range lock held on the output vnode, but kern_gzio.c does not pass the
IO_RANGELOCKED flag to vn_rdwr() calls, resulting in deadlock when vn_rdwr()
attempts to reacquire the range lock. Moreover, the new gzio interface can
be used to implement kernel core compression.

This change also modifies the kernel configuration options needed to enable
userland core dump compression support: gzio is now an option rather than a
device, and the COMPRESS_USER_CORES option is removed. Core dump compression
is enabled using the kern.compress_user_cores sysctl/tunable.

Differential Revision: https://reviews.freebsd.org/D1832
Reviewed by: rpaulo
Discussed with: kib

9 years agoCall xo_finish(3) before exiting in usage().
Mark Johnston [Mon, 9 Mar 2015 03:31:26 +0000 (03:31 +0000)]
Call xo_finish(3) before exiting in usage().

9 years agoProvide a shim layer in loader to condense the Open Firmware device tree to
Nathan Whitehorn [Mon, 9 Mar 2015 02:57:34 +0000 (02:57 +0000)]
Provide a shim layer in loader to condense the Open Firmware device tree to
an FDT. This is how Linux and OS X boot and can avoid some issues with
using Open Firmware at runtime. The code is highly experimental and disabled
by default; it can be turned on by setting the loader environment variable
"usefdt" to a non-NULL value.

9 years agoFix loader on PowerPC following r279784. It turns out that, due to .PATH
Nathan Whitehorn [Mon, 9 Mar 2015 02:19:44 +0000 (02:19 +0000)]
Fix loader on PowerPC following r279784. It turns out that, due to .PATH
confusion, the _setjmp.S in libstand was never being used and was instead
being shadowed by the libc version. Since the libc version now uses FPRs,
it caused loader to crash.

9 years agoMethodise a couple more of the VLAN methods.
Adrian Chadd [Sun, 8 Mar 2015 23:02:15 +0000 (23:02 +0000)]
Methodise a couple more of the VLAN methods.

9 years agotouch(1): Xref utimensat(2) instead of utimes(2).
Jilles Tjoelker [Sun, 8 Mar 2015 22:49:34 +0000 (22:49 +0000)]
touch(1): Xref utimensat(2) instead of utimes(2).

9 years agoNow that if_arge.c handles actual 'locked' media settings, enable
Adrian Chadd [Sun, 8 Mar 2015 22:07:32 +0000 (22:07 +0000)]
Now that if_arge.c handles actual 'locked' media settings, enable
the WAN port to look like it has its own PHY on PHY4 (port5).

9 years agoModify the if_arge code to use a /fixed/ media mode when it's configured.
Adrian Chadd [Sun, 8 Mar 2015 22:03:54 +0000 (22:03 +0000)]
Modify the if_arge code to use a /fixed/ media mode when it's configured.

Otherwise, the initial media speed would change if a PHY is hooked up,
sending PHY speed notifications.  For the AP135 at least, the RGMII
PHY has a static speed/duplex configured and if the PHY plumbing
attaches the PHY to the if_arge interface, the first link speed change
from 1000/full will set the MAC to something that isn't useful.

This shouldn't affect any other platforms - everything I looked at is
using hard-coded speed/duplex as static, as they're facing a switch
with no PHY attached.

9 years agoAdd per-port vlan support for the AR8327.
Adrian Chadd [Sun, 8 Mar 2015 21:59:03 +0000 (21:59 +0000)]
Add per-port vlan support for the AR8327.

All the per-port support is really doing is applying a port visibility
mask to each of the switchports.  Everything still look like a single
portgroup (vlan id 1), but the per-port visibility mask is modified.

Whilst I'm here, also add some initial dot1q support - the pvid stuff
is doing the right thing, but it's not useful without the rest of
the VLAN table programming.

It's enough for me to be able to use the LAN/WAN port distinction
on the AP135, where there isn't (for now!) a dedicated PHY for the
"WAN" port.

Tested:

* AP135, QCA9558 SoC + AR8327 switch

9 years agoSummary: Remove the need for `mpid which is Illumos/Solaris specific.
George V. Neville-Neil [Sun, 8 Mar 2015 21:51:37 +0000 (21:51 +0000)]
Summary: Remove the need for `mpid which is Illumos/Solaris specific.

9 years agoFix contraction and unnecessary commas in function arguments.
Luiz Otavio O Souza [Sun, 8 Mar 2015 21:17:56 +0000 (21:17 +0000)]
Fix contraction and unnecessary commas in function arguments.

Found with mandoc and igor.

9 years agoPut the new sentence on a new line.
Luiz Otavio O Souza [Sun, 8 Mar 2015 21:11:08 +0000 (21:11 +0000)]
Put the new sentence on a new line.

Found with igor.

9 years agobge(4): Small memory leak
Pedro F. Giffuni [Sun, 8 Mar 2015 19:55:46 +0000 (19:55 +0000)]
bge(4): Small memory leak

CID: 1229985
Reviewed by: marcel
Differential Review: https://reviews.freebsd.org/D2024