CVS commit: src/external/cddl/osnet/dev/fbt/x86

2021-08-18 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Wed Aug 18 11:26:17 UTC 2021

Modified Files:
src/external/cddl/osnet/dev/fbt/x86: fbt_isa.c

Log Message:
PR/56355: Exclude the symbol trap, not all symbols other than trap.


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 src/external/cddl/osnet/dev/fbt/x86/fbt_isa.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/arch/arm/sunxi

2021-08-07 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Aug  7 15:41:01 UTC 2021

Modified Files:
src/sys/arch/arm/sunxi: sun8i_crypto.c

Log Message:
sun8icrypto(4): Call crypto_unblock when a task completes.

Otherwise under load this would presumably just hang after returning
ERESTART to opencrypto.


To generate a diff of this commit:
cvs rdiff -u -r1.25 -r1.26 src/sys/arch/arm/sunxi/sun8i_crypto.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/external/bsd/drm2/linux

2021-08-02 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Mon Aug  2 23:14:15 UTC 2021

Modified Files:
src/sys/external/bsd/drm2/linux: linux_reservation.c

Log Message:
drm: Plug another fence leak.

XXX pullup-9


To generate a diff of this commit:
cvs rdiff -u -r1.13 -r1.14 \
src/sys/external/bsd/drm2/linux/linux_reservation.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/external/bsd/drm2/linux

2021-08-02 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Mon Aug  2 20:20:54 UTC 2021

Modified Files:
src/sys/external/bsd/drm2/linux: linux_reservation.c

Log Message:
drm: Release fence if we're about to return too.

Should fix another fence leak.

XXX pullup-9


To generate a diff of this commit:
cvs rdiff -u -r1.12 -r1.13 \
src/sys/external/bsd/drm2/linux/linux_reservation.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/pci

2021-07-17 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jul 17 10:45:58 UTC 2021

Modified Files:
src/sys/dev/pci: pucdata.c

Log Message:
puc(4): Add Intel Core 5G (mobile) KT.


To generate a diff of this commit:
cvs rdiff -u -r1.109 -r1.110 src/sys/dev/pci/pucdata.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev

2021-06-30 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Wed Jun 30 17:34:03 UTC 2021

Modified Files:
src/sys/dev: devlist2h.awk

Log Message:
devlist2h.awk: Nix trailing whitespace.

No functional change intended.


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/sys/dev/devlist2h.awk

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/net

2021-06-29 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Tue Jun 29 21:19:58 UTC 2021

Modified Files:
src/sys/net: if.c if.h if_stats.c if_stats.h

Log Message:
Make if_stats_init, if_attach, if_initialize return void.

percpu_alloc can't fail.

Author: Maya Rashish 
Committer: Taylor R Campbell 


To generate a diff of this commit:
cvs rdiff -u -r1.485 -r1.486 src/sys/net/if.c
cvs rdiff -u -r1.290 -r1.291 src/sys/net/if.h
cvs rdiff -u -r1.3 -r1.4 src/sys/net/if_stats.c
cvs rdiff -u -r1.2 -r1.3 src/sys/net/if_stats.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/external/bsd/drm2/linux

2021-06-27 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sun Jun 27 08:10:36 UTC 2021

Modified Files:
src/sys/external/bsd/drm2/linux: linux_reservation.c

Log Message:
drm: Release fence after use.

May plug the dreaded radeon kmem memory leak.

XXX pullup-9


To generate a diff of this commit:
cvs rdiff -u -r1.11 -r1.12 \
src/sys/external/bsd/drm2/linux/linux_reservation.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/pci

2021-06-24 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Thu Jun 24 09:17:53 UTC 2021

Modified Files:
src/sys/dev/pci: if_iwm.c

Log Message:
iwm(4): Disentangle attach.

Don't attach a half-baked interface and then detach it and then
reattach it after mountroot when we can read firmware; just defer
attaching the interface altogether until mountroot.

Likely fixes some panics I've seen every now and then at boot with
iwm(4).


To generate a diff of this commit:
cvs rdiff -u -r1.86 -r1.87 src/sys/dev/pci/if_iwm.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/usb

2021-06-24 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Thu Jun 24 08:20:42 UTC 2021

Modified Files:
src/sys/dev/usb: ucom.c

Log Message:
ucom(4): Fix earlier mistake causing pipes not to be closed.

In revision 1.123, mrg@ changed what he thought was a double-close,
but was actually abort&close (as is appropriate) to just abort (which
is not enough -- leaks the pipe).  This restores the abort&close.

