]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
8 years agoAdd assertions that capture invalid configurations for new libraries.
bdrewery [Wed, 2 Dec 2015 01:24:31 +0000 (01:24 +0000)]
Add assertions that capture invalid configurations for new libraries.

Fix current findings, which should fix cases of NO_SHARED not building
properly.

Given libfoo:
 - Ensure that a LIBFOO is set.  For INTERNALLIBS advise setting this in
   src.libnames.mk, otherwise bsd.libnames.mk.
 - Ensure that a LIBFOODIR is properly set.
 - Ensure that _DP_foo is set and matches the LIBADD in the build of foo's own
   Makefile

Sponsored by: EMC / Isilon Storage Division

8 years agoDon't overlink pthread to kerberos library consumers.
bdrewery [Wed, 2 Dec 2015 01:23:16 +0000 (01:23 +0000)]
Don't overlink pthread to kerberos library consumers.

I'm not sure why this was here, none of these use pthread themselves and
none of the consumers are broken with removing this.

Sponsored by: EMC / Isilon Storage Division

8 years agoDon't overlink pthread to libsqlite3 consumers.
bdrewery [Wed, 2 Dec 2015 01:17:09 +0000 (01:17 +0000)]
Don't overlink pthread to libsqlite3 consumers.

At least usr.bin/mandoc was overlink.

Sponsored by: EMC / Isilon Storage Division

8 years agoFix truncation of _DP_proc and add missing libelf.
bdrewery [Wed, 2 Dec 2015 00:54:05 +0000 (00:54 +0000)]
Fix truncation of _DP_proc and add missing libelf.

Sponsored by: EMC / Isilon Storage Division

8 years agoReduce overlinking of libdtrace consumers with libctf, libelf, libproc.
bdrewery [Wed, 2 Dec 2015 00:49:49 +0000 (00:49 +0000)]
Reduce overlinking of libdtrace consumers with libctf, libelf, libproc.

The proper place for this list is _DP_dtrace.

Due to removing the LDADD_dtrace, more LIBADD are needed in
cddl/usr.sbin/dtrace to prevent underlinking.

This fixes overlinking in cddl/usr.sbin/lockstat and
cddl/usr.sbin/plockstat.

Sponsored by: EMC / Isilon Storage Division

8 years agoFully connect cddl/usr.sbin/plockstat.
bdrewery [Wed, 2 Dec 2015 00:49:45 +0000 (00:49 +0000)]
Fully connect cddl/usr.sbin/plockstat.

There seems to be no reason to keep this so private.

Also add missing optional MK_CDDL files.

Sponsored by: EMC / Isilon Storage Division

8 years agoDon't overlink libmt consumers with libsbuf.
bdrewery [Wed, 2 Dec 2015 00:49:42 +0000 (00:49 +0000)]
Don't overlink libmt consumers with libsbuf.

This change came in r281332 which was reducing overlinking in mt(1) but
currently mt(1) is linked with sbuf when it does not need it due to the
LDADD_mt+=${LDADD_sbuf}.  Only libmt needs sbuf.

Add sbuf to _DP_mt so static linkage of libmt picks it up.

Sponsored by: EMC / Isilon Storage Division

8 years agolibssh uses libz even without MK_LDNS
bdrewery [Wed, 2 Dec 2015 00:49:39 +0000 (00:49 +0000)]
libssh uses libz even without MK_LDNS

Sponsored by: EMC / Isilon Storage Division

8 years agoRevert incomplete r291623.
bdrewery [Wed, 2 Dec 2015 00:17:13 +0000 (00:17 +0000)]
Revert incomplete r291623.

8 years agoAdd assertions that capture invalid configurations for new libraries.
bdrewery [Wed, 2 Dec 2015 00:01:09 +0000 (00:01 +0000)]
Add assertions that capture invalid configurations for new libraries.

Fix current findings.

Given libfoo:
 - Ensure that a LIBFOO is set.  For INTERNALLIBS advise setting this in
   src.libnames.mk, otherwise bsd.libnames.mk.
 - Ensure that a LIBFOODIR is properly set.
 - Ensure that _DP_foo is set and matches the LIBADD in the build of foo's own
   Makefile

Sponsored by: EMC / Isilon Storage Division

8 years agoFix build after r291620.
bdrewery [Tue, 1 Dec 2015 22:50:32 +0000 (22:50 +0000)]
Fix build after r291620.

  "don't know how to make /Versions.def. Stop"

This was trying to define a target in bsd.symver.mk based on LIBCDIR which was
not yet defined.  Switching the order of inclusion of bsd.prog.mk and
bsd.symver.mk fixes it and seems fine.

Pointyhat to: bdrewery
Sponsored by: EMC / Isilon Storage Division

8 years agoDon't add LIBADD=ipf to libipf itself.
bdrewery [Tue, 1 Dec 2015 22:39:19 +0000 (22:39 +0000)]
Don't add LIBADD=ipf to libipf itself.

This had no real impact since libipf is a static INTERNALLIB.  It does conflict
with an assertion I am adding for LIBADD though.

Sponsored by: EMC / Isilon Storage Division

8 years agoDon't override LIB*DIR variables from src.libnames.mk.
bdrewery [Tue, 1 Dec 2015 22:20:04 +0000 (22:20 +0000)]
Don't override LIB*DIR variables from src.libnames.mk.

In some cases switch to the LIB*SRCDIR value.

These recently were defined in r291327 and r291619.

Sponsored by: EMC / Isilon Storage Division

8 years agoDefine a LIB*SRCDIR for all known _LIBRARIES.
bdrewery [Tue, 1 Dec 2015 22:19:17 +0000 (22:19 +0000)]
Define a LIB*SRCDIR for all known _LIBRARIES.

