OpenBSD cvs log

created 2024-02-05T07:45:34Z
begin 2024-01-31T00:00:00Z
end 2024-02-01T00:00:00Z
path src/sys
commits 6

date 2024-01-31T01:01:10Z
author hastings
files src/sys/dev/fdt/com_fdt.c log diff annotate
message add MediaTek UART support.

ok kettenis@

date 2024-01-31T05:49:33Z
author guenther
files src/sys/arch/amd64/amd64/vmm_machdep.c log diff annotate
src/sys/arch/amd64/include/cpufunc.h log diff annotate
message Make wrpkru() consistent with rdpkru() by passing ecx as an argument.

ok mlarkin@

date 2024-01-31T06:06:28Z
author guenther
files src/sys/arch/amd64/amd64/trap.c log diff annotate
src/sys/arch/amd64/include/frame.h log diff annotate
message Swap the r10 and rcx registers in the amd64 trapframe so that the
first six entries are in the same order as syscall arguments, such
that syscall() can just use the trapframe as the argument vector
for mi_syscall() and not need to reorder into another buffer on the
stack. This doesn't affect coredump layout or ptrace(2), but does
affect kernel crash dumps.

Possibility noted during miod@'s cleanup of the MD syscall()
implementations

ok mlarkin@ kurt@

date 2024-01-31T12:27:57Z
author bluhm
files src/sys/netinet/in_pcb.c log diff annotate
src/sys/netinet/in_pcb.h log diff annotate
src/sys/netinet6/in6_pcb.c log diff annotate
src/sys/netinet6/ip6_output.c log diff annotate
message Split in_pcbrtentry() and in6_pcbrtentry() based on INP_IPV6.

Splitting the IPv6 code into a separate function results in less
#ifdef INET6. Also struct route_in6 *ro in in6_pcbrtentry() is of
the correct type and in_pcbrtentry() does not rely on the fact that
inp_route and inp_route6 are pointers to the same union.

OK kn@ claudio@

date 2024-01-31T14:56:42Z
author bluhm
files src/sys/net/route.c log diff annotate
src/sys/net/route.h log diff annotate
src/sys/netinet/ip_input.c log diff annotate
message Add route generation number to route cache.

The outgoing route is cached at the inpcb. This cache was only
invalidated when the socket closes or if the route gets invalid.
More specific routes were not detected. Especially with dynamic
routing protocols, sockets must be closed and reopened to use the
correct route. Running ping during a route change shows the problem.

To solve this, add a route generation number that is updated whenever
the routing table changes. The lookup in struct route is put into
the route_cache() function. If the generation number is too old,
the cached route gets discarded.

Implement route_cache() for ip_output() and ip_forward() first.
IPv6 and more places will follow.

OK claudio@

date 2024-01-31T14:56:43Z
author bluhm
files src/sys/netinet/ip_output.c log diff annotate
src/sys/netinet6/in6.h log diff annotate
message Add route generation number to route cache.

The outgoing route is cached at the inpcb. This cache was only
invalidated when the socket closes or if the route gets invalid.
More specific routes were not detected. Especially with dynamic
routing protocols, sockets must be closed and reopened to use the
correct route. Running ping during a route change shows the problem.

To solve this, add a route generation number that is updated whenever
the routing table changes. The lookup in struct route is put into
the route_cache() function. If the generation number is too old,
the cached route gets discarded.

Implement route_cache() for ip_output() and ip_forward() first.
IPv6 and more places will follow.

OK claudio@