]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
6 years agoOnly fillin data srucuture when actually stored.
Michael Tuexen [Mon, 21 May 2018 14:53:22 +0000 (14:53 +0000)]
Only fillin data srucuture when actually stored.

6 years agoDo the appropriate accounting when ip_output() fails.
Michael Tuexen [Mon, 21 May 2018 14:52:18 +0000 (14:52 +0000)]
Do the appropriate accounting when ip_output() fails.

6 years agoMake clear why there is an assignment, which is not necessary.
Michael Tuexen [Mon, 21 May 2018 14:51:20 +0000 (14:51 +0000)]
Make clear why there is an assignment, which is not necessary.

6 years agoPair CURVNET_SET and CURVNET_RESTORE in a block
Ed Maste [Mon, 21 May 2018 13:08:44 +0000 (13:08 +0000)]
Pair CURVNET_SET and CURVNET_RESTORE in a block

Per vnet(9), CURVNET_SET and CURVNET_RESTORE cannot be used as a single
statement for a conditional and CURVNET_RESTORE must be in the same
block as CURVNET_SET (or a subblock).

Reviewed by: andrew
Sponsored by: The FreeBSD Foundation

6 years agorelease: arm64: Use loader.efi as bootaa64.efi for RPI3 and PINE64
Emmanuel Vadot [Mon, 21 May 2018 11:58:02 +0000 (11:58 +0000)]
release: arm64: Use loader.efi as bootaa64.efi for RPI3 and PINE64

boot1.efi have some trouble to read MBR partitions, it needs them to be
aligned a certain way while loader.efi can cope with them either way.
We want to switch to loader.efi as the main efi loader everywhere, it seems
that arm64 using MBR partition will be the guinea pig.

Tested On: RPI3, Pine64
Reviewed by: imp
Approved by: gjb

6 years agoRevert r333968, it broke all archs but i386 and amd64
Ed Maste [Mon, 21 May 2018 11:56:07 +0000 (11:56 +0000)]
Revert r333968, it broke all archs but i386 and amd64

6 years agotop(1): fix build
Eitan Adler [Mon, 21 May 2018 09:43:50 +0000 (09:43 +0000)]
top(1): fix build

Remove 'top.local.hs'. This was not noticed since
/srv/obj/fbsd/srv/src/freebsd/svn/head/amd64.amd64/usr.bin/top/top.local.h
existed locally on my machine despite "make clean". Only fully removing
the objdir allowed me to observe the error directly.

Pointyhat to: me

6 years agotop(1): clean up some "const" related warnings
Eitan Adler [Mon, 21 May 2018 09:32:52 +0000 (09:32 +0000)]
top(1): clean up some "const" related warnings

This leaves at WARNS=6:
35 warnings in top.c
88 warnings in machine.c

all of which are either "incompatible-pointer-types-discards-qualifiers"
or "cast-qual"

6 years agotop(1): modernize a bit; reduce warnings
Eitan Adler [Mon, 21 May 2018 09:25:21 +0000 (09:25 +0000)]
top(1): modernize a bit; reduce warnings

- Replace caddr_t with "void *". This reduces
the number of warnings at WARNS=6
- use "static" where possible
- sprinkle const where possible

This leaves at WARNS=6:
35 warnings in top.c
88 warnings in machine.c
7 warnings in commands.c

all of which are either "incompatible-pointer-types-discards-qualifiers"
or "cast-qual"

6 years agoAdd missing va_end
Eitan Adler [Mon, 21 May 2018 09:21:42 +0000 (09:21 +0000)]
Add missing va_end

Reported by: andrew

6 years agoRevert r333969 which contained one too many changes
Eitan Adler [Mon, 21 May 2018 09:20:26 +0000 (09:20 +0000)]
Revert r333969 which contained one too many changes

6 years agotop(1): modernize a bit; reduce warnings
Eitan Adler [Mon, 21 May 2018 09:18:01 +0000 (09:18 +0000)]
top(1): modernize a bit; reduce warnings

