Commit Graph

228756 Commits

Author SHA1 Message Date
Eitan Adler
5539cb324e mtree: remove /etc/skel
We use /usr/share/skel instead of /etc/skel. The existence of /etc/skel
has confused people.

PR:		46062 (submitted 2002-12-07)
PR:		218897
Submitted by:	carl@slackerbsd.org
Submitted by:	asv@inhio.net
2017-12-31 07:25:55 +00:00
Eitan Adler
1a1620dc88 skel: Quote PAGER in dot.shrc
PR:		181853
Submitted by:	pl@catslair.org
MFC After:	1 week
2017-12-31 06:58:58 +00:00
Kyle Evans
1ccce047f5 aw_sid: rewrite compat-string configuration to be more flexible
This will allow easiser support in the future for boards that have thermal
data and different offsets for root key/efuse data.
2017-12-31 06:44:15 +00:00
Nathan Whitehorn
5261ac0eda Use data from the boot loader to pick the appropriate output graphics mode
instead of hard-coding a default. This information is passed implicitly by
the PS3 firmware and can be relied upon. Also adjust the default mode, if
somehow firmware doesn't pass one, to 1920x1080 from 720x480 since it is
2017.

MFC after:	2 weeks
2017-12-31 06:10:07 +00:00
Nathan Whitehorn
a891d21aac Make sure the first instruction of the low-memory spinloop is in the
cacheline being invalidated.

MFC after:	1 month
2017-12-31 05:38:19 +00:00
Kyle Evans
24888292cd stand/fdt: Make fdt_overlay_apply signature-compatible with libfdt
libfdt will assume a writable fdt overlay blob has been passed in, so make
ours compatible to allow easier review when we try to drop libfdt into
place. overlay from the calling context is writable, making it safe to
simply rip out everything related to copying the overlay blob in
fdt_overlay_apply.

I note here that we still have problems: fdt_overlay_apply, both our version
and libfdt's, may fail and have already clobbered the base fdt to some
extent. Future work will make sure we don't apply a potentially bogus fdt,
instead discarding the base fdt if we had an error.

Reviewed by:	gonzo
Differential Revision:	https://reviews.freebsd.org/D13695
2017-12-31 05:22:26 +00:00
Alan Cox
4abca9bb05 Previously, swap_pager_copy() freed swap blocks one at at time, via
swp_pager_meta_ctl(), with no opportunity to recognize freeing of
consecutive blocks and free fewer block ranges.  To open that opportunity,
this change removes the SWM_FREE option from swp_pager_meta_ctl(), and
compels the caller to do the freeing when a valid block address is returned.
In swap_pager_copy(), these frees are aggregated, so that a sequence of them
can be done at one time.

The only other caller to swp_pager_meta_ctl() that passed SWM_FREE,
swp_pager_unswapped(), is also modified to handle its single free
explicitly.

Submitted by:	Doug Moore <dougm@rice.edu>
Reviewed by:	kib (an earlier version)
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D13290
2017-12-31 04:01:47 +00:00
Pedro F. Giffuni
0879ca728a sysv_{ipc|shm}: update the NetBSD VCS tags to match nearer our files.
Both files originated in NetBSD:

sysv_ipc.c CVS 1.9:
Most of their changes don't apply to us as we already have similar
changes. This is a better reference for future merges.

sysv_shm.c CVS 1.39:
Most of their changes don't apply to our code but interestingly this
revision merged our changes and is a better point for reference.

Move the VCS tags to the position recommended in our committers guide
(section 8),

No functional change.
2017-12-31 03:34:00 +00:00
Nathan Whitehorn
9f7602f019 Teach bsdinstall partedit/sade how to format FAT partitions on GPT, which
have the partition type code "ms-basic-data".

