Commit Graph

216444 Commits

Author SHA1 Message Date
Sevan Janiyan
3efd3d9d44 Add history section for atmconfig(8)
PR:		212415
Approved by:	bcr (mentor)
MFC after:	5 days
Differential Revision:	https://reviews.freebsd.org/D8104
2016-10-05 19:49:48 +00:00
Sevan Janiyan
2bb154d973 Add history section for test(1)
http://minnie.tuhs.org/cgi-bin/utree.pl?file=V7/usr/src/cmd/test.c

PR:		211789
Approved by:	bcr (mentor)
MFC after:	5 days
Differential Revision:	https://reviews.freebsd.org/D8104
2016-10-05 19:47:02 +00:00
Sevan Janiyan
3578fc3e0c Add history section for stty(1)
http://minnie.tuhs.org/cgi-bin/utree.pl?file=V3/man/man1/stty.1

PR:		211788
Approved by:	bcr (mentor)
MFC after:	5 days
Differential Revision:	https://reviews.freebsd.org/D8104
2016-10-05 19:37:46 +00:00
Sevan Janiyan
25907b311b Add history section of pwd(1)
http://minnie.tuhs.org/cgi-bin/utree.pl?file=V5/usr/source/s2/pwd.c

PR:		211787
Approved by:	bcr (mentor)
MFC after:	5 days
Differential Revision:	https://reviews.freebsd.org/D8104
2016-10-05 19:31:29 +00:00
Sevan Janiyan
c5ca929f63 Document origins of expr & authors
http://minnie.tuhs.org/cgi-bin/utree.pl?file=PWB1/usr/man/man1/expr.1

PR:		173979
Approved by:	bcr (mentor)
MFC after:	5 days
Differential Revision:	https://reviews.freebsd.org/D8104
2016-10-05 19:26:35 +00:00
Sevan Janiyan
1e73a8c171 Add history section for echo(1)
Sourced using the draft copy of the second edition manual
http://www.tuhs.org/Archive/PDP-11/Distributions/research/1972_stuff/unix_2nd_edition_manual.pdf

PR:		211785
Approved by:	bcr (mentor)
MFC after:	5 days
Differential Revision:	https://reviews.freebsd.org/D8104
2016-10-05 19:16:55 +00:00
Luiz Otavio O Souza
ba14258f32 if_cpsw overhaul:
- Fix RX and TX teardown:
  . TX teardown would not reclaim the abandoned descriptors;
  . Interrupt storms in RX teardown;
  . Fixed the acknowledge of the teardown completion interrupt.

- Remove temporary lists for the descriptors;

- Simplified the descriptor handling (less writes and reads from
  descriptors where possible);

- Better debug;

- Add support for the RX threshold interrupts:
  With interrupt moderation only, an RX overrun is likely to happen.  The
  RX threshold is set to trigger a non paced interrupt everytime your RX
  free buffers are under the minimum threshold, helping to prevent the rx
  overrun.

The NIC now survive when pushed over its limits (where previously it would
lock up in a few seconds).

uFW (600MHz SoC) can now forward up to 560Mb/s of UDP traffic (netmap
pkt-gen as source and sink).  TCP forwarding rate is over 350Mb/s.

No difference (other than CPU use) was seen on Beaglebone black (1GHz SoC)
for his fast ethernet.

Tested on:	uFW, BBB
Sponsored by:	Rubicon Communications, LLC (Netgate)
2016-10-05 19:09:27 +00:00
Mariusz Zaborski
5ec81a23a8 Add man page for dnvlist.
Submitted by:	Adam Starak <starak.adam@gmail.com>
Reviewed by:	cem, wblock
2016-10-05 19:01:00 +00:00
Sevan Janiyan
2a19a3f546 Add history section for dd(1)
First version of UNIX to include dd found using TUHS
http://minnie.tuhs.org/cgi-bin/utree.pl?file=V5/usr/source/s1/dd.c

PR:		211777
Approved by:	bcr (mentor)
MFC after:	5 days
Differential Revision:	https://reviews.freebsd.org/D8104
2016-10-05 18:38:38 +00:00
Sevan Janiyan
58475c0d39 Document where chio(1) originated from & which version of FreeBSD first included it.
PR:		211776
Approved by:	bcr (mentor)
MFC after:	5 days
Differential Revision:	https://reviews.freebsd.org/D8104
2016-10-05 18:26:39 +00:00
Alan Cox
70cf3ced3c Make the page daemon's notion of what kind of pass is being performed
by vm_pageout_scan() local to vm_pageout_worker().  There is no reason
to store the pass in the NUMA domain structure.