This is a follow-up to r291327 which added a LIB*DIR for all known
_LIBRARIES.

Sponsored by: EMC / Isilon Storage Division

8 years agoDon't override LIB*DIR variables from src.libnames.mk.
bdrewery [Tue, 1 Dec 2015 22:04:59 +0000 (22:04 +0000)]
Don't override LIB*DIR variables from src.libnames.mk.

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

8 years agoDon't override LIB*DIR variables from src.libnames.mk.
bdrewery [Tue, 1 Dec 2015 22:03:40 +0000 (22:03 +0000)]
Don't override LIB*DIR variables from src.libnames.mk.

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

8 years agoEnable libcrypt tests.
rodrigc [Tue, 1 Dec 2015 21:25:18 +0000 (21:25 +0000)]
Enable libcrypt tests.

kyua 0.12 has fix for https://github.com/jmmv/kyua/pull/148
which eliminates invalid XML characters from being written to test reports
with "kyua report-junit".

8 years agoHack test so that it works on FreeBSD.
rodrigc [Tue, 1 Dec 2015 21:22:29 +0000 (21:22 +0000)]
Hack test so that it works on FreeBSD.

8 years agoRestore cleaning of auto-generated kobj files after the recent MFILES
jhb [Tue, 1 Dec 2015 21:19:16 +0000 (21:19 +0000)]
Restore cleaning of auto-generated kobj files after the recent MFILES
changes.  Use the list of MFILES found by find to identify the set of
possible auto-generated files and add the intersection of this set and
SRCS to CLEANFILES.

Submitted by: imp (previous version), sbruno
Differential Revision: https://reviews.freebsd.org/D4336

8 years agoOnly include src.conf if _WITHOUT_SRCCONF not defined.
bdrewery [Tue, 1 Dec 2015 20:56:16 +0000 (20:56 +0000)]
Only include src.conf if _WITHOUT_SRCCONF not defined.

This does not really fix anything currently since _WITHOUT_SRCCONF must be
defined in the environment or local.sys.*.mk, but is proper and needed for
downstream fixes.  I am working towards reworking src.conf inclusion still.

Sponsored by: EMC / Isilon Storage Division

8 years agoSupport LOCAL_LIBRARIES for LIBADD.
bdrewery [Tue, 1 Dec 2015 20:50:14 +0000 (20:50 +0000)]
Support LOCAL_LIBRARIES for LIBADD.

Sponsored by: EMC / Isilon Storage Division

8 years agoAdd NO_INSTALLKERNEL to undo the assumption that the first KERNCONF will be
bdrewery [Tue, 1 Dec 2015 20:24:58 +0000 (20:24 +0000)]
Add NO_INSTALLKERNEL to undo the assumption that the first KERNCONF will be
installed as "kernel".  This is relevant for packaging of the kernel when
not wanting a default "kernel.txz".

Submitted by: Russell Cattelan <cattelan@thebarn.com>
MFC after: 2 weeks
Obtained from: OneFS
Sponsored by: EMC / Isilon Storage Division

8 years agoAllow storing package(world|kernel) tarballs into a different location at PACKAGEDIR.
bdrewery [Tue, 1 Dec 2015 19:58:08 +0000 (19:58 +0000)]
Allow storing package(world|kernel) tarballs into a different location at PACKAGEDIR.

Submitted by: Russell Cattelan <cattelan@thebarn.com>
Discussed with: gjb
MFC after: 2 weeks
Obtained from: OneFS
Sponsored by: EMC / Isilon Storage Division

8 years agoFix typos in error messages dealing with unknown groups/users
ngie [Tue, 1 Dec 2015 19:37:24 +0000 (19:37 +0000)]
Fix typos in error messages dealing with unknown groups/users

MFC after: 1 month
X-MFC with: r291447, r291452
Sponsored by: EMC / Isilon Storage Division

8 years agoFix spelling, as recommended by igor tool.
rodrigc [Tue, 1 Dec 2015 19:20:38 +0000 (19:20 +0000)]
Fix spelling, as recommended by igor tool.

8 years agoAdd more text to explain --libxo flag.
rodrigc [Tue, 1 Dec 2015 19:18:53 +0000 (19:18 +0000)]
Add more text to explain --libxo flag.

8 years agoFix errors being ignored in many phases of the build since the bmake integration.
bdrewery [Tue, 1 Dec 2015 19:00:43 +0000 (19:00 +0000)]
Fix errors being ignored in many phases of the build since the bmake integration.

Say it with me, "I will not chain commands with && in Makefiles"

This was originally fixed and explained quite well by bde@ in r36074.  The
initial bmake integration caused 'set -e' to stop being used which lead to
r252419.  Later 'set -e' expectations were fixed with bmake in r254980.

Because of the && here, errors would be ignored when building in parallel and
a dependency failed.  Such as bootstrap-tools since it builds everything in
parallel.  If any tool failed in obj/depend/all, it would just ignore the error
and continue to build.  This later would result in cascaded errors that only
confused the real issue.  This could also cause commands after the failed
command to still execute, leading to more confusion.

This should be fine if the command is in a sub-shell such as: (cmd1 && cmd2)

This reverts r252419.

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

8 years agoAdd missing LIB80211 entry for DPADD needs.
bdrewery [Tue, 1 Dec 2015 18:09:40 +0000 (18:09 +0000)]
Add missing LIB80211 entry for DPADD needs.

Sponsored by: EMC / Isilon Storage Division

