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 (6m)  netbsd-8 (6d)  netbsd-10 (6d)  netbsd-9 (12d)  thorpej-ifq (176d)  thorpej-altq-separation (178d) 

2024-05-10 21:50:02 UTC Now

2022-02-27 10:44:45 UTC MAIN commitmail json YAML

2022-02-27 10:31:58 UTC MAIN commitmail json YAML

2022-02-27 08:31:26 UTC MAIN commitmail json YAML

2022-02-27 07:50:09 UTC MAIN commitmail json YAML

lint: clean up memory management for string buffers

There is no reason to duplicate all the work that is already done by the
memory allocator.

No functional change.

(rillig)

2022-02-27 07:38:54 UTC MAIN commitmail json YAML

2022-02-27 06:55:13 UTC MAIN commitmail json YAML

lint: remove custom free list for memory blocks

Trust the system memory allocator to do its thing, including marking the
memory as fresh or freed.  One less thing to worry about.

(rillig)

2022-02-27 01:47:28 UTC MAIN commitmail json YAML

lint: rename ARG to OLD_STYLE_ARG

Pre-C90 argument declarations have been old for more than 30 years now,
so mention that fact in the constant name.  This reduces potential
confusion with other occurrences of the words 'arg' or 'argument'.

No functional change.

(rillig)

2022-02-27 01:03:14 UTC MAIN commitmail json YAML

lwp.h: correct grammar in a comment

(gutteridge)

2022-02-26 23:07:28 UTC MAIN commitmail json YAML

lint: improve debug logging for symbol kinds

(rillig)

2022-02-26 20:36:11 UTC MAIN commitmail json YAML

lint: fix memory corruption in statement expressions (since 2021-12-17)

The commit that introduced the assertion failure looks innocent, it only
adds a few predefined functions for GCC mode.  Nevertheless, before that
commit, lint consistently complained about 'error: void type illegal in
expression [109]', which doesn't make sense either.

This fix also removes the creative use of the initialization stack to
store the type of the statement expression.  Having a separate stack for
these statement expressions makes the code easier to understand.

(rillig)

2022-02-26 19:01:09 UTC MAIN commitmail json YAML

lint: extract code for handling statement expressions from the grammar

This prepares the fix of the memory corruption bug that is demonstrated
in t_integration.sh, test case assertion_failures.

No functional change.

(rillig)

2022-02-26 18:49:42 UTC MAIN commitmail json YAML

don't require arc4random_buf for tools build

(christos)

2022-02-26 18:35:01 UTC MAIN commitmail json YAML

lint: enable memory debugging

Filling deallocated memory with 0x00 may hide errors, so rather fill
with 0xA5.

While this doesn't change anything about the test about the assertion
failure after a do-while loop (see t_integration.sh, test case
assertion_failures), it may detect other similar bugs earlier.

(rillig)

2022-02-26 17:02:47 UTC MAIN commitmail json YAML

explain CRON_WITHIN better.

(christos)

2022-02-26 16:43:20 UTC MAIN commitmail json YAML

tests/lint: demonstrate assertion failure in GCC compound expression

(rillig)

2022-02-26 16:21:59 UTC MAIN commitmail json YAML

Mark randomly failing test cases as expected failures with a reference
to PR bin/56506.

(gson)

2022-02-26 15:57:22 UTC MAIN commitmail json YAML

drm2: do not try to return a value from a void function

lint complained:
vmalloc.h(79): error: void function vfree cannot return value [213]

No functional change.

(rillig)

2022-02-26 15:40:09 UTC MAIN commitmail json YAML

re-enable getrandom for the non-tools build (thanks martin)

(christos)

2022-02-26 15:04:40 UTC MAIN commitmail json YAML

if_wm.c: fix value return from void function

lint complained:
if_wm.c(10028): error:
    void function wm_txrxintr_disable cannot return value [213]
if_wm.c(10049): error:
    void function wm_txrxintr_enable cannot return value [213]

No functional change.

(rillig)

2022-02-26 14:53:05 UTC MAIN commitmail json YAML

if_wm.c: remove stray semicolons from struct declaration

C99 does not allow 'struct { int member;; }'.

No binary change.

(rillig)

2022-02-26 13:30:19 UTC MAIN commitmail json YAML

fix merge botch and reduce diff from upstream.

(christos)

2022-02-26 13:17:39 UTC MAIN commitmail json YAML

2022-02-26 13:15:19 UTC MAIN commitmail json YAML

2022-02-26 11:57:21 UTC MAIN commitmail json YAML

make: fix memory leak in Lst_Remove (since 2020-10-23)

The code to free the list node (as opposed to the node data) was
accidentally removed in lst.c 1.83 from 2020-10-23 as part of cleaning
up an unnecessarily complicated function for traversing linked lists.

The memory leak only affected a few lists that actually used Lst_Remove.
Most lists are append-only and are freed using Lst_Done or Lst_Free at
the end, which correctly free the memory.

(rillig)

2022-02-26 11:13:01 UTC MAIN commitmail json YAML

tests/lint: sync tests for platform-dependent character comparisons

(rillig)

2022-02-26 10:16:35 UTC MAIN commitmail json YAML

Try to fix the build: HAVE_GETRANDOM does not compile

(martin)

2022-02-26 03:02:25 UTC MAIN commitmail json YAML

unmask interrupt bits leading to other interrupt registers
now hardware interrupts actually fire instead of being found pending by the
timer interrupt
with this SCSI throughput on my c360 is what you'd expect from an UW esiop

(macallan)

2022-02-25 21:52:47 UTC MAIN commitmail json YAML

libexpat: add matching #endif for #if 0

(wiz)

2022-02-25 20:52:49 UTC MAIN commitmail json YAML

2022-02-25 17:42:59 UTC MAIN commitmail json YAML

2022-02-24 10:08:41 UTC netbsd-8 commitmail json YAML

2022-02-24 10:07:47 UTC netbsd-8 commitmail json YAML

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

bin/sh/histedit.c: revision 1.60

After (a few days short of) 21 years, revert 1.25, which did nothing except
make the -e option to "fc" fail to work (the commit message was about some
other changes entirely, so I an only assume this was committed by mistake).

It says a lot about the use of the fc command that no-one noticed that
this did not work properly for all this time.

Internally in sh, it is possible for built in commands to use either
getopt(3) (from libc) or the much simpler internal shell nextopt() routine
for option (flag) parsing.    However it makes no sense to use getopt()
and then access a global variable set only by nextopt() instead of the
one getopt() sets (which is what the code had used previously, forever).

Use the correct variable again.

XXX pullup -9 -8  (-7 -6 -5 ...)

(martin)

2022-02-24 08:06:41 UTC MAIN commitmail json YAML

2022-02-24 06:34:32 UTC MAIN commitmail json YAML