Reviewed by:	kib
MFC after:	3 weeks
2016-10-05 17:32:06 +00:00
Mark Johnston
f30cad3355 CAM ccbq sanity: checks on insert and remove
KASSERT in cam_ccbq_insert_ccb that only XPT_FC_QUEUED ops are queued,
and XPT_FC_USER_CCB ops are not. Otherwise cam_ccbq_ccb_done may be
skipped.

Bounds check the index used for camq_remove in order to panic instead
of scribble on removal of an out-of-bounds index (e.g. consider the
effect of camq_remove of CAM_UNQUEUED_INDEX).

KASSERT in cam_ccbq_remove_ccb that the ccb removed by index was the
one sought.

Submitted by:	Ryan Libby <rlibby@gmail.com>
Reviewed by:	imp, mav
MFC after:	2 weeks
Sponsored by:	Dell EMC Isilon
Differential Revision:	https://reviews.freebsd.org/D8151
2016-10-05 17:18:24 +00:00
Ed Maste
a01a51a352 libm: remove unused variables
Sponsored by:	The FreeBSD Foundation
2016-10-05 17:04:58 +00:00
Ed Maste
7e81ad1292 abort in srandomdev if kern.arandom sysctl fails
The sysctl cannot fail. If it does fail on some FreeBSD derivative or
after some future change, just abort() so that the problem will be found
and fixed.

While abort() is not normally suitable for a library, it makes sense
here.

This is akin to r306636 for arc4random.

Reviewed by:	ed
MFC after:	2 weeks
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D8077
2016-10-05 17:03:22 +00:00
Mariusz Zaborski
e7798d20c5 Fix naming in Casper man page. 2016-10-05 16:23:02 +00:00
Alan Cox
e57dd910e6 Change vm_pageout_scan() to return a value indicating whether the free page
target was met.

Previously, vm_pageout_worker() itself checked the length of the free page
queues to determine whether vm_pageout_scan(pass >= 1)'s inactive queue scan
freed enough pages to meet the free page target.  Specifically,
vm_pageout_worker() used vm_paging_needed().  The trouble with
vm_paging_needed() is that it compares the length of the free page queues to
the wakeup threshold for the page daemon, which is much lower than the free
page target.  Consequently, vm_pageout_worker() could conclude that the
inactive queue scan succeeded in meeting its free page target when in fact
it did not; and rather than immediately triggering an all-out laundering
pass over the inactive queue, vm_pageout_worker() would go back to sleep
waiting for the free page count to fall below the page daemon wakeup
threshold again, at which point it will perform another limited (pass == 1)
scan over the inactive queue.

Changing vm_pageout_worker() to use vm_page_count_target() instead of
vm_paging_needed() won't work because any page allocations that happen
concurrently with the inactive queue scan will result in the free page count
being below the target at the end of a successful scan.  Instead, having
vm_pageout_scan() return a value indicating success or failure is the most
straightforward fix.

Reviewed by:	kib, markj
MFC after:	3 weeks
Sponsored by:	Dell EMC Isilon
Differential Revision:	https://reviews.freebsd.org/D8111
2016-10-05 16:15:26 +00:00
Andrew Turner
c5bf621b7a We don't use cpu_control on armv6, remove the macro there. 2016-10-05 14:00:05 +00:00
Michal Meloun
9567acca41 ARM: Remove next bunch of unused cpu_functions from ARMv6. 2016-10-05 12:19:09 +00:00
Michal Meloun
983dea151d ARM: Disconnect elf_trampoline.c from ARMv6 build.
The trampoline code never functioned properly for Cortex CPUs,
and its functionality is already provided by ubldr.
2016-10-05 12:17:43 +00:00
Justin Hibbits
e5a8e24549 Fix e500mc/derivatives cpu idle
Setting the doze registers wasn't actually working, and was being masked by a
bad #ifdef.  Since the #ifdef was fixed, now e500mc-based SoCs hang at idle.
Fix this by using the intended wait.