- Replace caddr_t with "void *". This reduces
the number of warnings at WARNS=6
- use "static" where possible
- sprinkle const where possible

This leaves at WARNS=6:
35 warnings in top.c
72 warnings in machine.c
5 warnings in commands.c

all of which are either "incompatible-pointer-types-discards-qualifiers"
or "cast-qual"

6 years agoin(6)_mcast: Expand out vnet set / restore macro so that they work in a conditional...
Matt Macy [Mon, 21 May 2018 08:34:10 +0000 (08:34 +0000)]
in(6)_mcast: Expand out vnet set / restore macro so that they work in a conditional block

Reported by: zec at fer.hr

6 years agoensure that vnet is set when doing in_leavegroup
Matt Macy [Mon, 21 May 2018 07:12:06 +0000 (07:12 +0000)]
ensure that vnet is set when doing in_leavegroup

6 years agoamd64: annotate pti with __read_frequently
Mateusz Guzik [Mon, 21 May 2018 05:20:23 +0000 (05:20 +0000)]
amd64: annotate pti with __read_frequently

6 years agotop(1): add myself as a MAINTAIENR
Eitan Adler [Mon, 21 May 2018 05:00:19 +0000 (05:00 +0000)]
top(1): add myself as a MAINTAIENR

also fix some nits

6 years agotop(1): remove prime.c
Eitan Adler [Mon, 21 May 2018 04:51:43 +0000 (04:51 +0000)]
top(1): remove prime.c

This file was not connected to the build, and is better served by
primes(6) anyways.

6 years agotop(1): fix MIPS
Eitan Adler [Mon, 21 May 2018 04:47:13 +0000 (04:47 +0000)]
top(1): fix MIPS

I missed where the parentheses were.

Reported by: imp

6 years agotop(1): further unconditionally assume we're on FreeBSD
Eitan Adler [Mon, 21 May 2018 04:40:20 +0000 (04:40 +0000)]
top(1): further unconditionally assume we're on FreeBSD

6 years agotop(1): clean up in prep for const poisoning
Eitan Adler [Mon, 21 May 2018 04:32:14 +0000 (04:32 +0000)]
top(1): clean up in prep for const poisoning

- sprinkle "const" in a few obvious places
- remove "(void)" in front of lack-of-error-checked functions

6 years agotop(1): further unconditionally assume we're on FreeBSD
Eitan Adler [Mon, 21 May 2018 04:02:45 +0000 (04:02 +0000)]
top(1): further unconditionally assume we're on FreeBSD

6 years agotop(1): build with WARNS=3
Eitan Adler [Mon, 21 May 2018 03:58:15 +0000 (03:58 +0000)]
top(1): build with WARNS=3

This fixes everything but
-Wincompatible-pointer-types-discards-qualifiers

6 years agotop(1): fix several more warnings
Eitan Adler [Mon, 21 May 2018 03:36:16 +0000 (03:36 +0000)]
top(1): fix several more warnings

6 years agock: simplify interface with libkvm consumers by defining ck_queue types
Matt Macy [Mon, 21 May 2018 01:53:23 +0000 (01:53 +0000)]
ck: simplify interface with libkvm consumers by defining ck_queue types
as their queue.h equivalents if !_KERNEL

6 years agotop(1): fix build on arches where size_t != ull
Eitan Adler [Mon, 21 May 2018 01:39:26 +0000 (01:39 +0000)]
top(1): fix build on arches where size_t != ull

6 years ago- Unbreak booting sparc64 kernels after the metadata unification in
Marius Strobl [Mon, 21 May 2018 01:20:19 +0000 (01:20 +0000)]
- Unbreak booting sparc64 kernels after the metadata unification in
  r329190; sparc64 kernels are always 64-bit but with that revision
  in place, the loader was treating them as 32-bit ones.
- In order to reduce the likelihood of this kind of breakage in the
  future, #ifdef out md_load() on sparc64 and make md_load_dual() -
  which is currently local to metadata.c anyway - static.