8 years agoFix underlinking in lib80211 and define static dependencies in src.libnames.mk
bdrewery [Tue, 1 Dec 2015 17:38:52 +0000 (17:38 +0000)]
Fix underlinking in lib80211 and define static dependencies in src.libnames.mk
so NO_SHARED works properly.

Reported by: Manfred Antar <null@pozo.com>
Sponsored by: EMC / Isilon Storage Division

8 years agoNo trailing slash is needed here.
bdrewery [Tue, 1 Dec 2015 17:31:22 +0000 (17:31 +0000)]
No trailing slash is needed here.

8 years agoAllow loader to load 64-bit ELFv2 PowerPC kernels.
nwhitehorn [Tue, 1 Dec 2015 17:01:27 +0000 (17:01 +0000)]
Allow loader to load 64-bit ELFv2 PowerPC kernels.

8 years agoMissed header_supported call from r291020: make really, really sure the brand
nwhitehorn [Tue, 1 Dec 2015 17:00:31 +0000 (17:00 +0000)]
Missed header_supported call from r291020: make really, really sure the brand
likes the executable.

8 years agoModify the rctl rc script to add multiple rules in a single run.
trasz [Tue, 1 Dec 2015 16:42:39 +0000 (16:42 +0000)]
Modify the rctl rc script to add multiple rules in a single run.

MFC after: 1 month
Sponsored by: The FreeBSD Foundation

8 years agoSome problems were introduced during the libxo-ification of vmstat, fix them
allanjude [Tue, 1 Dec 2015 16:31:07 +0000 (16:31 +0000)]
Some problems were introduced during the libxo-ification of vmstat, fix them

stop vmstat -i segfaulting
remove duplicate header from vmstat -i
do not pad the name of the interupt in encoded outputs
fix stray % and missing } in the header for vmstat -i
add outer container to vmstat -i
add missing xo_flush in vmstat -i (when run with an interval or delay)
add outer container to vmstat -m
do not pad the name of malloc areans
add outer container to vmstat -z
do not pad the name of memory zones

Reviewed by: rodrigc
Approved by: bapt (mentor)
Sponsored by: ScaleEngine Inc.
Differential Revision: https://reviews.freebsd.org/D4263

8 years agoCorrect r291591: Don't remove /usr/lib/libelf*, these are still installed.
bdrewery [Tue, 1 Dec 2015 16:16:40 +0000 (16:16 +0000)]
Correct r291591: Don't remove /usr/lib/libelf*, these are still installed.
Only the shared library moved to /lib.

X-MFC-With: r291566

8 years agoCorrect r291566 for defining SHLIBDIR.
bdrewery [Tue, 1 Dec 2015 16:08:38 +0000 (16:08 +0000)]
Correct r291566 for defining SHLIBDIR.

This must happen before including bsd.own.mk which sets the default to /usr/lib.

X-MFC-With: r291566
Reported by: Max N. Boyarov

8 years agoAt the time a destination or a gateway of `netstat -r'
ume [Tue, 1 Dec 2015 16:04:50 +0000 (16:04 +0000)]
At the time a destination or a gateway of `netstat -r'
protrudes its field, narrow the next field to raise
readability bit.

8 years agoFix removal of libelf.so.2 and add missing files for it.
bdrewery [Tue, 1 Dec 2015 15:55:20 +0000 (15:55 +0000)]
Fix removal of libelf.so.2 and add missing files for it.

X-MFC-With: r291566

8 years agosfxge: retry VF vAdaptor allocation if it fails because of no EVB port yet
arybchik [Tue, 1 Dec 2015 15:54:46 +0000 (15:54 +0000)]
sfxge: retry VF vAdaptor allocation if it fails because of no EVB port yet

After an MC reboot, a VF driver may reset before the PF driver has
finished bringing everything back up. This includes the VFs EVB port.
MC_CMD_VADAPTOR_ALLOC is the first MCDI call after an MC reboot to
require the EVB port, so if it fails with MC_CMD_ERR_NO_EVB_PORT,
retry the command a few times after waiting a while.

Submitted by:   Mark Spender <mspender at solarflare.com>
Sponsored by:   Solarflare Communications, Inc.
MFC after:      2 days
Differential Revision: https://reviews.freebsd.org/D4333

8 years agoFAST_DEPEND: Actually use -MP from DEPEND_MP, completing r291554.
bdrewery [Tue, 1 Dec 2015 15:50:35 +0000 (15:50 +0000)]
FAST_DEPEND: Actually use -MP from DEPEND_MP, completing r291554.

X-MFC-With: r291554
MFC after: 1 week
Pointyhat to: bdrewery
Sponsored by: EMC / Isilon Storage Division

8 years agosfxge: add function to query link control privilege
arybchik [Tue, 1 Dec 2015 15:38:39 +0000 (15:38 +0000)]
sfxge: add function to query link control privilege

Make link control privilege visible to OS driver to guard updates to
flow control and PHY advertised capabilities.

Submitted by:   Richard Houldsworth <rhouldsworth at solarflare.com>
Sponsored by:   Solarflare Communications, Inc.
MFC after:      2 days
Differential Revision: https://reviews.freebsd.org/D4330

8 years agosfxge: FPGA and FPGA backup (diagnostic) partitions added to hunt_parttbl
arybchik [Tue, 1 Dec 2015 15:32:37 +0000 (15:32 +0000)]
sfxge: FPGA and FPGA backup (diagnostic) partitions added to hunt_parttbl

It allows manftest to program them.

Submitted by:   Paul Fox <pfox at solarflare.com>
Sponsored by:   Solarflare Communications, Inc.
MFC after:      2 days
Differential Revision: https://reviews.freebsd.org/D4329

