summaryrefslogtreecommitdiff
path: root/sys
AgeCommit message (Collapse)Author
2015-11-30Add support for the touchpad found on the MacBooPro12,1.Mark Kettenis
ok jcs@
2015-11-29Make it possible to detach bge(4).Mark Kettenis
ok deraadt@
2015-11-29Unconnected xhci(4) super speed ports may come up with the XHCI_PS_WRC,Mark Kettenis
indicating a warm reset has happened. Communicate this as UPS_C_BH_PORT_RESET to the upper layers and make uhub(4) clear this bit such that we receive further connection status change notifications. Make sure we only do this for super speed (USB 3.0) hubs as high speed (USB 2.0) hubs use the same bit for UPS_C_PORT_L1. Make hotplugging USB 3.0 devices work on my MacBookPro12,1. ok mpi@
2015-11-29Clear the UPS_C_PORT_RESET feature when exploring. Apparently xhci(4) superMark Kettenis
speed ports may have the XHCI_PS_PRC bit set after xhci(4) attaches. Just clearing this bit isn't enough though, since the device is already connected and no further connection status change is signalled. So fake one. This makes the integrated SD card reader in the MacBookPro12,1 attach. ok mpi@
2015-11-29Convert the simple list of multipath route entries used by ART kernelsMartin Pieuchot
to a SRP list. This turns the rtable_* layer mpsafe. We now only need to protect the ART implementation itself. Note that route(8) regress tests will now fail due to a supplementary reference taken by the SRPL_INIT(9) API. ok dlg@
2015-11-29Disk size in blocks is LastBlock+1. Fix whitespace nit.Kenneth R Westerback
ok yasuoka@
2015-11-29Use if_get() rather than dereferencing rt_ifp in ip6_getpmtu().Martin Pieuchot
While here fix a NULL dereference introduced by the support for multiple rdomains. It seems that this code path is never run... With input from David Hill, ok florian@
2015-11-29Fix an hypotetical NULL dereference which might become true once the TCPMartin Pieuchot
layer will be turned mpsafe. We're not there yet. Reported by David Hill, ok florian@
2015-11-29On a SMALL_KERNEL, pledge "pf" has to be a no-op. We cannot matchTheo de Raadt
the device node (since it does not exist...)
2015-11-29Add pledge "pf" which allows ioctls on pf(4). This will be used bySebastian Benoit
relayd and other programs manipulating the packet filter. ok deraadt@
2015-11-28rework dc_start and dc_encap to take advantage of m_defrag.David Gwynne
if the chip needs coalesced packages in tx, set the tx dmamaps up to only use a single dma descriptor. use m_defrag when bus_dmamap_load_mbuf returns EFBIG rather than copying the packet to a separate mbuf with hand rolled code in dc_coal. that in turn makes the ifq_deq_begin, ifq_deq_commit, and ifq_deq_rollback handling more straightforward. tested by me on a hppa a180c with a "DEC 21142/3", and fred on bugs@ with a sparc64 netra x1 "Davicom DM9102".
2015-11-28Use the same function as kern/subr_disk.c and fdisk/mbr.c to checkKenneth R Westerback
for a GPT protective MBR. Better than mangling findopenbsd() to do the check. Tested & ok yasuoka@
2015-11-28move buffer size adjustment to buf_adjcnt - from Walter NetoBob Beck
ok mpi@
2015-11-28Convert pppoe(4) to use if_get()/if_put(): instead of storing aReyk Floeter
pointer to the parent "pppoedev", it now only stores an interface index. This also fixes a potential NULL pointer dereference that could happen in pppoe_find_softc_by_session() when the parent got deconfigured but the session was still active. Found the hard way with pppoe(4) on vlan7. OK mpi@, with debugging help from mikeb@
2015-11-28pledge: allow getsockopt IP_IPDEFTTL with promise inetSebastian Benoit
then relayd's host check engine can be pledged. ok reyk@, approach suggested by deraadt@ weeks ago.
2015-11-28Delete sc_root_port which became unused when RSTP is merged.YASUOKA Masahiko
ok reyk mpi
2015-11-28regenMark Kettenis
2015-11-28Add a few devices found on the MacBookPro12,1Mark Kettenis
2015-11-28Check the protective MBR stricter not to choose a broken GPT.YASUOKA Masahiko
test and ok gonzalo
2015-11-28Rework gem_start to check that there's enough space in the ring beforeJonathan Matthew
dequeueing a packet, then drop the packet if it can't be sent, rather than using two phase dequeue then commit. Adjust sc_tx_cnt using atomic operations, take the kernel lock before calling gem_start or gem_init from the interrupt handler, and use an interrupt barrier when taking the interface down. With all this done, we can mark the interrupt handler for pci (but not sbus) attached gem(4) as mpsafe. mpi@ wrote this initially, I fixed bugs to keep sparc64 happy and kept it up to date with ifq changes. ok mpi@ dlg@
2015-11-27Two additional ioctls for pledge("disklabel"), needed by installboot.Jeremie Courreges-Anglas
Committing on behalf of tb@, problem reported by Rolf Sommerhalder on misc@.
2015-11-27Keep "struct vxlan_softc" private to prevent pulling more headers whenMartin Pieuchot
<net/if_vxlan.h> is included.
2015-11-27Don't panic in pmap_enter() if we deplete the pool of pv entries and theMark Kettenis
PMAP_CANFAIL flag is set. Return ENOMEM instead.
2015-11-27Don't report a bus conflict for bridges that are left (partly) unconfigured byMark Kettenis
the system firmware.
2015-11-27Keep lo(4) definitions inside if_loop.cMartin Pieuchot
2015-11-27Document that routing table heads are never freed as suggested by dlg@Martin Pieuchot
and kill rtable_put() because we're not going to use it. The overhead of keeping a "struct art_root/radix_node_head" around is very small compared to the added complexity needed to reference count such structures.
2015-11-27Protect the growth of the routing table arrays used by rtable_get()Martin Pieuchot
with SRPs. This is a simplified version of the dynamically sizeable array of pointers used by if_get() because routing table heads are never freed. ok dlg@
2015-11-27Attach the iPhone 6 as ugen(4), from Laurent GUALDI.Martin Pieuchot
2015-11-27regenMartin Pieuchot
2015-11-27iPhone 6, from Laurent GUALDI.Martin Pieuchot
2015-11-27correct logic for a IEEE80211_MODE_11N testJonathan Gray
ok stsp@
2015-11-26Avoid setting mode to GOP if the mode is unchanged. Also don't panicYASUOKA Masahiko
if the setting mode is failed. reported and tested by Joe Gidi
2015-11-26Add SRPL_FOREACH_SAFE_LOCKED(9), needed to turn the single list ofMartin Pieuchot
multipath route entries mpsafe. ok dlg@
2015-11-26Fix a typo in comment.YASUOKA Masahiko
2015-11-26Use rtalloc(9) to look for a local address (RTF_LOCAL) in ip_setmoptions().Martin Pieuchot
This simplifies the if_get()/if_put() dance. Tested by jasper@
2015-11-26init pat_default to 0 as it may potentially be used uninitialisedJonathan Gray
ok mlarkin@
2015-11-26Automatically start vmm(4) when the first VM is created and after theReyk Floeter
last VM is terminated. This allows to remove the explicit "vmm enable" / "vmm disable" (VMM_IOC_START / VMM_IOC_STOP) ioctls. You'll have to update kernel and userland for this change, as the kernel ABI changes. OK mpi@ mlarkin@
2015-11-25Don't bother keeping track of the resident count for the kernel pmap.Mark Kettenis
2015-11-25permit kern.maxpartitionsTheo de Raadt
2015-11-25Simplify the setup of gather segments.Visa Hankala
2015-11-25Network drivers should not include <net/route.h> or <net/netisr.h>Martin Pieuchot
2015-11-25Small fixes related to the IFF_OACTIVE removal.Martin Pieuchot
2015-11-25add size to freeTed Unangst
2015-11-25trim unused variableDavid Gwynne
2015-11-25replace IFF_OACTIVE manipulation with mpsafe operations.David Gwynne
there are two things shared between the network stack and drivers in the send path: the send queue and the IFF_OACTIVE flag. the send queue is now protected by a mutex. this diff makes the oactive functionality mpsafe too. IFF_OACTIVE is part of if_flags. there are two problems with that. firstly, if_flags is a short and we dont have any MI atomic operations to manipulate a short. secondly, while we could make the IFF_OACTIVE operates mpsafe, all changes to other flags would have to be made safe at the same time, otherwise a read-modify-write cycle on their updates could clobber the oactive change. instead, this moves the oactive mark into struct ifqueue and provides an API for changing it. there's ifq_set_oactive, ifq_clr_oactive, and ifq_is_oactive. these are modelled on ifsq_set_oactive, ifsq_clr_oactive, and ifsq_is_oactive in dragonflybsd. this diff includes changes to all the drivers manipulating IFF_OACTIVE to now use the ifsq_{set,clr_is}_oactive API too. ok kettenis@ mpi@ jmatthew@ deraadt@
2015-11-24Add sendsyslog2(), which accepts the syslog/openlog "logopt" flagTheo de Raadt
LOG_CONS. If syslogd is not accepting messages, direct them to the console. This allows us to remove the direct /dev/console opening code from the bowels of libc. Of course, that forgotten code was exposed by pledge. ok kettenis millert beck
2015-11-24syncTheo de Raadt
2015-11-24Add sendsyslog2... this has an additional flags variable to permitTheo de Raadt
passing LOG_CONS ok millert kettenis beck
2015-11-24regenMark Kettenis
2015-11-24Add a few missing devices found on recent Apple hardware.Mark Kettenis
From Bryan Vyhmeister.