- Make md_getboothowto() - also local to metadata.c - static.
- Get rid of the unused DTB pointer on sparc64.

6 years agotop(1): pull function declarations and externs into headers
Eitan Adler [Mon, 21 May 2018 01:16:26 +0000 (01:16 +0000)]
top(1): pull function declarations and externs into headers

6 years agotop(1): fix "variable without declaration" warning
Eitan Adler [Mon, 21 May 2018 01:05:32 +0000 (01:05 +0000)]
top(1): fix "variable without declaration" warning

This is only shown at WARNS=6, but since we don't yet build at WARNS=2
its hidden.

6 years agotop(1): clean much of WARNS=3 issues
Eitan Adler [Mon, 21 May 2018 00:53:42 +0000 (00:53 +0000)]
top(1): clean much of WARNS=3 issues

There is still one glaring issue: new_message is not a protoype, but
can't be trivially converted since it uses K&R style var-args.

6 years agotop(1): build with WARN=2
Eitan Adler [Mon, 21 May 2018 00:32:48 +0000 (00:32 +0000)]
top(1): build with WARN=2

6 years agotop(1): add getrusage to SEE also
Eitan Adler [Mon, 21 May 2018 00:20:32 +0000 (00:20 +0000)]
top(1): add getrusage to SEE also

This documents the various columns that top might support.

PR: 199637
Submitted by: vermaden@interia.pl

6 years agotop(1): Remove now-unused variable
Eitan Adler [Sun, 20 May 2018 23:39:08 +0000 (23:39 +0000)]
top(1): Remove now-unused variable

6 years agotop(1): pull configuration directly into header files
Eitan Adler [Sun, 20 May 2018 23:37:30 +0000 (23:37 +0000)]
top(1): pull configuration directly into header files

This sets configuration variables directly in the various header files,
avoiding the need to have special logic in our Makefile to build the
header.

6 years agotop(1): set max username length based on system constant
Eitan Adler [Sun, 20 May 2018 23:19:09 +0000 (23:19 +0000)]
top(1): set max username length based on system constant

This changes previous behavior of calculating it at startup based on
the current max username length.

This is done because:
- it is in theory possible for the max length to change at run-time
  (e.g., a new user is added after top starts running)
- on machines with many users this delays startup significantly

PR: 20799
PR: 89762
Reported by: ob@e-Gitt.NET
Reported by: wkwu@Kavalan.csie.NCTU.edu.tw
Reported on: 2000-08-23 and 2005-11-30

6 years agoRevert last change to file/magic/Magdir/elf, it misidentifies most shared
Antoine Brodin [Sun, 20 May 2018 22:07:44 +0000 (22:07 +0000)]
Revert last change to file/magic/Magdir/elf, it misidentifies most shared
libraries installed from ports as pie executables instead of shared libraries,
and consequently breaks ports.

6 years agoUse St macro for specifying C standards.
Sevan Janiyan [Sun, 20 May 2018 21:56:08 +0000 (21:56 +0000)]
Use St macro for specifying C standards.

Reported by: rgrimes@

6 years agoAF_UNIX gc unused label
Matt Macy [Sun, 20 May 2018 21:37:34 +0000 (21:37 +0000)]
AF_UNIX gc unused label

...sigh

6 years agoAF_UNIX: Don't unlock unp/unp2 if they're not locked
Matt Macy [Sun, 20 May 2018 21:20:26 +0000 (21:20 +0000)]
AF_UNIX: Don't unlock unp/unp2 if they're not locked

Reported by: mjg

6 years agomake sure vnet is set when freeing
Matt Macy [Sun, 20 May 2018 20:48:26 +0000 (20:48 +0000)]
make sure vnet is set when freeing

Reported by: pho

6 years agopmc: detach free_gtask on unload
Matt Macy [Sun, 20 May 2018 20:34:15 +0000 (20:34 +0000)]
pmc: detach free_gtask on unload