MFC after:	2 weeks
2017-12-31 03:13:45 +00:00
Mateusz Guzik
efa9f177f5 locks: adjust loop limit check when waiting for readers
The check was for the exact value, but since the counter started being
incremented by the number of readers it could have jumped over.
2017-12-31 02:31:01 +00:00
Mateusz Guzik
cde25ed4cd sx: fix up non-smp compilation after r327397 2017-12-31 01:59:56 +00:00
Eitan Adler
d592c356d3 cacos(3): correct spelling of 'I'
In some cases we had 'i' instead of 'I'.

PR:		195517
Submitted by:	stephen
2017-12-31 00:55:00 +00:00
Mateusz Guzik
28f1a9e3ff locks: re-check the reason to go to sleep after locking sleepq/turnstile
In both rw and sx locks we always go to sleep if the lock owner is not
running.

We do spin for some time if the lock is read-locked.

However, if we decide to go to sleep due to the lock owner being off cpu
and after sleepq/turnstile gets acquired the lock is read-locked, we should
fallback to the aforementioned wait.
2017-12-31 00:47:04 +00:00
Eitan Adler
518e4554be isgreater(3): correct description of isunordered macro
PR:		211376
Submitted by:	Duane <parakleta@darkreality.org>
MFC After:	1 week
2017-12-31 00:46:41 +00:00
Mateusz Guzik
fb10612355 sx: read the SX_NOADAPTIVE flag and Giant ownership only once
These used to be read multiple times when waiting for the lock the become
free, which had the potential to issue completely avoidable traffic.
2017-12-31 00:37:50 +00:00
Eitan Adler
03cd714fc5 man(1): document exit code
man(1) uses standard exit codes, document that.

PR:		223517
Reported by:	wosch
MFC after:	1 week
2017-12-31 00:35:11 +00:00
Mateusz Guzik
15140a8ade mtx: deduplicate indefinite wait check in spinlocks and thread lock 2017-12-31 00:34:29 +00:00
Mateusz Guzik
1f4d28c7ea mtx: pre-read the lock value in thread_lock_flags_
Since this function is effectively slow path, if we get here the lock is most
likely already taken in which case it is cheaper to not blindly attempt the
atomic op.

While here move hwpmc probe out of the loop to match other primitives.
2017-12-31 00:33:28 +00:00
Mateusz Guzik
80c39f6c37 rwlock: tidy up __rw_runlock_hard similarly to r325921 2017-12-31 00:31:14 +00:00
Emmanuel Vadot
74e0613ead dwmmc: Fully subclass driver
Fully subclass the dwmmc driver and split every driver into multiple files.

There is still a few quirks in the dwmmc driver that will need some work.

Tested On: Pine64 Rock64

Differential Revision:	https://reviews.freebsd.org/D13615
2017-12-30 22:01:17 +00:00
Nathan Whitehorn
01d1c9d889 Avoid use of the fdt_get_property_*() API, which is intrinsically
incompatible with FDT versions < 16. This also simplifies the code a bit.

MFC after:	1 month
2017-12-30 20:28:29 +00:00
Nathan Whitehorn
3159111ed6 Garbage-collect loader.ps3. It is currently disconnected from the build and
is superseded by either direct loading of the kernel by petitboot (soon to
become the installer default) or loader.kboot.
2017-12-30 20:27:13 +00:00
Nathan Whitehorn
3fca788024 Remove logic for early console with loader.ps3 now that loader.ps3 is dead. 2017-12-30 20:25:33 +00:00
Nathan Whitehorn
ba06dbb874 Change the way SMP startup works to match the new multi-AP features in
locore64.S introduced in r327358.

MFC after:	3 weeks
2017-12-30 20:24:33 +00:00
Nathan Whitehorn
223d42a4de Check more aggressively for whether the desired properties actually exist.
If they don't, the code would look up some random part of the device tree
and seize the console inappropriately.

MFC after:	2 weeks
2017-12-30 20:23:14 +00:00
Bryan Venteicher
ac2b436d20 Add macro for vxlan list mutex lock and unlock
This will simplify some later VNET support.

