Commit Graph

286768 Commits

Author SHA1 Message Date
christos
bf20da46a0 prefixing lwp names with isc- adds no useful information and causes
truncation of the useful part.
2021-04-03 22:20:26 +00:00
rillig
c5ad6426ce make: remove unused Expr.varFlags
No functional change.
2021-04-03 22:06:23 +00:00
rillig
c71fbc370e make: remove VarFlags from debug logging
Before the introduction of ExprDefined, VarFlags contained whether the
expression was defined or not, which was useful to know since the final
value of the expression depends on this information.  The other VarFlags
do not influence the evaluation, so there is no point logging them.
2021-04-03 22:02:59 +00:00
rillig
567911c217 make: simplify access to the name of an expression during evaluation
During the evaluation, the flags of the variable don't change, except
for VFL_IN_USE, but in such a case make exits immediately anyway.

Logging the variable flags does not provide any useful information, so
it will be removed soon.  Logging the variable flags made sense when the
definedness of the expression was still encoded in the variable flags,
instead of in the separate ExprDefined.

No functional change.
2021-04-03 21:55:27 +00:00
thorpej
94013754e4 Document thorpej-cfargs branch. 2021-04-03 21:36:03 +00:00
christos
57f83fe0d8 - Bump field width for state to accommodate > 9 CPUs
- When star formatting to adjust the width, count the trailing number of
  digits starting backwards instead of using strcspn because the lwp name
  might contain other digits like wm0TxRx/10.
2021-04-03 19:25:38 +00:00
christos
f366ee68fe new acpica 2021-04-03 17:46:07 +00:00
christos
98244dcf8c Merge local changes with acpica-20210331 2021-04-03 17:45:02 +00:00
christos
46a330b4ff 31 March 2021. Summary of changes for version 20210331:
This release is available at https://acpica.org/downloads, and
includes all ACPI 6.4 support

1) ACPICA kernel-resident subsystem:
ACPI 6.4: iASL: deprecate DDBHandleObj keyword
Always create namespace nodes using AcpiNsCreateNode(). ACPICA is
allocating an object using kmalloc(), but then frees it using
kmem_cache_free(<"Acpi-Namespace" kmem_cache>). This is wrong.
Fixed a race condition in generic serial bus operation region
handler. Fixed by Hans de Goede.

2) iASL Compiler/Disassembler and ACPICA tools:

ACPI 6.4: NFIT: add Location Cookie field
ACPI 6.4: HMAT: add new fields/flags
ACPI 6.4: Add new flags in SRAT
ACPI 6.4: add SDEV secure access components
ACPI 6.4: add Csi2Bus resource template
ACPI 6.4: add support for PHAT table
ACPI 6.4: add support for PMTT table
Add disassembly support for the IVRS table. Compilation of the
table is not yet complete.  Fixed a potential infinite loop due to
type mismatch. The for-loop is using a UINT8 counter and comparing
the upper limit against a UINT32 AslGbl_ExpectedMessagesIndex
maximum. In the case where AslGbl_ExpectedMessagesIndex is > 255
the counter i will wrap around to zero and the loop will never
exit. I suspect the AslGbl_ExpectedMessagesIndex is never that
high, but fixing this does future proof the code and cleans up
static analysis warnings.Colin King.

iASL/TableCompiler: update it with IORT table E.b revision changes.
	From shamiali2008.
iASL/TableCompiler: Add compilation support for the VIOT table.
	Signed-off-by: Jean-Philippe Brucker.
iASL/TableCompiler: Add compilation support for CEDT table.
	 Also, update the CEDT template.
2021-04-03 17:43:31 +00:00
palle
4eb6bc7ede update TODO after cpu_idle() has been improved (sun4v only for now) 2021-04-03 17:02:31 +00:00
palle
27ed5ac363 Improve cpu_idle() by allowing a platform specific implementaion (same logic as the sparc implementation) - currently only used by sun4v 2021-04-03 17:01:24 +00:00
thorpej
18787f8eb1 Slight tweak to last: Our IPL gets raised to IPL_SCHED by simply *trying*
to acquire the pmap activation lock, regardless of whether or not that was
successful.  So, in addition to remember if we acquired it, also remember
if we tried, and drop back to IPL_VM if so.
2021-04-03 15:29:02 +00:00
rillig
6b6212fb65 make: revert accidental change from the previous commit
The definition of MAKE_GNUC_PREREQ was not supposed to be changed.  This
change only slipped accidentally, the test for __STDC_VERSION__ was only
supposed to be for UNCONST.
2021-04-03 15:22:23 +00:00
thorpej
ab671aa0ea Fix an IPI deadlock scenario that resulted in a TLB shootdown timeout
panic reported by John Klos on port-alpha:

- pmap_tlb_shootnow(): If we acquire a pmap's activation lock, we will
  have raised the IPL on the current CPU to IPL_SCHED until we drop
  the tlb_lock (due to how nested spin mutexes work).  As such, when
  we release the activation lock, forcibly lower our IPL back to IPL_VM
  so that we can receive and process IPIs while waiting for other CPUs
  to process the shootdowns.
- mutex_vector_enter(): Invoke SPINLOCK_SPIN_HOOK while spinning to acquire
  a spin mutex.  This is a nop on most platforms, but it's important on
  the Alpha.  Without this, IPIs (and thus TLB shootdowns) cannot be
  processed if trying to acquire an IPL_SCHED spin mutex such as those
  used by the scheduler.

...and while we're poking around in here:

- Rework the Alpha SPINLOCK_SPIN_HOOK to only check curcpu()->ci_ipis
  if the current CPU's IPL is >= IPL_CLOCK (thus ensuring that preemption
  is disabled and thus guaranteeing that curcpu() is stable).  (Alpha does
  not yet support kernel preemption, but this is now one less thing that
  would need to be fixed.)
2021-04-03 14:56:13 +00:00
rillig
a71bce0149 make: backport to C90
In the past few months I had accidentally used C99 features in the make
code.  According to tools/README, tools that are used in the build
system should restrict themselves to C90.

This allows make to build with GCC's options "-pedantic
-Wno-system-headers -Dinline= -Wno-error=cast-qual".

I didn't notice anyone actively complaining though, I just wanted to see
how much work this backporting would be.  The identifier __func__ is
still used, as in other tools.

No functional change.
2021-04-03 14:39:02 +00:00
rillig
1e65de9557 make: rename function parameters to match boolean constants
No functional change.
2021-04-03 14:31:44 +00:00
simonb
ba42c78d37 Add a -L option to follow all symbolic links. Useful if you have symlinks
in a makefs directory tree but want to refer to the actual file.
2021-04-03 14:10:56 +00:00
simonb
353a61bfae Deal with the case when a device gets recreated (eg when mtree is called by
MAKEDEV) and the stat buffer contains information about the original device
before checking/setting the owner/group/mode of the new device file.
2021-04-03 13:37:18 +00:00
simonb
af1c0e7ba9 Centralise the setitimer() timer type validation in dosetitimer() as is
done with dogetitimer().
2021-04-03 12:57:21 +00:00
simonb
2beb587e3e Print the "preposterous TOD clock time" message only if the RTC is
before very late 2020 (1/1/2021 minus a few leap days) instead of
late 1994.  Someone(TM) should remember to adjust this in somewhat
less than 26 years.
2021-04-03 12:06:53 +00:00
rillig
588b377eb0 make: use standard %H in strftime instead of %k
The conversion specifier %k is neither in C99 nor in C90.