Reported by: pho

6 years agoFix a typo and remove an unneeded Tn macro as highlighted by mandoc -Tlint.
Sevan Janiyan [Sun, 20 May 2018 20:28:17 +0000 (20:28 +0000)]
Fix a typo and remove an unneeded Tn macro as highlighted by mandoc -Tlint.

Submitted by: Mateusz Piotrowski
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D15204

6 years agoin(s)_moptions: free before tearing down inpcb
Matt Macy [Sun, 20 May 2018 20:08:21 +0000 (20:08 +0000)]
in(s)_moptions: free before tearing down inpcb

6 years agopmc: avoid potential race on shutdown
Matt Macy [Sun, 20 May 2018 19:35:24 +0000 (19:35 +0000)]
pmc: avoid potential race on shutdown

Clear shutdown flag first, conservatively allow 5ms for all hardclock consumers to
see flag before drainining

6 years agoFix build with PSERIES but not POWERNV defined.
Nathan Whitehorn [Sun, 20 May 2018 18:26:09 +0000 (18:26 +0000)]
Fix build with PSERIES but not POWERNV defined.

6 years agobsd-family-tree: announce DragonFly 5.2.1
Eitan Adler [Sun, 20 May 2018 18:18:56 +0000 (18:18 +0000)]
bsd-family-tree: announce DragonFly 5.2.1

See
http://lists.dragonflybsd.org/pipermail/commits/2018-May/672214.html

6 years agotop(1): unconditionally assume we are on FreeBSD (more unifdef)
Eitan Adler [Sun, 20 May 2018 18:11:58 +0000 (18:11 +0000)]
top(1): unconditionally assume we are on FreeBSD (more unifdef)

Now that we're our own upstream, remove useless ifdefs.

6 years agoRetry revert
Eitan Adler [Sun, 20 May 2018 18:03:40 +0000 (18:03 +0000)]
Retry revert

I had a local modification before my revert. Try reverting one more time.

6 years agorevert r333928
Eitan Adler [Sun, 20 May 2018 18:02:40 +0000 (18:02 +0000)]
revert r333928

I had missed a file when testing this, and it does not build. Will try again.

6 years agotop(1): Make lack of "percent" information explicit
Eitan Adler [Sun, 20 May 2018 17:59:59 +0000 (17:59 +0000)]
top(1): Make lack of "percent" information explicit

When count is 1, no delta information can be produced. Make this
explicit.

PR: 195717
Submitted by: fernape

6 years agotop(1): remove 'xs' and 'xh' source files
Eitan Adler [Sun, 20 May 2018 17:58:22 +0000 (17:58 +0000)]
top(1): remove 'xs' and 'xh' source files

Now that we're our own upstream these files buy us nothing.

6 years agosh: Allow unquoted newlines in word in ${param+word} etc.
Jilles Tjoelker [Sun, 20 May 2018 17:25:52 +0000 (17:25 +0000)]
sh: Allow unquoted newlines in word in ${param+word} etc.

POSIX requires accepting unquoted newlines in word in parameter expansions
like ${param+word}, ${param#word}, although the Bourne shell did not support
it, it is not commonly used and might make it harder to find a missing
closing brace.

It was also strange that something like

foo="${bar#
}"

was rejected.

Reported by: Martijn Dekker via Robert Elz

6 years agoteken, vt(4): Parse the "Cursor style" escape sequence
Jean-Sébastien Pédron [Sun, 20 May 2018 14:21:20 +0000 (14:21 +0000)]
teken, vt(4): Parse the "Cursor style" escape sequence

The escape sequence (e.g. `^[[2 q`) was unsupported before and the
letter `q` was displayed as a typed character. The sequence is used by
Neovim for instance.

Now, it is properly parsed. However, it is ignored, so it won't change
the cursor style.

Because the escape sequence contains a space character, the
`gensequences` script had to be modified to support that. In the
`sequences` file, a space is represented as the string `SP`.