The original `bug' was found by code inspection, whereas this bug was
found by asserting in usb_subr.c that no pipes are open on device
disconnection after detach; the asserts actually triggered with
several ucom(4) devices, and no longer trigger with this change.

XXX pullup-9


To generate a diff of this commit:
cvs rdiff -u -r1.128 -r1.129 src/sys/dev/usb/ucom.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sbin/restore

2021-06-23 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Wed Jun 23 14:22:08 UTC 2021

Modified Files:
src/sbin/restore: dirs.c

Log Message:
restore(8): Mark fail_dirtmp __dead to fix clang build.


To generate a diff of this commit:
cvs rdiff -u -r1.52 -r1.53 src/sbin/restore/dirs.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/external/gpl3/gdb/bin/gdbserver

2021-06-20 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sun Jun 20 12:29:58 UTC 2021

Modified Files:
src/external/gpl3/gdb/bin/gdbserver: Makefile

Log Message:
gdbserver(1): Work around clang build failure.


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/external/gpl3/gdb/bin/gdbserver/Makefile

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/share/misc

2021-06-18 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Fri Jun 18 21:58:20 UTC 2021

Modified Files:
src/share/misc: acronyms acronyms.comp

Log Message:
EEE: embrace, extend, extinguish; or eastern equine encephalitis


To generate a diff of this commit:
cvs rdiff -u -r1.309 -r1.310 src/share/misc/acronyms
cvs rdiff -u -r1.323 -r1.324 src/share/misc/acronyms.comp

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/tests/net/if_wg

2021-06-17 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Thu Jun 17 12:45:59 UTC 2021

Modified Files:
src/tests/net/if_wg: t_misc.sh

Log Message:
tests/net/if_wg: Only expect this to fail once!

Not sure how that happened, weird artefact of applying fuzzy patch
twice or something.


To generate a diff of this commit:
cvs rdiff -u -r1.9 -r1.10 src/tests/net/if_wg/t_misc.sh

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/tests/net/if_wg

2021-06-17 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Thu Jun 17 12:16:09 UTC 2021

Modified Files:
src/tests/net/if_wg: t_misc.sh

Log Message:
tests/net/if_wg: Mark as flaky (PR kern/56252).


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/tests/net/if_wg/t_misc.sh

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/tests/fs/tmpfs

2021-06-16 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Thu Jun 17 00:03:05 UTC 2021

Modified Files:
src/tests/fs/tmpfs: t_times.sh

Log Message:
tests/fs/tmpfs: Print bad values on failure for diagnosis.


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 src/tests/fs/tmpfs/t_times.sh

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/tests/fs/vfs

2021-06-16 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Wed Jun 16 23:58:07 UTC 2021

Modified Files:
src/tests/fs/vfs: t_renamerace.c

Log Message:
tests/fs/vfs: Mark udf_renamerace_cycle flaky, PR kern/56253.


To generate a diff of this commit:
cvs rdiff -u -r1.40 -r1.41 src/tests/fs/vfs/t_renamerace.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/tests/net/if_wg

2021-06-16 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Wed Jun 16 23:45:53 UTC 2021

Modified Files:
src/tests/net/if_wg: t_misc.sh

Log Message:
tests/net/if_wg: Fix typo: $ifconfig, not $ifconfg.


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/tests/net/if_wg/t_misc.sh

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sbin/cgdconfig

2021-06-16 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Wed Jun 16 23:22:08 UTC 2021

Modified Files:
src/sbin/cgdconfig: cgdconfig.c

Log Message:
cgdconfig(8): Fail more gracefully than SIGSEGV if shell_cmd fails.


To generate a diff of this commit:
cvs rdiff -u -r1.51 -r1.52 src/sbin/cgdconfig/cgdconfig.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/libexec/ld.elf_so

2021-06-16 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Wed Jun 16 21:53:51 UTC 2021

Modified Files:
src/libexec/ld.elf_so: rtld.c

Log Message:
ld.elf_so(1): Omit needless membar_enter.

The use of membar_enter is to separate atomic r/m/w on a lock from
the body of the critical section so two different critical sections
happen in order:

body of previous critical section;

exit critical section:
membar_exit();
atomic_r/m/w(lock stuff);

enter critical section:
atomic_r/m/w(lock stuff);
membar_enter();

body of next critical section;

_rtld_shared_enter does this, but it _also_ issued an extraneous
membar_enter before the atomic_r/m/w part, which doesn't impose any
semantically important order but may cost some performance.


To generate a diff of this commit:
cvs rdiff -u -r1.208 -r1.209 src/libexec/ld.elf_so/rtld.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/usb

2021-06-16 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Wed Jun 16 13:20:49 UTC 2021

Modified Files:
src/sys/dev/usb: usbdi.c

Log Message:
usb(4): Fix uninitialized variable for error branch.


To generate a diff of this commit:
cvs rdiff -u -r1.217 -r1.218 src/sys/dev/usb/usbdi.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src

2021-06-15 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Wed Jun 16 00:21:20 UTC 2021

Modified Files:
src/share/man/man4: usbnet.4
src/sys/arch/arm/broadcom: bcm53xx_eth.c
src/sys/arch/powerpc/booke/dev: pq3etsec.c
src/sys/arch/usermode/dev: if_veth.c
src/sys/dev/hyperv: if_hvn.c
src/sys/dev/ic: an.c athn.c atw.c bwfm.c bwi.c dwc_gmac.c malo.c
rt2560.c rt2661.c rt2860.c rtw.c wi.c
src/sys/dev/pci: if_aq.c if_iavf.c if_ipw.c if_iwi.c if_iwm.c if_iwn.c
if_ixl.c if_rtwn.c if_wm.c if_wpi.c
src/sys/dev/pci/ixgbe: ixgbe.c ixv.c
src/sys/dev/pcmcia: if_malo_pcmcia.c
src/sys/dev/scsipi: if_se.c
src/sys/dev/usb: if_umb.c usbnet.c
src/sys/net: if_arcsubr.c if_bridge.c if_faith.c if_gif.c if_l2tp.c
if_loop.c if_mpls.c if_pppoe.c if_srt.c if_stf.c if_tap.c if_vlan.c
if_wg.c
src/sys/net/lagg: if_lagg.c
src/sys/netinet: ip_carp.c
src/sys/rump/net/lib/libshmif: if_shmem.c
src/sys/rump/net/lib/libvirtif: if_virt.c

Log Message:
if_attach and if_initialize cannot fail, don't test return value

These were originally made failable back in 2017 when if_initialize
allocated a softint in every interface for link state changes, so
that it could fail gracefully instead of panicking:

https://mail-index.NetBSD.org/source-changes/2017/10/23/msg089053.html

However, this spawned many seldom- or never-tested error branches,
which are risky to have around.  And that softint in every interface
has since been replaced by a single global workqueue, because link
state changes require thread context but not low latency or high
throughput:

https://mail-index.NetBSD.org/source-changes/2020/02/06/msg113759.html

So there is no longer any reason for if_initialize to fail.  (The
subroutine if_stats_init can't fail because percpu_alloc can't fail
either.)

There is a snag: the softint_establish in if_percpuq_create could
fail, potentially leading to bad consequences later on trying to use
the softint.  This change doesn't introduce any new bugs because of
the snag -- if_percpuq_attach was already broken.  However, the snag
can be better addressed without spawning error branches, either by
using a single softint or making softints less scarce.

(Separate commit will change the signatures of if_attach and
if_initialize to return void, scheduled to ride whatever is the next
convenient kernel bump.)

Patch and testing on amd64 and evbmips64-eb by maya@; commit message
soliloquy, and compile-testing on evbppc/i386/earmv7hf, by me.


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/share/man/man4/usbnet.4
cvs rdiff -u -r1.40 -r1.41 src/sys/arch/arm/broadcom/bcm53xx_eth.c
cvs rdiff -u -r1.54 -r1.55 src/sys/arch/powerpc/booke/dev/pq3etsec.c
cvs rdiff -u -r1.14 -r1.15 src/sys/arch/usermode/dev/if_veth.c
cvs rdiff -u -r1.20 -r1.21 src/sys/dev/hyperv/if_hvn.c
cvs rdiff -u -r1.74 -r1.75 src/sys/dev/ic/an.c
cvs rdiff -u -r1.24 -r1.25 src/sys/dev/ic/athn.c
cvs rdiff -u -r1.170 -r1.171 src/sys/dev/ic/atw.c
cvs rdiff -u -r1.30 -r1.31 src/sys/dev/ic/bwfm.c
cvs rdiff -u -r1.37 -r1.38 src/sys/dev/ic/bwi.c
cvs rdiff -u -r1.73 -r1.74 src/sys/dev/ic/dwc_gmac.c
cvs rdiff -u -r1.18 -r1.19 src/sys/dev/ic/malo.c
cvs rdiff -u -r1.38 -r1.39 src/sys/dev/ic/rt2560.c
cvs rdiff -u -r1.43 -r1.44 src/sys/dev/ic/rt2661.c
cvs rdiff -u -r1.35 -r1.36 src/sys/dev/ic/rt2860.c
cvs rdiff -u -r1.135 -r1.136 src/sys/dev/ic/rtw.c
cvs rdiff -u -r1.255 -r1.256 src/sys/dev/ic/wi.c
cvs rdiff -u -r1.26 -r1.27 src/sys/dev/pci/if_aq.c
cvs rdiff -u -r1.13 -r1.14 src/sys/dev/pci/if_iavf.c
cvs rdiff -u -r1.73 -r1.74 src/sys/dev/pci/if_ipw.c
cvs rdiff -u -r1.115 -r1.116 src/sys/dev/pci/if_iwi.c
cvs rdiff -u -r1.85 -r1.86 src/sys/dev/pci/if_iwm.c
cvs rdiff -u -r1.95 -r1.96 src/sys/dev/pci/if_iwn.c
cvs rdiff -u -r1.76 -r1.77 src/sys/dev/pci/if_ixl.c
cvs rdiff -u -r1.19 -r1.20 src/sys/dev/pci/if_rtwn.c
cvs rdiff -u -r1.704 -r1.705 src/sys/dev/pci/if_wm.c
cvs rdiff -u -r1.90 -r1.91 src/sys/dev/pci/if_wpi.c
cvs rdiff -u -r1.283 -r1.284 src/sys/dev/pci/ixgbe/ixgbe.c
cvs rdiff -u -r1.161 -r1.162 src/sys/dev/pci/ixgbe/ixv.c
cvs rdiff -u -r1.25 -r1.26 src/sys/dev/pcmcia/if_malo_pcmcia.c
cvs rdiff -u -r1.112 -r1.113 src/sys/dev/scsipi/if_se.c
cvs rdiff -u -r1.19 -r1.20 src/sys/dev/usb/if_umb.c
cvs rdiff -u -r1.41 -r1.42 src/sys/dev/usb/usbnet.c
cvs rdiff -u -r1.82 -r1.83 src/sys/net/if_arcsubr.c
cvs rdiff -u -r1.179 -r1.180 src/sys/net/if_bridge.c
cvs rdiff -u -r1.61 -r1.62 src/sys/net/if_faith.c
cvs rdiff -u -r1.154 -r1.155 src/sys/net/if_gif.c
cvs rdiff -u -r1.46 -r1.47 src/sys/net/if_l2tp.c
cvs rdiff -u -r1.112 -r1.113 src/sys/net/if_loop.c
cvs rdiff -u -r1.36 -r1.37 src/sys/net/if_mpls.c
cvs rdiff -u -r1.176 -r1.177 src/sys/net/if_pppoe.c
cvs rdiff -u -r1.31 -r1.32 src/sys/net/if_srt.c
cvs rdiff -u -r1.107 -r1.108 src/sys/net/if_stf.c
cvs rdiff -u -r1.121 -r1.122 src/sys/net/if_tap.c
cvs rdiff -u -r1.153 -r1.154 

CVS commit: src/sys/kern

2021-06-15 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Wed Jun 16 00:19:46 UTC 2021

Modified Files:
src/sys/kern: kern_drvctl.c

Log Message:
drvctl(4): If no ifattr is specified on rescan, rescan all of them.

No longer must you remember the magic `-a ata_hl' incantation when
you deign to `drvctl -r atabusN'.  It didn't actually do anything
anyway: atabus_rescan always rescans all ifattrs; same with
uhub_rescan and many others.


To generate a diff of this commit:
cvs rdiff -u -r1.48 -r1.49 src/sys/kern/kern_drvctl.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/usb

2021-06-15 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Tue Jun 15 23:39:43 UTC 2021

Modified Files:
src/sys/dev/usb: ohci.c

Log Message:
ohci(4): Constify a constant debug string table.


To generate a diff of this commit:
cvs rdiff -u -r1.315 -r1.316 src/sys/dev/usb/ohci.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev

2021-06-15 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Tue Jun 15 23:24:57 UTC 2021

Modified Files:
src/sys/dev: dev_verbose.h

Log Message:
dev_verbose(9): Use a comma expression, not an expression block.

Should pacify clang's -Wcompound-token-split-by-macro.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/sys/dev/dev_verbose.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev

2021-06-14 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Tue Jun 15 00:20:33 UTC 2021

Modified Files:
src/sys/dev: ipmi.c

Log Message:
ipmi(4): Tidy up ipmi_thread a little.

- Join on detach -- don't free anything until thread has exited; thread
  may still be using stuff.
- Nix dead error branch -- malloc(M_WAITOK) cannot fail.
- x = malloc(sizeof(x[0]) * n), not x = malloc(sizeof(type_t) * n)


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/dev/ipmi.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev

2021-06-14 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Mon Jun 14 22:00:10 UTC 2021

Modified Files:
src/sys/dev: ipmi.c

Log Message:
ipmi(4): Notify config_pending_decr when ready, not when dying.

Should fix hang at boot.


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/sys/dev/ipmi.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/pad

2021-06-14 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Mon Jun 14 18:44:53 UTC 2021

Modified Files:
src/sys/dev/pad: pad.c

Log Message:
pad(4): Explain what's wrong with using device pointers like this.

...and why the kernel lock is not enough.


To generate a diff of this commit:
cvs rdiff -u -r1.74 -r1.75 src/sys/dev/pad/pad.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/pad

2021-06-14 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Mon Jun 14 18:44:45 UTC 2021

Modified Files:
src/sys/dev/pad: pad.c padvar.h

Log Message:
pad(4): Omit unused sc_blksize.


To generate a diff of this commit:
cvs rdiff -u -r1.73 -r1.74 src/sys/dev/pad/pad.c
cvs rdiff -u -r1.15 -r1.16 src/sys/dev/pad/padvar.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/pad

2021-06-14 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Mon Jun 14 18:44:37 UTC 2021

Modified Files:
src/sys/dev/pad: pad.c

Log Message:
pad(4): Refactor for clarity, and fix locking bugs.

- Don't touch sc_buflen outside sc_intr_lock.

- Omit needless broadcast in pad_halt_output -- nothing wakes on the
  new condition (sc_buflen == 0), so this can't make a difference
  except possibly in buggy code.

- Sprinkle KASSERTs.


To generate a diff of this commit:
cvs rdiff -u -r1.72 -r1.73 src/sys/dev/pad/pad.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/pad

2021-06-14 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Mon Jun 14 10:21:21 UTC 2021

Modified Files:
src/sys/dev/pad: pad.c

Log Message:
pad(4): Destroy the callout when done.

Should not be possible for it to be pending or firing at this point,
because we have detached the audio(4) child and so it should have
halted output.


To generate a diff of this commit:
cvs rdiff -u -r1.71 -r1.72 src/sys/dev/pad/pad.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/pad

2021-06-14 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Mon Jun 14 10:14:58 UTC 2021

Modified Files:
src/sys/dev/pad: pad.c

Log Message:
pad(4): Make this exclusively a cloning device.

padN numbering never corresponded with audioM numbering except by
accident, so the non-cloning device never worked reliably for
scripting.  This simplifies the logic substantially.

While here, fix drvctl detach race.


To generate a diff of this commit:
cvs rdiff -u -r1.70 -r1.71 src/sys/dev/pad/pad.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/pad

2021-06-14 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Mon Jun 14 10:14:46 UTC 2021

Modified Files:
src/sys/dev/pad: pad.c padvar.h

Log Message:
pad(4): Sort includes.  Add missing includes to padvar.h.


To generate a diff of this commit:
cvs rdiff -u -r1.69 -r1.70 src/sys/dev/pad/pad.c
cvs rdiff -u -r1.14 -r1.15 src/sys/dev/pad/padvar.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/pad

2021-06-14 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Mon Jun 14 10:14:01 UTC 2021

Modified Files:
src/sys/dev/pad: pad.c padvar.h

Log Message:
pad(4): Fix some locking.

- No need for sc_cond_lock.
- Issue cv_broadcast under the correct lock.
- Use callout_halt, not haphazard callout_stop.
- IPL_SOFTCLOCK for a mutex taken from a callout.


To generate a diff of this commit:
cvs rdiff -u -r1.68 -r1.69 src/sys/dev/pad/pad.c
cvs rdiff -u -r1.13 -r1.14 src/sys/dev/pad/padvar.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/pad

2021-06-13 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Mon Jun 14 00:21:09 UTC 2021

Modified Files:
src/sys/dev/pad: pad.c

Log Message:
pad(4): Some incomplete tidying.

- Put pseudo-device softc setup/teardown back in pad_attach/detach,
  not in the cdev/fops operations which are about file descriptors.
- Remove unnecessary sc_dying flag.
- Omit needless config_deactivate(sc->sc_audiodev); the only effect
  of this is already done by config_detach anyway, which is done in
  the same context.
- Issue config_detach_children and free softc stuff in the right
  order.
- Omit needless `if (sc == NULL) return ENXIO'.