MFC after:	1 week
2016-10-05 04:40:48 +00:00
Alexander Motin
769cbdb7a3 Do not retry on some security sense codes.
MFC after:	1 week
2016-10-05 00:45:58 +00:00
Kurt Lidl
d3de26c3d0 Make 502.pfdenied find blacklistd/* filter names dynamically
This change is needed to make the 520.pfdenied script find the new
blacklistd/* anchor points for reporting blocked traffic.

Reviewed by:	kp
MFC after:	1 week
Sponsored by:	The FreeBSD Foundation
2016-10-04 23:12:35 +00:00
Kurt Lidl
30f7128157 Make blacklist-helper commands emit a message when successful
The blacklistd daemon expects to see a message on stdout, instead
of just relying on the exit value from any invoked programs.

Change the pf filtering to create multiple filters, attached under
a the "blacklist/*" anchor point.  This prevents the filtering for
each port's filtering rule from overwriting the previously installed
filtering rule.  Check for an existing filtering rule for each port,
so the installation of a given filtering rule only happens once.
Reinstalling the same rule resets the counters for the pf rule, and
we don't want that.

Reported by:	David Horn (dhorn2000 at gmail.com)
Reviewed by:	emaste
MFC after:	1 week
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D8081
2016-10-04 23:10:43 +00:00
Jung-uk Kim
c5b5d71ad3 MFV: r306687
Merge byacc 20160606.
2016-10-04 22:22:32 +00:00
Bryan Drewery
0617f64ec6 Correct some comments after r294299.
Sponsored by:	Dell EMC Isilon
2016-10-04 21:44:20 +00:00
Jung-uk Kim
710e7be2e2 Import byacc 20160606. 2016-10-04 20:54:49 +00:00
Jung-uk Kim
493deb390b Merge ACPICA 20160930. 2016-10-04 20:27:15 +00:00
Kristof Provost
813196a11a pf: remove fastroute tag
The tag fastroute came from ipf and was removed in OpenBSD in 2011. The code
allows to skip the in pfil hooks and completely removes the out pfil invoke,
albeit looking up a route that the IP stack will likely find on its own.
The code between IPv4 and IPv6 is also inconsistent and marked as "XXX"
for years.

Submitted by:	Franco Fichtner <franco@opnsense.org>
Differential Revision:	https://reviews.freebsd.org/D8058
2016-10-04 19:35:14 +00:00
Ed Maste
65eea7ede6 ANSIfy inflate.c
Reviewed by:	kib
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D8143
2016-10-04 17:57:30 +00:00
Konstantin Belousov
83c001d3c2 Re-apply r306516 (by cem):
Reduce the cost of TLB invalidation on x86 by using per-CPU completion flags

Reduce contention during TLB invalidation operations by using a per-CPU
completion flag, rather than a single atomically-updated variable.

On a Westmere system (2 sockets x 4 cores x 1 threads), dtrace measurements
show that smp_tlb_shootdown is about 50% faster with this patch; observations
with VTune show that the percentage of time spent in invlrng_single_page on an
interrupt (actually doing invalidation, rather than synchronization) increases
from 31% with the old mechanism to 71% with the new one.  (Running a basic file
server workload.)

Submitted by:	Anton Rang <rang at acm.org>
Reviewed by:	cem (earlier version)
Sponsored by:	Dell EMC Isilon
Differential Revision:	https://reviews.freebsd.org/D8041
2016-10-04 17:01:24 +00:00
Gleb Smirnoff
37d0ac15e6 Fix indentation.
CID:	1363671
2016-10-04 16:44:40 +00:00
Adrian Chadd
85ab1aeccf [geom_redboot] Extend geom_redboot to handle non-zero fis offset.
Submitted by:	Mori Hiroki <yamori813@yahoo.co.jp>
Differential Revision:	https://reviews.freebsd.org/D7237
2016-10-04 16:35:38 +00:00
Allan Jude
452bd5bf51 GELIBoot may attempt to read past the end of the disk
Usually there is some slack after the last partition due to 4k alignment
In the 10.3 EC2 images, there was not. EC2 seems to hang if you try to
read past the end of the disk in the loader, resulting in an unbootable
instance after upgrading to 11.0

PR:		213196
Reported by:	Peter Ankerstal <peter@pean.org>
Tested by:	cperciva
Reviewed by:	tsoome
MFC after:	3 days
Sponsored by:	ScaleEngine Inc.
Differential Revision:	https://reviews.freebsd.org/D8144
2016-10-04 16:33:03 +00:00
Adrian Chadd
f7948591dc Add AR531x port options.
Submitted by: Mori Hiroki <yamori813@yahoo.co.jp>
Differential Revision:	https://reviews.freebsd.org/D7237
2016-10-04 16:29:26 +00:00
Adrian Chadd
7c12b677f5 [ar531x] add initial port for the AR231x/531x series of SoCs.
These are older MIPS4kc parts from Atheros.  They typically ran at
sub-200MHz and have 11bg, 11a, or 11abg wifi MAC/PHYs integrated.

This port is the initial non-wifi pieces required to bring up the
chip.  I'll commit the redboot and other pieces later, and then
hopefully(!) wifi support will follow.

Submitted by:   Mori Hiroki <yamori813@yahoo.co.jp>
Differential Revision:  https://reviews.freebsd.org/D7237
2016-10-04 16:27:36 +00:00
Konstantin Belousov
5420f76b59 Style.
Reviewed by:	emaste
Sponsored by:	The FreeBSD Foundation
MFC after:	3 days
2016-10-04 15:23:03 +00:00
Mariusz Zaborski
059cc32342 libcapsicum: limit stderr
Don't limit stdout twice, instead limit stderr.

Pointed out by:	rpokala@
2016-10-04 13:33:43 +00:00
Andrew Turner
1834282de6 Split CPU_CORTEXA into CPU_CORTEXA8, for the Cortex-A8, and CPU_CORTEXA_MP,
for later Cortex-A CPUs that support the Multiprocessor Extensions. This
will be needed to support both in a single GENERIC kernel while still
being able to only build for a single SoC.

Reviewed by:	mmel
Relnotes:	yes
Sponsored by:	ABT Systems Ltd
Differential Revision:	https://reviews.freebsd.org/D8138
2016-10-04 12:25:44 +00:00
Andrew Turner
d029cb6152 Read the Multiprocessing Extensions bit from the Multiprocessor Affinity
register.

Sponsored by:	ABT Systems Ltd
X-Differential Revision:	https://reviews.freebsd.org/D8092
2016-10-04 12:01:08 +00:00
Martin Matuska
f3e9b21a7a MFV r306669:
Sync libarchive with vendor including security fixes.

Important vendor bugfixes (relevant to FreeBSD):
#747: Out of bounds read in mtree parser
#761: heap-based buffer overflow in read_Header (7-zip)
#784: Invalid file on bsdtar command line results in internal errors (1)

PR:		213092 (1)
MFC after:	1 week
2016-10-04 11:56:46 +00:00
Martin Matuska
adb01b286d Update vendor/libarchive to git 024be27d1b299c030e8841bed3002ee07ba9eedc
Important vendor bugfixes (relevant to FreeBSD):
#747: Out of bounds read in mtree parser
#761: heap-based buffer overflow in read_Header (7-zip)
#784: Invalid file on bsdtar command line results in internal errors (1)

PR:		213092 (1)
Obtained from:	https://github.com/libarchive/libarchive
2016-10-04 11:44:21 +00:00
Michal Meloun
fe8151a0e3 ARM: Add mising early clobber modifier in atomic_swap_32().
MFC after: 2 weeks
2016-10-04 09:59:37 +00:00
Michal Meloun
6542d1a4e7 ARM: Add atomic_swap_64(). It's need by linuxkpi and drm-next-4.7.
MFC after: 2 weeks
2016-10-04 09:51:54 +00:00
Michal Meloun
c7533311be TEGRA: Fix PCIe link timeout.
MFC after: 2 weeks
2016-10-04 09:14:48 +00:00
Andriy Gapon
9ba3abc30e zfs: fix a wrong assertion for extended attributes
For the extended attributes the order between z_teardown_lock and the
vnode lock is different.
The bug was triggered only with DIAGNOSTIC turned on.
This fix is developed in cooperation with avos.

PR:		213112
Reported by:	avos
Tested by:	avos
MFC after:	1 week
2016-10-04 08:09:25 +00:00
Jared McNeill
1ef15cafa0 Clear GT_CTRL_ENABLE to stop the timer.
Reviewed by:	andrew
2016-10-03 21:42:05 +00:00
Mariusz Zaborski
7a6e3cf83e libcapsicum: introduce Capsicum helpers
Capsicum helpers are a set of inline functions which goal is to reduce
duplicated patterns used to Capsicumize applications.

Reviewed by:	cem, AllanJude, bapt, ed, emaste
Differential Revision:	https://reviews.freebsd.org/D8013
2016-10-03 20:48:18 +00:00
Andrew Turner
c6b8d2a2a3 Use the cortex functions when booting on one of the Cortex-A ARMv8 CPUs.
This list is incomplete, however we don't have the ID values for the
missing Cortex-A32 or A35.

Submitted by:	loos (Cortex-A53)
Sponsored by:	ABT Systems Ltd
2016-10-03 20:05:33 +00:00
Luiz Otavio O Souza
430d5eb47d Enable the TX completion interrupt for the cpsw NIC to assure the free tx
descriptors are reclaimed as soon as possible.

Without this the free buffers are reclaimed only on watchdog runs or after
trying to enqueue more packets.

Sponsored by:	Rubicon Communications, LLC (Netgte)
2016-10-03 19:48:56 +00:00
Oleksandr Tymoshenko
82e4e00f18 Add Tegra TK1 DTBs to GENERIC kernel
Approved by:	andrew
2016-10-03 19:34:32 +00:00