Add more -I to find expat_config.h

(martin)

2022-02-24 03:35:33 UTC MAIN commitmail json YAML

2022-02-24 00:26:27 UTC MAIN commitmail json YAML

2022-02-23 21:54:41 UTC MAIN commitmail json YAML

2022-02-23 19:09:42 UTC MAIN commitmail json YAML

2022-02-23 19:08:48 UTC MAIN commitmail json YAML

2022-02-23 19:07:35 UTC MAIN commitmail json YAML

Add more -I so that expat_config.h is found

(martin)

2022-02-23 19:07:20 UTC MAIN commitmail json YAML

Merge differences between openssh-8.8 and openssh-8.9

(christos)

2022-02-23 17:28:32 UTC MAIN commitmail json YAML

build the newer version of the ati driver frontend, that knows how
to load amdgpu if that is found.

(mrg)

2022-02-23 15:25:50 UTC MAIN commitmail json YAML

2022-02-23 15:24:06 UTC MAIN commitmail json YAML

2022-02-23 12:17:06 UTC MAIN commitmail json YAML

openssh 8.9 out

(wiz)

2022-02-23 10:56:18 UTC MAIN commitmail json YAML

sqlite-3.38 out

(wiz)

2022-02-23 08:56:11 UTC MAIN commitmail json YAML

2022-02-23 07:55:56 UTC MAIN commitmail json YAML

2022-02-23 00:06:49 UTC MAIN commitmail json YAML

libXi: Fixup libmansuffix in manual pages.

The manpages use unadorned libmansuffix instead of __libmansuffix__ or
@libmansuffix@ that the standard transformations handle.

Add ad-hoc s/// command for it.  It has "3" hardcoded because there's
no easy way to look up that mapping, but then that very same "3" is
hardcoded in the file names anyway.

(uwe)

2022-02-22 22:49:39 UTC MAIN commitmail json YAML

2022-02-22 17:03:48 UTC MAIN commitmail json YAML

Incllude POWERMAC_G5.local if it exists

(martin)

2022-02-22 15:42:09 UTC MAIN commitmail json YAML

libXxf86vm: Add missing XF86VidModeAddModeLine.3 mlink.

(uwe)

2022-02-22 00:05:14 UTC MAIN commitmail json YAML

libXv: add missing man pages added in libXv-1.0.5

While here, split MAN and MLINKS into individual += assignments and
sort them.

(uwe)

2022-02-21 17:59:04 UTC netbsd-9 commitmail json YAML

2022-02-21 17:58:11 UTC netbsd-9 commitmail json YAML

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

bin/sh/histedit.c: revision 1.60

After (a few days short of) 21 years, revert 1.25, which did nothing except
make the -e option to "fc" fail to work (the commit message was about some
other changes entirely, so I an only assume this was committed by mistake).

It says a lot about the use of the fc command that no-one noticed that
this did not work properly for all this time.

Internally in sh, it is possible for built in commands to use either
getopt(3) (from libc) or the much simpler internal shell nextopt() routine
for option (flag) parsing.    However it makes no sense to use getopt()
and then access a global variable set only by nextopt() instead of the
one getopt() sets (which is what the code had used previously, forever).

Use the correct variable again.

XXX pullup -9 -8  (-7 -6 -5 ...)

(martin)

2022-02-21 17:07:45 UTC MAIN commitmail json YAML

Fix wrong assertion, the negatiopn of "a && b" is "!a || !b" so we
need "DIP(ip, blocks) != 0" here.

Should fix PR kern/56725 (Panic when ls directory with device nodes
on an older ffs)

(hannken)

2022-02-21 08:15:05 UTC MAIN commitmail json YAML

new expat 2.4.6 available

(wiz)

2022-02-21 02:13:47 UTC MAIN commitmail json YAML

libXext: Fix MLINKS for XShape.3

XShapeQueryExtension.3 and XShapeQueryVersion.3 are not conjoined twins.
While here split XShape.3 links into separate MLINKS += src dst assignments
and sort them.

(uwe)

2022-02-20 18:56:01 UTC MAIN commitmail json YAML

Convert assembly to something both gcc and clang understand.

(christos)

2022-02-20 15:21:14 UTC MAIN commitmail json YAML

Validate basic fcntl(2) behavior for eventfd and timerfd.

(thorpej)

2022-02-20 14:43:39 UTC MAIN commitmail json YAML

Document critical_filesystems_zfs.

(alnsn)

2022-02-20 14:42:08 UTC MAIN commitmail json YAML

2022-02-20 10:49:17 UTC MAIN commitmail json YAML

Document zfs variable.

(alnsn)

2022-02-20 09:40:07 UTC MAIN commitmail json YAML

Be less optimistic about i386 system reqirements. Remove extremely outdated
list of support devices.

(nia)

2022-02-19 17:54:02 UTC MAIN commitmail json YAML

expat-2.4.5 out (security fix release)

(wiz)

2022-02-19 17:45:02 UTC MAIN commitmail json YAML

PR/56695: Walter Lozano: Correct declaration of hook functions.

(christos)

2022-02-18 19:04:52 UTC MAIN commitmail json YAML

Backout previous and fix the correct macro magic

(martin)

2022-02-18 18:58:15 UTC MAIN commitmail json YAML

pmap_pv_protect is not STATIC

(martin)

2022-02-18 18:31:19 UTC MAIN commitmail json YAML

revert "drm: Respect is_console property on main drm device, not fb child."

breaks booting on some machines

ok riastradh@

(wiz)

2022-02-18 06:43:00 UTC MAIN commitmail json YAML

Don't crash when reporting an undefined symbol.

(mlelstv)

2022-02-17 16:28:29 UTC MAIN commitmail json YAML

Implement eventfd_ioctl() and handle FIONBIO so that fcntl(O_NONBLOCK)
works.  While here, also implement FIONREAD and FIONWRITE, and document
why we don't implement FIONSPACE.

Also implement FIONBIO and FIONREAD for in timerfd_ioctl() (for the same
reason).

PR kern/56718

(thorpej)

2022-02-17 16:09:00 UTC MAIN commitmail json YAML

include pmap_pvt.c in bridge mode as well

(macallan)

2022-02-17 14:39:51 UTC MAIN commitmail json YAML

Do the space accounting before VOP_INACTIVE() so we may
unlock the vnode after VOP_INCATIVE().

This was the last call from vrelel() to VOP_UNLOCK() with v_interlock held.

(hannken)

2022-02-17 14:39:14 UTC MAIN commitmail json YAML

Add a marker VUSECOUNT_VGET to v_usecount that gets set whenever
vcache_vget() or vache_tryvget() succeeds.

Use it to rerun VOP_INACTIVE() if another thread ran a vget()..vrele()
cycle while we inactivated our last reference.

(hannken)