Survives eight parallel t_mixerctl tests many times over on an
8-thread/4-core machine.

XXX TODO:
- Remove padconfig; it is not appropriate to hold a mutex over
  sleeping allocation or autoconf config_attach operations.  This
  should be done another way.
- Fix agreement of sc_condvar with locks: is it sc_cond_lock or
  sc_intr_lock?  Can't be both; unclear why both exist.
- Determine whether both cdev and fops are really needed -- it is
  confusing to have two types of paths into all this logic, and it
  seems to me only one of them should be necessary.


To generate a diff of this commit:
cvs rdiff -u -r1.67 -r1.68 src/sys/dev/pad/pad.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/pad

2021-06-13 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sun Jun 13 23:09:23 UTC 2021

Modified Files:
src/sys/dev/pad: pad.c

Log Message:
pad(4): Take kernel lock around autoconf stuff.

This is not really enough -- the padconfig locking logic violates
rules about sleeping while holding locks, might be deadlocky, and may
also be racy.  But, it'll serve to make progress.


To generate a diff of this commit:
cvs rdiff -u -r1.66 -r1.67 src/sys/dev/pad/pad.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/usb

2021-06-13 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sun Jun 13 14:48:10 UTC 2021

Modified Files:
src/sys/dev/usb: uhub.c usb.c usb_subr.c usbdi.h

