openbsd
21 months agosync
deraadt [Sun, 8 Jan 2023 18:02:56 +0000 (18:02 +0000)]
sync

21 months agoUse NULL instead 0 for pointer initialization.
mvs [Sun, 8 Jan 2023 10:26:36 +0000 (10:26 +0000)]
Use NULL instead 0 for pointer initialization.

21 months ago- tweak the text relating to -w
jmc [Sun, 8 Jan 2023 08:27:17 +0000 (08:27 +0000)]
- tweak the text relating to -w
- sync usage() and SYNOPSIS

ok ratchov

21 months agoAdd -w option to display variables periodically
ratchov [Sun, 8 Jan 2023 06:58:07 +0000 (06:58 +0000)]
Add -w option to display variables periodically

The purpose of -w is to monitor underruns without triggering long
kernel code-paths (ex. fork and exec of new audioctl process) that may
cause additional underruns than the ones being monitored.

ok chehola, edd

21 months agoDue to xonly on arm64 it is no longer possible to read the testfly routine.
anton [Sun, 8 Jan 2023 06:56:01 +0000 (06:56 +0000)]
Due to xonly on arm64 it is no longer possible to read the testfly routine.
Put it in the rodata section allowing it to be copied. Note that testfly is
never executed directly but only after placing it in a separate chunk of memory
allowing its permissions to be mutated.

21 months agocope with recent thread name changes
anton [Sun, 8 Jan 2023 06:55:18 +0000 (06:55 +0000)]
cope with recent thread name changes

21 months agoRename argument funcidx_swid to func_idx as it does not include any software id.
anton [Sun, 8 Jan 2023 06:54:51 +0000 (06:54 +0000)]
Rename argument funcidx_swid to func_idx as it does not include any software id.
No functional change.

21 months agoAdd getthrname(2) manpage
guenther [Sun, 8 Jan 2023 04:54:50 +0000 (04:54 +0000)]
Add getthrname(2) manpage

ok jmc@ schwarze@

21 months agosync
deraadt [Sat, 7 Jan 2023 19:56:38 +0000 (19:56 +0000)]
sync

21 months agoBring back a local copystr() declaration, as copy{in,out} still make us of it
miod [Sat, 7 Jan 2023 17:29:37 +0000 (17:29 +0000)]
Bring back a local copystr() declaration, as copy{in,out} still make us of it
but its body is in locore.

21 months agoRewrite/simplify BN_free().
jsing [Sat, 7 Jan 2023 16:17:29 +0000 (16:17 +0000)]
Rewrite/simplify BN_free().

ok tb@

21 months agoFlip BN_clear_free() and BN_free()
jsing [Sat, 7 Jan 2023 16:13:46 +0000 (16:13 +0000)]
Flip BN_clear_free() and BN_free()

All of our BIGNUMs are cleared when we free them - move the code to
BN_free() and have BN_clear_free() call BN_free(), rather than the other
way around.

ok tb@

21 months agoUse calloc() in BN_new(), rather than malloc() and then manually zeroing.
jsing [Sat, 7 Jan 2023 16:09:18 +0000 (16:09 +0000)]
Use calloc() in BN_new(), rather than malloc() and then manually zeroing.

ok tb@

21 months agoaccept --executable-only on aarch64, riscv64, and mips64 because the
deraadt [Sat, 7 Jan 2023 16:01:58 +0000 (16:01 +0000)]
accept --executable-only on aarch64, riscv64, and mips64 because the
linker is creating correct binaries.  There can also be problems with
compilers generating incorrect data-inside-text, but those (so far minor)
issues are being resolved seperately.
ok kettenis

21 months agosync
deraadt [Sat, 7 Jan 2023 15:20:27 +0000 (15:20 +0000)]
sync

21 months agoFix previous.
jsing [Sat, 7 Jan 2023 14:30:57 +0000 (14:30 +0000)]
Fix previous.

21 months agofix firmware filename typo in iwx(4) man page: ao -> a0
stsp [Sat, 7 Jan 2023 12:34:29 +0000 (12:34 +0000)]
fix firmware filename typo in iwx(4) man page: ao -> a0

