Age | Commit message (Collapse) | Author |
|
machdep.unaligned_* sysctl to control its behaviour. Such code made sense more
than 20 years ago where a lot of code was not 64-bit clean, but this is no
longer the case those days.
ok jsg@ millert@ deraadt@
|
|
without netlock for SIOC{G,S}IFMEDIA commands.
ok bluhm@
|
|
|
|
This caused stuck ndp cache entries as found by naddy, sorry.
|
|
|
|
In order to move riscv64 to a machine-independent clock interrupt
subsystem, the riscv64 clock interrupt code needs to function without
any specific knowledge of the clock interrupt schedule.
The easiest way to achieve this (as we just did with powerpc and
powerpc64) is, if the timer interrupt fires while the CPU is at or
above IPL_CLOCK, defer clock interrupt work until the the timer
interrupt is logically unmasked in splx(9).
In particular, trigger the timer interrupt from plic_setipl() so the
interrupt, if any, is pending before we handle soft interrupts.
Because we're no longer deferring work until the next tick, we don't
need to count pending statclock ticks in struct cpu_info.
kettenis@ notes that the timer triggering code should be refactored
into more generic code when we add support for a non-plic(4) riscv64
machine.
Graciously fixed, compiled, and tested by jca@.
Link: https://marc.info/?l=openbsd-tech&m=165931635410276&w=2
ok kettenis@
|
|
In order to move to a machine-independent clock interrupt subsystem,
the powerpc64 clock interrupt code needs to work without knowing
anything about the clock interrupt schedule.
The easiest way to do this is, if the DEC fires while the CPU's IPL is
at or above IPL_CLOCK, to postpone clock interrupt work until the
clock interrupt is logically unmasked from splx(9).
Because we no longer defer work until the next tick, we don't need to
keep track of pending statclock ticks in the cpu_info struct.
With input from kettenis@.
Graciously compiled and tested by gkoehler@ and kettenis@.
Link: https://marc.info/?l=openbsd-tech&m=165862522102767&w=2
ok kettenis@ gkoehler@.
|
|
checksum, IPv6 fragments contained invalid checksum. For fragments
the protocol checksum has to be calculated before fragmentation.
Hardware cannot do this as it is too late. Do it earlier in software.
tested and OK mbuhl@
|
|
All of them are passed to inspect/copy out fields, none of the functions
writes to the struct.
This makes it easier to argue about code (in MP context).
OK bluhm
|
|
IPv6 pendant to bluhm's sys/netinet/if_ether.c r1.249:
Instead of calling getuptime() all the time in ARP code, do it only
once per function. This gives a more consistent time value.
OK claudio@ miod@ mvs@
OK bluhm
|
|
ok miod@
|
|
ok miod@ millert@
|
|
Use their reference counter in more places.
The in_pcb lookup functions hold the PCBs in hash tables protected
by table->inpt_mtx mutex. Whenever a result is returned, increment
the ref count before releasing the mutex. Then the inp can be used
as long as neccessary. Unref it at the end of all functions that
call in_pcb lookup.
As a shortcut, pf may also hold a reference to the PCB. When
pf_inp_lookup() returns it, it also incements the ref count and the
caller can handle it like the inp from table lookup.
OK sashan@
|
|
comment.
Found by Tetsuya Isaki at NetBSD and nono project, during
investigating work-in-progress NetBSD/luna88k.
It originally comes from Mach luna88k port, more than 30 years ago:-)
Tested by me, "That's much better!" miod@
|
|
on libc trying to open /var/run/ypbind.lock, so pledge had to BYPASSUNVEIL
accesses to this file. We accepted the opening of that file for a small
period for build cross-over, but that waiting period ends now.
|
|
immutable/atomic/owned ala <sys/proc.h>. Move CPUF_USERSEGS and
CPUF_USERXSTATE, which really are private to the CPU, into a new
ci_pflags and rename s/CPUF_/CPUPF_/. Make all (remaining) ci_flags
alterations via atomic_{set,clear}bits_int(), so its annotation
isn't a lie. Delete ci_info member as unused all the way from
rev 1.1
ok jsg@ mlarkin@
|
|
fast path in the pager code; this benefits most mips64 platforms.
ok kettenis@ mpi@
|
|
to be available to other files. NFC
ok kettenis@ mpi@
|
|
not support media parameter, so just skip these ioctls. Do not
release a netlock that was not taken.
panic found and fix tested by Michael Graves; OK mvs@
|
|
NET_RLOCK_IN_IOCTL, which have the same implementation. The R and
W are hard to see, call the new macro NET_LOCK_SHARED. Rename the
opposite assertion from NET_ASSERT_WLOCKED to NET_ASSERT_LOCKED_EXCLUSIVE.
Update some outdated comments about net locking.
OK mpi@ mvs@
|
|
helper functions.
The refactored code ensures disklabels are read from/written to
disk only from/to unused space or an OpenBSD partition. This
prevents accidental damage to filesystems that start immediately
following an MBR or GPT.
The refactored code also finds the disklabel present on the
i386/amd64 floppyXX.img, rather than spoofing the media as a
single MSDOS partition.
Tweak and positive comments from jmatthew@
|
|
reduce the diff with DragonFlyBSD by using swblk_t and u_swblk_t types.
while here, move bitmap type (u_swblk_t) to u_int64_t on all archs. it makes the
regress the same on 64 and 32bits archs (and it success on both).
ok mpi@
|
|
- it is currently unused (except in some regress)
- it is non-standard
- it shouldn't have been visible in first place
ok jca@ mpi@ todd@ deraadt@
|
|
ok jsg@
|
|
ok jsg@
|
|
|
|
Legacy drivers run with kernel lock, interface media is MP safe or
has kernel lock. Assert kernel lock in ix(4) and ixl(4).
OK kettenis@
|
|
|
|
|
|
of significant bits on big endian machines. Bug has been introduced
in previous commit by removing the =! 0 check.
OK mvs@
|
|
root on softraid on sparc64 currently requires explicitly passing the volume
name as part of the boot arguments, e.g.
boot-file=sr0
boot-file=sr0a:/bsd
or
{ok} boot my-devalias sr0:
(ofwboot always probes for softraid devices, assembles them but continues
to ignore such volumes unless specified.)
This is inconsistent with softraid support on other platforms and has
further drawbacks when it comes to sysupgrade logic.
Unless an explicit root disk was given, make ofwboot default to the softraid
volume on the boot device to make root on softraid work out of the box
without having to set variables or pass arguments in OpenBoot.
Eventually, ofwboot's disk discovery and softraid assembly machinery will be
fixed and boot-file won't be misused for softraid purposes anymore.
Remove the quirky softraid paragraph from boot_sparc64(8) now that it
is purely optional, expecting users from now on to either leave boot-file
empty or pass a kernel filename alone.
Tested on T4-2 guest domains with and without root on softraid.
Feedback claudio kettenis stsp
OK kettenis (previous diff)
OK stsp
|
|
block that takes data from apldma(4), serializes it and sends it out on
the i2s ports. The aplaudio(4) driver ties together aplmca(4) and various
codecs to present an audio(4) interface to the system.
This is still WIP, but good enough to play back audio on the speaker in the
M1 mini.
ok patrick@
|
|
ok patrick@
|
|
to pf_lb.c was not complete. We must add a test to determine number of
addresses defined by pool, so we don't treat pool definition
172.16.0.0/16 as a single IP address in pool. If pool is defined as
172.16.0.0/16, then we don't want to fall back to PF_POOL_NONE. Missing
this measure in pf_map_addr() may cause pf_get_sport() to enter infinite
loop when source ports translation become depleted for the first address
found in pool (like 172.16.0.1), because the bug prevents pf_map_addr()
to move to next address in pool (like 172.16.0.2).
while investigating issue I've also noticed an oddity for small random
pools such as 192.168.1.32/28. One would expect the addresses for nat
will be randomly picked from range .32 - .47 in this case. however the
random selection yield significantly more (like 20%) addresses ending by .32
In order to fix it we make random pool to use arc4random_uniform(~mask + 1)
instead of current arc4random().
feedback by claudio@
tested by hrvoje@
|
|
https://frame.work/blog/solving-for-silicon-shortages
|
|
From Imre Deak
59207e63801fbcd39ca68df6e2ba5ae90f76c0c3 in mainline linux
|
|
These must be handled as write faults rather than read faults, since xmem
performs both a read and a write, and unlike on 88100, we don't have an easy
bit to check.
This solves libcrypto spinning on its locks on 88110.
|
|
PMAP_PREFER is checked to prevent cache aliasing issues when the physical
page is mapped at different virtual addresses.
This speeds up file-based mmap faults.
ok kettenis@
|
|
to the padded syscalls going away.
|
|
|
|
|
|
from:
12th Generation Intel Core Processors
Datasheet, Volume 1 of 2, Doc. No.: 655258, Rev.: 008
Intel 600 Series Chipset Family On-Package Platform Controller Hub
Datasheet, Volume 1 of 2, Doc. No.: 691222, Rev.: 002
and SanDisk SN850 while here
|
|
it.
ok patrick@
|
|
|
|
From Hayden Goodfellow
c6e4817ab622f526d6afe9e02c6d85b177b3e846 in linux 5.15.y/5.15.58
655c167edc8c260b6df08bdcfaca8afde0efbeb6 in mainline linux
|
|
From Dan Carpenter
ec9ec3bc08b18c5b1b2feafd306ea7c348013898 in linux 5.15.y/5.15.58
a35faec3db0e13aac8ea720bc1a3503081dd5a3d in mainline linux
|
|
From Jose Exposito
f85a6046f7718f11c6ad015a0ba25d897194b1ac in linux 5.15.y/5.15.58
978ffac878fd64039f95798b15b430032d2d89d5 in mainline linux
|
|
From Nicholas Kazlauskas
760fe32034931a8c97c773edef2f1b7c7346f43a in linux 5.15.y/5.15.58
d82b3266ef88dc10fe0e7031b2bd8ba7eedb7e59 in mainline linux
|
|
From Nicholas Kazlauskas
c2b484d784c8dfc3eb62fd4f9ff11515b6e78e19 in linux 5.15.y/5.15.58
62e5a7e2333a9f5395f6a9db766b7b06c949fe7a in mainline linux
|
|
From Nicholas Kazlauskas
9581511948582a0ed8da03fb91d2ab658087283d in linux 5.15.y/5.15.58
34316c1e561db0b24e341029f04a5a5bead9a7bc in mainline linux
|