Log Message:
usb(4): Bus exploration is single-threaded -- assert it so.

New usb_in_event_thread(dev) returns true if dev is a USB device --
that is, a device with a usbN ancestor -- and the current thread is
the USB event thread.

(Kinda kludgey to pass around the device_t instead of, say, struct
usbd_bus, but I don't see a good way to get to the usbN device_t or
struct usb_softc from there.)


To generate a diff of this commit:
cvs rdiff -u -r1.152 -r1.153 src/sys/dev/usb/uhub.c
cvs rdiff -u -r1.195 -r1.196 src/sys/dev/usb/usb.c
cvs rdiff -u -r1.264 -r1.265 src/sys/dev/usb/usb_subr.c
cvs rdiff -u -r1.102 -r1.103 src/sys/dev/usb/usbdi.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/usb

2021-06-13 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sun Jun 13 14:46:07 UTC 2021

Modified Files:
src/sys/dev/usb: uhub.c

Log Message:
uhub(4): Defer rescan to USB event thread.

Keep all of the USB bus exploration in a single thread -- this
appears to have been the original assumption, violated back in 2008
when uhub_rescan was added, and will make everything simpler.


To generate a diff of this commit:
cvs rdiff -u -r1.151 -r1.152 src/sys/dev/usb/uhub.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/tests/dev/sysmon

2021-06-13 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sun Jun 13 14:45:36 UTC 2021

Modified Files:
src/tests/dev/sysmon: t_swsensor.sh

Log Message:
tests/dev/sysmon: Query bits of data, not bits of entropy.

Fixes PR kern/47661.


To generate a diff of this commit:
cvs rdiff -u -r1.11 -r1.12 src/tests/dev/sysmon/t_swsensor.sh

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/kern

2021-06-13 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sun Jun 13 09:30:48 UTC 2021

Modified Files:
src/sys/kern: subr_autoconf.c

Log Message:
autoconf(9): Take kernel lock in config_detach.

config_detach is used in too many places to audit for now -- so
although I'm quite sure it is racy (e.g., with cloning devices and
drvctl: drvctl -d a newly opened fss0 before sc_state has
transitioned from FSS_IDLE), this will mitigate the immediate fallout
until we can properly fix autoconf's notions of device pointers.


To generate a diff of this commit:
cvs rdiff -u -r1.286 -r1.287 src/sys/kern/subr_autoconf.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/usb

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sun Jun 13 00:13:24 UTC 2021

Modified Files:
src/sys/dev/usb: usb_subr.c usbdi.c usbdivar.h

Log Message:
usb(4): Tighten interface locking and pipe references.

- Just use a reference count, not a list of pipes.

- Take the reference in usbd_open_pipe*, before we even look up the
  endpoint by address; the endpoint is not stable until we hold the
  interface and prevent usbd_set_interface.

- Make opening pipes just fail if usbd_set_interface is in progress.
  => No need to block -- might block for a while, and this is
 essentially a driver error rather than a legitimate reason to
 block.
  => This should maybe be a kassert, but it's not clear that ugen(4)
 doesn't have a user-triggerable path to that kassert, so let's
 keep it as a graceful failure for now until someone can audit
 ugen(4) and make an informed decision.

- No need for a separate interface pipe lock; just use the bus lock.

This is a little bit longer than before, but makes the bracketed
nature of the references a little clearer and introduces more
kasserts to detect mistakes with internal API usage.


To generate a diff of this commit:
cvs rdiff -u -r1.260 -r1.261 src/sys/dev/usb/usb_subr.c
cvs rdiff -u -r1.215 -r1.216 src/sys/dev/usb/usbdi.c
cvs rdiff -u -r1.127 -r1.128 src/sys/dev/usb/usbdivar.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/usb

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sun Jun 13 00:11:57 UTC 2021

Modified Files:
src/sys/dev/usb: uhub.c

Log Message:
uhub(4): Trigger bus exploration after rescanning children.

Otherwise, if uhub4 is attached at uhub1, then when we do

# drvctl -d uhub4
# drvctl -r -a usbdevif uhub1

the rescan never discovers devices attached recursively at uhub4, and
uhub4 leaks a config_pending_incr count so it can't be detached.


To generate a diff of this commit:
cvs rdiff -u -r1.150 -r1.151 src/sys/dev/usb/uhub.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/kern

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sun Jun 13 00:11:46 UTC 2021

Modified Files:
src/sys/kern: subr_autoconf.c

Log Message:
autoconf(9): Sprinkle KASSERT(dev->dv_pending == 0) in dealloc paths.

This would have made uhub's config_pending_incr leak more obvious by
crashing in KASSERT(dev->dv_pending == 0) early on, rather than
crashing in a tailq panic later on when the config_pending list gets
corrupted with use-after-free because nothing took the device off
dv_pending_list when attached.