21 months agoMake net80211 drop beacons received on secondary HT/VHT channels.
stsp [Sat, 7 Jan 2023 11:09:16 +0000 (11:09 +0000)]
Make net80211 drop beacons received on secondary HT/VHT channels.

Prevents iwm firmware panics and makes association work with 11ac APs
which transmit beacons on channels other than their primary channel.
We would use the wrong channel in such cases, and iwm would request
a bogus channel configuration, which made the firmware unhappy.

Tested by myself on iwm 8265 and florian on iwm 9260.
This issue did likely affect iwx devices, too.

ok mpi@

21 months agoThe PA-RISC architecture supports execute-only mappings by using a
kettenis [Sat, 7 Jan 2023 10:09:34 +0000 (10:09 +0000)]
The PA-RISC architecture supports execute-only mappings by using a
"remain at privilege level 3" gateway page.  Make use of this.

ok deraadt@, miod@

22 months agoThe maximum length of the value is extended to 64k bytes.
asou [Sat, 7 Jan 2023 06:40:21 +0000 (06:40 +0000)]
The maximum length of the value is extended to 64k bytes.

ok yasuoka

22 months agoAdd argument and return support for {get,set}thrname()
guenther [Sat, 7 Jan 2023 05:26:40 +0000 (05:26 +0000)]
Add argument and return support for {get,set}thrname()

22 months agoregen
guenther [Sat, 7 Jan 2023 05:25:39 +0000 (05:25 +0000)]
regen

22 months agoAdd {get,set}thrname(2) for putting thread names in the kernel and
guenther [Sat, 7 Jan 2023 05:24:58 +0000 (05:24 +0000)]
Add {get,set}thrname(2) for putting thread names in the kernel and
exposed in a new field returned by sysctl(KERN_PROC).  Update
pthread_{get,set}_name_np(3) to use the syscalls.  Show them, when
set, in ps -H and top -H output.

libc and libpthread minor bumps

ok mpi@, mvs@, deraadt@

22 months agotlsfuzzer: hook up new connection abort tests while skipping the NST
tb [Fri, 6 Jan 2023 19:25:20 +0000 (19:25 +0000)]
tlsfuzzer: hook up new connection abort tests while skipping the NST
tests for TLSv1.3 since that's not currently handled.

22 months agoUse copyin32() to fetch a faulting instruction rather than short-circuit it
miod [Fri, 6 Jan 2023 19:23:53 +0000 (19:23 +0000)]
Use copyin32() to fetch a faulting instruction rather than short-circuit it
with a comment saying that we really ought to use copyin* here.

22 months agoOops, forgot to cvs rm
miod [Fri, 6 Jan 2023 19:12:12 +0000 (19:12 +0000)]
Oops, forgot to cvs rm

22 months agoRemove copystr(9), unless used internally by copy{in,out}str.
miod [Fri, 6 Jan 2023 19:10:18 +0000 (19:10 +0000)]
Remove copystr(9), unless used internally by copy{in,out}str.

22 months agoReplace last user of copystr() with strlcpy(). NFCI
miod [Fri, 6 Jan 2023 19:08:36 +0000 (19:08 +0000)]
Replace last user of copystr() with strlcpy(). NFCI

22 months agoRemove no longer needed and quite worthless header.
miod [Fri, 6 Jan 2023 19:07:17 +0000 (19:07 +0000)]
Remove no longer needed and quite worthless header.

22 months agoRemove unused local variables as well as the dependency on <machine/nvm.h>.
miod [Fri, 6 Jan 2023 19:05:46 +0000 (19:05 +0000)]
Remove unused local variables as well as the dependency on <machine/nvm.h>.

22 months agoPF_ANCHOR_STACK_MAX is insufficient protection against stack overflow.
sashan [Fri, 6 Jan 2023 17:44:33 +0000 (17:44 +0000)]
PF_ANCHOR_STACK_MAX is insufficient protection against stack overflow.
On amd64 stack overflows for anchor rule with depth ~30. The tricky
thing is the 'safe' depth varies depending on kind of packet processed
by pf_match_rule(). For example for local outbound TCP packet stack
overflows when recursion if pf_match_rule() reaches depth 24.