6 years agonfsclient: warnings cleanups
Matt Macy [Sun, 20 May 2018 06:14:12 +0000 (06:14 +0000)]
nfsclient: warnings cleanups

6 years agoStyle fixup:
Cy Schubert [Sun, 20 May 2018 05:59:42 +0000 (05:59 +0000)]
Style fixup:

A non-functional commit to make adjustment to an aesthetically
unpleasing long line.

6 years agoFix build post r333919.
Cy Schubert [Sun, 20 May 2018 05:59:35 +0000 (05:59 +0000)]
Fix build post r333919.

This commit results in an aesthetically unpleasing long line
which will be fixed next commit.

6 years agoAF_UNIX: fix LOR introduced by the locking rewrite
Matt Macy [Sun, 20 May 2018 05:50:53 +0000 (05:50 +0000)]
AF_UNIX: fix LOR introduced by the locking rewrite

6 years agoAdd additional preinitialized cap_rights
Matt Macy [Sun, 20 May 2018 05:13:12 +0000 (05:13 +0000)]
Add additional preinitialized cap_rights

6 years agoMFV: file 5.33
Eitan Adler [Sun, 20 May 2018 05:06:42 +0000 (05:06 +0000)]
MFV: file 5.33

Merge the latest file(1) in.

Relevent Changelog:
- extend the support for ${x?:} expansions for magic descriptions
- add support for ${x?:} in mime types to handle pie binaries.
- add support for negative offsets (offsets from the end of file)
- close the file on error when writing magic

Relnotes: yes

6 years agoVendor import of file 5.33
Eitan Adler [Sun, 20 May 2018 04:56:46 +0000 (04:56 +0000)]
Vendor import of file 5.33

6 years agovfs: simplify vop_stdlock/unlock
Mateusz Guzik [Sun, 20 May 2018 04:45:05 +0000 (04:45 +0000)]
vfs: simplify vop_stdlock/unlock

The interlock pointer is non-NULL by definition and the compiler see through
that and eliminates the NULL checks. Just remove them from the code as they
play no role.

No difference in generated assembly.

6 years agoinpcb: defer destruction of inpcb until after a grace period has elapsed
Matt Macy [Sun, 20 May 2018 04:38:04 +0000 (04:38 +0000)]
inpcb: defer destruction of inpcb until after a grace period has elapsed

in_pcbfree will remove the incpb from the list and release the rtentry
while the vnet is set, but the actual destruction will be deferred
until any threads in a (not yet used) epoch section, no longer potentially
have references.

6 years agoAF_UNIX: make unpcb lock name line up with what's in witness
Matt Macy [Sun, 20 May 2018 04:32:48 +0000 (04:32 +0000)]
AF_UNIX: make unpcb lock name line up with what's in witness

6 years agoepoch.h: hide proc.h->priority.h from user
Matt Macy [Sun, 20 May 2018 04:15:12 +0000 (04:15 +0000)]
epoch.h: hide proc.h->priority.h from user

6 years agoAdd support for the XIVE XICS emulation mode for POWER9 systems
Justin Hibbits [Sun, 20 May 2018 03:23:17 +0000 (03:23 +0000)]
Add support for the XIVE XICS emulation mode for POWER9 systems

Summary:
POWER9 systems use a new interrupt controller, XIVE, managed through OPAL
firmware calls.  The OPAL firmware includes support for emulating the previous
generation XICS presentation layer in addition to a new "XIVE Exploitation"
mode.  As a stopgap until we have XIVE exploitation mode, enable XICS emulation
mode so that we at least have an interrupt controller.

Since the CPPR is local to the current CPU, it cannot be updated for APs when
initializing on the BSP.  This adds a new function, directly called by the
powernv platform code, to initialize the CPPR on AP bringup.

Reviewed by: nwhitehorn
Differential Revision: https://reviews.freebsd.org/D15492

6 years agoinpcb: consolidate possible deletion in pcblist functions in to epoch
Matt Macy [Sun, 20 May 2018 02:27:58 +0000 (02:27 +0000)]
inpcb: consolidate possible deletion in pcblist functions in to epoch
deferred context.