(This is slightly academic now because config_detach blocks until
dev->dv_pending == 0, but it doesn't hurt and makes the intent
clearer.)


To generate a diff of this commit:
cvs rdiff -u -r1.285 -r1.286 src/sys/kern/subr_autoconf.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/kern

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sun Jun 13 00:11:17 UTC 2021

Modified Files:
src/sys/kern: subr_autoconf.c

Log Message:
autoconf(9): Take kernel lock in a few entry points.

The arguments to config_attach_pseudo, config_init/fini_component,
and config_cfdata_attach/detach are generally statically allocated
objects in a module or the main kernel and as such are stable, and
there are no data structure invariants they assume the kernel lock
will covers from call to call.  So there should be no need for the
caller to hold the kernel lock.

Should fix panic on modload of, e.g., nvmm.


To generate a diff of this commit:
cvs rdiff -u -r1.284 -r1.285 src/sys/kern/subr_autoconf.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/usb

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 15:49:45 UTC 2021

Modified Files:
src/sys/dev/usb: usb_subr.c usbdi.c usbdivar.h

Log Message:
usb(4): Nix unused struct usbd_interface::ui_priv.


To generate a diff of this commit:
cvs rdiff -u -r1.259 -r1.260 src/sys/dev/usb/usb_subr.c
cvs rdiff -u -r1.214 -r1.215 src/sys/dev/usb/usbdi.c
cvs rdiff -u -r1.126 -r1.127 src/sys/dev/usb/usbdivar.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/usb

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 15:41:22 UTC 2021

Modified Files:
src/sys/dev/usb: usb_subr.c usbdi.c

Log Message:
usb(4): Make usbd_fill_iface_data atomic.

Now either it replaces and frees the old endpoints array, or it
leaves everything in place; it never leaves a partial update nor
requires the caller to free the old array.


To generate a diff of this commit:
cvs rdiff -u -r1.258 -r1.259 src/sys/dev/usb/usb_subr.c
cvs rdiff -u -r1.213 -r1.214 src/sys/dev/usb/usbdi.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/usb

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 15:40:07 UTC 2021

Modified Files:
src/sys/dev/usb: usbdi.c

Log Message:
usb(4): Tweak style in usbd_close_pipe.

No functional change intended.


To generate a diff of this commit:
cvs rdiff -u -r1.212 -r1.213 src/sys/dev/usb/usbdi.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/usb

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 15:39:57 UTC 2021

Modified Files:
src/sys/dev/usb: usb_subr.c usbdi.c

Log Message:
usb(4): Merge logic in usbd_kill_pipe and usbd_close_pipe.

usbd_kill_pipe is now just usbd_abort/close_pipe.

No functional change intended.


To generate a diff of this commit:
cvs rdiff -u -r1.257 -r1.258 src/sys/dev/usb/usb_subr.c
cvs rdiff -u -r1.211 -r1.212 src/sys/dev/usb/usbdi.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/usb

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 15:39:46 UTC 2021

Modified Files:
src/sys/dev/usb: usb_subr.c usbdi.c

Log Message:
usb(4): Fix fix for interface change pipe fix.

If there is an interface:
- Always put the pipe on the list in usbd_setup_pipe (if successful).
- Always have the pipe on the list from _before_ upm_open.
- Always keep the pipe on the list to _after_ upm_close, and after
  the async task has completed.

This brings the logic in usbd_close_pipe and usbd_kill_pipe closer.


To generate a diff of this commit:
cvs rdiff -u -r1.256 -r1.257 src/sys/dev/usb/usb_subr.c
cvs rdiff -u -r1.210 -r1.211 src/sys/dev/usb/usbdi.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/usb

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 15:09:18 UTC 2021

Modified Files:
src/sys/dev/usb: usbdi.c

Log Message:
Revert "usb(4): Fix mistake in previous fix for pipe/interface-change races."

Little too fast on the commit trigger there before testing, oops.
We don't have the pipe yet until usbd_setup_pipe_flags returns!


To generate a diff of this commit:
cvs rdiff -u -r1.209 -r1.210 src/sys/dev/usb/usbdi.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/usb

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 14:57:53 UTC 2021

Modified Files:
src/sys/dev/usb: usbdi.c

Log Message:
usb(4): Fix mistake in previous fix for pipe/interface-change races.

Must block interface changes _before_ we enter usbd_setup_pipe_flags,
which calls the bus pipe open method.


To generate a diff of this commit:
cvs rdiff -u -r1.208 -r1.209 src/sys/dev/usb/usbdi.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/usb

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 14:43:27 UTC 2021

Modified Files:
src/sys/dev/usb: usb_subr.c usbdi.c usbdivar.h

Log Message:
usb(4): Fix races between usbd_open_pipe* and usbd_set_interface.


To generate a diff of this commit:
cvs rdiff -u -r1.255 -r1.256 src/sys/dev/usb/usb_subr.c
cvs rdiff -u -r1.207 -r1.208 src/sys/dev/usb/usbdi.c
cvs rdiff -u -r1.125 -r1.126 src/sys/dev/usb/usbdivar.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/usb

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 13:58:06 UTC 2021

Modified Files:
src/sys/dev/usb: usb_subr.c usbdi.c usbdivar.h xhci.c

Log Message:
usb(4): Fix racy endpoint reference counting.

Rules:

1. After usbd_setup_pipe*, must usbd_kill_pipe.
2. After usbd_open_pipe*, must usbd_close_pipe.

Still haven't merged the logic in usbd_kill_pipe and usbd_close_pipe,
but getting closer.


To generate a diff of this commit:
cvs rdiff -u -r1.254 -r1.255 src/sys/dev/usb/usb_subr.c
cvs rdiff -u -r1.206 -r1.207 src/sys/dev/usb/usbdi.c
cvs rdiff -u -r1.124 -r1.125 src/sys/dev/usb/usbdivar.h
cvs rdiff -u -r1.145 -r1.146 src/sys/dev/usb/xhci.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/usb

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 13:57:51 UTC 2021

Modified Files:
src/sys/dev/usb: usbdi.c

Log Message:
usb(4): Omit needless lock/unlock cycle in usbd_pipe_close.

pipe->up_intrxfer is stable after construction, so no need to hold
the lock to check it.


To generate a diff of this commit:
cvs rdiff -u -r1.205 -r1.206 src/sys/dev/usb/usbdi.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/usb

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 13:57:40 UTC 2021

Modified Files:
src/sys/dev/usb: usbdi.c

Log Message:
usb(4): Cancel and wait for async task on closing pipe.

XXX usbd_kill_pipe and usbd_close_pipe should not be copypasta; there
should be only one instance of this logic.


To generate a diff of this commit:
cvs rdiff -u -r1.204 -r1.205 src/sys/dev/usb/usbdi.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/ic

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 12:15:54 UTC 2021

Modified Files:
src/sys/dev/ic: ath.c

Log Message:
ath(4): Use config_deactivate; don't abuse autoconf private dv_flags.


To generate a diff of this commit:
cvs rdiff -u -r1.134 -r1.135 src/sys/dev/ic/ath.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 12:15:43 UTC 2021

Modified Files:
src/sys/dev: ipmi.c
src/sys/external/bsd/drm2/i915drm: intelfb.c