These timestamps are only used in the debug output.
2021-04-03 12:01:00 +00:00
simonb
bef679e4ab CTASSERT that NSIG <= 128. There are many hard-coded assumptions that
there are <= 4 x 32bit signal mask bits.
2021-04-03 11:19:11 +00:00
rillig
244fd9f4c4 make: use C99 bool type instead of defining its own
No functional change.
2021-04-03 11:08:40 +00:00
simonb
8fab31f439 For MIPS N32, register_t needs to be uint64_t as "long" isn't
big enough.
2021-04-03 07:38:11 +00:00
simonb
31ca042232 Revert parsedate(3) XXX as per discussion with kre@. 2021-04-03 04:33:08 +00:00
isaki
398f413a6e Rework about the rest note in speaker(4).
- Obsolete the sc_rest callback.  The rest note operation can be done by
  the common spkr layer.  This also fixes PR kern/56060.
  This work-in-progress patch was left in my local tree for years. :(
- Improve calculations of tone and rest length.
2021-04-03 04:10:30 +00:00
isaki
74bd6922f5 Improve SPKRDEBUG code.
- Replace wrong aprint_debug_dev() with device_printf().
  By this, it no longer need to print dev_t.
- Improve some messages.
2021-04-03 03:21:53 +00:00
rillig
a5de3b3d6e lint: reword message about constant argument to '!'
In the other messages, operators are typically written in their literal
form as well.  Using single quotes disambiguates them from normal
punctuation.
2021-04-02 22:41:53 +00:00
rillig
c0d1467e66 tests/lint: add test for constant argument to '!' 2021-04-02 22:38:42 +00:00
rillig
473375a8eb lint: reduce memory usage
No functional change.
2021-04-02 22:05:43 +00:00
rillig
1cb2fa84ac tests/lint: prevent typo from tree.c 1.264 from happening again 2021-04-02 17:25:04 +00:00
rillig
ff88ea5538 lint: fix typo from previous commit in merge_qualifiers 2021-04-02 17:10:52 +00:00
rillig
59a0181251 lint: clean up merge_qualifiers
No functional change.
2021-04-02 17:01:39 +00:00
macallan
e99657a23f clarify comment in previous
( this is a hack, should go away when the root cause is fixed etc. )
no functional change
2021-04-02 16:59:59 +00:00
rillig
15fe6af379 lint: rename local variable in build_colon
The name 'rtp' was confusing since it did not correspond to 'rn'.  The
'r' meant 'result', not 'right-hand side'.

No functional change.
2021-04-02 16:38:08 +00:00
rillig
5f2c416cbb lint: replace a new modtab with op_name
This reduces the types of variables that are passed around.

No functional change.
2021-04-02 16:17:19 +00:00
rillig
423d380130 lint: rename getopname to op_name
There are several functions called 'get' that allocate memory.  Remove
this possible confusion.

No functional change.
2021-04-02 15:06:35 +00:00
rillig
60a8adda7c lint: reorder struct members to be in comprehension order
No functional change.
2021-04-02 14:50:47 +00:00
rin
36b164a2d7 Fix style to appease changes2html. 2021-04-02 14:41:07 +00:00
rillig
ee16289de5 lint: rename members of brace_level
The terms 'member' and 'subscript' are distinctive enough.

No functional change.
2021-04-02 14:32:27 +00:00
rillig
7910543396 lint: remove unused brace_level.bl_array_of_unknown_size
Since init.c 1.177 from 2021-03-29, the type of the object to be
initialized is no longer modified in the middle of the initialization,
as required by C99 6.7.8p22.  Therefore it is no longer necessary to
keep this redundant information around.

No functional change.
2021-04-02 14:19:33 +00:00
rillig
59dc6d2516 tests/lint: add test for enum type mismatch 2021-04-02 13:16:38 +00:00
rillig
4a7db9da8e lint: add parentheses after sizeof, as required by share/misc/style
No functional change.
2021-04-02 12:16:50 +00:00
rin
6c56221482 For ports with __HAVE_LEGACY_INTRCNT, turn intrcnt[] and derived
variables into u_int, to match with kern/subr_evcnt.c.
2021-04-02 12:11:41 +00:00
rillig
a9672b5f66 lint: rename functions for duplicating types
No functional change.
2021-04-02 11:53:25 +00:00
simonb
f39221eba7 Make extern declaration of intrcnt a u_int instead of a long. Matches
some declartions in some ports.  Fixes build on news68k (and probably
newsmips).
2021-04-02 10:39:22 +00:00
rillig
719899e56c lint: rename members of struct memory_block
No functional change.
2021-04-02 10:30:35 +00:00
rillig
53a994099e lint: name memory allocation functions consistently
No functional change.
2021-04-02 10:13:03 +00:00
martin
c3782d2faa named/filter-aaaa.so is unrelated to DYNAMICROOT 2021-04-02 10:06:26 +00:00
rillig
1e98380776 lint: rename getnode to expr_zalloc_tnode
The new name highlights that the returned memory is only valid in the
scope of the current expression.  This was misleading before since the
other related functions all have a 't' (probably for 'temporary') in
their names.

Also encode in the function name that the returned memory is zeroed out
as that could not be inferred from the old name.

No functional change.
2021-04-02 09:52:36 +00:00