Age | Commit message (Collapse) | Author |
|
time_second(9) and time_uptime(9) are widely used in the kernel to
quickly get the system UTC or system uptime as a time_t. However,
time_t is 64-bit everywhere, so it is not generally safe to use them
on 32-bit platforms: you have a split-read problem if your hardware
cannot perform atomic 64-bit reads.
This patch replaces time_second(9) with gettime(9), a safer successor
interface, throughout the kernel. Similarly, time_uptime(9) is replaced
with getuptime(9).
There is a performance cost on 32-bit platforms in exchange for
eliminating the split-read problem: instead of two register reads you
now have a lockless read loop to pull the values from the timehands.
This is really not *too* bad in the grand scheme of things, but
compared to what we were doing before it is several times slower.
There is no performance cost on 64-bit (__LP64__) platforms.
With input from visa@, dlg@, and tedu@.
Several bugs squashed by visa@.
ok kettenis@
|
|
aassigned to adapter_buswidth to indicate the adapter is not a target
on the bus.
ok dlg@ as part of a larger diff.
|
|
indicate the adapter is not a target on the bus.
ok dlg@ as part of a larger diff.
|
|
the adapter is not a target on the bus.
ok dlg@ as part of a larger diff.
|
|
set/trust the scsiconf.c probing limits. Same as was done to
vioblk(4).
ok dlg@
|
|
this is a step toward deprecating softclock based livelock detection.
|
|
on the RockPro64 WiFi module.
Note that there is no fiirmware for this chip in the bwfm-firmware package
at the moment.
ok patrick@
|
|
|
|
|
|
dormant in the driver for years, we just needed to insert the IV before
transmission and do packet number checks on received frames.
tested by kevlo@ solene@ benno@ and me on a variety of hardware
ok kevlo@ stsp@
|
|
adds kernel support for
amdgpu: vega20, raven2, renoir, navi10, navi14
inteldrm: icelake, tigerlake
Thanks to the OpenBSD Foundation for sponsoring this work, kettenis@ for
helping, patrick@ for helping adapt rockchip drm and many developers for
testing.
|
|
conversion steps). it only contains kernel prototypes for 4 interfaces,
all of which legitimately belong in sys/systm.h, which are already included
by all enqueue_randomness() users.
|
|
miod explained it was initially a long as it was thought drivers may
need to allocate storage but in practice they don't need more than
32 bits for an attribute.
suggested and reviewed by miod@
|
|
Suggested by John Carmack. miod agrees a rename would make sense and
explained it was initially thought drivers may need to allocate storage
but in practice they don't need more than 32 bits for an attribute.
ok mpi@
|
|
|
|
Avoids an unusable screen when switching to a VT with a custom VGA font
from X. While it is possible to modify the xserver to invoke an ioctl
for this kettenis@ points out the xserver may have crashed so doing it
in the kernel is preferred.
Problem reported by and patch from John Carmack. Changed slightly to
do the vga_restore_fonts() (write to video memory) call before
vga_setfont() (pointing the character generator at it) at the suggestion
of kettenis@.
ok kettenis@
|
|
vga attribute controller index or set the enable/'palette address source'
bit when saving and restoring 256 colour vga palette with 0x3c6-0x3c9 as
this does not touch the attribute registers.
When this code was ported from FreeBSD in vga.c rev 1.48 the flip-flop
reset parts were mistakenly made to read 0x3ca instead of 0x3da.
Fixes a problem with VirtualBox where the text mode background was a dim
red colour instead of black after VT switch.
Problem reported by and patch from John Carmack.
ok matthieu@ who notes this also fixes a similiar problem with a KVM /
virt-manager virtual machine.
|
|
So far, drivers using hardware CCMP decryption were expected to keep the
most recently seen CCMP packet number (PN) up-to-date, and to discard frames
with lower PNs as replays.
A-MPDU subframes may legitimately arrive out of order, and the drivers skipped
CCMP replay checking for such frames. Re-ordering happens in ieee80211_inputm(),
after the driver is done with a frame. Drivers cannot tell replayed frames
apart from legitimate out-of-order retransmissions.
To fix this, update the PN value in ieee80211_inputm() after subframes have
been reordered into their proper sequence. Drivers still perform replay checks
but they no longer have to worry about updating the last seen PN value.
The 802.11 spec confirms that replay checking is supposed to happen after
A-MPDU re-ordering.
Tested by jmc@, benno@, solene@, and myself with the following drivers:
athn(4), iwn(4), iwm(4), wpi(4), urtwn(4)
ok solene@
|
|
constraints in a separate blob, instead of in the firmware.
This .clm_blob needs to be loaded as well.
|
|
This fix simplifies HW decrytion error checking: Frame header contents aren't
relevant because we are going to drop frames that had errors in any case.
I made a mistake by trying to add an exception for multicast frames at this
point. Frame header contents might not even be valid.
This problem was introduced with CCMP hardware offload support and detected
by Coverity (CID 1492755).
ok mestre@ kevlo@
|
|
This flag restricts a wireless driver to MCS0 - MCS7 for both transmission
and reception. It can be set to work around packet loss in 11n mode caused
by unused antenna connectors on a MIMO-capable wireless network device.
man page tweak from tracey@
ok deraadt@
|
|
ok kevlo@ mpi@
|
|
This reduces CPU load during traffic bursts, which is especially noticeable
on boards with relatively slow CPUs such as Alix and APU. For reference,
my rcc-ve boards (Intel Atom C2558) now forward ~2000pps between Ethernet
and wifi with <= 1% CPU interrupt time according to systat. Beforehand, these
boards became noticeably less responsive with fairly high interrupt and spin %.
CCMP offload is used on both PCI and USB devices (thanks kevlo@ for catching
my omission of USB devices in the first iteration of this change!)
Tested by (at least) Kevin Chadwick, tracey@, kevlo@, kili@, Ted Patterson,
David Dahlberg, and Scott Bennett.
ok tracey@ kevlo@
|
|
sc_link.openings is greater than 34.
Encountered by Sigi Rudzio on his Blade 2500, who kindly did some
testing to discover that the answer is 34, not 42.
Nuke some whitespace on the way by.
|
|
Original work by Neil Ashford and dlg@
ok kettenis@
|
|
Not used yet but may become useful later.
|
|
Original work by Neil Ashford and dlg@
Feedback from jsg@
ok kettenis@, dlg@
|
|
Use a monotonic clock for timestamping LUNs to avoid problems when the
UTC clock jumps.
ok krw@
|
|
the Raspberry Pi4.
ok patrick@
|
|
|
|
does nothing at all.
The first one spotted as CID 1452976.
Reads good to millert@
ok mpi@
|
|
ok patrick@
|
|
This also adds panel support to rkanxdp(4). Code to hook up simplepanel(4)
is still missing and will come later.
ok patrick@
|
|
"Bump nvme(4) max physio() i/o size to 128K"
|
|
The coverity-related diff breaks sparc64's ability to read the disk.
ok deraadt
|
|
KASSERT(), or has already blown up by dereferencing the
pointer.
Two of the four invocations of ahci_get_pmp_ccb() check for
NULL. Save a couple of bytes by not bothering. Add comments
to the invocations to docuement the assumption.
|
|
printf()'s.
|
|
From Rob Schmersel
|
|
|
|
removal of internal queuing of scsi_xfer's. Put them out of their
misery. Nuke an obsolete comment in passing.
CID 1453357.
|
|
12. PAGE_SHIFT is 12 (a.k.a. PAGE_SIZE == 4096) or more on OpenBSD
architectures. So remove some dead code by unconditionally setting
sc_mps (memory page size) to 1 << PAGE_SHIFT.
CID 1491655.
No functional change.
|
|
sgl (scatter gather list) and prpl (physical region page list) are two
different things in the NVMe world. Only the latter is currently
implemented in nvme(4) so rename sc_max_sgl to sc_max_prpl to reflect
this.
No functional change.
|
|
different things in the NVMe world. Only the latter is currently
implemented in nvme(4) so rename sc_max_sgl to sc_max_prpl to reflect
this.
No functional change.
|
|
driver. The information by the driver is supposed more reliable than
the information which was set up earlier.
ok patrick
|
|
external tool to pre-process the NVRAM, even though it's simple to
do ourselves. This allows easier firmware distribution.
ok kurt@
|
|
|
|
ok patrick@
|
|
No functional change.
|
|
RK3399 SoC.
ok patrick@
|
|
and ffs(16)-1 with the constant results (i.e. 6 and 4). Add comments
to clarify use of these constants. Net result, one less invocation of
ffs(), softc smaller by one u_int, and less potential confusion over
'mps'.
No functional change.
|