Submitted by:	hrs
MFC after:	2 weeks
2017-12-30 19:49:40 +00:00
Bryan Venteicher
6d7bc5838b Advertise IFCAP_LINKSTAT after r326480 added link status support
MFC after:	2 weeks
2017-12-30 19:35:12 +00:00
Cy Schubert
57229a86bf Fix r327383:
.../sys/dev/ep/elink.c:31:1: error: '/*' within block comment
[-Werror,-Wcomment]
/* $NetBSD: elink.c,v 1.6 1995/01/07 21:37:54 mycroft Exp $
^
2017-12-30 19:27:22 +00:00
Pedro F. Giffuni
8a2141f0e3 elink.[ch]: Move historic VCS tags after the license.
This matches better our common practices and style.
2017-12-30 15:13:33 +00:00
Edward Tomasz Napierala
2e07d451f9 Improve usbconfig(8) manual page by adding descriptions for subcommands.
Reviewed by:	hselasky
MFC after:	2 weeks
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D13445
2017-12-30 12:56:50 +00:00
Konstantin Belousov
abbfe9e5d1 Move i386/isa/elink.[hc] to dev/ep.
The ep(4) driver is the only consumer of the two functions from
elink.c.  I removed the standalone module as well, and most likely,
the module metadata is not needed anywhere, but this is for later
cleanup.

Discussed with:	imp, jhb
Sponsored by:	The FreeBSD Foundation
2017-12-30 11:42:49 +00:00
Konstantin Belousov
0cc997d237 Move i386/isa/npx.c to i386i386/npx.c.
The i386 FPU (AKA npx) code does not depend on ISA devices at all,
after the support for IRQ13 FPU exceptions was removed.  Put the file
into the expected place in the kernel source tree.

Discussed with:	jhb
Sponsored by:	The FreeBSD Foundation
2017-12-30 11:33:04 +00:00
Warner Losh
9e1472ca00 On further testing on actual machines with this hardware, we should
only warn for devices that are attached. Add missing \n.
2017-12-30 08:16:31 +00:00
Warner Losh
d14e21a831 Remove two stray references to wl driver, removed some time ago. 2017-12-30 07:59:32 +00:00
Kyle Evans
37cb59c8ac libsa: Pull in strnlen from libc
strnlen is not used at the moment, but it will be when libfdt gets updated.
Prepare for the not-so-distant future by pulling in strnlen.

Noticed because:	segfault in ld.bfd due to strnlen missing
2017-12-30 07:03:52 +00:00
Kyle Evans
d2084bf608 stand/fdt: Swap libfdt include order
libfdt.h should be included before fdt.h, as hinted at by all of libfdt/;
standard include order being libfdt.h, libfdt_env.h, fdt.h.

The current include order also causes problems when libfdt gets updated, as
fdt.h requires some definitions from libfdt.h.

Differential Revision:	https://reviews.freebsd.org/D13688
2017-12-30 06:53:27 +00:00
Bryan Venteicher
33e0d8f057 Add support for IPv6 scoped addresses to vxlan
MFC after:	2 weeks
2017-12-30 04:03:53 +00:00
John Baldwin
8bbeea2b1d Remove a redunant check. 2017-12-30 03:08:49 +00:00
Pedro F. Giffuni
2afb21f309 geom_ccd.c: Fix the licenses properly
The license merging in r109471 didn't take into account that licensing
could change. Just removing the 3rd clause obviates the copyright
assignment to the NetBSD Foundation.

We do have plenty of files that have two or more licensing as in this
case, so fix this properly by splitting back the licenses as they are
upstream.

Obtained from:	NetBSD
2017-12-30 02:07:18 +00:00
Pedro F. Giffuni
68689f580b geom_ccd.c: Update the license with changes from upstream.
Part of this file originated in NetBSD, with the original file
carrying two versions of 4-clause BSD licenses. r109471 attempted to
simplify the situation by putting both licenses together.

Meanwhile, NetBSD dropped Clauses 3 and 4 from their own license, and
eventually NetBSD got permission from the University of Utah to drop the
3rd clause.

Keep the license "simple" by dropping the third clause since both TNF,
Utah/Berkeley and phk agree in principle that it can be dropped.

Obtained from:	NetBSD (ccd.c CVS 1.128, 1.138)
2017-12-30 01:37:08 +00:00
Andriy Voskoboinyk
bcabc90835 net80211: sanitize input for ieee80211_output()
- Add some basic checks for i_fc* bits (ToDS, FromDS, MoreFrag, Protected);
those are used / checked across various places in Tx path.
- Mark injected 802.11 frame as encapsulated (just as it should be).
- Classify 802.11 frame in a proper way (extract ether_type from LLC header
for Data frames, use AC_BE queue for others (NoData / Management / Control).
- Subtract header length from tx_bytes statistics (so it will correspond
to the comment).

Was checked with RTL8188EU (AP) + Intel 6205 (STA).

Reviewed by:	adrian
Differential Revision:	https://reviews.freebsd.org/D13161
2017-12-30 00:40:34 +00:00
Pedro F. Giffuni
02547822f3 ccdconfig: Move VCS tags to be more consistent with our style.
Update a now-bogus SPDX tag while here.
2017-12-30 00:26:42 +00:00
Andriy Voskoboinyk
f6b986459f net80211: handle VHT nodes in ieee80211_node_setuptxparms()
Select proper mode when node can do VHT.

Currently there are no drivers with VHT support in the tree,
so this should be noop.

Reviewed by:	adrian
Differential Revision:	https://reviews.freebsd.org/D9806
2017-12-30 00:24:53 +00:00
Pedro F. Giffuni
9a827f1751 ccdconfig: Update licensing terms to match NetBSD.
The code originated in NetBSD which has since removed Clauses 3 and 4.

Approved by:	phk (concerning his own copyright)
Obtained from:	NetBSD (CVS ccdconfig.c 1.47, ccdconfig.8 1.24)
2017-12-30 00:22:47 +00:00
Ian Lepore
2d09b07279 Make kernel option KERNVIRTADDR optional, remove it from std.<platform>
files that can use the default value.

It used to be required that the low-order bits of KERNVIRTADDR matched
the low-order bits of the physical load address for all arm platforms.
That hasn't been a requirement for armv6 platforms since FreeBSD 10.
There is no longer any relationship between load addr and KERNVIRTADDR
except that both must be aligned to a 2 MiB boundary.

This change makes the default KERNVIRTADDR value 0xc0000000, and removes the
options from all the platforms that can use the default value.  The default
is now defined in vmparam.h, and that file is now included in a few new
places that reference KERNVIRTADDR, since it may not come in via the
forced-include of opt_global.h on the compile command line.
2017-12-30 00:20:49 +00:00
Eitan Adler
9faaeffdbd examples: fix typo 2017-12-29 23:58:05 +00:00
Eitan Adler
73454f8624 Remove a reference to burncd
I'm unclear of the purpose of this pseudo-target
but while its here keep it up to date
2017-12-29 23:56:06 +00:00
Conrad Meyer
66ad253880 Add AHCI/XHCI device IDs found on AMD 1950X+X399 system
A follow-up to r327094.

Sponsored by:	Dell EMC Isilon
2017-12-29 22:24:41 +00:00
Conrad Meyer
d8a0fe102c find(1): Fix -newer and -samefile to conform to POSIX[0]
By default, or with the -P flag, find(1) should evaluate paths "physically."
For symlinks, this means using the link itself instead of the target.

Historically (since the import of BSD 4.4-lite from CSRG), find(1) has
failed to refer to the link itself, at least for -newer and -samefile.

[0]: http://pubs.opengroup.org/onlinepubs/9699919799/utilities/find.html

PR:		222698
Reported by:	Harald Schmalzbauer <bugzilla.freebsd AT omnilan.de>
Sponsored by:	Dell EMC Isilon
2017-12-29 22:08:43 +00:00
Maxim Konovalov
cad0074dd6 Sort by time. 2017-12-29 21:37:36 +00:00