8 years agosfxge: allow VFs to have locally administered MAC addresses
arybchik [Tue, 1 Dec 2015 15:29:51 +0000 (15:29 +0000)]
sfxge: allow VFs to have locally administered MAC addresses

Submitted by:   Mark Spender <mspender at solarflare.com>
Sponsored by:   Solarflare Communications, Inc.
MFC after:      2 days
Differential Revision: https://reviews.freebsd.org/D4328

8 years agosfxge: support MAC spoofing for 4.2.x firmare
arybchik [Tue, 1 Dec 2015 15:26:46 +0000 (15:26 +0000)]
sfxge: support MAC spoofing for 4.2.x firmare

Common code should infer other privileges from Admin privilege to
support firmware that pre-dates introduction of specific privilege
flags.

Submitted by:   Richard Houldsworth <rhouldsworth at solarflare.com>
Sponsored by:   Solarflare Communications, Inc.
MFC after:      2 days
Differential Revision: https://reviews.freebsd.org/D4327

8 years agosfxge: parse packets for TSO early in if_transmit
arybchik [Tue, 1 Dec 2015 14:55:24 +0000 (14:55 +0000)]
sfxge: parse packets for TSO early in if_transmit

Submitted by:   Artem V. Andreev <Artem.Andreev at oktetlabs.ru>
Sponsored by:   Solarflare Communications, Inc.
MFC after:      1 week
Differential Revision: https://reviews.freebsd.org/D4309

8 years agoFix rctl rule filters - eg the 'rctl -r :' case.
trasz [Tue, 1 Dec 2015 14:02:14 +0000 (14:02 +0000)]
Fix rctl rule filters - eg the 'rctl -r :' case.

MFC after: 1 month
Sponsored by: The FreeBSD Foundation

8 years agoLoad our configuration before setting defaults, so local_unbound_workdir
des [Tue, 1 Dec 2015 13:20:21 +0000 (13:20 +0000)]
Load our configuration before setting defaults, so local_unbound_workdir
actually has an effect.

PR: 204931
Submitted by: Eugene Grosbein <eugen@grosbein.net>
MFC after: 1 week

8 years agoRework the exception entry/return functions to make them valid frames to be
andrew [Tue, 1 Dec 2015 12:37:04 +0000 (12:37 +0000)]
Rework the exception entry/return functions to make them valid frames to be
unwound through. For this we need the frame pointer (x29) to point to the
location on the stack where we stored the previous frame pointer, and link
register. To simplify this the stack pointer is only adjusted by addition
and subtraction, and not through the use of post increment on loads and
stores.

The updated frame layout is:

+------------+
| lr -- x30  |
+------------+
| fp -- x29  | <-- x29 points at this
+------------+
| Trap frame |
| ...        |
|            | <-- sp points at this
+------------+

The only difference is the first two items, and setting of x29.

Sponsored by: ABT Systems Ltd

8 years agoRework the atomic code to reduce the repetition. This merges some of the
andrew [Tue, 1 Dec 2015 12:27:36 +0000 (12:27 +0000)]
Rework the atomic code to reduce the repetition. This merges some of the
atomic functions where they are almost identical, or have acquire/release
semantics.

While here clean these function up. The cbnz instruction doesn't change
the condition flags so drop cc, however they should have memory added to the
clobber list.

Reviewed by: kib
Sponsored by: ABT Systems Ltd
Differential Revision: https://reviews.freebsd.org/D4318

8 years agoIn the same way fix the problem described in r291578 for IGMPv3.
ae [Tue, 1 Dec 2015 11:24:30 +0000 (11:24 +0000)]
In the same way fix the problem described in r291578 for IGMPv3.

In case when router has a lot of multicast groups, the reply can take
several packets due to MTU limitation.
Also we have a limit IGMP_MAX_RESPONSE_BURST == 4, that limits the number
of packets we send in one shot. Then we recalculate the timer value and
schedule the remaining packets for sending.
The problem is that when we call igmp_v3_dispatch_general_query() to send
remaining packets, we queue new reply in the same mbuf queue. And when
number of packets is bigger than IGMP_MAX_RESPONSE_BURST, we get endless
reply of IGMPv3 reports.
To fix this, add the check for remaining packets in the queue.

MFC after: 1 week
Sponsored by: Yandex LLC

8 years agomld_v2_dispatch_general_query() is used by mld_fasttimo_vnet() to send
ae [Tue, 1 Dec 2015 11:17:41 +0000 (11:17 +0000)]
mld_v2_dispatch_general_query() is used by mld_fasttimo_vnet() to send
a reply to the MLDv2 General Query. In case when router has a lot of
multicast groups, the reply can take several packets due to MTU limitation.
Also we have a limit MLD_MAX_RESPONSE_BURST == 4, that limits the number
of packets we send in one shot. Then we recalculate the timer value and
schedule the remaining packets for sending.
The problem is that when we call mld_v2_dispatch_general_query() to send
remaining packets, we queue new reply in the same mbuf queue. And when
number of packets is bigger than MLD_MAX_RESPONSE_BURST, we get endless
reply of MLDv2 reports.
To fix this, add the check for remaining packets in the queue.

PR: 204831
MFC after: 1 week
Sponsored by: Yandex LLC

8 years agoPrint useful information when we hit a data abort we can't handle. This
andrew [Tue, 1 Dec 2015 09:52:41 +0000 (09:52 +0000)]
Print useful information when we hit a data abort we can't handle. This
prints the trap frame, along with the exception syndrome and fault address
registers. Even though esr is 64-bits here it is only 32-bits in hardware
so only print the valid 32-bits.