6 years agoin_pcb: add helper for deferring inpcb rele calls from list functions
Matt Macy [Sun, 20 May 2018 02:17:30 +0000 (02:17 +0000)]
in_pcb: add helper for deferring inpcb rele calls from list functions

6 years agotop(1): Quiesce several warnings
Eitan Adler [Sun, 20 May 2018 02:14:27 +0000 (02:14 +0000)]
top(1): Quiesce several warnings

This is all warnings at level six (6) that are not
char-subscripts, incompatible-pointer-types,
sign-compare, switch, int-conversion,
missing-variable-declarations, cast-qual, cast-align

Some warnings that are fixed by this commit are:
shadow, strict-prototypes, missing-prototypes, pointer-arith,
unused-parameter, unused-const-variable, and several others

6 years agotop(1): remove use of 'register' keyword
Eitan Adler [Sun, 20 May 2018 01:32:27 +0000 (01:32 +0000)]
top(1): remove use of 'register' keyword

This keyword is meaningless is obscures future diffs that help clear up
warnings in top.

6 years agotop(1): be constant in a structure
Eitan Adler [Sun, 20 May 2018 01:30:19 +0000 (01:30 +0000)]
top(1): be constant in a structure

This silences some warnings that are still hidden since the remainder of
top(1) does not build with higher WARNS yet.

6 years agoepoch.h: move kernel only bits under _KERNEL
Matt Macy [Sun, 20 May 2018 01:00:56 +0000 (01:00 +0000)]
epoch.h: move kernel only bits under _KERNEL

6 years agoip(6)_freemoptions: defer imo destruction to epoch callback task
Matt Macy [Sun, 20 May 2018 00:22:28 +0000 (00:22 +0000)]
ip(6)_freemoptions: defer imo destruction to epoch callback task

Avoid the ugly unlock / lock of the inpcbinfo where we need to
figure out what kind of lock we hold by simply deferring the
operation to another context. (Also a small dependency for
converting the pcbinfo read lock to epoch)

6 years agoUse the canonical check for reservation support.
Mark Johnston [Sat, 19 May 2018 23:49:13 +0000 (23:49 +0000)]
Use the canonical check for reservation support.

6 years agotop(1): unconditionally assume we are running on FreeBSD
Eitan Adler [Sat, 19 May 2018 23:19:24 +0000 (23:19 +0000)]
top(1): unconditionally assume we are running on FreeBSD

This allows us to remove a special header and more specifically just the
system headers we want.

6 years agotop(1): unconditionally provide 'FreeBSD' as a version
Eitan Adler [Sat, 19 May 2018 23:04:42 +0000 (23:04 +0000)]
top(1): unconditionally provide 'FreeBSD' as a version

6 years agotop(1): assume that we're building on FreeBSD
Eitan Adler [Sat, 19 May 2018 22:59:58 +0000 (22:59 +0000)]
top(1): assume that we're building on FreeBSD

This allows us to avoid the ifdefs that we set unconditionally.

6 years agotop(1): bump WARNS to 1
Eitan Adler [Sat, 19 May 2018 22:45:43 +0000 (22:45 +0000)]
top(1): bump WARNS to 1

Nothing else builds without errors yet, but 1 is better than 0

6 years agotop(1): Migrate top to usr.bin
Eitan Adler [Sat, 19 May 2018 22:40:23 +0000 (22:40 +0000)]
top(1): Migrate top to usr.bin

We've been maintaining top(1) for a long time, and the upstream
hasn't existed/been used in similarly as long. Make it clear that we own
top(1)

Tested with 'make universe'. Everything passed except MIPS which failed
for unrelated reasons. Install also tested for amd64.

Reviewed by: sbruno
No objections: imp, mmacy
Differential Revision: https://reviews.freebsd.org/D15387