Instead of lowering PF_ANCHOR_STACK_MAX to 20 and hoping it will
be enough on all platforms and for all packets I'd like to stop
calling pf_match_rule() recursively. This commit brings back
pf_anchor_stackframe array we used to have back in 2017. It also
revives patrick@'s idea to pre-allocate stack frame arrays
from per-cpu.

OK kn@

22 months agoRework the main <-> parser/filemode communication protocol a bit.
claudio [Fri, 6 Jan 2023 16:06:43 +0000 (16:06 +0000)]
Rework the main <-> parser/filemode communication protocol a bit.

Swap repo_id and filename to simplify the code in parser.c. In filemode
both repo_id and filename are ignored.
Additionally do not errx() in case of unknown file types. Instead send back
enough info that the code can move on.

OK tb@

22 months agoClean up struct nd_opts, use nd6_options() function local variables
kn [Fri, 6 Jan 2023 14:35:34 +0000 (14:35 +0000)]
Clean up struct nd_opts, use nd6_options() function local variables

nd_opts_search is really the next option, so call it next_opt.

nd_opts_done == 1 means next_opt == NULL, i.e. no more option to handle,
so zap the former and use the latter to stop.

Finally drop the useless struct members, all under _KERNEL.

OK claudio

22 months agoInline nd6_option() helper, remove indirections
kn [Fri, 6 Jan 2023 14:32:55 +0000 (14:32 +0000)]
Inline nd6_option() helper, remove indirections