2022-02-17 14:38:06 UTC MAIN commitmail json YAML

If the vnode to vrelel() is already reclaimed there is no need
to lock or defer it.  Jump straight to decrement usecount and requeue.

(hannken)

2022-02-17 14:33:25 UTC MAIN commitmail json YAML

remove one whitespace to align report, misalignment occured after typo fix.

(andvar)

2022-02-17 01:38:38 UTC MAIN commitmail json YAML

drm: Fix membars around dma_buf_put reference count release.

(riastradh)

2022-02-17 01:21:03 UTC MAIN commitmail json YAML

drm/vmwgfx: First draft.  Passes make depend, doesn't build yet.

(riastradh)

2022-02-17 00:54:51 UTC MAIN commitmail json YAML

evbppc: fix typo from cfargs rototill.

(riastradh)

2022-02-16 23:49:27 UTC MAIN commitmail json YAML

2022-02-16 23:31:13 UTC MAIN commitmail json YAML

2022-02-16 23:30:52 UTC MAIN commitmail json YAML

powerpc: Implement bus_dmamap_load_raw.

Can probably delete some of the round-trips between bus addresses and
physical addresses -- did these only to copy the logic already in
_bus_dmamap_load_buffer.

(riastradh)

2022-02-16 23:30:10 UTC MAIN commitmail json YAML

drm: Respect is_console property on main drm device, not fb child.

The MD device enumeration sets the property on, e.g., PCI devices --
not on drm framebuffer children, which are mostly a software
abstraction.  Not sure examining the nouveaufb, intelfb, &c., device
properties is worthwhile at all, but in case it breaks something
let's just leave it in while we're fixing other things.

(riastradh)

2022-02-16 23:20:38 UTC MAIN commitmail json YAML

macppc: Support *macppc* GENERIC.local, not evbarm GENERIC64.local.

Managed to fumble with a copypasta error of local commits, and
committed the one that didn't work instead of the one that did.

(riastradh)

2022-02-16 22:00:57 UTC MAIN commitmail json YAML

2022-02-16 20:31:43 UTC MAIN commitmail json YAML

2022-02-16 20:14:41 UTC MAIN commitmail json YAML

macppc: Support GENERIC.local.

(riastradh)

2022-02-16 20:14:30 UTC MAIN commitmail json YAML

sys: Include files.acpica unconditionally.

This way acpica.h always exists unconditionally, so MI code can be
conditional on NACPICA.

It is not great to have such conditionals, but it's better to have

#include "acpica.h"

#ifdef NACPICA > 0

than to have

#if defined(__i386__) || defined(__x86_64__) || defined(__arm__)
#include "acpica.h"
#endif

#ifdef NACPICA > 0

and we can still grep for NACPICA to find places that could be
factored better.

(riastradh)

2022-02-16 20:14:06 UTC MAIN commitmail json YAML

pmap_pvt.h: Fix bogus include.

(riastradh)

2022-02-16 20:13:58 UTC MAIN commitmail json YAML

uvm: MI declaration of pmap_pv_protect.

(riastradh)

2022-02-16 14:37:00 UTC netbsd-9 commitmail json YAML

2022-02-16 14:36:12 UTC netbsd-9 commitmail json YAML

