Commit Graph

300189 Commits

Author SHA1 Message Date
rillig 17f65f1e9a tests/lint: sync test for nonportable character comparisons
Message 230 was changed on 2023-02-22 but only tested on signed char
platforms.
2023-02-27 21:59:14 +00:00
sekiya d5fc68ea80 Uncomment and protect sanity checks that would drop into the debugger with a
CPSW_DEBUG_DMA define.

This handles a condition where checking for DMA_RXEOQ in the received packet
results in the console being spammed with "rxeoq" messages, which soon results
in a kernel panic.  The corresponding Debugger() call for this check was
commented out.

The TI documentation ("AM335x and AMIC110 Sitara™ Processors Technical
Reference Manual") documents the EOQ bit thus:

	(14.3.2.4.1.2.4) This bit is set by the EMAC when the EMAC identifies
	that a descriptor is the last for a given packet received (also sets
	the EOP flag), and there are no more descriptors in the receive list
	(next descriptor pointer is NULL).  The software application can use
	this bit to detect when the EMAC receiver for the corresponding channel
	has halted. This is useful when the application appends additional free
	buffer descriptors to an active receive queue. Note that this flag is
	valid on EOP descriptors only.

Moving this check (and the offending printf() ) into a debug #ifdef results in
the BeagleBone Green surviving the nightly checks; it would always drop into
the debugger before this change.
2023-02-27 21:15:09 +00:00
fcambus f672cebc56 Add PGO (profile guided optimization). 2023-02-27 21:04:43 +00:00
christos 7f2d4a670e Disable completely mips ifunc test to make cross-compilation on other OSs work.
(Jan-Benedict Glaw)
2023-02-27 17:38:18 +00:00
riastradh e088bb05d6 uvm(9): KASSERT(A && B) -> KASSERT(A); KASSERT(B)
While here, print some of the inputs with KASSERTMSG.
2023-02-27 16:24:45 +00:00
riastradh 1f867660b6 amd64_trap.S: Annotate trap vectors with their mnemonics.
Derived from Intel and AMD manuals.

Intel 64 and IA-32 Architectures Software Developer's Manual, Volume 3
(3A, 3B, 3C, & 3D: System Programming Guide, Order Number:
325384-077US, April 2022.
https://cdrdv2.intel.com/v1/dl/getContent/671447

AMD64 Technology: AMD64 Architecture Programmers' Manual, Volume 2:
System Programming, Publication No. 24953, Revision 3.40, January 2023.
https://www.amd.com/system/files/TechDocs/24593.pdf

No functional change intended.

XXX Should apply the same treatment to i386_trap.S.
2023-02-27 16:24:28 +00:00
msaitoh c7942c0506 igpio(4): Disable Baytrail and Lynxpoint support. Fixes PR kern/57225.
It seems additional code is required to support Baytrail and Lynxpoint.
Disable those support.
2023-02-27 15:41:41 +00:00
kardel 8f3b9c1ccd cast to the correct message structure (rt_msghdr instead of if_msghdr) 2023-02-27 13:39:09 +00:00
rillig 67db92f955 tests/make: describe the absent fallback for ':O' modifiers more clearly 2023-02-27 08:29:36 +00:00
mrg 4fc5460497 obsolete several xorg-server.old configurations and normalise some comments. 2023-02-27 00:34:11 +00:00
andvar 45db36d858 s/superblok/superblock/ in comment. 2023-02-26 22:55:02 +00:00
mrg 8a59e5b8bc updates for xf86-video-trident 1.4.0. 2023-02-26 20:19:05 +00:00
mrg 03646e0f95 bump amdgpu_drv version, obsolete old one. 2023-02-26 20:16:13 +00:00
uwe 126bf81cc3 wsemul_vt100_subr: spell edp->tabs assertion with NULL 2023-02-26 14:00:42 +00:00
uwe bfe55737b4 wsemul_vt100_subr: don't assert unsigned ncols >= 0 2023-02-26 13:57:56 +00:00
skrll c1da2a84d2 nkmempages should be size_t 2023-02-26 07:27:14 +00:00
skrll c591e46de3 ci_data.cpu_kcpuset -> ci_kcpuset
NFCI.
2023-02-26 07:13:54 +00:00
rillig 5680df50a4 tests/make: extend tests for expression modifiers, especially ':N' 2023-02-26 06:08:06 +00:00
sjg 6f6525029a meta.c: use macro to access job->bm
and if job is NULL use Mybm.

No functional change.
2023-02-25 22:52:21 +00:00
sjg 68f52b2486 t_make skip varname-dot-make-meta-ignore_*
The meta-ignore tests will likely not work in this environment
so skip them.
2023-02-25 19:37:33 +00:00
sjg f65c78637b make: meta-ignore tests will not work if TMPDIR is /tmp
Since /tmp and /var/tmp are always part of .MAKE.META.IGNORE_PATHS
the varname-dot-make-meta-ignore_* tests will not work
if TMPDIR is either (or subdir) of those.
2023-02-25 19:30:32 +00:00
rillig ebcc57bf5c tests/make: clean up tests for MAKEFLAGS and related variables 2023-02-25 19:24:07 +00:00
riastradh 2522c3f764 x86: Add kthread_fpu_enter/exit support, take two -- forgot i386 bits. 2023-02-25 18:35:54 +00:00
riastradh 0ddb09c5c9 x86/fpu.c: Sprinkle KNF.
No functional change intended.
2023-02-25 18:28:57 +00:00
riastradh 0dafb3bd57 x86: Add kthread_fpu_enter/exit support, take two.
This time, make sure to restore the FPU state when switching to a
kthread in the middle of kthread_fpu_enter/exit.

This adds a single predicted-taken branch for the case of kthreads
that are not in kthread_fpu_enter/exit, so it incurs a penalty only
for threads that actually use it.  Since it avoids FPU state
switching in kthreads that do use the FPU, namely cgd worker threads,
this should be a net performance win on systems using it and have
negligible impact otherwise.

XXX pullup-10
2023-02-25 18:04:42 +00:00
riastradh 0a4b6dc8b4 x86: Label boolean is_64bit argument to fpu_area_restore.
No functional change intended.
2023-02-25 18:04:25 +00:00
uwe ea045e23c8 ftp(1): better mark up for url vs cd example 2023-02-25 17:37:09 +00:00
riastradh a89583ca1c x86: Mitigate MXCSR Configuration Dependent Timing in kernel FPU use.
In fpu_kern_enter, make sure all the MXCSR exception status bits are
set when we start using the FPU, so that instructions which exhibit
MCDT are unaffected by it.

While here, zero all the other FPU registers in fpu_kern_enter.

In principle we could skip this step on future CPUs that fix the MCDT
bug, but there's probably not much benefit -- workloads that do a lot
of crypto in the kernel are probably better off using
kthread_fpu_enter or WQ_FPU to skip the fpu_kern_enter/leave cycles
in the first place.

For details, see:
https://www.intel.com/content/www/us/en/developer/articles/technical/software-security-guidance/best-practices/mxcsr-configuration-dependent-timing.html
2023-02-25 13:57:37 +00:00
riastradh 69631d6b3e i386/bioscall: Disable preemption while we load the kernel pmap.
Fixes crash on boot in new KASSERT(kpreempt_disabled()) in
cpu_load_pmap.

We could do KASSERT(kpreempt_disabled() || cold), but I don't know if
bioscall is ever reachable after warm boot; this way is safer.

XXX Would be nice if bioscall were a C function, not asm -- I don't
see any reason why we need it to be asm?
2023-02-25 13:52:09 +00:00
uwe e07284c9b0 ftp(1): minor markup tweaks
Use .Ql instead of .Sq Li, add some missing ones.  Use .Pq instead of
explicit () for longer phrases - these are easier to read in the
postscript output b/c of extra spacing.
2023-02-25 13:51:48 +00:00
riastradh 67201c1e64 linux asm/barrier.h: Fix !MULTIPROCESSOR build. 2023-02-25 12:23:36 +00:00
mlelstv ddcd952b6c Add option sslnoverify to control validation of SSL certificates.
Add netrc processing to fetch-mode (URL on command line) to enable options and autologin
via netrc.
Fix SSL cleanup in some error paths.

Certificate validation is now enabled by default. Set FTPSSLNOVERIFY=1 in environment
or configure a corresponding init macro via netrc to not validate certs (required if
you haven't installed a required CA certificate for OpenSSL).

Discussed with lukem@ on icb.
2023-02-25 12:07:25 +00:00
rillig b78a257d1d tests/make: move tests for MAKRFLAGS to the correct file
I had accidentally added these tests to the file for the special
variable '.MAKEFLAGS' instead of the file for the environment variable
'MAKEFLAGS'.  While here, add a basic test that shows how 'MAKEFLAGS' is
built from '.MAKEFLAGS' and '.MAKEOVERRIDES'.
2023-02-25 11:59:12 +00:00
rillig 90e6b996ac tests/make: test that MAKEFLAGS is an environment variable 2023-02-25 11:11:16 +00:00
rillig 2c2c63ef0f tests/make: fix explanation for '$' in MAKEFLAGS
My previous interpretation was completely wrong.
2023-02-25 10:41:14 +00:00
rillig 0856968224 tests/make: activate all tests for MAKEFLAGS 2023-02-25 09:02:45 +00:00
skrll b80a6b95b4 Convert some assignments into KASSERTs.
l_md is zeroised by lwp_create with

         memset(&l2->l_startzero, 0, sizeof(*l2) -
                    offsetof(lwp_t, l_startzero));
2023-02-25 08:41:37 +00:00
skrll 3b390fc259 Convert some assignments into KASSERTs.
l_md is zeroised by lwp_create with

         memset(&l2->l_startzero, 0, sizeof(*l2) -
                    offsetof(lwp_t, l_startzero));
2023-02-25 08:30:31 +00:00
skrll 64ac4486df Trailing whitespace 2023-02-25 08:22:00 +00:00
skrll 49721fc44e Restore the ability to have EARLYCONS work for the QEMU virt after
SOC_VIRT got removed.
2023-02-25 08:19:35 +00:00
skrll adedf7ab7d Don't refer to physical_{start,end} here and just pass minimum (0UL)
address and maximum (~0UL) physical address.  The values are passed
through to uvm_pglistalloc which knows about the RAM ranges.
2023-02-25 08:05:46 +00:00
skrll 2fbe4f5b5a Add a KASSERT 2023-02-25 08:00:35 +00:00
rillig 3fdfc37236 tests/make: reproduce and explain '$' in MAKEFLAGS
https://mail-index.netbsd.org/current-users/2023/02/24/msg043633.html
2023-02-25 06:54:08 +00:00
riastradh 7cb05f22e7 aarch64: curcpu() audit.
Sprinkle KASSERT (or KDASSERT in hot paths) for kpreempt_disabled()
when we use curcpu() and it's not immediately obvious that the caller
has preemption disabled but closer scrutiny suggests the caller has.

Note unsafe curcpu()s for syscall event counting.  Not sure this is
worth changing.

Possible bugs fixed:

- cpu_irq and cpu_fiq could be preempted while trying to run softints
  on this CPU.

- data_abort_handler might incorrectly think it was invoked in
  interrupt context when it was only preempted and migrated to
  another CPU.

- pmap_fault_fixup might report the wrong CPU logs.

(However, we don't currently run with kpreemption on aarch64, so
these are not yet real bugs fixed except if you patch it to build
with __HAVE_PREEMPTION.)
2023-02-25 00:40:22 +00:00
riastradh aba5e6ba51 xennetback(4): Nix trailing whitespace.
No functional change intended.
2023-02-25 00:37:47 +00:00
riastradh 51dd0b0dc5 xenbus_comms.c: Nix trailing whitespace.
No functional change intended.
2023-02-25 00:37:34 +00:00
riastradh bad5336a8a xengnt(4): Nix trailing whitespace.
No functional change intended.
2023-02-25 00:35:52 +00:00
riastradh f34c02f1ad xencons(4): Nix trailing whitespace.
No functional change intended.
2023-02-25 00:35:40 +00:00
riastradh d43e6cfb4f xbdback(4): Nix trailing whitespace.
No functional change intended.
2023-02-25 00:35:28 +00:00
riastradh 5d483f5ae6 xbd(4): Nix trailing whitespace. 2023-02-25 00:35:15 +00:00