Move the function body into the while loop, merge identical variables,
pull the `invalid' label out of the loop and straighten `skip' into the
`skip1' label.

Merging nd6_option() into nd6_options() is now much clearer after the
previous clean up.

nd_opts_{search,last,done} are now clearly "private" to n6_options() and
can be cleaned up from struct nd_opts next.

OK claudio

22 months agoClarify nd6_option() return semantics
kn [Fri, 6 Jan 2023 14:29:47 +0000 (14:29 +0000)]
Clarify nd6_option() return semantics

nd_opts_last is set only once in nd6_options() during struct init and
guaranteed non-NULL as it is set to the function's argument *opt which
is passed in as (struct_ptr + 1) in both callers.

nd6_option(), the internal helper, returns a pointer to the next option
or NULL, which means either "no option, ok" or "invalid option, fail".

Failure is signaled through nd_opts_last being NULL after nd6_option()
returned, which only happens if nd6_option() zeroed the whole *ndopts.

Move the two cases under mnemonic labels and zap the now obviously
redundant bzero() call in nd6_options().

OK claudio

22 months agoSimplify nd6_options() initialise logic
kn [Fri, 6 Jan 2023 14:24:36 +0000 (14:24 +0000)]
Simplify nd6_options() initialise logic

nd_opts_{search,last,done} are exlusively used in the internal option
handling machinery;  the only two nd6_options() callers only use
nd_opts_{src,tgt}_lladdr.

nd6_options() always zeroes and initialises the caller's struct nd_opts.
If icmp6len is zero, i.e. if there are no ICMP6 header options left,
everything inside *ndopts is zero, except nd_opts_done=1 which is not
used by the callers.

Set the internal nd_opts_{search,last,done} members only when needed.

OK claudio

22 months agoMerge common code into new nd6_dad_destroy()
kn [Fri, 6 Jan 2023 14:17:15 +0000 (14:17 +0000)]
Merge common code into new nd6_dad_destroy()

The current code wrt. stopping DAD for and removing a particular IP from
the list is flawed.

Introduce a single nd6_dad_destroy() to the cleanup, so that there's
only one place to fix.

This is just a mechanical deduplication without significant behaviour
change;  in case a duplicated address was found, RTM_CHGADDRATTR now goes
out before cleanup, which should be no problem.

The nd6_dad_create() pendant could be done as well, but the end of
nd6_dad_start() is currently the only place where a new IP/DAD entry is
set up, so little gain besides function name symmetry.

OK claudio

22 months agosync with rpki-client 'more dastardly white spaces' commit
tb [Fri, 6 Jan 2023 13:26:57 +0000 (13:26 +0000)]
sync with rpki-client 'more dastardly white spaces' commit

22 months agomore dastardly white spaces
deraadt [Fri, 6 Jan 2023 13:22:00 +0000 (13:22 +0000)]
more dastardly white spaces

22 months agoZap trailing tabs
tb [Fri, 6 Jan 2023 13:19:43 +0000 (13:19 +0000)]
Zap trailing tabs

22 months agoWhen OpenSSL is not available, skip parts of percent test that require it.
dtucker [Fri, 6 Jan 2023 12:33:33 +0000 (12:33 +0000)]
When OpenSSL is not available, skip parts of percent test that require it.
Based on github pr#368 from ren mingshuai.

22 months agoSave debug logs from ssh for debugging purposes.
dtucker [Fri, 6 Jan 2023 08:50:33 +0000 (08:50 +0000)]
Save debug logs from ssh for debugging purposes.

22 months agotweak previous; ok djm
jmc [Fri, 6 Jan 2023 08:44:11 +0000 (08:44 +0000)]
tweak previous; ok djm

22 months agoregression test for ChannelTimeout
djm [Fri, 6 Jan 2023 08:07:39 +0000 (08:07 +0000)]
regression test for ChannelTimeout

22 months agofix typo in verbose logging
djm [Fri, 6 Jan 2023 07:18:18 +0000 (07:18 +0000)]
fix typo in verbose logging

22 months agoIf a pane is killed, cancel reading from the file. GitHub issue 3422.
nicm [Fri, 6 Jan 2023 07:09:27 +0000 (07:09 +0000)]
If a pane is killed, cancel reading from the file. GitHub issue 3422.

22 months agounit tests for misc.c:ptimeout_* API
djm [Fri, 6 Jan 2023 02:59:50 +0000 (02:59 +0000)]
unit tests for misc.c:ptimeout_* API

22 months agoImplement channel inactivity timeouts
djm [Fri, 6 Jan 2023 02:47:18 +0000 (02:47 +0000)]
Implement channel inactivity timeouts

This adds a sshd_config ChannelTimeouts directive that allows channels that
have not seen traffic in a configurable interval to be automatically closed.
Different timeouts may be applied to session, X11, agent and TCP forwarding
channels.

Note: this only affects channels over an opened SSH connection and not
the connection itself. Most clients close the connection when their channels
go away, with a notable exception being ssh(1) in multiplexing mode.

ok markus dtucker

22 months agoAdd channel_set_xtype()
djm [Fri, 6 Jan 2023 02:42:34 +0000 (02:42 +0000)]
Add channel_set_xtype()

This sets an "extended" channel type after channel creation (e.g.
"session:subsystem:sftp") that will be used for setting channel inactivity
timeouts.

ok markus dtucker

22 months agotweak channel ctype names
djm [Fri, 6 Jan 2023 02:41:49 +0000 (02:41 +0000)]
tweak channel ctype names

These are now used by sshd_config:ChannelTimeouts to specify timeouts by
channel type, so force them all to use a similar format without whitespace.

ok dtucker markus

22 months agoAdd channel_force_close()
djm [Fri, 6 Jan 2023 02:39:59 +0000 (02:39 +0000)]
Add channel_force_close()

This will forcibly close an open channel by simulating read/write errors,
draining the IO buffers and calling the detach function.

Previously the detach function was only ever called during channel garbage
collection, but there was no way to signal the user of a channel (e.g.
session.c) that its channel was being closed deliberately (vs. by the
usual state-machine logic). So this adds an extra "force" argument to the
channel cleanup callback to indicate this condition.

ok markus dtucker

22 months agoreplace manual poll/ppoll timeout math with ptimeout API
djm [Fri, 6 Jan 2023 02:38:23 +0000 (02:38 +0000)]
replace manual poll/ppoll timeout math with ptimeout API

feedback markus / ok markus dtucker

22 months agoadd ptimeout API for keeping track of poll/ppoll timeouts;
djm [Fri, 6 Jan 2023 02:37:04 +0000 (02:37 +0000)]
add ptimeout API for keeping track of poll/ppoll timeouts;
ok dtucker markus

22 months agomore consistently name pf_state * variables "st".
dlg [Thu, 5 Jan 2023 23:44:35 +0000 (23:44 +0000)]
more consistently name pf_state * variables "st".

pf_state ** are generally called "stp" now too.

discussed with and ok sashan@

22 months agodo not blow up if NOMAN is set
deraadt [Thu, 5 Jan 2023 22:17:43 +0000 (22:17 +0000)]
do not blow up if NOMAN is set

22 months agoafter a few trap.c were fixed to fault with the right access, the
deraadt [Thu, 5 Jan 2023 21:39:57 +0000 (21:39 +0000)]
after a few trap.c were fixed to fault with the right access, the
signal trampoline can now be PROT_EXEC (without PROT_READ) everywhere
ok kettenis

22 months agoThe access type for a prefetch abort should not include PROT_READ,
kettenis [Thu, 5 Jan 2023 20:35:44 +0000 (20:35 +0000)]
The access type for a prefetch abort should not include PROT_READ,
otherwise faults on executable pages mapped only as PROT_EXEC will
not work.

ok deraadt@

22 months agoAdd a dummy --no-execute-only option for compatibility with ld.lld.
kettenis [Thu, 5 Jan 2023 18:55:04 +0000 (18:55 +0000)]
Add a dummy --no-execute-only option for compatibility with ld.lld.
This will allow ports people to sprinkle -Wl,--no-execute-only across the
ports tree when necessary without having to distinguish between ld.bfd and
ld.lld arcitectures.

ok deraadt@, sthen@

22 months agopfctl fails to add addresses to undefined/inactive table
sashan [Thu, 5 Jan 2023 10:06:58 +0000 (10:06 +0000)]
pfctl fails to add addresses to undefined/inactive table

pfr_add_tables() function must set PFR_TFLAG_ACTIVE flag
to table which is attached to rule. This will then allow
pfr_add_addrs() to populate the table with addresses.

without this pair of pfctl(8) commands fails as follows:
    # echo 'pass from <foo> to any' |pfctl -f -
    # pfctl -t foo -T add 192.168.1.0/24
    pfctl: Table does not exist

OK mbuhl@

22 months agosuppress "Connection closed" message when in quiet mode
djm [Thu, 5 Jan 2023 05:49:13 +0000 (05:49 +0000)]
suppress "Connection closed" message when in quiet mode

22 months agoRewrite BN_rshift()
jsing [Thu, 5 Jan 2023 04:51:13 +0000 (04:51 +0000)]
Rewrite BN_rshift()

This improves readability and eliminates special handling for various
cases, making the code cleaner and closer to constant time.

Basic benchmarking shows a performance gain on modern 64 bit architectures,
while there is a decrease on legacy 32 bit architectures (i386),
particularly for the zero bit shift case (which is now handled in the
same code path).

ok tb@

22 months agoAdd additional shift benchmarks that are useful on BN_BITS2 == 32 platforms
jsing [Thu, 5 Jan 2023 04:44:20 +0000 (04:44 +0000)]
Add additional shift benchmarks that are useful on BN_BITS2 == 32 platforms

22 months agoMake free_chunks() return 'const struct chunk *' since we don't
krw [Thu, 5 Jan 2023 00:19:53 +0000 (00:19 +0000)]
Make free_chunks() return 'const struct chunk *' since we don't
modify chunks outside of free_chunks(). Adjust local variables taking
the return value as needed.

No intentional functional change.

22 months agoDelete remnants of removed "diff -l" option.
millert [Thu, 5 Jan 2023 00:00:44 +0000 (00:00 +0000)]
Delete remnants of removed "diff -l" option.
From Nathan Houghton

22 months agoCopy bytes from the_banana[] rather than banana()
tb [Wed, 4 Jan 2023 22:48:57 +0000 (22:48 +0000)]
Copy bytes from the_banana[] rather than banana()

Fixes test failure due to segfault seen on arm64 with xonly snap.

ok djm

22 months agoThe access type for an instruction storage interrupt should not
kettenis [Wed, 4 Jan 2023 22:13:43 +0000 (22:13 +0000)]
The access type for an instruction storage interrupt should not
include PROT_READ, otherwise faults on executable pages mapped only as
PORT_EXEC will not work.

ok deraadt@

22 months agoUse 'const struct disklabel *' parameters where the disklabel is
krw [Wed, 4 Jan 2023 21:08:08 +0000 (21:08 +0000)]
Use 'const struct disklabel *' parameters where the disklabel is
not altered. And 'const struct partition *' for pointers into
newly const disklabels.

No intentional functional change.

22 months agominor text shuffle, for clarity; ok millert
jmc [Wed, 4 Jan 2023 19:12:34 +0000 (19:12 +0000)]
minor text shuffle, for clarity; ok millert

22 months agoEliminate two unnecessary 'i' loop variables by incrementing
krw [Wed, 4 Jan 2023 18:41:25 +0000 (18:41 +0000)]
Eliminate two unnecessary 'i' loop variables by incrementing
the pointer instead.

No intentional functional change.

22 months agoPrint RRDP serial + ID if nothing changed
job [Wed, 4 Jan 2023 16:51:34 +0000 (16:51 +0000)]
Print RRDP serial + ID if nothing changed

OK tb@

22 months agoImplement strscpy() and implement strscpy_pad() on top of that. Fixes the
kettenis [Wed, 4 Jan 2023 15:48:00 +0000 (15:48 +0000)]
Implement strscpy() and implement strscpy_pad() on top of that.  Fixes the
return value in case of truncation.

ok jsg@

22 months agoReplace p_fstype to/from FS_UNUSED dances around invocations of
krw [Wed, 4 Jan 2023 15:18:46 +0000 (15:18 +0000)]
Replace p_fstype to/from FS_UNUSED dances around invocations of
free_chunks() with a parameter that names the partition to treat
as FS_UNUSED when building the list of free space chunks. With -1
indicating that no partition should be ignored.

Simplifies code and enables further simplifications and a raft
of const'ifications.

No intentional functional change. Regress still happy.
SUN_CYLCHECK, SUN_AAT0 and D_VENDOR still happy.

22 months agoEduardo Horvath agreed to rescind clause 3 and 4 in
jsg [Wed, 4 Jan 2023 14:58:04 +0000 (14:58 +0000)]
Eduardo Horvath agreed to rescind clause 3 and 4 in
NetBSD fgen.1 rev 1.9 cpu_in_cksum.S rev 1.2

https://mail-index.netbsd.org/source-changes/2009/10/19/msg002130.html

22 months agoChristos Zoulas removed his name from advertising clauses and copyrights
jsg [Wed, 4 Jan 2023 14:42:46 +0000 (14:42 +0000)]
Christos Zoulas removed his name from advertising clauses and copyrights
of some files in NetBSD.  Make the same changes here.

https://mail-index.netbsd.org/source-changes/2017/06/03/msg084953.html
https://mail-index.netbsd.org/source-changes/2017/06/03/msg084955.html
https://mail-index.netbsd.org/source-changes/2019/12/02/msg111431.html
https://mail-index.netbsd.org/source-changes/2019/12/02/msg111432.html

22 months agoAdjust open policy integration test to the change of config in bgpd.
claudio [Wed, 4 Jan 2023 14:34:50 +0000 (14:34 +0000)]
Adjust open policy integration test to the change of config in bgpd.

22 months agoAdd a per eBGP session role to the config.
claudio [Wed, 4 Jan 2023 14:33:30 +0000 (14:33 +0000)]
Add a per eBGP session role to the config.

This somewhat replaces the RFC 9234 open policy role. This is done because
ASPA requires the same role to be present to properly validate paths.
For iBGP sessions the role is forced to ROLE_NONE. If no role is set on
an ebgp session then 'announce policy' is forced to 'no'.
Also make sure the the role capability is only added if the role is set.
OK tb@

22 months agoThe redirectchain test actually works again. The test servr fixed the
claudio [Wed, 4 Jan 2023 14:27:00 +0000 (14:27 +0000)]
The redirectchain test actually works again. The test servr fixed the
redirect location to be https.

22 months agoWhen building this regress test I copied a bad UUID from some other
claudio [Wed, 4 Jan 2023 14:26:08 +0000 (14:26 +0000)]
When building this regress test I copied a bad UUID from some other
RRDP file and so a few files have bad unique ids, fix them up to be valid.

22 months agoValidate the session_id to be a real UUID.
claudio [Wed, 4 Jan 2023 14:22:43 +0000 (14:22 +0000)]
Validate the session_id to be a real UUID.

RFC 8182 requires the session_id to be a version 4 random UUID (using
variant 1). Now checking the version and variant is currently disabled
because there is at least one CA with a session_id that is all random
and therefor the version check triggers there.
Joint work with job@. OK job@, tb@

22 months agoremove unused version of ncr53cxxx.c
jsg [Wed, 4 Jan 2023 13:08:23 +0000 (13:08 +0000)]
remove unused version of ncr53cxxx.c
ok deraadt@ miod@

22 months agoexperiments for --execute-only on arm64 and riscv64 are going well,
deraadt [Wed, 4 Jan 2023 13:01:46 +0000 (13:01 +0000)]
experiments for --execute-only on arm64 and riscv64 are going well,
which will prompt making that the default.  That means efiboot, which
build in a different way, must disable the link option.
ok kettenis

22 months agoChristos Zoulas agreed to rescind clause 3 and 4 in
jsg [Wed, 4 Jan 2023 13:00:11 +0000 (13:00 +0000)]
Christos Zoulas agreed to rescind clause 3 and 4 in
NetBSD fsck.8 rev 1.35 fsutil.h rev 1.14 pathnames.h rev 1.2
netgroup_mkdb.8 rev 1.9 netgroup_mkdb.c rev 1.18 str.c rev 1.7
str.h rev 1.4 rdate.8 rev 1.11 rdate.c rev 1.19 extern.h rev 1.14
getnetgrent.c rev 1.41 netgroup.h rev 1.10
fparseln.3 rev 1.4 fparseln.c rev 1.10

our stringlist.c/stringlist.h are derived from getnetgrent.c
rfc868time.c from rdate.c
newfs/pathnames.h from fsck/pathnames.h

https://mail-index.netbsd.org/source-changes/2009/10/21/msg002182.html
Not all files are covered as some had copyright assigned to TNF in 1998.

22 months agougly white space
deraadt [Wed, 4 Jan 2023 12:53:38 +0000 (12:53 +0000)]
ugly white space

22 months agoLeo Weppelman agreed to rescind clause 3 and 4 in
jsg [Wed, 4 Jan 2023 10:59:34 +0000 (10:59 +0000)]
Leo Weppelman agreed to rescind clause 3 and 4 in
NetBSD kvm_dump.3 rev 1.15 kcore.h rev 1.3

https://mail-index.netbsd.org/source-changes/2009/10/20/msg002169.html

22 months agomove the pf_state_tree_id type from pfvar.h to pfvar_priv.h.
dlg [Wed, 4 Jan 2023 10:31:55 +0000 (10:31 +0000)]
move the pf_state_tree_id type from pfvar.h to pfvar_priv.h.

the pf_state_tree_id type is private to the kernel.

while here, move it from being an RB tree to an RBT tree. this saves
about 12k in pf.o on amd64.

ok sashan@

22 months agoMichael L. Hitch agreed to rescind clause 3 and 4 in
jsg [Wed, 4 Jan 2023 10:05:44 +0000 (10:05 +0000)]
Michael L. Hitch agreed to rescind clause 3 and 4 in
NetBSD ncr53cxxx.c rev 1.16 osiop.ss rev 1.2

https://mail-index.netbsd.org/source-changes/2009/10/21/msg002215.html

22 months agoGordon W. Ross and Bill Studenmund agreed to rescind clause 3 and 4 in
jsg [Wed, 4 Jan 2023 09:34:26 +0000 (09:34 +0000)]
Gordon W. Ross and Bill Studenmund agreed to rescind clause 3 and 4 in
NetBSD zs.c rev 1.49

https://mail-index.netbsd.org/source-changes/2009/10/27/msg002419.html

22 months agoGordon W. Ross agreed to rescind clause 3 and 4 in
jsg [Wed, 4 Jan 2023 09:24:14 +0000 (09:24 +0000)]
Gordon W. Ross agreed to rescind clause 3 and 4 in
NetBSD dev_net.c rev 1.15 bootparam.c rev 1.19

https://mail-index.netbsd.org/source-changes/2009/10/21/msg002212.html

22 months ago- use Fl instead of Ar for print0; from josiah frentsos
jmc [Wed, 4 Jan 2023 07:33:00 +0000 (07:33 +0000)]
- use Fl instead of Ar for print0; from josiah frentsos
- while here, describe it as a primary rather than an option

22 months agoIchiro FUKUHARA agreed to rescind clause 3 and 4 in
jsg [Wed, 4 Jan 2023 07:06:08 +0000 (07:06 +0000)]
Ichiro FUKUHARA agreed to rescind clause 3 and 4 in
NetBSD if_ath_cardbus.c rev 1.36

https://mail-index.netbsd.org/source-changes/2009/10/21/msg002189.html

22 months agoChuck Cranor rescinded the advertising clause of uvm_mmap.c in
jsg [Wed, 4 Jan 2023 06:33:33 +0000 (06:33 +0000)]
Chuck Cranor rescinded the advertising clause of uvm_mmap.c in
NetBSD rev 1.134 and confirmed with Mike Hibler that the University of
Utah would do the same.

https://mail-index.netbsd.org/source-changes/2011/02/02/msg018021.html

ok deraadt@

22 months agofix a comment, no functional change.
dlg [Wed, 4 Jan 2023 03:47:10 +0000 (03:47 +0000)]
fix a comment, no functional change.

22 months agoTypos in vmd error message. No functional change.
dv [Wed, 4 Jan 2023 02:19:19 +0000 (02:19 +0000)]
Typos in vmd error message. No functional change.

22 months agomove the pf_state_tree rb tree type from pfvar.h to pfvar_priv.h
dlg [Wed, 4 Jan 2023 02:00:49 +0000 (02:00 +0000)]
move the pf_state_tree rb tree type from pfvar.h to pfvar_priv.h

the pf_state_tree types are kernel private, and are not used by
userland. make build agrees with me.

while here, move the pf_state_tree from the RB macros to the RBT
functions. this shaves about 13k off pf.o on amd64.

ok sashan@

22 months agoShuffle code a bit to eliminate need for inner loop
krw [Wed, 4 Jan 2023 01:22:48 +0000 (01:22 +0000)]
Shuffle code a bit to eliminate need for inner loop
variable 'j' in editor_allocspace().

No intentional functional change. Regress still happy.

22 months agoon sh/landisk, ELF binaries are currently unpadded between text and rodata.
deraadt [Wed, 4 Jan 2023 00:18:50 +0000 (00:18 +0000)]
on sh/landisk, ELF binaries are currently unpadded between text and rodata.
Comment says because no nx support.  Well, we'll soon be able to something
like nx, and need the rodata to not be mingled into the same pages as
executable, so enforce padding.
with kettenis, ok miod

22 months agoNo need to call editor_countfree() when displaying all the free
krw [Tue, 3 Jan 2023 23:27:03 +0000 (23:27 +0000)]
No need to call editor_countfree() when displaying all the free
chunks in the 'r' editor command. Just add up chunks as they are
displayed. Eliminates pointless second invocation of
free_chunks().

Increment the chunk pointer rather than using iteration
variable + indexing.

No intentional functional change.

22 months agodo not mention dhclient as a dhcp route message sender
deraadt [Tue, 3 Jan 2023 20:58:05 +0000 (20:58 +0000)]
do not mention dhclient as a dhcp route message sender

22 months agoPrint the RRDP Session ID and Serial in verbose mode
job [Tue, 3 Jan 2023 18:19:12 +0000 (18:19 +0000)]
Print the RRDP Session ID and Serial in verbose mode

OK tb@ claudio@

22 months agoPoll battery sensors less frequently.
anton [Tue, 3 Jan 2023 15:52:02 +0000 (15:52 +0000)]
Poll battery sensors less frequently.