Pull up following revision(s) (requested by jakllsch in ticket #1428):

sys/dev/usb/uhidev.c: revision 1.82

Do not explicitly set the HID Report Protocol upon attach, some devices
don't like it and should be in Report Protocol after enumeration/reset
anyway.

May address PR kern/55019.

(martin)

2022-02-16 10:29:13 UTC MAIN commitmail json YAML

Print Printed Board Assembly (PBA) number.

(msaitoh)

2022-02-16 03:15:27 UTC MAIN commitmail json YAML

Remove duplicated break. No functional change.

(msaitoh)

2022-02-16 01:26:31 UTC MAIN commitmail json YAML

Add missing cat pages to fix MKCATPAGES build.

(uwe)

2022-02-15 22:58:25 UTC MAIN commitmail json YAML

Fix typo, use Nm instead of Xr to itself.

(wiz)

2022-02-15 22:51:03 UTC MAIN commitmail json YAML

drm: Use KM_SLEEP to allocate reservation fence arrays.

Except as a fast path in an RCU reader.

The array sizes appear to be reasonably small and not trivially
controlled by userland, from what I can tell, so if my impression is
accurate, it is reasonable to sleep for allocation here.

(riastradh)

2022-02-15 22:46:53 UTC MAIN commitmail json YAML

membar_ops(3): xref bus_dma, bus_space in SEE ALSO section too

(riastradh)

2022-02-15 22:46:29 UTC MAIN commitmail json YAML

KERNEL_LOCK(9): New man page for old not-dead-yet hack.

I'm not documenting this to encourage anyone to use it.  I'm only
documenting this to remind myself what the semantics is, because it's
kind of confusing and not at all like mutex(9).

(riastradh)

2022-02-15 20:35:37 UTC MAIN commitmail json YAML

Document the calculation of CC64FSZ

(palle)

2022-02-15 19:32:32 UTC MAIN commitmail json YAML

2022-02-15 19:29:07 UTC MAIN commitmail json YAML

2022-02-15 18:48:32 UTC MAIN commitmail json YAML

This is the updated version of the Merkletree code, version 20220204

Digests supported are a bit more up to date:

blake2b
blake2s
sha256
sha3_256
sha3_512
sha512

The default algorithm is sha512, with an input blocksize of 1024.
Input can either be in the form of files, other directory entries, or
from standard input.

Output is in either standard format (similar to digest(1)),

% merkletree 1.in
sha512/1024 (1.in) 902387724175187f42a6bce7ab7f1a88a4ce536662880747347dc5ea761fed5a7dac5e98962c60b5c3d7988258c0c9e2a14e37cfeb7972fe9086e693381324c8
% merkletree < 1.in
902387724175187f42a6bce7ab7f1a88a4ce536662880747347dc5ea761fed5a7dac5e98962c60b5c3d7988258c0c9e2a14e37cfeb7972fe9086e693381324c8
%

or can be in JSON format:

{"name":"1.in","blocksize":1024,"digest":"sha512","1:0":"902387724175187f42a6bce7ab7f1a88a4ce536662880747347dc5ea761fed5a7dac5e98962c60b5c3d7988258c0c9e2a14e37cfeb7972fe9086e693381324c8"}

(or, run through jq):

% jq . < dist/tests/11.expected
{
  "name": "1.in",
  "blocksize": 1024,
  "digest": "sha512",
  "1:0": "902387724175187f42a6bce7ab7f1a88a4ce536662880747347dc5ea761fed5a7dac5e98962c60b5c3d7988258c0c9e2a14e37cfeb7972fe9086e693381324c8"
}
%

The input blocksize can be specified by the user, but must be twice
the size of the selected digest's algorithm in raw bytes.

It is possible to run merkletree on a hierarchy by using the "-p path"
argument:

% merkletree -a sha3_256 -p / bin
sha3_256/1024 (bin/chgrp) 39e8cc74388ffe34469b1ca91f63d49982662b1c942c9afbd32f48185c3df5ca
sha3_256/1024 (bin/cat) edc35ffbe3ee8c022bb7914530562a3da46680a5e7f3b37749f04ee04cb87cdb
sha3_256/1024 (bin/chmod) c58fca83a80c83f645e80365374be1d9191324cd490a78b99e3ab33fedebacb5
sha3_256/1024 (bin/chio) d8a00ff730bc8a4a108d170ab6f2d690e7f6c201b164b23f256f6013ee08ffef
sha3_256/1024 (bin/domainname) b04a2dafa1a9b14257f63e49acac8c91150c09649519daa3fc0e2f6add79644e
sha3_256/1024 (bin/cp) 7c97f28d4257e6743e315b46d8119baa3718adf6b1b25e4221016dd90db266c6
sha3_256/1024 (bin/cpio) 7e2371ff80c900f31783e147ded8a5a2b87cebdff6eda3638d52611aefe63243
sha3_256/1024 (bin/csh) 16e4e9acd76b3ca6de71a796c77a0593e365048037d0e433cba96d5a8d2b27d4
sha3_256/1024 (bin/date) 05891939e39d7180e8bf252b8b8fc087b309a46e4845b4980bbc3fea1f5307ae
sha3_256/1024 (bin/dd) 67b28e1d3399a2edef52b39683a0d8b56f812fa37b56aeda92a427b0db50dfb8
sha3_256/1024 (bin/df) a360c756b2d64003247140924b8223b1dbe161f9b70ce96a915c85d9bab23e51
sha3_256/1024 (bin/hostname) ddba878bc063a3123cdb4cf8d272a0438ab2f6a4141618e70726fda45f41b1cb
sha3_256/1024 (bin/echo) cd3c415f168bb4a8df2e2f12b1238137b7004453affa5497741175761e516cc0
sha3_256/1024 (bin/ed) 7a915104df73a5682d091fb0214af110e4c1c6bec306d9ccf2ffd527c09c856e
sha3_256/1024 (bin/expr) aaf51c742e02ca40abc402a6fdd283488c11d3e549039d0d62e7c29795987185
sha3_256/1024 (bin/mkdir) e425ae2f2c7771d4e4bfae0f335c44016548a37eb1915b5ed665ba4e4feeb1b6
sha3_256/1024 (bin/kill) 999a17e8c03e022180fe842e92273f7656719027618bb9de90b46ada48ab518f
sha3_256/1024 (bin/ksh) a862c37708a7417a4e35ed04363ef3d83c141efc5659eb04c141063fe0ec7ba2
sha3_256/1024 (bin/ln) a0e93d49eba74b0b48a712fa143faaf9735cf7a82343e992cb12b3cc8fa485c2
sha3_256/1024 (bin/ls) 006d65534a13845efa9af7c252174e54a75c142a1db4dfd86c78f95c7f5297b6
sha3_256/1024 (bin/pax) 0fb2c7557feb33ea9073b36db01a44ef4b2609386a4fb771db21ad44fd48064f
sha3_256/1024 (bin/sleep) d548731fc8b401d2070ab4eeeeab84c012d69c96a0a71dd8b7f882862b481ff0
sha3_256/1024 (bin/mt) 8223efa972949ebe508ca066bc9e9b7ee0c8f3dbec42b68919134bf2c38cdf2e
sha3_256/1024 (bin/mv) 65c5830326958f85165d49e673935df4305dff3802c86010e8c7efbccb084a33
sha3_256/1024 (bin/rmdir) 5b785cfb9594247f5772b15e6946e7546929679c170b40fcd0275a68ffa95eac
sha3_256/1024 (bin/ps) 8d5e766181cfa5d2174bd558994b773eddfdd126474b06bf9f4e1a87fc93dde0
sha3_256/1024 (bin/pwd) 5fd7c3c5e9af7135248afa1e01a3a431536ffc9363c26d74cd2ba95e44bb13dc
sha3_256/1024 (bin/rcmd) a6fde1189f80f354f024621954ec2630589384268182f458737a7d0820193d7d
sha3_256/1024 (bin/rcp) 9863785c1f95449150dddf634c4d0485b12fcd33f3fff85a268805b13665fc09
sha3_256/1024 (bin/rm) ba9f8bf91fb070db7aaccccbe21a79263810a6e7ce65dff93932fce569effb57
sha3_256/1024 (bin/tar) 5441da55b4db7ee6b5acd603edad069a1fa8a61643b1b6e6b4c14eb75e4239ec
sha3_256/1024 (bin/rump.dd) a15b1a5aa3b6b59568e2cae5cbfb2979abf0d73734f0b049fa1e13426b2cf035
sha3_256/1024 (bin/sh) 29b86c7f8fa34ac6d8a4e04e4b9280ca986f1e99906743eea2c4fe96b9cd16fc
sha3_256/1024 (bin/stty) 4b33e1afb82cabf8c93fe96bb419b6449d25ed28dc4e9a8afb94736f6922e087
sha3_256/1024 (bin/sync) 5b454179f10e47af9a49d6d4b473c1c833878f50dba49bb664a5b36a8e12ee36
sha3_256/1024 (bin/tcsh) 9ec17e221e01fea34b67e1c8db27dcd6360f749fa1ab64d1d4405e966cd7c6b2
sha3_256/1024 (bin/test) e04425b059ff599cc672d9e0dc81e887630c6243ae0e13461a5158fea4740a64
sha3_256/1024 (bin/[) e04425b059ff599cc672d9e0dc81e887630c6243ae0e13461a5158fea4740a64
sha3_256/1024 (bin/getfacl) 5bb9a9e1ffed1624dd9a2560e2378ac6c5ac3b071ff263b87a67160764244934
sha3_256/1024 (bin/setfacl) 1b098acf1fa48cada519a1f1e84fd87566462ae939a7976db88bdfed179287b8
%

(agc)

2022-02-15 18:14:18 UTC MAIN commitmail json YAML

Revert "i915: Defer final wakeup on active until after retirement."

This reverts i915_active.c 1.11.  ref->retire might free the object,
so touching it is not allowed -- that would use-after-free.  Linux
uses the object only for its address with wake_up_var.

The reason I made this change was that I guessed i915_active_wait has
to wait until after ref->retire finishes -- after all, Linux seems to
defer the wakeup until then.  However, even the Linux code doesn't
guarantee this, because i915_active_wait could be called _during_
ref->retire, and would witness ref->count == 0, and would not wait
until it has completed in that case.  So maybe my guess was wrong,
and it is OK for i915_active_wait to return while ref->retire is
still in flight -- I don't see any logic that obviously requires it
to wait for ref->retire, in any case.

Or maybe something does rely on i915_active_wait to wait for
ref->retire to finish, in which case we need a different mechanism
for i915_active_release itself to wait until i915_active_retire has
woken up, without dereferencing ref since it might be dead after
ref->retire.

(riastradh)

2022-02-15 16:21:35 UTC MAIN commitmail json YAML

Define becquerels in base units (like curies and rutherfords already are),
rather than in terms of curies.

Add symbol Bq for becquerel.

(jakllsch)

2022-02-15 13:44:47 UTC MAIN commitmail json YAML

fix inconsistent whitespace in units.lib

(jakllsch)

2022-02-15 12:01:55 UTC MAIN commitmail json YAML

2022-02-15 12:01:28 UTC MAIN commitmail json YAML

Add VMware AHCI and NVMe.

(msaitoh)

2022-02-14 20:37:51 UTC MAIN commitmail json YAML

i915: Defer final wakeup on active until after retirement.

Not sure what I was thinking when I moved this earlier!

(riastradh)

2022-02-14 19:13:04 UTC MAIN commitmail json YAML

linux: Don't skip the last node in rbtree iteration.

(riastradh)

2022-02-14 13:22:30 UTC MAIN commitmail json YAML

drm/mm: Find nearest geq/leq, not matching, holes in first_hole.

(riastradh)

2022-02-14 13:22:21 UTC MAIN commitmail json YAML

drm/mm: Allow hole address range queries.

(riastradh)

2022-02-14 13:22:11 UTC MAIN commitmail json YAML

drm/mm: Assert invariant of another rb lookup.

This one looks a little more questionable.

(riastradh)

2022-02-14 13:02:31 UTC MAIN commitmail json YAML

drm/mm: Assert invariant of rb lookup.

Just to make sure I didn't get the sense of the lookup reversed,
which is quite likely, because I've done it probably more than once
in this code before...

(riastradh)

2022-02-14 09:25:39 UTC MAIN commitmail json YAML

drm/ttm: Avoid uninitialized mem in error branch.

Not sure why this error branch is getting hit, but let's not make the
problem worse by choking on stack garbage.

Candidate fix for symptom of PR kern/56565, PR kern/56711.
Underlying problem -- that ttm_bo_mem_space fails with ENOMEM --
remains.

(riastradh)

2022-02-14 09:23:32 UTC MAIN commitmail json YAML

usbdi(9): Add some missing header include guards.

(riastradh)

2022-02-14 09:22:30 UTC MAIN commitmail json YAML

usbdi(9): Fix missing includes in usbdi.h.

(riastradh)

2022-02-14 08:12:48 UTC MAIN commitmail json YAML

hppa: Membar audit in cpu.c.

(riastradh)

2022-02-14 06:47:40 UTC netbsd-9 commitmail json YAML

2022-02-14 06:45:34 UTC netbsd-9 commitmail json YAML

Pull up following revision(s) (requested by martin in ticket #1427):
usr.sbin/sysinst/defs.h: revision 1.80
usr.sbin/sysinst/target.c: revision 1.18
usr.sbin/sysinst/arch/i386/md.c: revision 1.35
x86: fix previous: in the UEFI case copy the bootloaders from install
media during initial installation, but use the (by then: updated)
files from the target disk for system upgrades.

(msaitoh)

2022-02-14 00:28:33 UTC MAIN commitmail json YAML

drm: Delete mmiowb.

This no longer exists in Linux.

(riastradh)

2022-02-13 23:28:58 UTC MAIN commitmail json YAML

2022-02-13 22:20:09 UTC MAIN commitmail json YAML

2022-02-13 19:40:14 UTC MAIN commitmail json YAML

1. restore the previous finish() logic to make:
script -e -c /usr/bin/true
script -e -c /usr/bin/false
  exit with the proper exit code.
2. handle system return value correctly (nabijaczleweli)
3. factor out the conversion of wait status -> shell return code.

(christos)

2022-02-13 19:21:21 UTC MAIN commitmail json YAML

x86: Membar audit in idt.c.

- idt_vec_free/alloc are obviously supposed to synchronize with a
  happens-before relation, so use release/acquire.

- There is no store-before-load ordering needed, so omit membar_sync.

(riastradh)

2022-02-13 19:20:41 UTC MAIN commitmail json YAML

rump: Omit unused EIEIO #define, vestige of powerpc bus_dma.c.

(riastradh)

2022-02-13 19:20:33 UTC MAIN commitmail json YAML

thmap(9): Omit needless fences and use membar_exit for release fence.

It is the caller's responsibility to arrange that thmap_create, and,
if THMAP_SETROOT is set, thmap_root, happen before any use of the
thmap.  No need for them to issue fences internally.

(riastradh)

2022-02-13 19:20:23 UTC MAIN commitmail json YAML

npf(4): Use atomic_store_release and atomic_load_consume for conn_db.

...or atomic_load_relaxed, when npf->conn_lock is held, for the sake
of C11.

No need for store-before-load implied by membar_sync.

(riastradh)

2022-02-13 19:20:11 UTC MAIN commitmail json YAML

npf(4): Use atomic_store_release and atomic_load_consume for config.

...or atomic_load_relaxed, when the config is locked.  (Not necessary
to use atomic_* at all in NetBSD, but in C11 it will be cheaper to
say atomic_load_relaxed explicitly so an _Atomic-qualified object
doesn't cause the load to be surrounded by unnecessary membars.)

No need for store-before-load ordering here, so no need to
membar_sync.

(riastradh)

2022-02-13 19:07:38 UTC MAIN commitmail json YAML

vmx(4): Omit needless membar_sync wrapper.

Nothing uses this, and it is unlikely that any part of this driver
will need store-before-load ordering to synchronize with the host.

(riastradh)

2022-02-13 19:03:25 UTC MAIN commitmail json YAML

iscsi(4): Fix config_found usage -- needs kernel lock.

Candidate fix for PR kern/56709.

(riastradh)

2022-02-13 18:29:16 UTC MAIN commitmail json YAML

eqos(4): Nix trailing whitespace.  No functional change.

(riastradh)

2022-02-13 18:29:00 UTC MAIN commitmail json YAML

eqos(4): membar_* is not appropriate here; use bus_dmamap_sync.

(riastradh)

2022-02-13 16:51:56 UTC MAIN commitmail json YAML

2022-02-13 14:06:51 UTC MAIN commitmail json YAML

hppa: __cpu_simple_lock membar audit.

ok skrll

(riastradh)

2022-02-13 13:42:30 UTC MAIN commitmail json YAML

alpha: __cpu_simple_lock audit.

Add missing "cc" and "memory" asm clobbers to the compiler can't
reorder memory access around these.  The necessary memory barrier
instructions, mb, already appear in all the right places.

(riastradh)

2022-02-13 13:42:21 UTC MAIN commitmail json YAML

vax: __cpu_simple_lock audit.

Fix missing "memory" asm clobber so the compiler can't reorder memory
access around __cpu_simple_lock/lock_try/unlock.

(riastradh)

2022-02-13 13:42:12 UTC MAIN commitmail json YAML

or1k: __cpu_simple_lock membar audit.

(riastradh)

2022-02-13 13:41:53 UTC MAIN commitmail json YAML

sh3: __cpu_simple_unlock needs __insn_barrier.

No multiprocessor support here but the compiler can still reorder
memory access.

(riastradh)

2022-02-13 13:41:44 UTC MAIN commitmail json YAML

m68k: __cpu_simple_unlock audit.

- Use `cc' clobbers in asm volatile because they touch the condition
  codes.

- Use `memory' clobbers in asm volatile so the compiler doesn't move
  up loads and stores in the critical section at _other_ addresses
  than the lock so they happen before __cpu_simple_lock or
  __cpu_simple_lock_try.

- Not sure if we have any (or if there even are any?) multicore m68k
  systems out there, but __cpu_simple_unlock needs __insn_barrier
  either way so the compiler doesn't delay loads and stores prior to
  __cpu_simple_unlock so they happen after it.

(riastradh)

2022-02-13 13:41:26 UTC MAIN commitmail json YAML

acorn32: Partial __cpu_simple_lock membar audit.

For __cpu_simple_unlock, __insn_barrier is absolutely required.
Whether we need a stronger memory barrier, I don't know offhand and
I'm not sure what the right architecture manual to consult is -- it's
not clear why this isn't just using the generic arm lock.h.

(riastradh)

2022-02-13 13:41:18 UTC MAIN commitmail json YAML

sparc: __cpu_simple_lock membar audit.

No functional change -- comments only, to justify the absence of
barriers with reference to chapter & verse.

(riastradh)

2022-02-13 13:32:03 UTC MAIN commitmail json YAML

remove dup assignments (RVP)

(christos)

2022-02-13 12:48:12 UTC MAIN commitmail json YAML

indent: consistently use nparen for indexing parser_state.paren

No binary change.

(rillig)

2022-02-13 12:43:26 UTC MAIN commitmail json YAML

indent: rename parser_state.p_l_follow and paren_level

The previous variable names were misleading.

Paren_level is not the current level of parentheses but the one from the
beginning of the current output line.  For better accuracy, rename it to
line_start_paren_level.

P_l_follow is not the level of parentheses that will be active at some
point in the future, as the previous name suggested.  Instead, it is the
level of parentheses right now.  For better accuracy, rename it to
nparen.  This nicely matches its main usage, which is as index to the
parser_state.paren array.

No binary change.

(rillig)

2022-02-13 12:24:25 UTC MAIN commitmail json YAML

PR port-macppc/56091: on G5 macs we currently can not easily make
early serial console work, so keep the OF based "failsafe" console
but note that we would like to switch over.
Once zs attaches, use the new device mapping and do a belated init
of the zs console globals, and then switch over to real zs based
serial console.

(martin)

2022-02-13 12:20:10 UTC MAIN commitmail json YAML

indent: replace bitmasking code with struct

The struct directly represents the properties of a pair of parentheses,
without forcing the human reader to decode any bitset.  This makes it
easier to find the remaining bugs in the heuristic for determining the
kind of parentheses.

No functional change outside debug mode.

(rillig)

2022-02-13 12:09:19 UTC MAIN commitmail json YAML

indent: change parser_state.cast_mask to 0-based indexing

Having 1-based indexing was completely unexpected, and it didn't match
the 0-based indexing of parser_state.paren_indents.

No functional change.

(rillig)

2022-02-13 12:04:37 UTC MAIN commitmail json YAML

tests/indent: test token '('

There are already some tests in token_lparen.c that need to be merged.

(rillig)

2022-02-13 11:07:48 UTC MAIN commitmail json YAML

2022-02-13 00:39:45 UTC MAIN commitmail json YAML

2022-02-13 00:30:10 UTC MAIN commitmail json YAML

2022-02-12 23:50:14 UTC MAIN commitmail json YAML

s/Expceted/Expected/ in log message and s/attribtues/attributes/ in comment.

(andvar)

2022-02-12 23:30:30 UTC MAIN commitmail json YAML

2022-02-12 23:03:52 UTC MAIN commitmail json YAML

script: declare dooutput as __dead

This fixes the Clang build, which failed with:

usr.bin/script/script.c:255:1: error:
    function 'dooutput' could be declared with attribute 'noreturn'
    [-Werror,-Wmissing-noreturn]

(rillig)

2022-02-12 20:05:36 UTC MAIN commitmail json YAML

tests/make: clean up comments in test for indirect -k failures

See PR#49720.

(rillig)

2022-02-12 19:56:53 UTC MAIN commitmail json YAML

indent: fix indentation of enum constants in typedef (since 2019-04-04)

The solution is not elegant since it adds a small state machine inside
the parser state, but at least these states only depend on the sequence
of token types and not on any other part of the parser state.

Reported in PR#55453.

(rillig)

2022-02-12 19:46:56 UTC MAIN commitmail json YAML

tests/indent: add another test for indentation of enum constants

To prevent an overzealous quick hack for indenting enum constants in a
typedef, as part of fixing PR#55453.

(rillig)

2022-02-12 17:17:54 UTC MAIN commitmail json YAML

__cpu_simple_lock(9): Omit needless barriers in init.

It is, and always has been, the caller's responsibility to ensure the
lock is initialized before it can be used -- otherwise the memory
could hold garbage; it is nonsensical to even attempt locking
operations on it before initialization.

So there's no need to issue explicit barriers here.  The barrier
seems to have been introduced in sys/arch/alpha/alpha/lock_machdep.c
rev. 1.1 (since moved to inline asm in alpha/include/lock.h) and then
copied & pasted into several other architectures.

(riastradh)

2022-02-12 17:10:20 UTC MAIN commitmail json YAML

__cpu_simple_lock(9): New man page.

This doesn't mean you should use it!  Mostly it's to document the
semantics to help understand existing uses, which should not
proliferate, and audit definitions.

(riastradh)

2022-02-12 17:10:02 UTC MAIN commitmail json YAML

mips: Brush up __cpu_simple_lock.

- Eradicate last vestiges of mb_* barriers.

- In __cpu_simple_lock_init, omit needless barrier.  It is the
  caller's responsibility to ensure __cpu_simple_lock_init happens
  before other operations on it anyway, so there was never any need
  for a barrier here.

- In __cpu_simple_lock_try, leave comments about memory ordering
  guarantees of the kernel's _atomic_cas_uint, which are inexplicably
  different from the non-underscored atomic_cas_uint.

- In __cpu_simple_unlock, use membar_exit instead of mb_memory, and do
  it unconditionally.

  This ensures that in __cpu_simple_lock/.../__cpu_simple_unlock, all
  memory operations in the ellipsis happen before the store that
  releases the lock.

  - On Octeon, the barrier was omitted altogether, which is a bug --
    it needs to be there or else there is no happens-before relation
    and whoever takes the lock next might see stale values stored or
    even stomp over the unlocking CPU's delayed loads.

  - On non-Octeon, the mb_memory was sync.  Using membar_exit
    preserves this.

  XXX On Octeon, membar_exit only issues syncw -- this seems wrong,
  only store-before-store and not load/store-before-store, unless the
  CNMIPS architecture guarantees it is sufficient here like
  SPARCv8/v9 PSO (`Partial Store Order').

- Leave an essay with citations about why we have an apparently
  pointless syncw _after_ releasing a lock, to work around a design
  bug^W^Wquirk in cnmips which sometimes buffers stores for hundreds
  of thousands of cycles for fun unless you issue syncw.

(riastradh)

2022-02-12 17:09:44 UTC MAIN commitmail json YAML

2022-02-12 17:09:07 UTC MAIN commitmail json YAML

hppa: Membar audit in ipifuncs.c.

(riastradh)

2022-02-12 16:31:06 UTC MAIN commitmail json YAML

more __diagused to appease clang

(macallan)

2022-02-12 16:21:27 UTC MAIN commitmail json YAML

Don't dig into the guts of selinfo.

(thorpej)

2022-02-12 15:55:04 UTC MAIN commitmail json YAML

initialize ntag with the old dmatag so we never end up with an invalid one
suggested by jmcneill@

(macallan)

2022-02-12 15:51:29 UTC MAIN commitmail json YAML

Add inline functions to manipulate the klists that link up knotes
via kn_selnext:

- klist_init()
- klist_fini()
- klist_insert()
- klist_remove()

These provide some API insulation from the implementation details of these
lists (but not completely; see vn_knote_attach() and vn_knote_detach()).
Currently just a wrapper around SLIST(9).

This will make it significantly easier to switch kn_selnext linkage
to a different kind of list.

(thorpej)

2022-02-12 15:50:14 UTC MAIN commitmail json YAML

indent: extend debug logging for the parser state

The member names in struct parser_state are not trustworthy, for example
in_decl does not correspond to the intuitive definition of "inside a
declaration".  To cope with this uncertainty, output the full state of
the parser state to the debug log, not only the changes.  This helps to
track the inner state for small differences in the input, such as
between 'typedef enum { TA, TB } TT' and 'enum { EA, EB } ET'.

This hopefully helps in fixing PR#55453.

No functional change outside debug mode.

(rillig)

2022-02-12 14:59:32 UTC MAIN commitmail json YAML

libpthread: Move namespacing include to top of .c files.

Stuff like libc's namespace.h, or atomic_op_namespace.h, which does
namespacing tricks like `#define atomic_cas_uint _atomic_cas_uint',
has to go at the top of each .c file.  If it goes in the middle, it
might be too late to affect the declarations, and result in compile
errors.

I tripped over this by including <sys/atomic.h> in mips
<machine/lock.h>.

(Maybe we should create a new pthread_namespace.h file for the
purpose, but this'll do for now.)

(riastradh)

2022-02-12 13:38:29 UTC MAIN commitmail json YAML

tests/indent: demonstrate wrong formatting of enum (since 2019-04-04)

Reported by me in PR#55453.

(rillig)

2022-02-12 13:17:57 UTC MAIN commitmail json YAML

tests/make: document the history of bugs in '-k' mode

Reported in PR#49720 in 2015, fixed independently in compat.c 1.199 from
2020-12-07.

(rillig)

2022-02-12 11:14:48 UTC MAIN commitmail json YAML

make: fix echoing of command with '-' in silent target in jobs mode

Since job.c 1.83 from 2003-12-20, the command had been echoed even if
the target had the attribute '.SILENT'.

In sh-flags.exp, each removed 'echo' command is below a target name
matching the pattern 'opt-?j????-tgt-??s-cmd-?i?', which means that the
target was marked as silent, either through a global '.SILENT'
declaration or the command line option '-s' or the attribute '.SILENT'
on the target.

Reported by Alan Barrett in PR#45356.

(rillig)

2022-02-12 03:24:36 UTC MAIN commitmail json YAML

2022-02-12 02:58:50 UTC MAIN commitmail json YAML

ips(4): Missed a couple spots in device_t/softc split.

(riastradh)

2022-02-12 02:40:48 UTC MAIN commitmail json YAML

veriexec(4): Omit needless device crud in veriexec.c.

(riastradh)

2022-02-12 02:40:39 UTC MAIN commitmail json YAML

ips(4): device_t/softc split

(riastradh)

2022-02-12 02:40:28 UTC MAIN commitmail json YAML

evbppc/wdc(4) at obio: Stop fabricating bogus struct device.

Nothing uses this.

(riastradh)

2022-02-12 02:40:20 UTC MAIN commitmail json YAML

ts(4): Skip fabricating bogus struct device in tsmatch.

Doesn't appear to be used anywhere in tsmatch.  Let's not invent
bogus autoconf guts here.

(riastradh)

2022-02-12 01:23:44 UTC MAIN commitmail json YAML

2022-02-12 01:21:11 UTC MAIN commitmail json YAML

ipi(9): Document memory ordering guarantees.

(riastradh)

2022-02-12 01:15:18 UTC MAIN commitmail json YAML

2022-02-11 23:49:28 UTC MAIN commitmail json YAML

sparc64/vnet(4): device_t/softc split

(riastradh)

2022-02-11 23:49:19 UTC MAIN commitmail json YAML

2022-02-11 23:48:50 UTC MAIN commitmail json YAML

arm/samsung: Don't abuse child's dv_private for the parent's uses.

dv_private belongs to the device itself, i.e., the child here.

This overwrote the child's softc pointer, causing all kinds of havoc;
if this worked it was by an amazing accident.

(riastradh)

2022-02-11 23:48:41 UTC MAIN commitmail json YAML

exyopctl(4): Don't leak a duplicate softc on attach.

(riastradh)

2022-02-11 23:48:33 UTC MAIN commitmail json YAML

arm/ti: Omit needless dv_private assignment in omap2icu_attach.

(riastradh)

2022-02-11 23:44:18 UTC MAIN commitmail json YAML

tests/make: reproduce filesystem lookup of .PHONY nodes

As described in PR toolchain/15164.

(rillig)

2022-02-11 23:20:09 UTC MAIN commitmail json YAML

ccd(4): Fix typo in comment.

(riastradh)

2022-02-11 23:19:59 UTC MAIN commitmail json YAML

acpi(9): No need to test dv_locators.

It is always initialized by config_devalloc before config_devlink
makes it visible to device iteration.  No need to reach into private
autoconf internals.

(riastradh)

2022-02-11 23:19:43 UTC MAIN commitmail json YAML

driver(9): Correct paragraph about the driver activate function.

(riastradh)

2022-02-11 23:19:34 UTC MAIN commitmail json YAML

driver(9): Delete outdated info about softc and struct device.

(riastradh)

2022-02-11 21:44:11 UTC MAIN commitmail json YAML

make: remove comment about environment variable with empty name

At least on NetBSD, make cannot be fooled with an environment variable
having an empty name.  When running '/usr/bin/env =undefined make', the
argument is parsed as a variable assignment, but putenv(3) refuses to
process an empty variable name.  Calling execve(2) directly got a step
further, the kernel didn't filter '=undefined' from the environment
variables.  But getenv(3) always returns NULL when querying the
environment variable with the empty name.

On other operating systems, things may be different.  Trying to set an
environment variable with an empty name may cause errors in env(1),
putenv(3), execve(2), getenv(3) or other places, so don't add an
automatic test for now.

(rillig)

2022-02-11 21:40:59 UTC MAIN commitmail json YAML

libpthread: Fix membars around rwlocks.

1. After loading self->pt_rwlocked, membar_enter() must not be
  conditional on PTHREAD__ATOMIC_IS_MEMBAR because there is no
  atomic r/m/w operation here which could imply the acquire barrier.

  (This should maybe just be a load-acquire operation, but we don't
  have atomic_load_acquire in userland at the moment -- TBD.)

2. Before storing thread->pt_rwlocked, must issue membar_exit() so
  that this is a store-release operation -- except if we had just
  done an atomic r/m/w and PTHREAD__ATOMIC_IS_MEMBAR is set, in
  which case it can be elided.

  The second membar_exit() added here might be safely hoisted out of
  the loop but I'm not sure -- needs more analysis to prove that
  would be safe.

(riastradh)

2022-02-11 21:36:46 UTC MAIN commitmail json YAML

libc/getenv: remove trailing whitespace

No binary change.

(rillig)

2022-02-11 21:18:10 UTC MAIN commitmail json YAML

make: simplify control flow in CondParser_Comparison

No functional change.

(rillig)

2022-02-11 21:15:25 UTC MAIN commitmail json YAML

PR/56254: RVP: Don't call non-async-signal-safe functions from signal handlers.
Establish a non-restart signal handler to avoid blocking in long I/Os.

(christos)

2022-02-11 17:53:28 UTC MAIN commitmail json YAML

ucas(9): Membar audit.

- Omit needless membar_enter before ipi_trigger_broadcast.  This was
  presumably intended to imply a happens-before relation for the
  following two CPUs:

/* CPU doing ucas */
ucas_critical_enter()
ucas_critical_pausing_cpus = ncpu - 1 (A)
ipi_trigger_broadcast()

/* other CPU walking by whistling innocently */
IPI handler
ucas_critical_cpu_gate()
load ucas_critical_pausing_cpus (B)

  That is, this was presumably meant to ensure (A) happens-before (B).
  This relation is already guaranteed by ipi(9), so there is no need
  for any explicit memory barrier.

- Issue a store-release in ucas_critical_cpu_gate so we have the
  following happens-before relation which was otherwise not guaranteed
  except if __HAVE_ATOMIC_AS_MEMBAR:

/* other CPU walking by whistling innocently */
...other logic touching the target ucas word... (A)
IPI handler
ucas_critical_cpu_gate()
...
atomic_dec_uint(&ucas_critical_pausing_cpus)

  happens-before

/* CPU doing ucas */
ucas_critical_enter() -> ucas_critical_wait();
...touching the word with ufetch/ustore... (B)

  We need to ensure the logic (A) on another CPU touching the target
  ucas word happens-before we actually do the ucas at (B).

  (a) This requires the other CPU to do a store-release on
      ucas_critical_pausing_cpus in ucas_critical_cpu_gate, and

  (b) this requires the ucas CPU to do a load-acquire on
      ucas_critical_pausing_cpus in ucas_critical_wait.

  Without _both_ sides -- store-release and then load-acquire -- there
  is no such happens-before guarantee; another CPU may have a buffered
  store, for instance, that clobbers the ucas.

  For now, do the store-release with membar_exit conditional on
  __HAVE_ATOMIC_AS_MEMBAR and then atomic_dec_uint -- later with the
  C11 API we can dispense with the #ifdef and just use
  atomic_fetch_add_explicit(..., memory_order_release).  The
  load-acquire we can do with atomic_load_acquire.

- Issue a load-acquire in ucas_critical_cpu_gate so we have the
  following happens-before relation which was otherwise not guaranteed:

/* CPU doing ucas */
...ufetch/ustore... (A)
ucas_critical_exit()
ucas_critical_pausing_cpus = -1;

/* other CPU walking by whistling innocently */
IPI handler
ucas_critical_cpu_gate()
...
while (ucas_critical_pausing_cpus != -1)
spin;
...other logic touching the target ucas word... (B)

  We need to ensure the logic (A) to do the ucas happens-before logic
  that might use it on another CPU at (B).

  (a) This requires that the ucas CPU do a store-release on
      ucas_critical_pausing_cpus in ucas_critical_exit, and

  (b) this requires that the other CPU do a load-acquire on
      ucas_critical_pausing_cpus in ucas_critical_cpu_gate.

  Without _both_ sides -- store-release and then load-acquire -- there
  is no such happens-before guarantee; the other CPU might witness a
  cached stale value of the target location but a new value of some
  other location in the wrong order.

- Use atomic_load/store_* to avoid the appearance of races, e.g. for
  sanitizers.

- Document which barriers pair up with which barriers and what they're
  doing.

(riastradh)

2022-02-11 17:30:48 UTC MAIN commitmail json YAML

playstation2: Fix some pre-device_t/softc-split device private sizes.

Nothing appears to use device_private here, so let's not allocate
anything or ask for sizeof(struct device).

(riastradh)

2022-02-11 17:26:56 UTC MAIN commitmail json YAML

vax: Remove a vestige from before the device_t/softc split.

Verified MicroVAX 4000/96 still boots.

cpu0 at mainbus0: KA49, NVAX, 10KB L1 cache, 256KB L2 cache

(riastradh)

2022-02-11 16:33:18 UTC MAIN commitmail json YAML

Translate 254/255 compID values used for deleted entries as per UDF spec. This
allows the printing of the names of deleted file entries.

(reinoud)