While here also print esr and far when appropriate after printing the trap
frame.

Sponsored by: ABT Systems Ltd

8 years agor221714 fixed the situation when the collapse scan improperly handled
kib [Tue, 1 Dec 2015 09:06:09 +0000 (09:06 +0000)]
r221714 fixed the situation when the collapse scan improperly handled
invalid (busy) page supposedly inserted by the vm_fault(), in the
OBSC_COLLAPSE_NOWAIT case.  As a continuation to r221714, fix a case
when invalid page is found by the object scan in OBSC_COLLAPSE_WAIT
case as well.  But, since this is waitable scan, we should wait for
the termination of the busy state and restart from the beginning of
the backing object' page queue. [*]

Do not free the shadow page swap space when the parent page is
invalid, otherwise this action potentially corrupts user data.

Combine all instances of the collapse scan sleep code fragments into
the new helper vm_object_backing_scan_wait().

Improve style compliance and comments.  Change the return type of
vm_object_backing_scan() to bool.

Initial submission by: cem, https://reviews.freebsd.org/D4103 [*]
Reviewed by: alc, cem
Tested by: cem
Sponsored by: The FreeBSD Foundation
MFC after: 2 weeks
Differential revision: https://reviews.freebsd.org/D4146

8 years agoDisable mqueue test # 3 and # 4 until __mq_oshandle is properly publicized
ngie [Tue, 1 Dec 2015 07:52:41 +0000 (07:52 +0000)]
Disable mqueue test # 3 and # 4 until __mq_oshandle is properly publicized

This will unbreak the test script and make things green again after r291440

Sponsored by: EMC / Isilon Storage Division

8 years agosfxge: added setting TSO-related parameters
arybchik [Tue, 1 Dec 2015 06:29:11 +0000 (06:29 +0000)]
sfxge: added setting TSO-related parameters

Submitted by:   Artem V. Andreev <Artem.Andreev at oktetlabs.ru>
Sponsored by:   Solarflare Communications, Inc.
MFC after:      2 days
Differential Revision: https://reviews.freebsd.org/D4308

8 years agosfxge: avoid TSO packets collapses if packet header uses 2 segments
arybchik [Tue, 1 Dec 2015 06:23:15 +0000 (06:23 +0000)]
sfxge: avoid TSO packets collapses if packet header uses 2 segments

It is really observed in the case of VLAN over sfxge interface.
Also this change makes total value equal to 35 which is default assumed
by the kernel for if_hw_tsomaxsegcount.

Sponsored by:   Solarflare Communications, Inc.
MFC after:      2 days
Differential Revision: https://reviews.freebsd.org/D4319

8 years agoRevert r290840
ngie [Tue, 1 Dec 2015 06:22:27 +0000 (06:22 +0000)]
Revert r290840

This request by the submitter was valid, but unfortunately there is a good deal
of concern over breakage when DESTDIR != / or "", i.e. with release media.
Making this change correct for all cases would make it markedly more complex
than need be

Requested by: bdrewery, ian, imp
PR: 76362

8 years agoAdjust a comment; we now support these embedded boards!
adrian [Tue, 1 Dec 2015 06:11:09 +0000 (06:11 +0000)]
Adjust a comment; we now support these embedded boards!

8 years agoMove libelf.so.2 from /usr/lib to /lib to unbreak libkvm use after r291406
ngie [Tue, 1 Dec 2015 06:09:22 +0000 (06:09 +0000)]
Move libelf.so.2 from /usr/lib to /lib to unbreak libkvm use after r291406

Tested with the following commands as root:
- yes | make delete-old
- service ldconfig restart
- netstat -nr

X-MFC with: r291406
Reviewed by: jhb, kib
Sponsored by: EMC / Isilon Storage Division

8 years agoFix LINT-NOIP kernels after r291467
ngie [Tue, 1 Dec 2015 05:59:53 +0000 (05:59 +0000)]
Fix LINT-NOIP kernels after r291467

rn is only used if INET or INET6 are defined

Sponsored by: EMC / Isilon Storage Division

8 years agoMETA MODE: Add some basic bootstrapping support for no Makefile.depend.
bdrewery [Tue, 1 Dec 2015 05:29:30 +0000 (05:29 +0000)]
META MODE: Add some basic bootstrapping support for no Makefile.depend.

This will not work for bootstrapping dependencies, it will only
bootstrap the top-level build directory.

Sponsored by: EMC / Isilon Storage Division

8 years agoMETA MODE: Update dependencies with 'the-lot' and add missing directories.
bdrewery [Tue, 1 Dec 2015 05:23:19 +0000 (05:23 +0000)]
META MODE: Update dependencies with 'the-lot' and add missing directories.

This is not properly respecting WITHOUT or ARCH dependencies in target/.
Doing so requires a massive effort to rework targets/ to do so.  A
better approach will be to either include the SUBDIR Makefiles directly
and map to DIRDEPS or just dynamically lookup the SUBDIR.  These lose
the benefit of having a userland/lib, userland/libexec, etc, though and
results in a massive package.  The current implementation of targets/ is
very unmaintainable.

Currently rescue/rescue and sys/modules are still not connected.

Sponsored by: EMC / Isilon Storage Division

8 years agoMETA MODE: Fix userland/cddl.
bdrewery [Tue, 1 Dec 2015 05:22:10 +0000 (05:22 +0000)]
META MODE: Fix userland/cddl.

MK_CTF controls whether ctfmerge is ran against the binaries, not
whether CTF tools should be built.

Sponsored by: EMC / Isilon Storage Division

