summaryrefslogtreecommitdiff
path: root/sys
AgeCommit message (Collapse)Author
2015-12-09Do not trigger a KASSERT() if the route we're trying to remove does notMartin Pieuchot
exist and we get another matching one instead. This bug has been here since the KAME area and recently exposed by a refactoring at n2k15. The problem is that rtrequest(9) does not check on which interface the route entry is attached when issuing a RTM_DELETE. So the kernel would end up deleting the route attached on a different ifp when in_ifinit() fails. This fix is currently a workaround, a better fix is in the pipeline. Reported by Laurence Tratt <laurie AT tratt DOT net>, thanks!
2015-12-09Do not trigger a KASSERT() when destroying/detaching an interface withMartin Pieuchot
RTF_CLONED routes attached. In thise case if_get(9) can return NULL inside rtflushclone1() because ifdetach() starts by clearing the interface pointer in the index map. So it is perfectly correct to bail and we're not going to leak any route entry because we're garbage collecting all of them. Reported by daniel@ and Aaron Miller <aaron DOT miller04 AT gmail DOT com>
2015-12-09Backport some commits from mainline linux to enable High Bit Rate 2Jonathan Gray
(HBR2) for Broadwell and non-ULX Haswell DisplayPort. This enables support for 3840x2160 60Hz SST. Initial patch from and tested by Scot Doyle. drm/i915: Enable 5.4Ghz (HBR2) link rate for Displayport 1.2-capable devices from Todd Previte 06ea66b6bb445043dc25a9626254d5c130093199 drm/i915: don't try DP_LINK_BW_5_4 on HSW ULX from Paulo Zanoni 9bbfd20abe5025adbb0ac75160bd2e41158a9e83 drm/i915/dp: add missing \n in the TPS3 debug message from Jani Nikula f8d8a672f9370278ae2c9752ad3021662dbc42fd drm/i915/dp: only use training pattern 3 on platforms that support it from Jani Nikula 7809a61176b385ebb3299ea43c58b1bb31ffb8c0
2015-12-09rework the if_start mpsafe serialisation so it can serialise arbitrary workDavid Gwynne
work is represented by struct task. the start routine is now wrapped by a task which is serialised by the infrastructure. if_start_barrier has been renamed to ifq_barrier and is now implemented as a task that gets serialised with the start routine. this also adds an ifq_restart() function. it serialises a call to ifq_clr_oactive and calls the start routine again. it exists to avoid a race that kettenis@ identified in between when a start routine discovers theres no space left on a ring, and when it calls ifq_set_oactive. if the txeof side of the driver empties the ring and calls ifq_clr_oactive in between the above calls in start, the queue will be marked oactive and the stack will never call the start routine again. by serialising the ifq_set_oactive call in the start routine and ifq_clr_oactive calls we avoid that race. tested on various nics ok mpi@
2015-12-09successful vmm enter/leave does not need to be reportedTheo de Raadt
ok mlarkin
2015-12-09Don't expose XenStore ops we don't know how to deal withMike Belopuhov
2015-12-08Implements simple virtual device probing routineMike Belopuhov
Discussed with deraadt@, kettenis@, mpi@, OK mlarkin, mpi
2015-12-08Implement a function to detach emulated devices (such as an em(4)Mike Belopuhov
network interface) in order to attach a paravirtualized drivers (such as Xen Netfront). OK mlarkin
2015-12-08Driver for XenStore, the configuration storageMike Belopuhov
XenStore provides a hierarchical storage for Xen configuration in a style of an OpenFirmware. Itself it's an interrupt driven producer/consumer interface with two 1kb rings for input and output. It's required in order to do virtual device discovery and device configuration (fetch MAC address, various parameters). With input from and OK mlarkin, reyk
2015-12-08Disable xspd(4) until the man page is written; noticed by reyk@Mike Belopuhov
2015-12-08Driver for the XenSource Platform DeviceMike Belopuhov
This is a simple driver for the virtual PCI device with only one purpose: to allocate the interrupt vector and communicate that to the Hypervisor in case the IDT callback method was not available. With input from and OK deraadt, mlarkin, reyk, mpi
2015-12-08Add ability to establish virtual interrupts via Xen eventMike Belopuhov
channel ports. During boot, Xen will use polling mode, but once the system enables interrupts after cpu_configure(), xen_intr_enable will be called from the mountrook hook to unmask event ports. OK mlarkin, mpi, reyk
2015-12-08Communicate the selected IDT vector to the HypervisorMike Belopuhov
OK mlarkin, reyk
2015-12-08Set up an IDT vector for Xen callbacksMike Belopuhov
This adds support for delivering the combined Xen interrupt that later fans out into event port specific (device specific) interrupts via an IDT of a guest system. The Xen IDT vector is set to be the first of the IPL_NET group and is implemented the same way LAPIC timer and IPIs are done. The additional machinery is there to be able to mask it via standard mechanisms (e.g. splnet). Discussed with kettenis@, OK mlarkin, reyk
2015-12-08Allocate and hook up a "shared info page"Mike Belopuhov
This page provides a matrix of pending events and some other information like hypervisor timecounter. OK mlarkin, reyk
2015-12-08This brings in support for Xen hypercalls via an MI interfaceMike Belopuhov
and implements functions to fetch extended version and features. OK mlarkin
2015-12-08Setup a hypercall page in the kernel .text segmentMike Belopuhov
Its location will be communicated with the Xen hypervisor that will fill it in with instructions resulting in VMEXIT events. Discussed with kettenis@ and deraadt@, with input from and OK mpi, mlarkin, reyk
2015-12-08Xen basic infrastructure files and pvbus(4) attachment.Mike Belopuhov
With input from and OK mpi, mlarkin, reyk
2015-12-08When iwm(4) moves to AUTH state it asks the firmware for a "time event" toStefan Sperling
prevent it from moving off-channel during association. The firmware issues interrupts at beginning and end of the time event. The driver tried detecting the beginning with a tsleep() in the newstate task followed by a wakeup() from the interrupt handler. However, sometimes the newstate task did not get scheduled until the time event had already passed, and association was aborted. In rare cases the newstate task would even sleep forever and the iwm(4) interface would stop working until reboot. Fix these issues by issuing the time event and continuing association without checking for a "go" from the firmware. Our kernel does not provide the scheduling guarantees required for such precise synchronization so association is more likely to fail with the additional check than without. ok mpi@ tedu@
2015-12-08correct errant spacing here before it continues spreadingTed Unangst
2015-12-08correct errant spacingTed Unangst
2015-12-08No trailers has been the default and only option for 20 years, yet someTed Unangst
drivers still set IFF_NOTRAILERS while others do not. Remove all usage of the flag from the drivers which in ancient times used it (and the modern drivers which blindly copied it from those drivers of yore). suggested by guenther. ok mpi
2015-12-08_SYS_TASKQ_H_ -> _SYS_TASK_H_David Gwynne
2015-12-08tweak whitespace in struct definition. no functional change.David Gwynne
2015-12-08use struct task_list instead of TAILQ_HEAD(, task)David Gwynne
2015-12-08+TAILQ_HEAD(task_list, task);David Gwynne
2015-12-08vlan doenst have to handle SIOCGIFADDR cos the stack does it.David Gwynne
ok mpi@
2015-12-08Kill unused iftxlist.Martin Pieuchot
ok dlg@
2015-12-08if_stop is unused, so kill it.David Gwynne
ok mpi@
2015-12-08split the interface send queue (struct ifqueue) implementation out.David Gwynne
the intention is to make it more clear what belongs to a transmit queue and what belongs to an interface. suggested by and ok mpi@
2015-12-08Match 3rd party Xbox 360 controllers, from Christian Heckendorf.Martin Pieuchot
Tested by jeremy@
2015-12-08dont need to repeatedly set if_start to the same function.David Gwynne
2015-12-07Add cpuid bits documented in the August 2015 revision ofJonathan Gray
"Intel Architecture Instruction Set Extensions Programming Reference"
2015-12-07enable snooping on Intel 100 Series HDAJonathan Gray
from and tested by daniel@
2015-12-07match on intel 100 seriesJonathan Gray
from and tested by daniel@
2015-12-07NFS can pass a buffer cache buffer straight to VOP_STRATEGY here, so dma_flip isBob Beck
needed. Found by henning@ - thanks! ok deraadt@
2015-12-06Only declare buf_daemon() oncePhilip Guenther
2015-12-06child_return() is already declared in <sys/proc.h>Philip Guenther
2015-12-06add function prototypeMike Larkin
2015-12-06move around some deck chairs in preparation for supporting VM reboot. thisMike Larkin
diff moves the cpu register init code into its own function which will soon be called from vmd to reset processor state. no functional change with this diff.
2015-12-06Don't bother printing out the count of what type of cpu we have. InsteadMike Larkin
just print the feature being used (eg, VMX/EPT). suggested by and ok deraadt@
2015-12-06don't allow opening of /dev/vmm if we are in an unsupported configurationMike Larkin
or if vmm0 didn't attach, prevents later panics if we try to use vmm in such a state. reported by many on tech/misc
2015-12-06Change kernel internal pledge variables to 64bit (to prepare for moreTheo de Raadt
extensions). This change is exposed in ktrace.out files ok semarie
2015-12-06switch on the return value of bus_dmamap_load_mbuf not value != 0Jonathan Gray
problem in rev 1.47 spotted by clang's -Wswitch-bool ok jmatthew@ kettenis@
2015-12-06Since the page zeroing thread runs without the kernel lock,Bret Lambert
it relies upon the fpageq lock for data consistency and sleep/wakeup interlocking. Therefore, code which modifies page zeroing thread data or performs a wakeup of the thread must also hold the fpageq lock. Fix an instance where this was not the case. ok kettenis@ diff --git a/sys/uvm/uvm_pmemrange.c b/sys/uvm/uvm_pmemrange.c
2015-12-06g/c pf_change_a6(). it's exactly the same thing as pf_change_ap() with p =Henning Brauer
NULL. inspired by Richard Procter <richard.n.procter@gmail.com>'s mail on tech from Aug 17, but redone. ok sashan vgross
2015-12-06unbreak kernel link if vmm isnt being built as part of the kernel.David Gwynne
2015-12-06typo in log entrymmcc
2015-12-06restore VMM mode after resume from suspend/hibernateMike Larkin
2015-12-05Multiple cleanups.Martin Pieuchot
ok goda@, yasuoka@