6 years agoAvoid writing to the frame buffer in early boot on PowerPC if the CPU's
Nathan Whitehorn [Sat, 19 May 2018 22:04:54 +0000 (22:04 +0000)]
Avoid writing to the frame buffer in early boot on PowerPC if the CPU's
MMU is disabled.

This expands some earlier logic and avoids a number of potential problems:
1. The CPU may not be able to access the framebuffer in real mode (real
   mode does not necessarily encompass all available memory, especially
   under a hypervisor).
2. Real mode accesses generally assume cacheability, so it might not
   even have worked.
3. The difference in cacheability between real mode and later (and
   potentially earlier) points in the boot with the MMU on may cause
   ERAT parity problems, resulting in a machine check.

This fixes real-mode (usefdt=1) early boot on the G5 iMac, which was
previously broken as a result of issue #3. Late boot will require some
other fixups.

6 years agoStyle.
Konstantin Belousov [Sat, 19 May 2018 21:36:55 +0000 (21:36 +0000)]
Style.

Sponsored by: The FreeBSD Foundation
MFC after: 3 days

6 years agoConform to Berne Convention.
Cy Schubert [Sat, 19 May 2018 21:26:07 +0000 (21:26 +0000)]
Conform to Berne Convention.

Prompted by: Recent discussion
MFC after: 3 days

6 years agomtest: build with WARNS=3
Eitan Adler [Sat, 19 May 2018 20:57:22 +0000 (20:57 +0000)]
mtest: build with WARNS=3

6 years agomy copyright: some minor adjustments
Eitan Adler [Sat, 19 May 2018 20:35:15 +0000 (20:35 +0000)]
my copyright: some minor adjustments

- remove "all rights reserved" from my copyright on my extensive
  contributions
- belatedly add my name to tuning.7 which I was a large contributor to
  several years ago

This commit can also serve as implicit permission for any formatting or
non-substantive changes that FreeBSD wishes to make in the future.

6 years agoFix PCID+PTI pmap operations on Xen/HVM.
Konstantin Belousov [Sat, 19 May 2018 20:28:59 +0000 (20:28 +0000)]
Fix PCID+PTI pmap operations on Xen/HVM.

Install appropriate pti-aware shootdown IPI handlers, otherwise user
page tables do not get enough invalidations.  The non-pti handlers
were used so far.

Reported and tested by: cperciva
Sponsored by: The FreeBSD Foundation
MFC after: 3 days

6 years agoFix IBRS handling around MWAIT.
Konstantin Belousov [Sat, 19 May 2018 20:26:33 +0000 (20:26 +0000)]
Fix IBRS handling around MWAIT.

The intent was to disable IBPB and IBRS around MWAIT, and re-enable on
the sleep end.

Reviewed by: emaste
Sponsored by: The FreeBSD Foundation
MFC after: 3 days

6 years agoEnable kernel dump features in GENERIC for most platforms.
Mark Johnston [Sat, 19 May 2018 19:53:23 +0000 (19:53 +0000)]
Enable kernel dump features in GENERIC for most platforms.

This turns on support for kernel dump encryption and compression, and
netdump. arm and mips platforms are omitted for now, since they are more
constrained and don't benefit as much from these features.

Reviewed by: cem, manu, rgrimes
Tested by: manu (arm64)
Relnotes: yes
Differential Revision: https://reviews.freebsd.org/D15465

6 years agoufs: remove cgbno variable where unused
Matt Macy [Sat, 19 May 2018 19:30:42 +0000 (19:30 +0000)]
ufs: remove cgbno variable where unused

6 years agonet: fix uninitialized variable warning
Matt Macy [Sat, 19 May 2018 19:00:04 +0000 (19:00 +0000)]
net: fix uninitialized variable warning

6 years agoctf dwarf: don't report "no dwarf entry" as if it were an error
Matt Macy [Sat, 19 May 2018 18:50:58 +0000 (18:50 +0000)]
ctf dwarf: don't report "no dwarf entry" as if it were an error

