summaryrefslogtreecommitdiff
path: root/sys
AgeCommit message (Collapse)Author
2023-03-02Enable mvodog(4) and mvortc(4)Jonathan Matthew
2023-03-02Add mvortc(4), a driver for the RTC on the ARMADA 38x series.Jonathan Matthew
ok kettenis@ patrick@
2023-03-02Add mvodog(4), a driver for the watchdog on the ARMADA 38x series.Jonathan Matthew
ok kettenis@ patrick@
2023-03-02Add eephy(4), found on the Turris Omnia's WAN portJonathan Matthew
2023-02-27Pass MII flags depending on the phy mode specified in the device tree.Jonathan Matthew
With this, the WAN port on the Turris Omnia works. tested on Turris MOX by kettenis@ ok patrick@
2023-02-27Turn off TSO if interface is added to layer 2 devices.Jan Klemkow
ok bluhm@, claudio@
2023-02-27drm/i915: Remove __maybe_unused from mtl_infoJonathan Gray
From Lucas De Marchi 44610f4c3093bbce3061b77d37bdf1bed8e379da in linux-6.1.y/6.1.14 fff758698842fb6722be37498d8773e0fb47f000 in mainline linux
2023-02-27drm/edid: Fix minimum bpc supported with DSC1.2 for HDMI sinkJonathan Gray
From Ankit Nautiyal 0deb50618944aed143269214daea0ba2ddf2222d in linux-6.1.y/6.1.14 18feaf6d0784dcba888859109676adf1e0260dfd in mainline linux
2023-02-27syncTheo de Raadt
2023-02-27Include varags types in sys/syscalls.h commentAndrew Fresh
Separated with the existing "..." requested by deraadt@ OK gnezdo@
2023-02-26clockintr: add a kernel-facing APIScott Soule Cheloha
We need an API for creating, scheduling, and rescheduling clock interrupts. - Add struct clockintr, a schedulable clock interrupt callback. - Add clockintr_establish(). Allocates a new struct clockintr and binds it to the given clockintr_queue. - Add clockintr_expiration(). Returns the clockintr's absolute expiration uptime. - Add clockintr_nsecuptime(). Returns the clockintr's parent queue's cached uptime. Using a cached timestamp is cheaper than calling nsecuptime(9) repeatedly when we don't absolutely need to. - Add clockintr_schedule(). Schedules the clock interrupt to run at or after the given absolute uptime. - Add clockintr_advance(). Reschedules the clock interrupt in the future on the given period relative to the parent queue's cached uptime. With the above pieces in place we can push most of the scheduling code for hardclock()/statclock()/schedclock() from clockintr_dispatch() into the wrapper functions clockintr_hardclock(), clockintr_statclock(), and clockintr_schedclock(). These wrappers are temporary. I don't want to muck up the wrapped functions while things are still moving around. For the moment these interfaces are internal to kern_clockintr.c. In a later patch we will move the prototypes into <sys/clockintr.h> so anyone can use them. We first need to add a data structure for sorting the clockintr structs. We also need to add a mutex to clockintr_queue to allow arbitrary threads to safely manipulate clock interrupts established on other CPUs. Shown on hackers@. Tweaked by mlarkin@. ok mlarkin@, "no objections" kettenis@
2023-02-26Add a few missing bounds checks when processing terminal escape sequences.Miod Vallat
Without them, the kernel could be made to crash or reboot after receiving some specially crafted terminal escape sequences. Reported by David Leadbeater (dgl, dgl dot cx)
2023-02-26Defragment mbufs in the tx path to work around a (not fully understood)Mark Kettenis
issue on the StarFive JH7100 SoC where packets spanning multiple mbufs are corrupted. Makes ethernet work reliably on the StarFive VisionFive 1 board. ok patrick@
2023-02-26RK3588 support.Mark Kettenis
ok patrick@
2023-02-26Modern Rockchip SoCs, such as the RK356x and RK3588, use a differentMark Kettenis
register layout where the upper 16 bits decide which of the lower 16 bits apply when writing to a register. Handle this new variant. ok patrick@
2023-02-25regenVitaliy Makkoveev
2023-02-25Unlock select(2), pselect(2), poll(2) and ppoll(2).Vitaliy Makkoveev
The assertion within tsleep(9) was relaxed to allow calls on special `nowake' channel without kernel lock held. So the sisguspend(2) like cases "select(0, NULL, NULL, NULL, NULL)" and "poll(NULL, 0, INFTIM)" should not trigger it. Commit reverted diff back. ok claudio@
2023-02-24Change to use the default bsd.prog.mk "install" target.Kenji Aoyama
This also brings to install boot.8 man page correctly. ok miod@
2023-02-24Do not held the vm_map lock while flushing pages in msync(2) and madvise(2).Martin Pieuchot
Mark the VM map as busy instead to prevent any sibling thread to request an exclusive version of the vm_map. This is necessary to let any PG_BUSY page, found in the UVM vnode object, to be released by a sibling in the middle of a page-fault. Note: the page-fault handler releases & re-grab a shared version of the vm_map lock and expect it to be available to make progress. Prevent a 3-Threads deadlock between msync(2), page-fault and mmap(2). The deadlock reported on bugs@ by many occured as follow: ..ThreadA faults & grabs the shared `vmmaplk' then release it before calling ..uvn_get() which might sleep to allocate pages and mark them as PG_BUSY. ..Once the lock is released, threadB calls uvn_flush(). It sees at least a ..PG_BUSY page and sleeps on the `vmmaplk' waiting for threadA to un-busy ..the page. ..At the same time threadC asked for an exclusive version of the lock and ..sleeps until all reader are done with it. This prevents threadA to ..acquire a shared-version of the lock and finish the page fault. This issue is similar to NetBSD's PR #56952 and the fix is from Chuck Silvers. Tested by many on bugs@, thanks! ok kettenis@
2023-02-23Remove dangerous user-settable "addr" variable from MI boot loader, andMiod Vallat
only compile tty-related code (stty command, tty variable) on platforms where it makes sense for the boot loader to control it, rather than the PROM/firmware/whatever.
2023-02-23Make bootloader 'time' command work correctly on luna88k.Kenji Aoyama
Now the correct date is displayed instead of January 1, 1970. Tested on LUNA-88K2 and nono emulator by me. "make sense" miod@
2023-02-23Fix ethertype for NSH. RFC 8300 states ethertype 0x894F has beenMoritz Buhl
allocated for NSH. Found by bluhm. ok dlg.
2023-02-23drm/i915/gen11: Wa_1408615072/Wa_1407596294 should be on GT listJonathan Gray
From Matt Roper 2fc3ff76e96f48e5e4dd705f6794b8483f7c1624 in linux-6.1.y/6.1.13 d5a1224aa68c8b124a4c5c390186e571815ed390 in mainline linux
2023-02-23drm/amd/display: Fail atomic_check early on normalize_zpos errorJonathan Gray
From Leo Li 020eccac747e30a35f1fdd4dc6f18425ff1a5870 in linux-6.1.y/6.1.13 2a00299e7447395d0898e7c6214817c06a61a8e8 in mainline linux
2023-02-23drm/amd/amdgpu: fix warning during suspendJonathan Gray
From Jack Xiao dbe3529e816ee77a19fb6636e762b1dadbd02d10 in linux-6.1.y/6.1.13 8f32378986218812083b127da5ba42d48297d7c4 in mainline linux
2023-02-23drm/amd/display: Properly handle additional cases where DCN is not supportedJonathan Gray
From Alex Deucher b4e79d0c7f9bb938525716b3e05cfca6418e2bae in linux-6.1.y/6.1.13 6fc547a5a2ef5ce05b16924106663ab92f8f87a7 in mainline linux
2023-02-23drm/amdgpu: Enable vclk dclk node for gc11.0.3Jonathan Gray
From Yiqing Yao fc64b04297a0674f4e5aff50622efdce46715fe1 in linux-6.1.y/6.1.13 ac7170082c0e140663f0853d3de733a5341ce7b0 in mainline linux
2023-02-23drm/amdgpu: enable HDP SD for gfx 11.0.3Jonathan Gray
From Evan Quan e9cbb2b0d9f679d7e25b9415cf9d7345441a95c5 in linux-6.1.y/6.1.13 bb25849c0fa550b26cecc9c476c519a927c66898 in mainline linux
2023-02-23drm/amd/display: Reset DMUB mailbox SW state after HW resetJonathan Gray
From Nicholas Kazlauskas 488770cbddd8a873fb3bb8866e8a46211570c367 in linux-6.1.y/6.1.13 154711aa5759ef9b45903124fa813c4c29ee681c in mainline linux
2023-02-23drm/amd/display: Unassign does_plane_fit_in_mall function from dcn3.2Jonathan Gray
From George Shen 383e32fa274a330dbf2d2db538b6bf2f9ef390aa in linux-6.1.y/6.1.13 275d8a1db261a1272a818d40ebc61b3b865b60e5 in mainline linux
2023-02-23drm/amd/display: Adjust downscaling limits for dcn314Jonathan Gray
From Daniel Miess 7dbd205349f1fb098057c28a9a2af244aa868f72 in linux-6.1.y/6.1.13 dd2db2dc4bd298f33dea50c80c3c11bee4e3b0a4 in mainline linux
2023-02-23drm/amd/display: Add missing brackets in calculationJonathan Gray
From Daniel Miess 0c42622a573b716d79c57ff61c52fea46c0a5c94 in linux-6.1.y/6.1.13 ea062fd28f922cb118bfb33229f405b81aff7781 in mainline linux
2023-02-23include two required header files, because we want people to use utrace()Theo de Raadt
easier ok guenther
2023-02-21for process kills due to execve from non-pinned syscall address, exportTheo de Raadt
a new AEXECVE bit to acct(4), and print it in lastcomm(8) ok bluhm
2023-02-21Attach Apollo Lake HD Audio device, enabling audio on machines with it.Brian Callahan
ok jsg@ phessler@
2023-02-21Set the current pmap in macppc's pmap_activateGeorge Koehler
This fixes a possible freeze in execve(2). It sometimes froze when a dual-cpu macppc started daemons during boot. There is a chance that uvm_map.c uvmspace_exec sees ovm->vm_refcnt != 1 and switches curproc to a new pmap. If this happened, then execve froze by trying to copyout to the wrong pmap; curpcb->pcb_pm was old. Fix by setting pointers when uvmspace_exec calls pmap_activate. ok miod@
2023-02-20Rewrite the ROM walk logic to correctly iterate over non-STI ROMs (and skipMiod Vallat
them), such as x86 bios ROMs.
2023-02-20Wrap all printf calls in sti_check_rom() in order to automagically cope withMiod Vallat
ROM enable/disable; makes addition of debug code more fool-proof. NFC (yet)
2023-02-20Unbreak RAMDISK build by adding a check for MULTIPROCESSOR.Patrick Wildt
2023-02-19Make pinsyscall(2) always available for pledged processes. Needed by pledgeAnton Lindqvist
execpromises, as noted by regress/sys/kern/pledge/execpromise. sure deraadt@
2023-02-19Add support for deep(er) idle states that can be entered using PSCI. ForMark Kettenis
now this only supports states advertised in device trees, but ACPI support could be added as well. The parsing of the idle states as well as the heuristic to pick the deepest one is probably a bit to simple, but more complex cases can be added later. Worst case cores will use WFI and use more power in suspend. ok phessler@
2023-02-19Do not let the iwx init task run in parallel to wakeup code during resume.Stefan Sperling
The driver will resume in the ACPI thread and run code to wake the device. If a firmware error occurs then the init task will be scheduled and could then run in parallel to the wakeup code. This would lead to panics as the init task ran while we were not yet done with device initialization. To prevent this problem we now grab the rwlock during wakeup, the same lock which is used to prevent races between the init task and ioctls. Problem found by mvs@, who also suggested the fix implemented here and tested the changes. ok mvs@
2023-02-18acpipwrres(4): remove unused aml_value's.Dave Voutila
ok kettenis@
2023-02-17Validate execve() libc stub location if kernel knows it. (due to ld.soTheo de Raadt
telling the kernel with pinsyscall(2)
2023-02-17Do not need KTRC_CODE__SYSCALL in the ktrace files anymore, becauseTheo de Raadt
__syscall() was removed.
2023-02-17spellingJonathan Gray
ok mglocker@
2023-02-16Remove obsolete __HAVE_VM_PAGE_MD define - all platforms provide vm_page_mdMiod Vallat
those days, and nothing checks for that symbol anymore.
2023-02-16Enable dwqe(4).Mark Kettenis
2023-02-16Fix MAC address register offsets.Mark Kettenis
ok patrick@
2023-02-16regenClaudio Jeker