Log Message:
ipmi(4), intelfb(4): Use config_pending_incr/decr.

Don't abuse autoconf's private (and incoherent) dv_flags.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/sys/dev/ipmi.c
cvs rdiff -u -r1.17 -r1.18 src/sys/external/bsd/drm2/i915drm/intelfb.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/kern

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 12:14:13 UTC 2021

Modified Files:
src/sys/kern: subr_autoconf.c

Log Message:
autoconf(9): Must hold alldevs_lock to iterate dv_list on alldevs.


To generate a diff of this commit:
cvs rdiff -u -r1.283 -r1.284 src/sys/kern/subr_autoconf.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/kern

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 12:14:03 UTC 2021

Modified Files:
src/sys/kern: kern_drvctl.c

Log Message:
drvctl(4): Hold a deviter while issuing config_detach.

Otherwise another concurrent detach -- e.g., from concurrent drvctl
or from USB port disconnection -- can pull the device_t out from
under us.

XXX Need to do this for _every_ operation config_* operation on a
device_t; device_find_by_xname is just fundamentally broken because a
concurrent detach can pull the device_t rug out from under you.

We really need another mechanism for holding a weak reference to a
device, and temporarily getting a strong reference to it; abusing
deviter is a bit of a kludge, and doesn't work very well because it
doesn't properly trigger garbage collection of devices detached while
other concurrent deviters are pending.


To generate a diff of this commit:
cvs rdiff -u -r1.47 -r1.48 src/sys/kern/kern_drvctl.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 12:13:51 UTC 2021

Modified Files:
src/sys/kern: subr_autoconf.c
src/sys/sys: device.h

Log Message:
autoconf(9): Prevent concurrent attach/detach and detach/detach.

- Use config_pending_incr/decr around attach.  No need for separate
  flag indicating device is still attaching.  (dv_flags locking is also
  incoherent.)

- Any config_pending now blocks config_detach.

- New dv_detaching exclusive lock for config_detach.


To generate a diff of this commit:
cvs rdiff -u -r1.282 -r1.283 src/sys/kern/subr_autoconf.c
cvs rdiff -u -r1.170 -r1.171 src/sys/sys/device.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/usb

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 12:13:23 UTC 2021

Modified Files:
src/sys/dev/usb: uhub.c usb_subr.c

Log Message:
usb(4), uhub(4): Sprinkle usbhist.


To generate a diff of this commit:
cvs rdiff -u -r1.149 -r1.150 src/sys/dev/usb/uhub.c
cvs rdiff -u -r1.253 -r1.254 src/sys/dev/usb/usb_subr.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/usb

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 12:13:11 UTC 2021

Modified Files:
src/sys/dev/usb: uhub.c usb.c usb_subr.c xhci.c

Log Message:
usb(4): Sprinkle kernel lock assertions.


To generate a diff of this commit:
cvs rdiff -u -r1.148 -r1.149 src/sys/dev/usb/uhub.c
cvs rdiff -u -r1.194 -r1.195 src/sys/dev/usb/usb.c
cvs rdiff -u -r1.252 -r1.253 src/sys/dev/usb/usb_subr.c
cvs rdiff -u -r1.144 -r1.145 src/sys/dev/usb/xhci.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/kern

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 12:12:11 UTC 2021

Modified Files:
src/sys/kern: kern_drvctl.c subr_autoconf.c

Log Message:
autoconf(9), drvctl(4): Sprinkle kernel lock assertions.


To generate a diff of this commit:
cvs rdiff -u -r1.46 -r1.47 src/sys/kern/kern_drvctl.c
cvs rdiff -u -r1.281 -r1.282 src/sys/kern/subr_autoconf.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/kern

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 12:11:59 UTC 2021

Modified Files:
src/sys/kern: kern_drvctl.c

Log Message:
drvctl(4): Take the kernel lock around entry into autoconf(9).

Can make this finer-grained once the rest of autoconf(9) is in good
enough shape to support it.


To generate a diff of this commit:
cvs rdiff -u -r1.45 -r1.46 src/sys/kern/kern_drvctl.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/kern

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 12:11:49 UTC 2021

Modified Files:
src/sys/kern: subr_autoconf.c

Log Message:
autoconf(9): Take kernel lock on various entries into autoconf.

Most of autoconf still tacitly assumes the kernel lock is held.


To generate a diff of this commit:
cvs rdiff -u -r1.280 -r1.281 src/sys/kern/subr_autoconf.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/usb

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 12:11:38 UTC 2021

Modified Files:
src/sys/dev/usb: usb.c

Log Message:
usb(4): usb event thread is not actually MP-safe.

Still requires a lot of work in usb(4), uhub(4), and autoconf(9).


To generate a diff of this commit:
cvs rdiff -u -r1.193 -r1.194 src/sys/dev/usb/usb.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/usb

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 12:11:28 UTC 2021

Modified Files:
src/sys/dev/usb: usb_subr.c

Log Message:
usb(4): Verify dev->ud_subdevs is still there before freeing it.

usbd_attachinterfaces may sleep, and if it does, it releases the
kernel lock, in which case another thread may free dev->ud_subdevs.


To generate a diff of this commit:
cvs rdiff -u -r1.251 -r1.252 src/sys/dev/usb/usb_subr.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/usb

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 12:11:11 UTC 2021

Modified Files:
src/sys/dev/usb: usb_subr.c

Log Message:
usb(4): kmem_zalloc(KM_SLEEP) cannot fail; nix error branch.


To generate a diff of this commit:
cvs rdiff -u -r1.250 -r1.251 src/sys/dev/usb/usb_subr.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/usb

2021-06-12 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat Jun 12 12:11:01 UTC 2021

Modified Files:
src/sys/dev/usb: uhub.c

Log Message:
uhub(4): Allow only one explore/rescan at a time.

Otherwise we might simultaneously attach two autoconf instances of
the same device, which leads to no good.


To generate a diff of this commit:
cvs rdiff -u -r1.147 -r1.148 src/sys/dev/usb/uhub.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/audio

2021-06-08 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Tue Jun  8 09:46:04 UTC 2021

Modified Files:
src/sys/dev/audio: audio.c

Log Message:
audio(4): Revert revision 1.96 and redo it another way.

Instead of refusing to open /dev/audioN for writes when the device
doesn't support playback, just refuse to issue writes.

Although it seems more sensible to me to reject writable opens early
on, and it seems Solaris does so, this makes querying device
properties a little trickier and is a change to the NetBSD semantics.


To generate a diff of this commit:
cvs rdiff -u -r1.103 -r1.104 src/sys/dev/audio/audio.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sbin/mount_chfs

2021-06-04 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Fri Jun  4 22:41:36 UTC 2021

Modified Files:
src/sbin/mount_chfs: mount_chfs.c mount_chfs.h

Log Message:
mount_chfs(8): Remove some vestiges of chewiefs name.

Add RCS id while here and nix some needless whitespace.

No functional change intended.

Patch from Andrius V.


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/sbin/mount_chfs/mount_chfs.c
cvs rdiff -u -r1.1 -r1.2 src/sbin/mount_chfs/mount_chfs.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/audio

