Link [ NetBSD | NetBSD OpenGrok source search | PR fulltext-search | Summary of daily snapshot builds | history of daily build result | pkgsrc commit viewer ]


   
        usage: [branch:branch] [user:user] [path@revision] keyword [... [-excludekeyword [...]]] (e.g. branch:MAIN sys/arch/arm, if_wm.c@1.234 )




switch to index mode

recent branches: MAIN (2h)  netbsd-8 (5d)  netbsd-10 (6d)  netbsd-9 (12d)  thorpej-ifq (176d)  thorpej-altq-separation (178d) 

2024-05-10 17:09:34 UTC Now

2023-05-04 11:30:25 UTC MAIN commitmail json YAML

2023-05-04 09:20:01 UTC MAIN commitmail json YAML

zz9k.4: clean up manual page

New sentence, new line; spelling, duplicate words.

(rillig)

2023-05-04 00:02:10 UTC MAIN commitmail json YAML

t_fexecve.sh: fix head() function definitions of test cases

(gutteridge)

2023-05-03 13:49:30 UTC MAIN commitmail json YAML

Driver for the MNT ZZ9000 Zorro board. Submitted by Alain Runa.

It was formerly known as mntzz, which Alain released three years ago.
Since then, the ZZ9000 had several firmware updates which changed some
hardware interface details rendering the former driver non functional in some
aspects. Also the audio card plug-in ZZ9000AX became available from MNT
Research. Considering the major rewrite of the driver in some areas he
decided to rename it to zz9k(9). The driver consists of several sub-drivers
each addressing different functionality of the MNT ZZ9000 & ZZ9000AX combo
card.

zz9k* is the main card driver and need to be enabled if any of the sub-driver
is enabled. zz9k on its own is not very useful, it only provides a common
zz9kbus for the other sub-drivers to connect to, so only enable it if one of
the zz9k sub-drivers are enabled.
zzfb* represents the graphics driver for the boot console and the dumb
framebuffer for X11 based on WSCONS. ZZFB_CONSOLE option enables the ZZ9000
to become the boot console.
zz* represents the ethernet interface of the ZZ9000. It basically works but
is considered experimental.
zzax* represents the ZZ9000AX audio card driver, audio* attaches to it to
provide audio output and input functionality. The driver is not functional
yet.
zzusb* represents the ZZ9000AX usb driver. It was not implemented yet and
probably never will.

(phx)

2023-05-02 23:08:59 UTC MAIN commitmail json YAML

Cleanup previous: Try new bindings first, document old with DTCOMPAT, KNF

(jmcneill)

2023-05-02 21:31:57 UTC netbsd-10 commitmail json YAML

