OpenBSD cvs log

created 2021-01-30T23:14:39Z
begin 2021-01-28T00:00:00Z
end 2021-01-29T00:00:00Z
path src/sys
commits 13

date 2021-01-28T01:48:54Z
author kurt
files src/sys/dev/usb/dwc2/dwc2.c log diff annotate
message Rename bNumInterface to bNumInterfaces to fix build on arm64.

date 2021-01-28T09:37:20Z
author dlg
files src/sys/net/pf.c log diff annotate
message handle "once" rules before letting pfsync defer tx of a packet.

pfsync may want to defer the transmission of a packet. it does this so
it can try and get a state over to a peer firewall before a host may
send a reply to the peer, which would get dropped cos there's no
matching state.

i think the once rule processing should happen before that. the state
is created from the rule, whether the packet the state is for goes out
immediately or not shouldn't matter.

ok sashan@

date 2021-01-28T12:50:28Z
author mglocker
files src/sys/dev/usb/ugen.c log diff annotate
message Be consistent in not using parameter names for function prototypes;
I've missed two more cases in the previous commit.

date 2021-01-28T14:53:20Z
author visa
files src/sys/conf/files log diff annotate
src/sys/netinet/tcp_var.h log diff annotate
message Drop tcp_trace() from SMALL_KERNEL builds to make room on amd64 floppy

OK deraadt@

date 2021-01-28T15:13:27Z
author visa
files src/sys/kern/subr_witness.c log diff annotate
message Show when witness(4) has run out of lock order data entries.

This makes it clearer why lock order traces are sometimes not displayed.

Prompted by a question from, and OK anton@

date 2021-01-28T17:19:40Z
author cheloha
files src/sys/dev/acpi/tpm.c log diff annotate
message tpm(4): fix delay units

tpm(4) has timeout constants in milliseconds, e.g.

#define TPM_ACCESS_TMO 2000 /* 2sec */

This is fine.

The odd thing is that tpm(4) first converts these timeouts to counts
of ticks via tpm_tmotohz() before using DELAY() to busy-wait. DELAY()
takes a count of microseconds, which are not equivalent to ticks, so
the units are all screwed up.

Let's correct this:

- Remove tpm_tmotohz(). We're not working with ticks so we don't it.

- Multiply the timeouts to match the delay interval. tpm_request_locality()
and tpm_getburst() use intervals of 10 microseconds, so multiply the
millisecond timeouts by 100. In tpm_waitfor() the delay interval is 1
microsecond, so multiply the millisecond timeout by 1000.

- Update the parameter name in tpm_waitfor() to note that we expect a
count of milliseconds, not "tries".

Discussion: https://marc.info/?l=openbsd-tech&m=160995671326406&w=2

Prompted by kettenis@.

Suspend/resume tested by florian@ on an X1 Gen 2. For the record, it
looks like this:

tpm0 at acpi0 TPM_ addr 0xfed40000/0x5000, device 0x0000104a rev 0x4e

Earlier versions of this patch were reviewed by kn@, but the patch
became more ambitious when kettenis@ got involved so those reviews
are no longer applicable.

jcs@ notes (https://marc.info/?l=openbsd-tech&m=160834427630142&w=2)
in a related discussion that this driver "sucks" and should be
replaced with NetBSD's rewrite. This would get us a cleaner driver
with TPM 2.0 support. So there is future work to do here.

ok kettenis@

date 2021-01-28T17:39:01Z
author deraadt
files src/sys/arch/alpha/conf/Makefile.alpha log diff annotate
message Again allow COPTS= to come from the environment again, and don't lose the
SMALL_KERNEL specific variations.
ok espie jsg

date 2021-01-28T17:39:02Z
author deraadt
files src/sys/arch/amd64/conf/Makefile.amd64 log diff annotate
src/sys/arch/arm64/conf/Makefile.arm64 log diff annotate
src/sys/arch/armv7/conf/Makefile.armv7 log diff annotate
message Again allow COPTS= to come from the environment again, and don't lose the
SMALL_KERNEL specific variations.
ok espie jsg

date 2021-01-28T17:39:03Z
author deraadt
files src/sys/arch/hppa/conf/Makefile.hppa log diff annotate
src/sys/arch/i386/conf/Makefile.i386 log diff annotate
src/sys/arch/landisk/conf/Makefile.landisk log diff annotate
src/sys/arch/loongson/conf/Makefile.loongson log diff annotate
src/sys/arch/luna88k/conf/Makefile.luna88k log diff annotate
src/sys/arch/macppc/conf/Makefile.macppc log diff annotate
src/sys/arch/octeon/conf/Makefile.octeon log diff annotate
src/sys/arch/powerpc64/conf/Makefile.powerpc64 log diff annotate
src/sys/arch/sgi/conf/Makefile.sgi log diff annotate
src/sys/arch/sparc64/conf/Makefile.sparc64 log diff annotate
message Again allow COPTS= to come from the environment again, and don't lose the
SMALL_KERNEL specific variations.
ok espie jsg

date 2021-01-28T18:54:50Z
author deraadt
files src/sys/arch/amd64/stand/efiboot/memprobe.c log diff annotate
message bios_memmap[] should not be a common
ok kettenis

date 2021-01-28T18:54:52Z
author deraadt
files src/sys/arch/amd64/stand/libsa/memprobe.c log diff annotate
message bios_memmap[] should not be a common
ok kettenis

date 2021-01-28T20:04:44Z
author mvs
files src/sys/net/if_trunk.c log diff annotate
message trunk(4): convert ifunit to if_unit(9)

ok bluhm@

date 2021-01-28T20:06:38Z
author mvs
files src/sys/net/bridgectl.c log diff annotate
src/sys/net/if_bridge.c log diff annotate
message bridge(4): convert ifunit() to if_unit(9)

ok bluhm@ sashan@