8 years agoMETA MODE: Rework [bootstrapped] tools PATH support.
bdrewery [Tue, 1 Dec 2015 05:19:02 +0000 (05:19 +0000)]
META MODE: Rework [bootstrapped] tools PATH support.

- Support more of the toolchain from TOOLSDIR.
- This also improves 'make bootstrap-tools' to pass, for example,
  AS=/usr/bin/as to Makefile.inc1, which will tell cross-tools to use
  external toolchain support and avoid building things we won't be using
  in the build.
- Always set the PATH to contain the staged TOOLSDIR directories when
  not building the bootstrap targets.

  The previous version was only setting this at MAKE.LEVEL==0 and if the
  TOOLSDIR existed.  Both of these prevented using staged tools that were
  built during the build though as DIRDEPS with .host dependencies, such
  as the fix for needing usr.bin/localedef.host in r291311.
  This is not a common tool so we must build and use it during the build,
  and need to be prepared to change PATH as soon as it appears.

  This should also fix the issue of host dependencies disappearing from
  Makefile.depend and then reappearing due to the start of the fresh build not
  having the directory yet, resulting in the tools that were built not actually
  being used.
- Only use LEGACY_TOOLS while building in Makefile.inc1.  After r291317
  and r291546 there is no need to add LEGACY_TOOLS into the PATH for
  the pseudo/targets/toolchain build.
- Because the pseudo/targets/toolchain will now build its own
  [clang-]tblgen, the special logic in clang.build.mk is no longer needed.
- LEGACY_TOOLS is no longer used outside of targets/pseudo/bootstrap-tools
  so is no longer passed into the environment in its build.

Sponsored by: EMC / Isilon Storage Division

8 years agoMETA MODE: Fix rebuilding of lib/clang/include after clang-tblgen.host is
bdrewery [Tue, 1 Dec 2015 05:18:59 +0000 (05:18 +0000)]
META MODE: Fix rebuilding of lib/clang/include after clang-tblgen.host is
staged.

None of usr.bin/clang/clang-tblgen or its dependencies need
lib/clang/include, so there is no cyclic dependency here to worry about.
The issue came about because of workarounds to dependencies on clang
being optional.

Without this, the clang-tblgen called during the build would change
after it was staged for the host.  This would cause lib/clang/include to
rebuild due to changed build commands.

Sponsored by: EMC / Isilon Storage Division

8 years agoMETA MODE: Don't trim out lib/clang/include dependency.
bdrewery [Tue, 1 Dec 2015 05:18:55 +0000 (05:18 +0000)]
META MODE: Don't trim out lib/clang/include dependency.

Doing this causes more trouble than it is worth regarding cyclic
dependencies.  It should not be needed after cleaning up MACHINE=host
builds in r291324.

Sponsored by: EMC / Isilon Storage Division

8 years agoUpdate dependencies after r291406 added libelf to libkvm.
bdrewery [Tue, 1 Dec 2015 05:18:48 +0000 (05:18 +0000)]
Update dependencies after r291406 added libelf to libkvm.

Unfortunately filemon/meta mode tracks all indirect dependencies here
since ld(1) is reading libelf when linking in libkvm.  Churn would be
reduced if this was able to be limited to direct dependencies.

Sponsored by: EMC / Isilon Storage Division

8 years agoAdd initial support for RTL8152 USB Fast Ethernet. RTL8152 supports
kevlo [Tue, 1 Dec 2015 05:12:13 +0000 (05:12 +0000)]
Add initial support for RTL8152 USB Fast Ethernet.  RTL8152 supports
IPv4/IPv6 checksum offloading and VLAN tag insertion/stripping.

Since uether doesn't provide a way to announce driver specific offload
capabilities to upper stack, checksum offloading support needs more work
and will be done in the future.

Special thanks to Hayes Wang from RealTek who gave input.

8 years agoFAST_DEPEND: Workaround hacks in the wild that have '..' or '/' in OBJS.
bdrewery [Tue, 1 Dec 2015 03:09:54 +0000 (03:09 +0000)]
FAST_DEPEND: Workaround hacks in the wild that have '..' or '/' in OBJS.

This is mostly working around the converts/iconv port having '../ces/file.o'
in its OBJS list which resulted in '.depend../ces/file.o'.  Now it will have
'.depend.._ces_file.o'.

Other implementations have :T which would result in '.depend.file.o' here, but
that could lead to collisions.

X-MFC-With: r291554
MFC after: 1 week
Sponsored by: EMC / Isilon Storage Division

8 years agoFAST_DEPEND: Allow not using -MP by setting DEPEND_MP blank.
bdrewery [Tue, 1 Dec 2015 03:00:10 +0000 (03:00 +0000)]
FAST_DEPEND: Allow not using -MP by setting DEPEND_MP blank.

-MP creates empty targets for all dependency files, which can be useful when a
dependency is deleted from the file system.  This would otherwise cause an
error for "don't know how to build FOO" since the .depend file is included
with the dependency registered.

This is mostly a workaround for the misc/dahdi-kmod port using '::' for one of
its dependencies, while -MP uses just ':'.  This results in an 'Inconsistent
operator for' error.

X-MFC-With: r290433
MFC after: 1 week
Sponsored by: EMC / Isilon Storage Division

8 years agocapsicum: plug spurious memset in __cap_rights_init
mjg [Tue, 1 Dec 2015 02:48:42 +0000 (02:48 +0000)]
capsicum: plug spurious memset in __cap_rights_init

Reviewed by: pjd

8 years agoMETA MODE: Libc++ does in fact need Libcxxrt.
bdrewery [Tue, 1 Dec 2015 01:22:10 +0000 (01:22 +0000)]
META MODE: Libc++ does in fact need Libcxxrt.