6 years agomuge(4): chase r333813 if_addr_lock rwlock to epoch + mutex
Ed Maste [Sat, 19 May 2018 18:44:29 +0000 (18:44 +0000)]
muge(4): chase r333813 if_addr_lock rwlock to epoch + mutex

muge was committed to the tree in r333713 but not yet connected to the
tree, and it crossed paths with the migration to using ck.

Sponsored by: The FreeBSD Foundation

6 years agodisable printing value of SKEIN_LOOP during standard out,
Matt Macy [Sat, 19 May 2018 18:27:14 +0000 (18:27 +0000)]
disable printing value of SKEIN_LOOP during standard out,
not useful information

6 years agobhnd nvram map: don't write "variable records written" to standard out by default
Matt Macy [Sat, 19 May 2018 18:15:41 +0000 (18:15 +0000)]
bhnd nvram map: don't write "variable records written" to standard out by default

Add -v (verbose) option for the developers. The rest of us
derive no value from this information.

6 years agoRestore the all rights reserved language. Put it on each of the prior
Warner Losh [Sat, 19 May 2018 17:29:57 +0000 (17:29 +0000)]
Restore the all rights reserved language. Put it on each of the prior
two copyrights. The line originated with the Berkeely Regents, who
we have not approached about removing it (it's honestly too trivial
to be worth that fight). Restore it to rwatson's line as well. He
can decide if he wants it or not on his own. Matt clearly doesn't
want it, per project preference and his own statements on IRC.

Noticed by: rgrimes@

6 years agomp_ring: fix i386
Matt Macy [Sat, 19 May 2018 16:44:12 +0000 (16:44 +0000)]
mp_ring: fix i386

Even though 64-bit atomics are supported on i386 there are panics
indicating that the code does not work correctly there. Switch
to mutex based variant (and fix that while we're here).

Reported by: pho, kib

6 years agoFix whitespace; no functional changes.
Edward Tomasz Napierala [Sat, 19 May 2018 15:18:15 +0000 (15:18 +0000)]
Fix whitespace; no functional changes.

MFC after: 2 weeks
Sponsored by: The FreeBSD Foundation

6 years agoAdd #defines for vendor/product USB IDs. No functional changes.
Edward Tomasz Napierala [Sat, 19 May 2018 15:11:24 +0000 (15:11 +0000)]
Add #defines for vendor/product USB IDs.  No functional changes.

MFC after: 2 weeks
Sponsored by: The FreeBSD Foundation

6 years agoRemove duplicate cap_no_rights from r333874
Ed Maste [Sat, 19 May 2018 11:37:02 +0000 (11:37 +0000)]
Remove duplicate cap_no_rights from r333874

Archs using in-tree gcc were broken with `warning: redundant
redeclaration of 'cap_no_rights' [-Wredundant-decls]`.

Sponsored by: The FreeBSD Foundation

6 years agoPermit "(", ")", ":", and "/" in USB string descriptors.
Edward Tomasz Napierala [Sat, 19 May 2018 10:49:51 +0000 (10:49 +0000)]
Permit "(", ")", ":", and "/" in USB string descriptors.
This way we can properly show descriptors with URLs in them.

Reviewed by: hselasky@
MFC after: 2 weeks
Sponsored by: The FreeBSD Foundation

6 years agoUnbreak BeagleBone Black boot by collapsing 29 SYSINITs in to 1
Matt Macy [Sat, 19 May 2018 07:31:35 +0000 (07:31 +0000)]
Unbreak BeagleBone Black boot by collapsing 29 SYSINITs in to 1

Reported by: ilya at bakulin.de

6 years agointr unbreak KTR/LINT build
Matt Macy [Sat, 19 May 2018 07:04:43 +0000 (07:04 +0000)]
intr unbreak KTR/LINT build

6 years agoctfconvert: silence useless enum has too many values warning
Matt Macy [Sat, 19 May 2018 06:31:17 +0000 (06:31 +0000)]
ctfconvert: silence useless enum has too many values warning