Pull up following revision(s) (requested by mrg in ticket #154):

sys/arch/arm/dts/rk3328-crypto.dtsi: revision 1.1
sys/arch/arm/dts/rk3328-rock64.dts: revision 1.8
sys/arch/arm/rockchip/rk3328_cru.c: revision 1.10
sys/arch/arm/rockchip/rk_v1crypto.c: revision 1.11

enable rkv1crypto on rock64.

this comes from upstream d1152bc533c941f7e267bf53d344cee510ea2808.
(i tried to make this be in rk3328.dtsi so all rk3328 boards would
benefit, but it doesn't work, and this is the only one have to test.)

adjust rkv1crypto to support a per-platform clocks setup.

(martin)

2023-05-02 17:54:03 UTC netbsd-10 commitmail json YAML

2023-05-02 17:52:39 UTC netbsd-10 commitmail json YAML

Pull up following revision(s) (requested by jmcneill in ticket #155):

sys/arch/arm/ep93xx/ep93xx_intr.c: revision 1.28
sys/arch/arm/ep93xx/ep93xxvar.h: revision 1.7
sys/arch/evbarm/tsarm/tsarm_machdep.c: revision 1.36

TS7200: Defer event counter registration until after evcnt is initialized

Patch from Lloyd Parkes in PR kern/57386

(martin)

2023-05-02 17:39:55 UTC netbsd-10 commitmail json YAML

Pull up following revision(s) (requested by mlelstv in ticket #153):

sys/dev/pad/pad.c: revision 1.80
sys/dev/pad/pad.c: revision 1.81
sys/dev/pad/pad.c: revision 1.82
sys/dev/pad/pad.c: revision 1.79
sys/dev/pad/padvar.h: revision 1.17

Pace I/O timing to match the audio interface.

Enable interrupts while copying buffers.

Write slinear_le 16bit samples, independent from platform and
AUDIO_INTERNAL_BITS.

No longer use AUDIO_INTERNAL_BITS but rely on passed audio format.
Don't overflow when scaling 32bit samples.

(martin)

2023-05-02 17:27:31 UTC netbsd-8 commitmail json YAML

2023-05-02 17:26:35 UTC netbsd-8 commitmail json YAML

Pull up following revision(s) (requested by mlelstv in ticket #1822):

lib/libc/locale/newlocale.c: revision 1.4

Fix parsing a locale string with multiple components.
Also check for truncation of a long locale string.

(martin)

2023-05-02 17:25:54 UTC netbsd-9 commitmail json YAML

2023-05-02 17:24:55 UTC netbsd-9 commitmail json YAML

Pull up following revision(s) (requested by mlelstv in ticket #1630):

lib/libc/locale/newlocale.c: revision 1.4

Fix parsing a locale string with multiple components.
Also check for truncation of a long locale string.

(martin)

2023-05-02 17:23:33 UTC netbsd-10 commitmail json YAML

Pull up following revision(s) (requested by mlelstv in ticket #152):

lib/libc/locale/newlocale.c: revision 1.4

Fix parsing a locale string with multiple components.
Also check for truncation of a long locale string.

(martin)

2023-05-02 10:18:54 UTC MAIN commitmail json YAML

apparently the 'ahb' and 'ths' clocks were renamed to 'bus' and 'mod' in the
fdt at some point, so look for those as well
with this my pinebook's sensors work again

(macallan)

2023-05-02 09:49:33 UTC MAIN commitmail json YAML

TS7200: Defer event counter registration until after evcnt is initialized

Patch from Lloyd Parkes <lloyd@must-have-coffee.gen.nz> in PR# kern/57386

(jmcneill)

2023-05-02 00:11:27 UTC MAIN commitmail json YAML

t_expr.sh: fix naming of head() of lang test case

(gutteridge)

2023-05-01 20:22:18 UTC MAIN commitmail json YAML

Create the INFODIRFILE if it does not exist, so that we can take a lock
on it. Hopefully fixes a race condition where two parallel makes attempt
to create the file at the same time.

(christos)

2023-05-01 16:35:47 UTC MAIN commitmail json YAML

Don't overflow when scaling 32bit samples.

(mlelstv)

2023-05-01 12:18:08 UTC MAIN commitmail json YAML

mutex(9): Write comments in terms of ordering semantics.

Phrasing things in terms of implementation details like `acquiring
and locking cache lines' both suggests a particular cache coherency
protocol, paints an incomplete picture for more involved protocols,
and doesn't really help to prove theorems the way ordering relations
do.

No functional change intended.

(riastradh)

2023-05-01 12:17:56 UTC MAIN commitmail json YAML

mutex(9): Omit needless membar_consumer.

In practical terms, this is not necessary because MUTEX_SET_WAITERS
already issues MUTEX_MEMBAR_ENTER, which on all architectures is a
sequential consistency barrier, i.e., read/write-before-read/write,
subsuming membar_consumer.

In theoretical terms, MUTEX_MEMBAR_ENTER might imply only
write-before-read/write, so one might imagine that the
read-before-read ordering of membar_consumer _could_ be necessary.
However, the memory operations that are significant here are:

1. load owner := mtx->mtx_owner
2. store mtx->mtx_owner := owner | MUTEX_BIT_WAITERS
3. load owner->l_cpu->ci_curlwp to test if equal to owner

(1) is program-before (2) and at the same memory location,
mtx->mtx_owner, so (1) happens-before (2).

And (2) is separated in program order by MUTEX_MEMBAR_ENTER from (3),
so (2) happens-before (3).

So even if the membar_consumer were intended to guarantee that (1)
happens-before (3), it's not necessary, because we can already prove
it from MUTEX_MEMBAR_ENTER.

But actually, we don't really need (1) happens-before (3), exactly;
what we really need is (2) happens-before (3), since this is a little
manifestation of Dekker's algorithm between cpu_switchto and
mutex_exit, where each CPU sets one flag and must ensure it is
visible to the other CPUs before testing the other flag -- one flag
here is the MUTEX_BIT_WAITERS bit, and the other `flag' here is the
condition owner->l_cpu->ci_curlwp == owner; the corresponding logic,
in cpu_switchto, is:

1'. store owner->l_cpu->ci_curlwp := owner
2'. load mtx->mtx_owner to test if MUTEX_BIT_WAITERS set

(riastradh)

2023-05-01 11:57:53 UTC MAIN commitmail json YAML

s/betwen/between/ and s/singed/signed/.

(andvar)

2023-05-01 09:41:55 UTC MAIN commitmail json YAML

drm: KASSERT(A && B) -> KASSERT(A); KASSERT(B)

(riastradh)

2023-05-01 09:03:19 UTC MAIN commitmail json YAML

xen_clock(4): Sprinkle dtrace probes.

(riastradh)

2023-05-01 05:12:44 UTC MAIN commitmail json YAML

Default PROC_MACHINE_ARCH to machine_arch and use this for magic
symlinks to resolve "@machine_arch".

This keeps behaviour of magic symlinks and 'uname -p' output the same.
Fixes PR 57320.

(mlelstv)

2023-04-30 22:33:57 UTC MAIN commitmail json YAML

domains: re-gen with fix.

(nikita)

2023-04-30 22:32:51 UTC MAIN commitmail json YAML

update-domains: replace missed html.

(nikita)

2023-04-30 22:08:42 UTC MAIN commitmail json YAML

domains: re-gen

(nikita)

2023-04-30 22:08:14 UTC MAIN commitmail json YAML

fix update-domains rule.

(nikita)

2023-04-30 14:20:23 UTC MAIN commitmail json YAML

codec translates to 16bit slinear_le, not the internal format.

(mlelstv)

2023-04-30 10:58:53 UTC netbsd-10 commitmail json YAML

2023-04-30 10:58:07 UTC netbsd-10 commitmail json YAML

Pull up following revision(s) (requested by jmcneill in ticket #151):

sys/dev/sdmmc/sdmmc_mem.c: revision 1.75

sdmmc: Only check chipset WP status for SD cards.

The sdmmc_chip_write_protect callback returns the write protect switch
status from the controller (SDWP#). This signal does not exist for eMMC;
instead, write protect is signaled using card registers (CSD). So lets
skip asking the chipset for WP status on eMMC cards for each write
request.

(martin)

2023-04-30 08:46:33 UTC MAIN commitmail json YAML

sys/sdt.h: Omit spurious trailing semicolon in DTRACE_PROBE*.

(riastradh)

2023-04-30 08:46:20 UTC MAIN commitmail json YAML

sys/sdt.h: Nix needless SDT_VAR_DECL.

Previously introduced as a provisional build fix, its need has been
obviated by making SDT_PROBE* do __USE on the arguments in builds
without KDTRACE_HOOKS.

(riastradh)

2023-04-30 08:46:11 UTC MAIN commitmail json YAML

kern/vfs_subr.c: Revert previous build fixes, no longer needed.

SDT_PROBE* will now DTRT here.

(riastradh)

2023-04-30 08:46:03 UTC MAIN commitmail json YAML

sys/sdt.h: Make sure SDT_PROBE*, DTRACE_PROBE* compile the arguments.

This way there's no need to fuss around with conditional declarations
and assignments in the callers to avoid `variable set but not used'
errors in builds without KDTRACE_HOOKS.

(riastradh)

2023-04-30 08:45:48 UTC MAIN commitmail json YAML

sys/cdefs.h: New __MACROUSE for macros to type-check arguments.

This way, if there's a macro F(x) with a conditional definition --
e.g., conditional on DIAGNOSTIC or KDTRACE_HOOKS -- it can do
__MACROUSE(x) in the definition that's supposed to compile away,
without triggering `variable set but not used' errors, while still
catching type errors in the expression x.  But there's no cost or
side effects incurred in the generated code because the value is not
computed.

This should be the same as __USE, but I haven't figured out how to
make it work for both bit fields (which are likely to appear in macro
arguments) and aggregates (structs/unions, which are likely to appear
as variable declarations), so for now we use two separate macros.

(riastradh)

2023-04-30 08:45:39 UTC MAIN commitmail json YAML

sys/sdt.h: Whitespace cleanup (and internal macro semicolon tidying).

No functional change intended.

(riastradh)

2023-04-30 08:45:30 UTC MAIN commitmail json YAML

sys/sdt.h: Properly parenthesize macro arguments.

(riastradh)

2023-04-30 08:45:19 UTC MAIN commitmail json YAML

sys/sdt.h: Nix trailing whitspace.

No functional change intended.

(riastradh)

2023-04-30 08:35:53 UTC MAIN commitmail json YAML

xhci doesn't like 80 packets per USB interval, but 40 seems to be fine
for xhci (and ehci).

(mlelstv)

2023-04-29 23:30:18 UTC MAIN commitmail json YAML

Fix builds (hopefully) when DTRACE hooks are not included.

(kre)

2023-04-29 21:37:07 UTC MAIN commitmail json YAML

pthread_create(3): minor markup tweaks

(uwe)

2023-04-29 20:51:45 UTC MAIN commitmail json YAML

2023-04-29 20:31:59 UTC MAIN commitmail json YAML

Like everywhere else make sure DESTDIR is not empty before using it.
Otherwise if it is empty before we were adding an optargless -d, which
ended up using the next argument (a -Isomething) after the recent change
to xlint.c related to sysroot. This broke using the native tools make
with the cross toolchain (for example typing make in /usr/src/bin/ls)
to build and install a single program.

(christos)

2023-04-29 13:21:31 UTC MAIN commitmail json YAML

sdmmc: Only check chipset WP status for SD cards.

The sdmmc_chip_write_protect callback returns the write protect switch
status from the controller (SDWP#). This signal does not exist for eMMC;
instead, write protect is signaled using card registers (CSD). So lets
skip asking the chipset for WP status on eMMC cards for each write
request.

(jmcneill)

2023-04-29 13:00:17 UTC MAIN commitmail json YAML

dk(4): Rename label for consistency.  No functional change intended.

(riastradh)

2023-04-29 10:16:24 UTC MAIN commitmail json YAML

2023-04-29 10:07:30 UTC MAIN commitmail json YAML

vfs: Sprinkle dtrace probes into syncer.

(riastradh)

2023-04-29 10:07:22 UTC MAIN commitmail json YAML

vfs(9): Move SDT_PROVIDER_DEFINE(vfs) from vfs_cache.c to vfs_init.c.

Not a namecache-specific thing.

(riastradh)

2023-04-29 10:07:13 UTC MAIN commitmail json YAML

kern/vfs_init.c: Sort includes.  No functional change intended.

(riastradh)

2023-04-29 10:07:06 UTC MAIN commitmail json YAML

sys/vnode_impl.h: Declare vfs sdt provider.

This way it can be used by more than just vfs_cache.c.

(riastradh)

2023-04-29 10:06:33 UTC MAIN commitmail json YAML

kern/vfs_subr.c: Sort includes.  No functional change intended.

(riastradh)

2023-04-29 10:01:51 UTC MAIN commitmail json YAML

Fix build after previous. m68k uses symnum instead of symidx.

(skrll)

2023-04-29 08:15:13 UTC MAIN commitmail json YAML

tmpfs: Assert no arithmetic overflow in directory node tn_size.

Need >2^57 directory entries before this is a problem.  If we created
a million per second, this would take over 4000 years.

(riastradh)

2023-04-29 08:13:27 UTC MAIN commitmail json YAML

tmpfs: Refuse sizes that overflow round_page.

Reported-by: syzbot+8dbeee84de15f86df65b@syzkaller.appspotmail.com
https://syzkaller.appspot.com/bug?id=4a27b9fe074f8d4b0afbe22969339b8dfdb157e8

(riastradh)

2023-04-29 06:34:20 UTC MAIN commitmail json YAML

kern/vfs_syscalls.c: Nix trailing whitesapce.

No functional change intended.

(riastradh)

2023-04-29 06:29:55 UTC MAIN commitmail json YAML

tmpfs: Nix trailing whitespace.  No functional change intended.

(riastradh)

2023-04-29 06:28:13 UTC MAIN commitmail json YAML

sys/vnode_impl.h: Nix trailing whitespace.

No functional change intended.

(riastradh)

2023-04-29 06:23:37 UTC MAIN commitmail json YAML

dk(4): Fix lock assertion in size increase: parent's, not wedge's.

Reported-by: syzbot+d4dc610473cacc5183dd@syzkaller.appspotmail.com
https://syzkaller.appspot.com/bug?id=e18ddae8283d6fab44cfb1ac7e3f8e791f8c0700

(riastradh)

2023-04-29 03:36:55 UTC MAIN commitmail json YAML

White space fix.

(isaki)

2023-04-29 03:17:30 UTC MAIN commitmail json YAML

m68k: Support TT(Transparent Translation) for 020/030 buserror handler.
This avoids a panic when trying badaddr() against to an address where
bus error occurs in the TT region.  Only luna68k and news68k use TT.
Discussed on port-m68k.

(isaki)

2023-04-28 22:31:38 UTC MAIN commitmail json YAML

2023-04-28 22:23:45 UTC MAIN commitmail json YAML

one more place for recently fixed typo, s/phisycal/physical/.

(andvar)

2023-04-28 16:13:12 UTC MAIN commitmail json YAML

3RDPARTY: the atf-devel mailing list was closed years ago

(gutteridge)

2023-04-28 13:09:48 UTC MAIN commitmail json YAML

tests/make: add tests for target-local variables

While here, move a test from var-scope-local.mk to parse.mk since that
test is not related to variables.

(rillig)

2023-04-28 09:56:45 UTC MAIN commitmail json YAML

Fix typo in comment

(pgoyette)

2023-04-28 07:33:57 UTC MAIN commitmail json YAML

2023-04-28 07:12:39 UTC MAIN commitmail json YAML

Don't set the clear_to_eol variable in doupdate to NULL, this was a
leftover from previous code that makes no sense and makes worms(6)
crash randomly.  Thanks to kre@ for reporting this.

(blymn)

2023-04-27 20:55:27 UTC MAIN commitmail json YAML

Unbreak creation of i386 PIEs on amd64.

Functional patch by RVP;  set lists updated accordingly.

This fixes PR toolchain/57380.

(hgutch)

2023-04-27 13:21:59 UTC MAIN commitmail json YAML

dhcpcd: Fix non INET6 builds.

Thanks to J. Hannken-Illjes for the fix.

(roy)

2023-04-27 06:30:09 UTC MAIN commitmail json YAML

Remove an unnecessary cast in a KASSERTMSG

(skrll)

2023-04-27 06:23:31 UTC MAIN commitmail json YAML

2023-04-26 22:58:09 UTC MAIN commitmail json YAML

Add a little optional colour, optionally distinguish worm heads,
and optionally randomise worm lengths.  Just exit instead of
continuing with a nonsense display if the window shrinks (and
for consistency if it grows).

Most of the ideas and code from RVP.  Bugs and man page mangling
from me.

(kre)

2023-04-26 18:42:41 UTC MAIN commitmail json YAML

gcc 13.1 is out

(wiz)

2023-04-26 18:25:02 UTC MAIN commitmail json YAML

Us daemons don't need no unions - just wait, the easy way.

(kre)

2023-04-25 20:03:40 UTC MAIN commitmail json YAML

2023-04-25 19:00:57 UTC MAIN commitmail json YAML

lint: reword message for missing declaration in header

Suggested by Christos.

(rillig)

2023-04-25 17:51:32 UTC MAIN commitmail json YAML

2023-04-25 16:17:59 UTC netbsd-10 commitmail json YAML

2023-04-25 16:15:14 UTC netbsd-10 commitmail json YAML

Pull up following revision(s) (requested by ozaki-r in ticket #150):

sys/netinet/ip_output.c: revision 1.325

Revert "Fix panic on packet sending via a route with rt_ifa of AF_LINK."

The fix is mistakenly upstreamed.

(martin)

2023-04-25 16:12:05 UTC netbsd-10 commitmail json YAML

Pull up following revision(s) (requested by kre in ticket #148):

games/worms/worms.c: revision 1.24
games/worms/worms.c: revision 1.25
games/worms/worms.c: revision 1.26
games/worms/worms.c: revision 1.27
games/worms/worms.c: revision 1.28
games/worms/worms.c: revision 1.29
games/worms/worms.6: revision 1.17

Garbage collect "char *mp" - it used to point at memory malloc()'d
to hold the termcap entry, back when worms used termcap rather than
curses, and termcap was termcap, rather that a terminfo wannabe.

This should have been removed when worms was converted to curses in
1999, but wasn't, so worms has been doing a meaningless malloc(1024)
and never using the result, ever since.

While here, since the line needed changing anyway to remove mp,
change a malloc() of a product into calloc() so it can deal with
any possible (admittedly extremely unlikely here) integer overflows.

NFCI

80 column police.

If this code were just a few chars over the limit, it might get
let off with a warning, but 214 in an 80 zone is way beyond that.
Six months loss of coding licence, and a 214000 character fine.

NFCI.

(I verified the the code was unchanged by joining the resulting
lines back into one again, and then diff'ing that line against
the original - it is identical).

When worms default delay was changed from 0, to 20ms (Oct 2020)
it lost the ability to run flat out (no sleeps) - which while not
very useful for actually observing the behaviour of various Nematoda,
can be useful when 'worms' is being used to generate cpu heat - it
turns out to be a simple tool to make all of the app itself, the
xterm it runs in (when running under X) and the X server, all more
or less continuously busy - a trivial perpetual CPU load generator.

Changing that was not a simple matter of just allowing -d 0..1000
rather than -d 1..1000 which had always been the limits on -d, as
previously, simply by excluding 0, common error checking wasn't
essential.  -djunk would return 0 which was invalid, and so an error
- - that it was invalid because 0 < 1, rather than because "junk" is not
a number wasn't material.

Now we need some slightly more elaborate error checking code for the
- -d value, and if we're going to do that, may as well do the same for
the -l and -n options, which also take numeric values.  That is, it
will no longer be possible to say:

worms -n "5 worms"

Just the number is allowed (but -d now allows a "ms" or "us" suffix).

While here, place a reasonable upper limit (depending upon the
screen size, and worm length) upon the number of worms, so they
have somewhere to go, rather than just on top of each other.

exit(1) from the errx() rather than 0, in the case that curses
initscr() fails (doesn't seem right that it should appear as a
successful run of worms, if it never managed to start).

A couple more minor 80 column violations are handled, without
further penalty, in this update (one simply vanishes, the other
is wrapped).

Note that this sounds like a lot, but it is really all just minor
internal bookkeeping updates - the only real advertised user visible
change is the ability to use -d0 which just restores that which was
the default (though it could never be set via the option) until Oct 2020
- - so really all that's happening is replacing minor functionality lost
then, while leaving the change of the default delay that that change
made, untouched.

No man page update required (that never excluded -d0).

Correct some unfortunate behaviour in extreme cases pointed out by RVP.
(Very long worms in a smallish window could result in the max number of
worms being 0...)

While here (also suggested by RVP) seed the random number generator,
also add a -S option to set the seed (note: while this is documented
in the updated man page, it does not appear in the usage message in
case of an error ... not likely to be used often enough to include there).

Also some minor improvements suggested by RVP:
delete the prototype for main()
exit curses mode before abort() (which should not happen, but...)
no need to return (->exit) after abort() as modern abort() can
never return.

In addition, check for extraneous (ignored) (non-option) args.

Check for absurdly small or big screens (the worm placement algorithm
doesn't work well for lines of columns < 3, and the abort() mentioned
above actually happens if one of those is == 1).

More flavours of worms added.

Some minor man page wording improvements.

Typo in an error message (pointed out by RVP; Thanks)

Another err message typo!  (found this one myself!!)

(martin)

2023-04-25 15:58:37 UTC netbsd-10 commitmail json YAML

src/doc/3RDPARTY@1.1905.2.2 / diff / nxr@1.1905.2.2
src/external/public-domain/tz/dist/CONTRIBUTING@1.1.1.7.2.1 / diff / nxr@1.1.1.7.2.1
src/external/public-domain/tz/dist/Makefile@1.1.1.35.2.1 / diff / nxr@1.1.1.35.2.1
src/external/public-domain/tz/dist/NEWS@1.1.1.40.2.1 / diff / nxr@1.1.1.40.2.1
src/external/public-domain/tz/dist/TZDATA_VERSION@1.32.2.1 / diff / nxr@1.32.2.1
src/external/public-domain/tz/dist/africa@1.1.1.30.2.1 / diff / nxr@1.1.1.30.2.1
src/external/public-domain/tz/dist/antarctica@1.1.1.16.2.1 / diff / nxr@1.1.1.16.2.1
src/external/public-domain/tz/dist/asia@1.7.2.1 / diff / nxr@1.7.2.1
src/external/public-domain/tz/dist/australasia@1.6.2.1 / diff / nxr@1.6.2.1
src/external/public-domain/tz/dist/backward@1.10.2.1 / diff / nxr@1.10.2.1
src/external/public-domain/tz/dist/backzone@1.1.1.25.2.1 / diff / nxr@1.1.1.25.2.1
src/external/public-domain/tz/dist/checktab.awk@1.1.1.11.2.1 / diff / nxr@1.1.1.11.2.1
src/external/public-domain/tz/dist/europe@1.1.1.36.2.1 / diff / nxr@1.1.1.36.2.1
src/external/public-domain/tz/dist/iso3166.tab@1.1.1.7.2.1 / diff / nxr@1.1.1.7.2.1
src/external/public-domain/tz/dist/leap-seconds.list@1.4.2.1 / diff / nxr@1.4.2.1
src/external/public-domain/tz/dist/leapseconds@1.4.2.1 / diff / nxr@1.4.2.1
src/external/public-domain/tz/dist/leapseconds.awk@1.1.1.12.6.1 / diff / nxr@1.1.1.12.6.1
src/external/public-domain/tz/dist/northamerica@1.1.1.32.2.1 / diff / nxr@1.1.1.32.2.1
src/external/public-domain/tz/dist/southamerica@1.1.1.22.2.1 / diff / nxr@1.1.1.22.2.1
src/external/public-domain/tz/dist/theory.html@1.1.1.17.2.1 / diff / nxr@1.1.1.17.2.1
      :
(more 3 files)
Pull up the following, requested by kre in ticket #149:

external/public-domain/tz/dist/CONTRIBUTING    up to 1.1.1.8
external/public-domain/tz/dist/Makefile        up to 1.1.1.36
external/public-domain/tz/dist/NEWS            up to 1.1.1.43
external/public-domain/tz/dist/TZDATA_VERSION  up to 1.35
external/public-domain/tz/dist/africa          up to 1.1.1.31
external/public-domain/tz/dist/antarctica      up to 1.1.1.17
external/public-domain/tz/dist/asia            up to 1.10
external/public-domain/tz/dist/australasia      up to 1.7
external/public-domain/tz/dist/backward        up to 1.11
external/public-domain/tz/dist/backzone        up to 1.1.1.26
external/public-domain/tz/dist/checktab.awk    up to 1.1.1.12
external/public-domain/tz/dist/europe          up to 1.1.1.37
external/public-domain/tz/dist/iso3166.tab      up to 1.1.1.8
external/public-domain/tz/dist/leap-seconds.list up to 1.5
external/public-domain/tz/dist/leapseconds      up to 1.5
external/public-domain/tz/dist/leapseconds.awk  up to 1.1.1.13
external/public-domain/tz/dist/northamerica    up to 1.1.1.33
external/public-domain/tz/dist/southamerica    up to 1.1.1.23
external/public-domain/tz/dist/theory.html      up to 1.1.1.18
external/public-domain/tz/dist/version          up to 1.10
external/public-domain/tz/dist/zone.tab        up to 1.1.1.25
external/public-domain/tz/dist/zone1970.tab    up to 1.1.1.26
doc/3RDPARTY (apply patch)

sync with HEAD: updated tzdata to 2023c

(martin)

2023-04-25 15:33:22 UTC netbsd-10 commitmail json YAML

Pull up following revision(s) (requested by gutteridge in ticket #147):

usr.bin/resize/resize.h: revision 1.3

resize.c: use estrdup(3) with basename(3)
basename(3) is invoked more than once on different paths. Retain the
correct name for the utility itself on error. Addresses PR bin/57355
from RVP, who provided the patch.

(martin)

2023-04-25 15:30:10 UTC netbsd-10 commitmail json YAML

Pull up following revision(s) (requested by abs in ticket #146):

lib/librefuse/fuse.h: revision 1.35

Fix incorrect test for FUSE_USE_VERSION 34
(Thanks to Mark Davies for report)

(martin)

2023-04-25 15:25:36 UTC netbsd-10 commitmail json YAML

Pull up following revision(s) (requested by simonb in ticket #145):

sbin/nvmectl/devlist.c: revision 1.6

In "devlist" mode, exit with a 0 return code if any nvme devices are
found, rather than exiting with 1 return code always.

(martin)

2023-04-25 01:48:37 UTC MAIN commitmail json YAML

tip.1: s/Mail.1/mail.1/ ("Mail" was removed in 9)

(gutteridge)

2023-04-24 20:55:53 UTC MAIN commitmail json YAML

tests/rump/modautoload: reorder -lrumpvfs_nofifofs

Make the way we spell "-lrumpvfs -lrumpvfs_nofifofs" hack consistent.
The order doesn't matter here because of --whole-archive.

(uwe)

2023-04-24 20:35:49 UTC MAIN commitmail json YAML

tests: trim down the list of LIBRUMPBASE libraries

Now that cyclic dependencies are (mostly) broken, we can drop repeated
-l instances that worked around those cycles.  Links on sun2.

(uwe)

2023-04-24 20:02:53 UTC MAIN commitmail json YAML

PR/57376: Jorge Giner: readline file completion does not quote; do the same.

(christos)

2023-04-24 19:12:33 UTC MAIN commitmail json YAML

rump_wmd(1): there is no space in -lcomponent

A couple of minor markup tweaks while here.

(uwe)

2023-04-24 18:54:22 UTC MAIN commitmail json YAML

rump_allserver: trim down the list of libraries

Now that cyclic dependencies are (mostly) broken, we can drop repeated
-l instances that worked around those cycles.  Links on sun2.

(uwe)

2023-04-24 16:32:54 UTC MAIN commitmail json YAML

Fix DEVMAP_FLAGS, patch from Nick.

(martin)

2023-04-24 13:55:45 UTC MAIN commitmail json YAML

Merge x86 boot options in x86/boot(8) and add undocumented UEFI options

We were supposed to keep the option list in x86/boot(8), x86/dosoot(8)
and x86/pxeboot(8) in sync, but it did not happen, hence it may work
better with all the options in x86/boot(8). Also add the undocumented
UEFI boot options.

(manu)

2023-04-24 05:16:01 UTC MAIN commitmail json YAML

enable rkv1crypto on rock64.

this comes from upstream d1152bc533c941f7e267bf53d344cee510ea2808.

(i tried to make this be in rk3328.dtsi so all rk3328 boards would
benefit, but it doesn't work, and this is the only one have to test.)

adjust rkv1crypto to support a per-platform clocks setup.

(mrg)

2023-04-24 00:07:04 UTC MAIN commitmail json YAML

rump_allserver(1): fix markup, clarify

Reorder text for the -d option to hopefully make it easier to follow.
Clarify that the "disklabel" keyword takes partion letter (from RTFS).

(uwe)

2023-04-23 20:52:39 UTC MAIN commitmail json YAML

lua: fix ftb in lstrlib.c for clang

(error: enumeration values 'Knumber' and 'Kdouble' not handled in switch [-Werror,-Wswitch])

(nikita)

2023-04-23 16:49:38 UTC MAIN commitmail json YAML

2023-04-23 11:53:00 UTC MAIN commitmail json YAML

dlopen(3): Read _rtld_objtail under the lock.

XXX pullup-8
XXX pullup-9
XXX pullup-10

(riastradh)

2023-04-23 11:52:43 UTC MAIN commitmail json YAML

tests/lint: add rationale for not warning about alignment problems

(rillig)

2023-04-23 09:54:15 UTC MAIN commitmail json YAML

build.sh: drop -lrumpdev hack introduced in previous

The existing trick in sys/rump/librump/rumpdev/rump_dev.c was not
updated after the renames in the kernel.  kudos to riastradh.

PR kern/56599

(uwe)

2023-04-23 09:04:44 UTC MAIN commitmail json YAML

lint: be strict when parsing command line for excluded message IDs

Previously, lint accepted -X '1, 2, 3', while the manual page lists the
IDs without spaces.

On 32-bit platforms, lint accepted -X -4294967295, and on 64-bit
platforms, it accepted the corresponding larger numbers.

The code for parsing message IDs and query IDs conceptually does the
same, but the implementations differed for no reason.

(rillig)

2023-04-23 08:53:08 UTC MAIN commitmail json YAML

print stage formats with AUDIO_DEBUG

(mlelstv)

2023-04-23 08:47:27 UTC MAIN commitmail json YAML

tests/lint: test command line parsing for message and query IDs

The parsing methods differ but shouldn't.

(rillig)

2023-04-23 08:38:53 UTC MAIN commitmail json YAML

Be a little bit more informative on device timeout.

(mlelstv)

2023-04-23 08:26:05 UTC MAIN commitmail json YAML

2023-04-23 08:21:12 UTC MAIN commitmail json YAML

No longer use AUDIO_INTERNAL_BITS but rely on passed audio format.

(mlelstv)

2023-04-23 08:06:05 UTC MAIN commitmail json YAML

Enable 24bit support by default.

(mlelstv)

2023-04-23 08:05:37 UTC MAIN commitmail json YAML

Add 24bit/32bit hardware support.

(mlelstv)

2023-04-23 07:03:30 UTC MAIN commitmail json YAML

rumpdev: Catch up to buf_syncwait -> vfs_syncwait rename.

Do similarly with a do_sys_sync weak stub so we can drop the rumpvfs
dependency.

(riastradh)

2023-04-23 06:58:00 UTC MAIN commitmail json YAML

Explicitly check machine type (LUNA-II) on secondary spc(4) probe.

So that individual mainbus_attach_args for both LUNA and LUNA-II
are no longer necessary.
While here, use proper address macro in <machine/board.h>.

Tested on both LUNA and LUNA-II.

(tsutsui)

2023-04-23 06:30:58 UTC MAIN commitmail json YAML

2023-04-23 06:28:34 UTC MAIN commitmail json YAML

Make audio_device information available to drvctl and devpubd.

(mlelstv)

2023-04-23 06:13:35 UTC MAIN commitmail json YAML

Weed out duplicate sample rates and add comment about UAC2 clocks.

(mlelstv)

2023-04-23 02:01:33 UTC MAIN commitmail json YAML

build.sh: tweak rumptest and RUMP_LIBSETS

Use --no-whole-archive to keep us as honest as currently possible.
PR kern/56599

(uwe)

2023-04-23 00:46:46 UTC MAIN commitmail json YAML

t_open_pr_57260.c: KNF a block (spaces to tabs)

(gutteridge)

2023-04-22 20:54:28 UTC MAIN commitmail json YAML

lint: allow cast from a type to a union containing that type

(rillig)

2023-04-22 20:27:09 UTC MAIN commitmail json YAML

lint: fix wrong warning about 'extern' temporary identifier

(rillig)

2023-04-22 20:21:13 UTC MAIN commitmail json YAML

tests/lint: demonstrate wrong warning about extern temporary identifier

(rillig)

2023-04-22 20:17:19 UTC MAIN commitmail json YAML

lint: fix missing initialization for cast to union

The left operand of a unary AST node must not be NULL.

The previous code crashed lint when run with some query enabled, as
is_cast_redundant assumes that a non-null AST node has valid operands.

$ cat <<EOF > crash.c
double
demo(void) {
union u {
double *num;
} u;
u = (union u)&((double) { 0.0 });
return *u.num;
}
EOF
$ /usr/libexec/lint1 -w -S -g -q8 crash.c /dev/null

(rillig)

2023-04-22 19:45:04 UTC MAIN commitmail json YAML

tests/lint: test cast to union with stricter alignment

(rillig)

2023-04-22 19:41:15 UTC MAIN commitmail json YAML

lua: formatting in lvm.c

(nikita)

2023-04-22 18:55:59 UTC MAIN commitmail json YAML

rumpvfs: Link in secmodel_extensions_vfs.c as intended, like kernel.

Forgot to commit this part when splitting up secmodel_extensions.c.

(riastradh)

2023-04-22 17:49:15 UTC MAIN commitmail json YAML

lint: rename type_t.t_str to t_sou

The name 't_str' could have meant 'string' or 'struct'.  Since both
struct and union types have members, rename it to 't_sou'.

No functional change.

(rillig)

2023-04-22 17:42:29 UTC MAIN commitmail json YAML

lint: don't warn about cast between union and one of its member types

Seen in src/sbin/newfs_udf/udf_core.c for context.anchors.

(rillig)

2023-04-22 17:30:35 UTC MAIN commitmail json YAML

tests/lint: add test for conversions to and from a union type

Additionally, fix the line numbers in another test.

(rillig)

2023-04-22 15:32:49 UTC MAIN commitmail json YAML

specfs: KNF.  No functional change intended.

(riastradh)

2023-04-22 15:14:37 UTC MAIN commitmail json YAML

lint: do not warn about parenthesized assignment in controlling expr

Same as for GCC and Clang.

(rillig)

2023-04-22 14:30:54 UTC MAIN commitmail json YAML

Remove unused mount member mnt_transinfo.

Ride 10.99.4

(hannken)

2023-04-22 14:30:17 UTC MAIN commitmail json YAML

Remove unused specdev member sd_rdev.

Ride 10.99.4

(hannken)

2023-04-22 14:23:59 UTC MAIN commitmail json YAML

fcntl(2), flock(2): Assert FHASLOCK is clear if no fo_advlock.

(riastradh)

2023-04-22 14:23:50 UTC MAIN commitmail json YAML

fcntl(2), flock(2): Unify error branches.

Let's make this a bit less error-prone by having everything converge
in the same place instead of multiple returns in different contexts.

(riastradh)

2023-04-22 14:23:32 UTC MAIN commitmail json YAML

fcntl(2), flock(2): Fix missing fd_putfile in error branch.

Oops!

(riastradh)

2023-04-22 14:05:36 UTC MAIN commitmail json YAML

Welcome to 10.99.4, courtesy of struct fileops additions!

(riastradh)

2023-04-22 13:54:59 UTC MAIN commitmail json YAML

rump: Move vnode_if.c from rumpkern to rumpvfs.

This has become increasingly less of a `fully dynamic interface', and
the need for it in the rest of sys/kern/ has been obviated, so let's
put it where it belongs in rumpvfs.

(riastradh)

2023-04-22 13:54:20 UTC MAIN commitmail json YAML

secmodel_extensions: Split vfs part into separate .c file.

This way we can provide weak rumpkern stubs that don't require
rumpvfs for things that are relevant to vfs, but if you do link
rumpvfs then you get the same logic in secmodel extensions.

(riastradh)

2023-04-22 13:53:53 UTC MAIN commitmail json YAML

rump: Move ubc_uiomove, ubc_zerorange from rumpvfs to rumpkern.

Needed by kern_ksyms.c.  We could split kern_ksyms.c up into kernel-
internal interfaces and the user/kernel /dev/ksyms interface, but
there's nothing vfs-specific about ubc_uiomove and ubc_zerorange
anyway, so let's just define them in rumpkern.

(riastradh)

2023-04-22 13:53:44 UTC MAIN commitmail json YAML

rumpkern: Provide stub pnbuf_cache weak alias.

Needed only by sys_module.c handle_modctl_load, which won't work if
there's no rumpvfs linked in anyway.

(riastradh)

2023-04-22 13:53:37 UTC MAIN commitmail json YAML

rumpkern: Provide stub uvm_vnodeops weak alias.

Needed for UVM_OBJ_IS_VNODE, but not for anything else in rumpkern
without rumpvfs.

(riastradh)

2023-04-22 13:53:30 UTC MAIN commitmail json YAML

rumpkern: Provide fs_filtops weak alias.

We should introduce a link set for sys_kfilters, but this works
around the problem for now -- librump's dependency on librumpvfs
symbols.

(riastradh)

2023-04-22 13:53:03 UTC MAIN commitmail json YAML

file(9): New fo_posix_fadvise operation.

XXX kernel revbump -- changes struct fileops API and ABI

(riastradh)

2023-04-22 13:52:55 UTC MAIN commitmail json YAML

2023-04-22 13:52:46 UTC MAIN commitmail json YAML

file(9): New fo_advlock operation.

This moves the vnode-specific logic from sys_descrip.c into
vfs_vnode.c, like we did for fo_seek.

XXX kernel revbump -- struct fileops API and ABI change

(riastradh)

2023-04-22 13:52:37 UTC MAIN commitmail json YAML

sys/file.h: Sort forward declarations.

No functional change intended.

(riastradh)

2023-04-22 13:11:50 UTC MAIN commitmail json YAML

dk(4): Convert tests to assertions in various devsw operations.

.d_cancel, .d_strategy, .d_read, .d_write, .d_ioctl, and .d_discard
are only ever used between successful .d_open return and entry to
.d_close.  .d_open doesn't return until sc is nonnull and sc_state is
RUNNING, and dkwedge_detach waits for the last .d_close before
setting sc_state to DEAD.  So there is no possibility for sc to be
null or for sc_state to be anything other than RUNNING or DYING.

There is a small functional change here but only in the event of a
race: in the short window between when dkwedge_detach is entered, and
when .d_close runs, any I/O operations (read, write, ioctl, &c.) may
be issued that would have failed with ENXIO before.

This shouldn't matter for anything: disk I/O operations are supposed
to complete reasonably promptly, and these operations _could_ have
begun milliseconds prior, before dkwedge_detach was entered, so it's
not a significant distinction.

Notes:

- .d_open must still contend with trying to open a nonexistent wedge,
  of course.

- .d_close must also contend with closing a nonexistent wedge, in
  case there were two calls to open in quick succession and the first
  failed while the second hadn't yet determined it would fail.

- .d_size and .d_dump are used from ddb without any open/close.

(riastradh)

2023-04-22 12:33:46 UTC MAIN commitmail json YAML

dk(4): Fix racy access to sc->sc_dk.dk_openmask in dkwedge_delall1.

Need sc->sc_parent->dk_rawlock for this, as used in dkopen/dkclose.

(riastradh)

2023-04-22 11:58:01 UTC MAIN commitmail json YAML

disk(9): Fix missing unlock in error branch in previous change.

Reported-by: syzbot+870665adaf8911c0d94d@syzkaller.appspotmail.com
https://syzkaller.appspot.com/bug?id=a4ae17cf66b5bb999182ae77fd3c7ad9ad18c891

(riastradh)

2023-04-22 11:22:36 UTC MAIN commitmail json YAML

readdir(2), lseek(2): Fix races in access to struct file::f_offset.

For non-directory vnodes:
- reading f_offset requires a shared or exclusive vnode lock
- writing f_offset requires an exclusive vnode lock

For directory vnodes, access (read or write) requires either:
- a shared vnode lock AND f_lock, or
- an exclusive vnode lock.

This way, two files for the same underlying directory vnode can still
do VOP_READDIR in parallel, but if two readdir(2) or lseek(2) calls
run in parallel on the same file, the load and store of f_offset is
atomic (otherwise, e.g., on 32-bit systems it might be torn and lead
to corrupt offsets).

There is still a potential problem: the _whole transaction_ of
readdir(2) may not be atomic.  For example, if thread A and thread B
read n bytes of directory content, thread A might get bytes [0,n) and
thread B might get bytes [n,2n) but f_offset might end up at n
instead of 2n once both operations complete.  (However, f_offset
wouldn't be some corrupt garbled number like n & 0xffffffff00000000.)
Fixing this would require either:
(a) using an exclusive vnode lock in vn_readdir,
(b) introducing a new lock that serializes vn_readdir on the same
    file (but ont necessarily the same vnode), or
(c) proving it is safe to hold f_lock across VOP_READDIR, VOP_SEEK,
    and VOP_GETATTR.

(riastradh)

2023-04-22 10:22:43 UTC MAIN commitmail json YAML

KASSERT(kpreempt_disabled()) before accessing curcpu()

(skrll)

2023-04-22 10:09:12 UTC MAIN commitmail json YAML

2023-04-22 10:03:53 UTC MAIN commitmail json YAML

2023-04-22 10:00:24 UTC MAIN commitmail json YAML

2023-04-22 09:53:45 UTC MAIN commitmail json YAML

2023-04-22 09:39:14 UTC MAIN commitmail json YAML

lint: fix typos in comments

(rillig)

2023-04-21 23:01:59 UTC MAIN commitmail json YAML

2023-04-21 22:44:27 UTC MAIN commitmail json YAML

2023-04-21 22:43:11 UTC MAIN commitmail json YAML

Avoid an extern declaration in .c file.  Just declare it as static.

Suggested on tech-userlevel@.

(tsutsui)

2023-04-21 21:50:05 UTC MAIN commitmail json YAML

Add new test t_open_pr_57260

New test case that reflects the fix in PR kern/57260. The majority of
work for this case itself was by riastradh@, who'd supplied the basis
for it in the ticket, and provided further guidance.

(gutteridge)

2023-04-21 19:29:32 UTC MAIN commitmail json YAML

Fix incorrect test for FUSE_USE_VERSION 34

(Thanks to Mark Davies for report)

(abs)

2023-04-21 18:54:09 UTC MAIN commitmail json YAML

dk(4): Narrow the scope of the device numbering lookup on detach.

Just need it for vdevgone, order relative to other things in detach
doesn't matter.

No functional change intended.

(riastradh)

2023-04-21 18:45:13 UTC MAIN commitmail json YAML

dk(4): dkdump: Simplify.  No functional change intended.

(riastradh)

2023-04-21 18:44:59 UTC MAIN commitmail json YAML

dk(4): Omit needless locking in dksize, dkdump.

All the members these use are stable after initialization, except for
the wedge size, which dkwedge_size safely reads a snapshot of without
locking in the caller.

(riastradh)

2023-04-21 18:44:18 UTC MAIN commitmail json YAML

dk(4): Take a read-lock on dkwedges_lock if we're only reading.

- dkwedge_find_by_name
- dkwedge_find_by_parent
- dkwedge_print_wnames

(riastradh)

2023-04-21 18:31:00 UTC MAIN commitmail json YAML

dk(4): Set .d_cfdriver and .d_devtounit to plug open/detach race.

This way, opening dkN or rdkN will wait if attach or detach is still
in progress, and vdevgone will wake up such pending opens and make
them fail.  So it is no longer possible for a wedge to be detached
after dkopen has already started using it.

For now, we use a custom .d_devtounit function that looks up the
autoconf unit number via the dkwedges array, which conceivably may
use an independent unit numbering system -- nothing guarantees they
match up.  (In practice they will mostly match up, but concurrent
wedge creation could lead to different numbering.)  Eventually this
should be changed so the two numbering systems match, which would let
us delete the new dkunit function and just use dev_minor_unit like
many other drivers can.

(riastradh)

2023-04-21 18:30:52 UTC MAIN commitmail json YAML

dk(4): Use disk_begindetach and rely on vdevgone to close instances.

The first step is to decide whether we can detach (if forced, yes; if
not forced, only if not already open), and prevent new opens if so.
There's no need to start closing open instances at this point --
we're just making a decision to detach, and preventing new opens by
transitioning state that dkopen will respect[*].

The second step is to force all open instances to close.  This is
done by vdevgone.  By the time vdevgone returns, there can be no open
instances, so if there _were_ any, closing them via vdevgone will
have passed through dklastclose.

After that point, there can be no opens and no I/O operations, so
dk_openmask must already be zero and the bufq must be empty.

Thus, there's no need to have an explicit call to dklastclose (via
dkwedge_cleanup_parent) before or after making the decision to
detach.

[*] Currently access to this state is racy: nothing serializes
    dkwedge_detach's state transition with dkopen's test.  TBD in a
    separate commit shortly.

(riastradh)

2023-04-21 18:30:32 UTC MAIN commitmail json YAML

dk(4): Fix callout detach race.

1. Set a flag sc_iostop under the lock sc_iolock so dkwedge_detach
  and dkstart don't race over it.

2. Decline to schedule the callout if sc_iostop is set.  The callout
  is already only ever scheduled while the lock is held.

3. Use callout_halt to wait for any concurrent callout to complete.
  At this point, it can't reschedule itself.

Without this change, the callout could be concurrently rescheduling
itself as we issue callout_stop, leading to use-after-free later.

(riastradh)

2023-04-21 18:30:21 UTC MAIN commitmail json YAML

dk(4): Add null d_cancel routine to devsw.

This way, dkclose is guaranteed that dkopen, dkread, dkwrite,
dkioctl, &c., have all returned before it runs.  For block opens,
setting d_cancel also guarantees that any buffered writes are flushed
with vinvalbuf before dkclose is called.

(riastradh)

2023-04-21 18:30:04 UTC MAIN commitmail json YAML

disk(9): Fix use-after-free race with concurrent disk_set_info.

This can happen with dk(4), which allows wedges to have their size
increased without destroying and recreating the device instance.

Drivers which allow concurrent disk_set_info and disk_ioctl must
serialize disk_set_info with dk_openlock.

(riastradh)

2023-04-21 18:29:43 UTC MAIN commitmail json YAML

dk(4): Require dk_openlock in dk_set_geometry.

Not strictly necessary but this makes reasoning easier and documents
with an assertion how disk_set_info is serialized.

(riastradh)

2023-04-21 18:29:34 UTC MAIN commitmail json YAML

dk(4): Assert dkwedges[unit] is the sc we're about to free.

(riastradh)

2023-04-21 18:29:26 UTC MAIN commitmail json YAML

dk(4): Assert parent vp is nonnull before we stash it away.

Let's enable early attribution if this goes wrong.

If it's not the parent's first open, also assert the parent vp is
already nonnull.

(riastradh)

2023-04-21 18:29:18 UTC MAIN commitmail json YAML

dk(4): Don't touch dkwedges or ndkwedges outside dkwedges_lock.

(riastradh)

2023-04-21 18:26:36 UTC MAIN commitmail json YAML

dk(4): Move CFDRIVER_DECL and CFATTACH_DECL3_NEW earlier in file.

Follows the pattern of most drivers, and will be necessary for
referencing dk_cd in dk_bdevsw and dk_cdevsw soon, to prevent
open/detach races.

No functional change intended.

(riastradh)

2023-04-21 18:25:49 UTC MAIN commitmail json YAML

dk(4): Prevent races in access to struct dkwedge_softc::sc_size.

Rules:

1. Only ever increases, never decreases.

  (Decreases require removing and readding the wedge.)

2. Increases are serialized by dk_openlock.

3. Reads can happen unlocked in any context where the softc is valid.

Access is gathered into dkwedge_size* subroutines -- don't touch
sc_size outside these.  For now, we use rwlock(9) to keep the
reasoning simple.  This should be done with atomics on 64-bit
platforms and a seqlock on 32-bit platforms to avoid contention.
However, we can do that in a later change.

(riastradh)

2023-04-21 18:25:30 UTC MAIN commitmail json YAML

dk(4): <sys/rwlock.h> for rwlock(9).

(riastradh)

2023-04-21 18:25:22 UTC MAIN commitmail json YAML

dk(4): KNF: Sort includes.

No functional change intended.

(riastradh)

2023-04-21 18:25:09 UTC MAIN commitmail json YAML

dk(4): ENXIO, not ENODEV, means no such device.

ENXIO is `device not configured', meaning there is no such device.

ENODEV is `operation not supported by device', meaning the device is
there but refuses the operation, like writing to a read-only medium.

Exception: For undefined ioctl commands, it's not ENODEV _or_ ENXIO,
but rather ENOTTY, because why make any of this obvious when you
could make it obscure Unix lore?

(riastradh)

2023-04-21 18:24:56 UTC MAIN commitmail json YAML

dk(4): Fix typo in comment: dkstrategy, not dkstragegy.

No functional change intended.

(riastradh)

2023-04-21 18:24:48 UTC MAIN commitmail json YAML

dk(4): Omit needless void * cast.

No functional change intended.

(riastradh)

2023-04-21 18:24:39 UTC MAIN commitmail json YAML

dk(4): KNF: Whitespace.

No functional change intended.

(riastradh)

2023-04-21 18:24:32 UTC MAIN commitmail json YAML

dk(4): KNF: return (v) -> return v.

No functional change intended.

(riastradh)

2023-04-21 18:24:19 UTC MAIN commitmail json YAML

dk(4): Avoid holding dkwedges_lock while allocating array.

This is not great -- we shouldn't be choosing the unit number here
anyway; we should just let autoconf do it for us -- but it's better
than potentially blocking any dk_openlock or dk_rawlock (which are
sometimes held when waiting for dkwedges_lock) for memory allocation.

(riastradh)

2023-04-21 18:09:38 UTC MAIN commitmail json YAML

dk(4): Restore assertions in dklastclose.

We only enter dklastclose if the wedge is open (sc->sc_dk.dk_openmask
!= 0), which can happen only if dkfirstopen has succeeded, in which
case we hold a dk_rawopens reference to the parent that prevents
anyone else from closing it.  Hence sc->sc_parent->dk_rawopens > 0.

On open, sc->sc_parent->dk_rawvp is set to nonnull, and it is only
reset to null on close.  Hence if the parent is still open, as it
must be here, sc->sc_parent->dk_rawvp must be nonnull.

(riastradh)

2023-04-21 17:48:07 UTC MAIN commitmail json YAML

lua: fix formating diff to upstream in ldo.h

(nikita)

2023-04-21 17:35:43 UTC MAIN commitmail json YAML

autoconf(9): Add a comment where we risk arithmetic overflow.

(riastradh)

2023-04-21 17:31:33 UTC MAIN commitmail json YAML

2023-04-21 17:00:06 UTC MAIN commitmail json YAML

Note update to dhcpcd-10.0.1

(roy)

2023-04-21 16:54:26 UTC MAIN commitmail json YAML

2023-04-21 16:12:54 UTC MAIN commitmail json YAML

style: remove mentions of ANSI C

The distinction between traditional C and ISO C90 or later is no longer
needed in the style guide. Any old-style code is caught by the
compilers.

https://mail-index.netbsd.org/tech-userlevel/2023/04/15/msg013768.html
https://mail-index.netbsd.org/tech-userlevel/2023/04/17/msg013776.html

(rillig)

2023-04-21 15:04:47 UTC MAIN commitmail json YAML

2023-04-21 15:00:48 UTC MAIN commitmail json YAML

2023-04-21 15:00:27 UTC MAIN commitmail json YAML

2023-04-21 14:58:35 UTC MAIN commitmail json YAML

2023-04-21 14:57:52 UTC MAIN commitmail json YAML

2023-04-21 14:56:13 UTC MAIN commitmail json YAML

2023-04-21 02:17:32 UTC MAIN commitmail json YAML

virtio(4): change members of struct vring_desc_extra before free a slot

This prevents the following race condition.
1. Thread-A: calls virtio_dequeue_commit() and
            puts a slot into free descriptor chain in vq_free_slot()
2. Thread-B: calls virtio_enqueue_prep() and get the slot stored by Thread-A
3. Thread-B: calls virtio_enqueue_reserve() and
            changes desc_base and desc_free_idx for the slot
4. Thread-A: changes the same members updated by Thread-B

reported by hannken, thanks.

(yamaguchi)

2023-04-20 22:23:53 UTC MAIN commitmail json YAML

resize.c: use estrdup(3) with basename(3)

basename(3) is invoked more than once on different paths. Retain the
correct name for the utility itself on error. Addresses PR bin/57355
from RVP, who provided the patch.

(gutteridge)

2023-04-20 14:20:02 UTC netbsd-10 commitmail json YAML

2023-04-20 14:18:41 UTC netbsd-10 commitmail json YAML

Pull up following revision(s) (requested by brad in ticket #144):

sys/dev/ic/bmx280.c: revision 1.2

Do not create the sysctl tree if the initial setup of the chip fails.

(martin)

2023-04-20 14:15:22 UTC netbsd-9 commitmail json YAML