There seems to be no cyclic dependency here.  This partially reverts r283595
which had no explanation for the change.

Sponsored by: EMC / Isilon Storage Division

8 years agoMETA MODE: Always define HOST_*, even if not using them.
bdrewery [Tue, 1 Dec 2015 00:53:17 +0000 (00:53 +0000)]
META MODE: Always define HOST_*, even if not using them.

Sponsored by: EMC / Isilon Storage Division

8 years agoMETA MODE: For bootstrap-tools, don't let Makefile.inc1 build any of the
bdrewery [Tue, 1 Dec 2015 00:32:09 +0000 (00:32 +0000)]
META MODE: For bootstrap-tools, don't let Makefile.inc1 build any of the
toolchain.

This change prevents building of [clang-]tblgen, which is unneeded due
to already being a host dependency where needed for
targets/pseudo/toolchain.

Sponsored by: EMC / Isilon Storage Division

8 years agoMake the number of fasttrap probes and the size of the trace points hash table
stas [Tue, 1 Dec 2015 00:24:54 +0000 (00:24 +0000)]
Make the number of fasttrap probes and the size of the trace points hash table
tunable via sysctl or kernel tunables.

Illumos allows this parameters to be changed via the fasttrap.conf configuration
file, but FreeBSD code hardcoded the parameters.  Expose them under
the kern.dtrace.fasttrap sysctl tree.

MFC after: 2 weeks

8 years agoDelete the TUNABLE_INT() line. It was in r291527 so that it could be
rmacklem [Mon, 30 Nov 2015 23:37:09 +0000 (23:37 +0000)]
Delete the TUNABLE_INT() line. It was in r291527 so that it could be
MFC'd to stable/10 and still work.

8 years agoMETA MODE: Fix bootstrap-tools after r291349.
bdrewery [Mon, 30 Nov 2015 22:53:55 +0000 (22:53 +0000)]
META MODE: Fix bootstrap-tools after r291349.

Now that OBJTOP is assumed to be proper, it needs to be overridden for
the bootstrap-tools phase to ensure it is not kept as the top-level
OBJTOP.  Otherwise the libraries were not found during the
bootstrap-tools phase.

Sponsored by: EMC / Isilon Storage Division

8 years agoOnly DIRDEPS_BUILD should trigger this logic.
bdrewery [Mon, 30 Nov 2015 22:53:41 +0000 (22:53 +0000)]
Only DIRDEPS_BUILD should trigger this logic.

Missed in r290816.

Sponsored by: EMC / Isilon Storage Division

8 years agoDocument the __FreeBSD_version bump done for r291527 in UPDATING.
rmacklem [Mon, 30 Nov 2015 22:46:34 +0000 (22:46 +0000)]
Document the __FreeBSD_version bump done for r291527 in UPDATING.

8 years agoBump __FreeBSD_version since r291527 changes the interface between the
rmacklem [Mon, 30 Nov 2015 22:35:53 +0000 (22:35 +0000)]
Bump __FreeBSD_version since r291527 changes the interface between the
nfsd.ko and nfscommon.ko modules. As such, both modules need to be upgraded
to-gether.

8 years agoAdd support for the new "-manage-gids" option for the nfsuserd daemon
rmacklem [Mon, 30 Nov 2015 22:29:11 +0000 (22:29 +0000)]
Add support for the new "-manage-gids" option for the nfsuserd daemon
to the rc scripts. With these changes, setting nfs_server_managegids="YES"
in /etc/rc.conf will enable this capability.

Suggested by: jpaetzel
Tested by: jpaetzel
Reviewed by: rc (pending)
MFC after: 2 weeks

8 years agoDocument the new "-manage-gids" option for the nfsuserd daemon.
rmacklem [Mon, 30 Nov 2015 22:16:30 +0000 (22:16 +0000)]
Document the new "-manage-gids" option for the nfsuserd daemon.
This is a content change.

Suggested by: jpaetzel
Tested by: jpaetzel
MFC after: 2 weeks

8 years agoAdd support for the "-manage-gids" option to the nfsuserd daemon.
rmacklem [Mon, 30 Nov 2015 22:11:34 +0000 (22:11 +0000)]
Add support for the "-manage-gids" option to the nfsuserd daemon.
When this option is set, the NFS server uses the list of groups
acquired via getgrouplist(3) for the uid instead of the list of
groups in the RPC request. This can be used to avoid the 16 gid
limit for the group list in the RPC request.

Suggested by: jpaetzel
Tested by: jpaetzel
MFC after: 2 weeks

8 years agoUse SPI name for parallel SCSI.
mav [Mon, 30 Nov 2015 22:09:55 +0000 (22:09 +0000)]
Use SPI name for parallel SCSI.

8 years agoAdd kernel support to the NFS server for the "-manage-gids"
rmacklem [Mon, 30 Nov 2015 21:54:27 +0000 (21:54 +0000)]
Add kernel support to the NFS server for the "-manage-gids"
option that will be added to the nfsuserd daemon in a future
commit. It modifies the cache used by NFSv4 for name<-->id
translation (both username/uid and group/gid) to support this.
When "-manage-gids" is set, the server looks up each uid
for the RPC and uses the list of groups cached in the server
instead of the list of groups provided in the RPC request.
The cached group list is acquired for the cache by the nfsuserd
daemon via getgrouplist(3).
This avoids the 16 groups limit for the list in the RPC request.
Since the cache is now used for every RPC when "-manage-gids"
is enabled, the code also modifies the cache to use a separate
mutex for each hash list instead of a single global mutex.

Suggested by: jpaetzel
Tested by: jpaetzel
MFC after: 2 weeks