2021-06-04 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Fri Jun  4 08:57:05 UTC 2021

Modified Files:
src/sys/dev/audio: audio.c

Log Message:
audio(4): When closing /dev/audioN, drain before removing from list.

Previously, in revision 1.100, I factored the SLIST_REMOVE out of
audio_unlink and audio_close up into audioclose since it is now used
by /dev/audio, /dev/audioctl, and /dev/mixer alike.  But I didn't
realize that the order

1. audio_track_drain
2. SLIST_REMOVE from sc_files

was significant; it matters because audio_track_drain waits for
wakeups that are delivered by hardware interrupts only to files
listed in sc_files.

This also fixes a bug introduced with the audiobell -- it was missing
the SLIST_REMOVE altogether.

For now, duplicate the SLIST_REMOVE calls in a few more places --
this is suboptimal but I want to make sure the logic works before
factoring it all out to tidy up.


To generate a diff of this commit:
cvs rdiff -u -r1.102 -r1.103 src/sys/dev/audio/audio.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src

2021-06-03 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Thu Jun  3 20:18:06 UTC 2021

Modified Files:
src/share/man/man4: options.4
src/sys/uvm: files.uvm uvm_swap.c

Log Message:
uvm(9): Enable swap encryption by default.

For machines where the performance impact of swapping before the
system has an opportunity to process `vm.swap_encrypt=0' in
/etc/sysctl.conf, you can disable it again by adding

options VMSWAP_DEFAULT_PLAINTEXT

to the kernel config.


To generate a diff of this commit:
cvs rdiff -u -r1.518 -r1.519 src/share/man/man4/options.4
cvs rdiff -u -r1.36 -r1.37 src/sys/uvm/files.uvm
cvs rdiff -u -r1.204 -r1.205 src/sys/uvm/uvm_swap.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/kern

2021-06-03 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Thu Jun  3 09:22:47 UTC 2021

Modified Files:
src/sys/kern: kern_ksyms.c

Log Message:
ksyms(4): Allow multiple concurrent opens of /dev/ksyms.

First one takes a snapshot; others all agree with the snapshot.

Previously this code path was just broken (could fail horribly if
modules were unloaded after one of the opens is closed), so I just
blocked it off in an earlier commit, but that broke crash(8).  So
let's continue allowing multiple opens seeing the same snapshot, but
without the horrible bugs.


To generate a diff of this commit:
cvs rdiff -u -r1.96 -r1.97 src/sys/kern/kern_ksyms.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/kern

2021-06-02 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Thu Jun  3 01:00:24 UTC 2021

Modified Files:
src/sys/kern: kern_ksyms.c

Log Message:
ksyms(4): Don't skip symbol tables that are soon to be freed, take 2.

They will not actually be freed until /dev/ksyms is closed, so
continued access to them remains kosher.

The previous change was busted because of an off-by-one error in a
previous previous change's iteration over the symtabs; that error has
since been corrected.


To generate a diff of this commit:
cvs rdiff -u -r1.95 -r1.96 src/sys/kern/kern_ksyms.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/kern

2021-06-02 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Thu Jun  3 01:00:15 UTC 2021

Modified Files:
src/sys/kern: kern_ksyms.c

Log Message:
ksyms(4): Fix race in ksymsread iteration.

TAILQ_NEXT(ksyms_last_snapshot) might change while we are iterating,
but ksyms_last_snapshot itself cannot, so invert the loop structure.

Discussed with rin@.


To generate a diff of this commit:
cvs rdiff -u -r1.94 -r1.95 src/sys/kern/kern_ksyms.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/ic

2021-06-02 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Wed Jun  2 21:35:17 UTC 2021

Modified Files:
src/sys/dev/ic: tpm.c

Log Message:
tpm(4): Preserve error if any on ending commands.

This way we don't spuriously suppress an error, such as
TPM_DEACTIVATED, in a loop where we rely on it.


To generate a diff of this commit:
cvs rdiff -u -r1.21 -r1.22 src/sys/dev/ic/tpm.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/kern

2021-06-02 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Wed Jun  2 21:34:58 UTC 2021

Modified Files:
src/sys/kern: kern_tc.c

Log Message:
timecounter(9): Zero the next pointer after tc_detach.

This reverts it to a state where tc_init works again.


To generate a diff of this commit:
cvs rdiff -u -r1.61 -r1.62 src/sys/kern/kern_tc.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/kern

2021-06-02 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Wed Jun  2 09:23:32 UTC 2021

Modified Files:
src/sys/kern: subr_psref.c

Log Message:
psref(9): Make use-after-free panic message more obvious.

Previously it would almost always manifest as

mismatched psref target class: 0x0 (ref) != 0x... (expected)

and now it will manifest as

psref target already destroyed: 0x...


To generate a diff of this commit:
cvs rdiff -u -r1.13 -r1.14 src/sys/kern/subr_psref.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/kern

2021-06-02 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Wed Jun  2 08:46:17 UTC 2021

Modified Files:
src/sys/kern: kern_ksyms.c

Log Message:
Revert "ksyms(4): Don't skip symbol tables that are soon to be freed."

Apparently the equality kassert this restored doesn't work; to be
analyzed.


To generate a diff of this commit:
cvs rdiff -u -r1.92 -r1.93 src/sys/kern/kern_ksyms.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/wscons

2021-06-01 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Tue Jun  1 23:28:07 UTC 2021

Modified Files:
src/sys/dev/wscons: wsdisplay_compat_usl.c

Log Message:
wsdisplay(4): Use C99 initializer for usl_syncops.

Avoid sketchy function pointer cast while here.


To generate a diff of this commit:
cvs rdiff -u -r1.53 -r1.54 src/sys/dev/wscons/wsdisplay_compat_usl.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev

2021-06-01 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Tue Jun  1 22:58:03 UTC 2021

Modified Files:
src/sys/dev: dev_verbose.h

Log Message:
dev_verbose(9): Prohibit autounloading modules.

This logic is not safe for autounload right now -- there's no
mechanism by which to block new users and wait for existing users to
drain when unloading.  To be remedied!


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/sys/dev/dev_verbose.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/arch/x86

2021-06-01 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Tue Jun  1 21:29:24 UTC 2021

Modified Files:
src/sys/arch/x86/acpi: acpi_wakeup.c
src/sys/arch/x86/x86: tsc.c tsc.h

Log Message:
x86: Reset cached tsc in every lwp to 0 on suspend/resume.

This avoids spuriously warning about tsc going backwards, which is to
be expected after a suspend/resume cycle.


To generate a diff of this commit:
cvs rdiff -u -r1.53 -r1.54 src/sys/arch/x86/acpi/acpi_wakeup.c
cvs rdiff -u -r1.54 -r1.55 src/sys/arch/x86/x86/tsc.c
cvs rdiff -u -r1.7 -r1.8 src/sys/arch/x86/x86/tsc.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/audio

2021-06-01 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Tue Jun  1 21:27:36 UTC 2021

Modified Files:
src/sys/dev/audio: audio.c

Log Message:
audio(4): audio_unlink never fails, so make it return void.


To generate a diff of this commit:
cvs rdiff -u -r1.101 -r1.102 src/sys/dev/audio/audio.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/audio

2021-06-01 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Tue Jun  1 21:19:03 UTC 2021

Modified Files:
src/sys/dev/audio: audio.c

Log Message:
audio(4): Insert mixers and audioctls into sc_files on open too.

This is necessary so that on detach we set file->dying before any
operations, particularly audioclose, try to acquire a psref by the
time the audio softc is gone.

Candidate fix for PR kern/56164.


To generate a diff of this commit:
cvs rdiff -u -r1.100 -r1.101 src/sys/dev/audio/audio.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/audio

2021-06-01 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Tue Jun  1 21:15:37 UTC 2021

Modified Files:
src/sys/dev/audio: audio.c

Log Message:
audio(4): No need to set file->dying when closing the file.

No other file operations are possible by the time we get to
audioclose.


To generate a diff of this commit:
cvs rdiff -u -r1.99 -r1.100 src/sys/dev/audio/audio.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/audio

2021-06-01 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Tue Jun  1 21:14:52 UTC 2021

Modified Files:
src/sys/dev/audio: audio.c

Log Message:
audio(4): Grab sc->sc_cred under sc->sc_lock before freeing.

Otherwise we may race with open, leaking a cred no longer in use and
freeing a cred still in use.


To generate a diff of this commit:
cvs rdiff -u -r1.98 -r1.99 src/sys/dev/audio/audio.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/audio

2021-06-01 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Tue Jun  1 21:12:47 UTC 2021

Modified Files:
src/sys/dev/audio: audio.c

Log Message:
audio(4): Use kmem_alloc(sizeof(*p)) style.


To generate a diff of this commit:
cvs rdiff -u -r1.97 -r1.98 src/sys/dev/audio/audio.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/audio

2021-06-01 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Tue Jun  1 21:12:36 UTC 2021

Modified Files:
src/sys/dev/audio: audio.c

Log Message:
audio(4): Make sure to return ENXIO if device is being detached.

Don't return 0 indicating successful open of an unusable device!


To generate a diff of this commit:
cvs rdiff -u -r1.96 -r1.97 src/sys/dev/audio/audio.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/audio

2021-06-01 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Tue Jun  1 21:12:24 UTC 2021

Modified Files:
src/sys/dev/audio: audio.c

Log Message:
audio(4): Set AUMODE_PLAY/RECORD only if asked _and_ supported.

If one is requested and _not_ supported, fail; otherwise we might
enter audio_write with a null play track and crash on KASSERT.


To generate a diff of this commit:
cvs rdiff -u -r1.95 -r1.96 src/sys/dev/audio/audio.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/kern

2021-06-01 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Tue Jun  1 21:11:52 UTC 2021

Modified Files:
src/sys/kern: kern_ksyms.c

Log Message:
ksyms(4): Don't skip symbol tables that are soon to be freed.

They will not actually be freed until /dev/ksyms is closed, so
continued access to them remains kosher.


To generate a diff of this commit:
cvs rdiff -u -r1.91 -r1.92 src/sys/kern/kern_ksyms.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/kern

2021-06-01 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Tue Jun  1 21:11:07 UTC 2021

Modified Files:
src/sys/kern: kern_ksyms.c

Log Message:
ksyms(4): Modify ksyms_symtabs only at IPL_HIGH.

This limits the opportunities for ddb to witness an inconsistent
state of the symbol table list.


To generate a diff of this commit:
cvs rdiff -u -r1.90 -r1.91 src/sys/kern/kern_ksyms.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/kern

2021-06-01 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Tue Jun  1 21:10:23 UTC 2021

Modified Files:
src/sys/kern: kern_ksyms.c

Log Message:
ksyms(4): Fix ksymsread synchronization.

Fixes crash on concurrent update and read of /dev/ksyms.

XXX Unclear why we have to skip sd_gone entries here -- it seems like
they should be preserved until ksymsclose.


To generate a diff of this commit:
cvs rdiff -u -r1.89 -r1.90 src/sys/kern/kern_ksyms.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/usr.bin/audio/record

2021-06-01 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Tue Jun  1 21:08:48 UTC 2021

Modified Files:
src/usr.bin/audio/record: record.c

Log Message:
audiorecord(1): Handle read(2) return value gracefully.


To generate a diff of this commit:
cvs rdiff -u -r1.54 -r1.55 src/usr.bin/audio/record/record.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/uvm

2021-05-31 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Mon May 31 10:57:02 UTC 2021

Modified Files:
src/sys/uvm: uvm_extern.h

Log Message:
uvm: Make uvm_extern.h (more) self-contained, needs sys/types.h.


To generate a diff of this commit:
cvs rdiff -u -r1.231 -r1.232 src/sys/uvm/uvm_extern.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/external/bsd/drm2/include

2021-05-31 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Mon May 31 10:33:04 UTC 2021

Modified Files:
src/sys/external/bsd/drm2/include/asm: processor.h
src/sys/external/bsd/drm2/include/linux: delay.h

Log Message:
drm: sys/param.h, not machine/param.h, for DELAY.


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/sys/external/bsd/drm2/include/asm/processor.h
cvs rdiff -u -r1.6 -r1.7 src/sys/external/bsd/drm2/include/linux/delay.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/pckbport

2021-05-30 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sun May 30 13:20:01 UTC 2021

Modified Files:
src/sys/dev/pckbport: synaptics.c

Log Message:
synaptics(4): New sysctl knob for debug output.

Set hw.synaptics.debug=1 to re-enable it; the compile-time DIAGNOSTIC
option was inappropriate for this.


To generate a diff of this commit:
cvs rdiff -u -r1.70 -r1.71 src/sys/dev/pckbport/synaptics.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev/acpi

2021-05-30 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sun May 30 11:24:11 UTC 2021

Modified Files:
src/sys/dev/acpi: thinkpad_acpi.c

Log Message:
thinkpad(4): Fix evaluation of MHKA on version 2 devices.

Need to pass an argument.


To generate a diff of this commit:
cvs rdiff -u -r1.52 -r1.53 src/sys/dev/acpi/thinkpad_acpi.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys/dev

2021-05-30 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sun May 30 11:24:02 UTC 2021

Modified Files:
src/sys/dev: ld.c ldvar.h

Log Message:
ld(4): Block requests while suspended until resumed.

Otherwise nothing stops us from continuing to feed I/O to the disk
controller when it expects that the queues are quiesced as it pokes
registers to change its power states.  Fixes resume during disk
activity on my T480 with nvme.


To generate a diff of this commit:
cvs rdiff -u -r1.111 -r1.112 src/sys/dev/ld.c
cvs rdiff -u -r1.34 -r1.35 src/sys/dev/ldvar.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/sys

2021-05-29 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sat May 29 16:49:57 UTC 2021

Modified Files:
src/sys/dev/acpi: thinkpad_acpi.c
src/sys/sys: power.h

Log Message:
Add some more Thinkpad hotkeys.


To generate a diff of this commit:
cvs rdiff -u -r1.51 -r1.52 src/sys/dev/acpi/thinkpad_acpi.c
cvs rdiff -u -r1.21 -r1.22 src/sys/sys/power.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



  1   2   3   4   5   6   7   8   9   10   >