r354701 bdragon Nov. 14, 2019, 4:34 a.m.
Fix wrong section ordering that was causing a ".got is not contiguous with
other relro sections" lld error. This also brings ldscript.powerpc and
ldscript.powerpcspe closer to ldscript.powerpc64.

Also, remove unnecessary text relocs from the ppc32 AIM trap code.

Approved by: jhibbits (mentor)
Differential Revision: https://reviews.freebsd.org/D22349
ViewVC
r354700 imp Nov. 14, 2019, 1:38 a.m.
Add ifdefs in the assembler for soft-float compile case.

Submitted by: Hiroki Mori
Reviewed by: ray@
Differential Review: https://reviews.freebsd.org/D22352
ViewVC
r354699 brooks Nov. 13, 2019, 11:31 p.m.
Reported by:	kib
Sponsored by:	DARPA, AFRL
ViewVC
r354697 kib Nov. 13, 2019, 10:43 p.m.
Instead of providing ioctl cmd value, which has no meaning to user,
print MSR number.  The later is what the user expects in this place
even.

Reported by:	pstef
Sponsored by:	The FreeBSD Foundation
MFC after:	3 days
ViewVC
r354696 kib Nov. 13, 2019, 10:39 p.m.
from usermode.

If CPU supports RDFSBASE, the flag also means that userspace fsbase
and gsbase are already written into pcb, which might be not true when
we handle #gp from kernel.

The offender is rdmsr_safe(), and the visible result is corrupted
userspace TLS base.

Reported by:	pstef
Sponsored by:	The FreeBSD Foundation
MFC after:	3 days
ViewVC
r354694 brooks Nov. 13, 2019, 9:51 p.m.
Reviewed by:	emaste, sef
MFC after:	3 days
Sponsored by:	DARPA, AFRL
Differential Revision:	https://reviews.freebsd.org/D22353
ViewVC
r354693 jhb Nov. 13, 2019, 9:49 p.m.
MK_CLANG_IS_CC controls installing links for GCC, not just clang.  Set
MK_CLANG_IS_CC to the value of MK_CLANG_BOOTSTRAP.  This will leave it
as "no" if no bootstrap compiler is being built or GCC 4.2.1 is being
used as the bootstrap compiler, and "yes" if clang is being used as
the bootstrap compiler.

Submitted by:	bdrewery (kind of, he suggested this on IRC while I was
	  		  testing the original patch)
Reviewed by:	kevans, imp
Sponsored by:	DARPA
Differential Revision:	https://reviews.freebsd.org/D22350
ViewVC
r354692 emaste Nov. 13, 2019, 9:02 p.m.
/proc/curproc/file and the KERN_PROC_PATHNAME sysctl may not return the
desired path if there are multiple hardlinks to the file.

PR:		241932
Tested by:	ler
Sponsored by:	The FreeBSD Foundation
ViewVC
r354691 trasz Nov. 13, 2019, 8:32 p.m.
and add some missing Xrs.

Reviewed by:	brueffer, emaste (earlier version)
MFC after:	2 weeks
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D22277
ViewVC
r354690 trasz Nov. 13, 2019, 8:27 p.m.
to disable mounting Linux-specific filesystems under /compat/linux
when 'linux_enable' is set to YES.

Reviewed by:	netchild, ian (earlier version)
MFC after:	2 weeks
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D22320
ViewVC
r354689 kevans Nov. 13, 2019, 6:21 p.m.
__has_attribute(__constructor__) is a better test for clang than
defined(__clang__). Switch to it instead.

While we're already here and touching it, pfg@ nailed down when GCC actually
introduced the priority argument -- 4.3. Use that instead of our
hammer-guess of GCC >= 5 for the sake of correctness.
ViewVC
r354688 brooks Nov. 13, 2019, 6:10 p.m.
The second argument should have been "pa" not "ps".  It worked by
accident because the argument was always "pa" which was an in-scope
local variable.

Submitted by:	sson
Reviewed by:	jhb, kevans
Obtained from:	CheriBSD
MFC after:	3 days
Sponsored by:	DARPA, AFRL
Differential Revision:	https://reviews.freebsd.org/D22338
ViewVC
r354686 jhb Nov. 13, 2019, 5:06 p.m.
Missed in r354667.

Pointy hat to:	jhb
MFC after:	1 month
Sponsored by:	Chelsio Communications
ViewVC
r354685 glebius Nov. 13, 2019, 4:28 p.m.
Reported & tested by:	garga
ViewVC
r354684 dougm Nov. 13, 2019, 3:56 p.m.
around entry->{next,prev} when those are used for ordered list
traversal, and use those wrapper functions everywhere. Where the next
field is used for maintaining a stack of deferred operations, #define
defer_next to make that different usage clearer, and then use the
'right' pointer instead of 'next' for that purpose.

Approved by: markj
Tested by: pho (as part of a larger patch)
Differential Revision: https://reviews.freebsd.org/D22347
ViewVC