8 years agoFix a double-semicolon typo in my libkvm changes.
jhb [Mon, 30 Nov 2015 21:53:24 +0000 (21:53 +0000)]
Fix a double-semicolon typo in my libkvm changes.

Submitted by: jmallett

8 years agolibllvmmirparser and libllvmlibdriver are only used in usr.bin/clang/llc and
bdrewery [Mon, 30 Nov 2015 19:16:58 +0000 (19:16 +0000)]
libllvmmirparser and libllvmlibdriver are only used in usr.bin/clang/llc and
usr.bin/clang/llvm-ar, respectively, when MK_CLANG_EXTRAS is yes.

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

8 years agoAdd support for Intel Skylake and Intel Broadwell PMC's. The Broadwell PMC's have...
rrs [Mon, 30 Nov 2015 17:35:49 +0000 (17:35 +0000)]
Add support for Intel Skylake and Intel Broadwell PMC's. The Broadwell PMC's have been
tested on the Broadwell-Xeon with a hacked up version of pmcstudy -T. I still need
to circle back and add in to pmcstudy all the new tests from the Broadwell Vtune
guide (for the hacked up version I just made it so I could run the -T option). The
Skylake CPU is not yet available (even though Intel is advertising it .. imagine that).
The Skylake PMC's will need to be tested once we can get a sample skylake CPU :-)

Sponsored by: Netflix Inc.

8 years agowpi: ignore ic_update_promisc() call when device is not running
avos [Mon, 30 Nov 2015 17:16:51 +0000 (17:16 +0000)]
wpi: ignore ic_update_promisc() call when device is not running

This change will fix kernel panic with uninitialized (zeroed)
RXON structure.

Tested with Intel 3945BG, IBSS mode.

Approved by: adrian (mentor)
Differential Revision: https://reviews.freebsd.org/D4304

8 years agoARM: create new memory attribute for writethrough cacheable memory.
mmel [Mon, 30 Nov 2015 17:09:25 +0000 (17:09 +0000)]
ARM: create new memory attribute for writethrough cacheable memory.
- add new TEX class for WT cacheable memory
- export new TEX class to kernel as VM_MEMATTR_WT attribute
- add new aliases VM_MEMATTR_WRITE_COMBINING and
  VM_MEMATTR_WRITE_BACK, it's used in DRM code

Note:
 Only Cortex A8 supports WT caching in HW. On rest of Cortex CPUs,
 WT requests is treated as uncacheable.

Approved by: kib (mentor)

8 years agoFix the build after ifconfig was converted over to lib80211 in r291470
ngie [Mon, 30 Nov 2015 16:34:13 +0000 (16:34 +0000)]
Fix the build after ifconfig was converted over to lib80211 in r291470

Reported by: jenkins, O. Hartmann <ohartman@zedat.fu-berlin.de>
Pointyhat to: adrian

8 years agosfxge: avoid TSO packets collapses bacause of not 2K aligned data
arybchik [Mon, 30 Nov 2015 13:27:40 +0000 (13:27 +0000)]
sfxge: avoid TSO packets collapses bacause of not 2K aligned data

Sponsored by:   Solarflare Communications, Inc.
MFC after:      2 days
Differential Revision: https://reviews.freebsd.org/D4310

8 years agoShorten conditional branch code.
kib [Mon, 30 Nov 2015 10:18:15 +0000 (10:18 +0000)]
Shorten conditional branch code.

Reviewed by: andrew
Sponsored by: The FreeBSD Foundation

8 years agoRemove unneeded instructions.
kib [Mon, 30 Nov 2015 10:17:13 +0000 (10:17 +0000)]
Remove unneeded instructions.

Reviewed by: andrew
Sponsored by: The FreeBSD Foundation

8 years agoAdd more functions and types to the LinuxKPI.
hselasky [Mon, 30 Nov 2015 09:24:12 +0000 (09:24 +0000)]
Add more functions and types to the LinuxKPI.

MFC after: 1 week
Sponsored by: Mellanox Technologies

8 years agoadd missing lib80211 include.
adrian [Mon, 30 Nov 2015 09:02:28 +0000 (09:02 +0000)]
add missing lib80211 include.

8 years agoFix the build
ngie [Mon, 30 Nov 2015 08:02:52 +0000 (08:02 +0000)]
Fix the build

ichan is only used if AH_DEBUG_ALQ if defined

Pointyhat to: adrian

8 years agoAdd missing lib declaration.
adrian [Mon, 30 Nov 2015 06:56:25 +0000 (06:56 +0000)]
Add missing lib declaration.

8 years agoConvert ifconfig to use lib80211.
adrian [Mon, 30 Nov 2015 06:34:16 +0000 (06:34 +0000)]
Convert ifconfig to use lib80211.

* remove regdomain.[ch] - it's now part of lib80211.
* convert ifieee80211.c to use the ioctl routines in lib80211 and
  implement the "error? exit" wrapper behaviour the callers expect.

8 years agofix ht/40 configuration for ar9331 (hornet).
adrian [Mon, 30 Nov 2015 06:26:59 +0000 (06:26 +0000)]
fix ht/40 configuration for ar9331 (hornet).

The synth programming here requires the real centre frequency,
which for HT20 channels is the normal channel, but HT40 is
/not/ the primary channel.  Everything else was using 'freq',
which is the correct centre frequency, but the hornet config
was using 'ichan' to do the lookup which was also the primary
channel.

So, modify the HAL call that does the mapping to take a frequency
in MHz and return the channel number.

Tested:

* Carambola 2, AR9331, tested both HT/20 and HT/40 operation.