summaryrefslogtreecommitdiff
path: root/sys
AgeCommit message (Collapse)Author
2010-09-24TCP send and recv buffer scaling.Claudio Jeker
Send buffer is scaled by not accounting unacknowledged on the wire data against the buffer limit. Receive buffer scaling is done similar to FreeBSD -- measure the delay * bandwith product and base the buffer on that. The problem is that our RTT measurment is coarse so it overshoots on low delay links. This does not matter that much since the recvbuffer is almost always empty. Add a back pressure mechanism to control the amount of memory assigned to socketbuffers that kicks in when 80% of the cluster pool is used. Increases the download speed from 300kB/s to 4.4MB/s on ftp.eu.openbsd.org. Based on work by markus@ and djm@. OK dlg@, henning@, put it in deraadt@
2010-09-24dead store; found by clangTheo de Raadt
2010-09-24move DEBUG-only variable into #ifdefTheo de Raadt
2010-09-24itojun picked exactly the right reason in that REASON_SET call. really noHenning Brauer
reason to question himself by adding an XXX
2010-09-24use pd->rdomain for the PF_MISMATCHAW checks in pf_test_fragment instead ofHenning Brauer
hardcoding 0. roughly almost a bit equivalent to what pf_test_rule does. changing the rdomain for not reassembled fragments is not going to work ever, so the full dance pf_test_rule does doesn't make sense here. speaking of sense, I don't see anything remotely resembling sense in pf filtering on fragments without reassembling them first. with/ok claudio
2010-09-24no need to pf_tag_packet in the stateless case in pf_test sinceHenning Brauer
pf_test_rule will have done it already, as correctly XXX-comment noted by claudio almost a year ago. pf_test6 (which is scarily different there) didn't have that at all.
2010-09-24hello, this is captain obvious speaking:Henning Brauer
/* XXX This does NOT affect pass rules! */ SLIST_FOREACH(ri, &s->match_rules, entry) { ... delete that comment, entirely superfluous
2010-09-24remove misleading XXX comment. it is pretty clear by now thatHenning Brauer
pf_compare_state_keys will stay, we play safe.
2010-09-24nicer linewraps, purely cosmeticHenning Brauer
2010-09-24enable utwitch(4) for SGI machines too.Yojiro Uo
ok deraadt@, miod@
2010-09-24init err to 0 in sd_get_parms to avoid confusion when checking rigidDavid Gwynne
geometry. it doesnt matter waht the value there is cos rigid will be NULL, but this is clearer.
2010-09-24remove useless storeDavid Gwynne
2010-09-24no use setting cmd in mfi_ioctl_setstate if you never use it.David Gwynne
2010-09-24vol_list in mpi_get_raid is never used.David Gwynne
2010-09-24kill some unused arguments to pf_create_stateJonathan Gray
ok henning@
2010-09-24tsleep on a static and private handle, since our goal is to not beTheo de Raadt
woken up by a wakeup, but only by the actual timeout expiry. On architectures which share a kva upage area between processes, we would not want an accidental wakeup (too short). discussed with various
2010-09-23The only sensible argument for VOP_* calls that take a struct proc pointer isOwain Ainsworth
curproc. A bunch of callers were passing in 0 (not even NULL, 0) as this pointer, which was fine until the called vnode function tried to do something with it. Typically, this code was then copy/pasted to various parts of the tree. Accept the facts of life and switch all of these over to passing curproc for now until the argument can be removed. Discovered by stsp trying to create a softraid on top of a vnd, which crashed with a NULL deref in vndioctl. softraid bits tested by mikeb and jsing. raidframe bits tested by pea, matthieu and naddy. The rest tested by at least thib, jsing and myself. ok thib@, jsing@.
2010-09-23In procfs_root(), while the vn_lock on a newly-allocated vnode can notOwain Ainsworth
fail it is still good practise to either check the return value or to provide a flag that won't (to avoid copy pasted code that gets it wrong). So change LK_EXCLUSIVE to LK_EXCLUSIVE | LK_RETRY, removing the one caller of vn_lock in the tree that doesn't either pass LK_RETRY or check the return value. ok thib@, jsing@ as part of a larger diff.
2010-09-23Change:Owain Ainsworth
/* something */ if (error) { VOP_UNLOCK(); return; } VOP_UNLOCK(); to the clearer and shorter: VOP_UNLOCK(); if (error) return; ok thib@, jsing@ as part of a larger diff.
2010-09-23remove dying flag in the detach() function.Yojiro Uo
the device driver which has DEACTIVATE processing seems to no need to set dying flag in the detach() function because the flag will be set in the DEACTIVATE process before detach(). ok jsg@, ok for experiment deraadt@
2010-09-23remove m_pad in favor of m_inject as it's equivalent to m_injectMike Belopuhov
with an offset equal to the actual data length. ok henning blambert
2010-09-23enable utwitch(4) (formely uyurex(4)) by defaultYojiro Uo
ok deraadt@
2010-09-23rename uyurex(4) to utwitch(4)Yojiro Uo
ok deraadt@
2010-09-23Break out rule counter update code into a separate function, makes theRyan Thomas McBride
behaviour consistent between IPv4 and IPv6. From martin.pelikan@gmail.com
2010-09-23Move clock attachment later in the game. This is needed for cpu scaling.Paul Irofti
Okay miod@.
2010-09-23Include the disklabel UID in hw.disknames.Joel Sing
ok deraadt@ krw@
2010-09-23When a disk is attached create a workq task to read the disklabel,Joel Sing
providing the DKF_NOLABELREAD flag is not set. This provides the kernel with the actual disklabel which includes the disklabel UID. ok deraadt@ miod@ krw@
2010-09-23Introduce a DKF_NOLABELREAD flag, which is used by a device to preventJoel Sing
automatic reading of disklabel on attach. ok deraadt@ miod@ krw@
2010-09-23translate WRITE SAME 16 into DSM TRIM.David Gwynne
2010-09-23commands and bits for data set management.David Gwynne
2010-09-23fix indentation to not confusingly align with an unassociated while() statementBret Lambert
ok claudio@
2010-09-23descripe a few bits of the write same commands.David Gwynne
2010-09-23tweak the mclgeti algorithm to behave better under load.David Gwynne
instead of letting hardware rings grow on every interrupt, restrict it so it can only grow once per softclock tick. we can only punish the rings on softclock ticks, so it make sense to only grow on softclock tick boundaries too. the rings are now punished after >1 lost softclock tick rather than >2. mclgeti is now more aggressive at detecting livelock. the rings get punished by an 8th, rather than by half. we now allow the rings to be punished again even if the system is already considered in livelock. without this diff a livelocked system will have its rx ring sizes scale up and down very rapidly, while holding the rings low for too long. this affected throughput significantly. discussed and tested heavily at j2k10. there are still some games with softnet we can play, but this is a good first step. "put it in" and ok deraadt@ ok claudio@ krw@ henning@ mcbride@ if we find out that it sucks we can pull it out again later. till then we'll run with it and see how it goes.
2010-09-23Do not declare the domain and protosw structures in at.h fixes build withClaudio Jeker
netatalk enabled.
2010-09-23returning here can cause the usb task thread to go to sleep forever,Jacob Meuser
becaue it skips a wakeup() later on. this is the only error condition that returns before the wakeup. not sure why this particular case is handled differently, and not certain what the error code should be, but this is better than breaking all of usb because of a problem on one port. dicussed with deraadt
2010-09-23add two members to struct usb_taskJacob Meuser
* usbd_device_handle dev - the device responsible for the task. use this to not run the task if the device's hub is dying. * int running - a flag to be set when the task is running. add usb_rem_wait_task(), a wrapper for usb_rem_task() that waits for the task to complete if the task is already running. s/usb_rem_task/usb_rem_wait_task/ in usb_detach(). probably most drivers using usb_tasks should do this as well. although device attach/detach is serialized in normal cases, in the special case where the usb bus is hotpluggable (like cardbus/pcmcia), devices are not detached in the task thread.
2010-09-23add a 'dying' flag to struct usbd_bus. use this to signify the busJacob Meuser
is dying, instead of setting a flag in struct usb_softc. as usbd_device_handle has a pointer to the usbd_bus it's attached to, usb devices, and functions they run or functions run on their behalf, can now easily check if their bus is dying. use this to stop usbd_do_request* from running and the usb task thread from adding new tasks when a device's bus is dying.
2010-09-23instead of waiting the full power-up-to-power-steady time for rootJacob Meuser
hubs before their first port explore, check how long it's actually been since power up and only wait as necessary. saves a little time on boot, especially now that explore tasks are serialized. ok yuo@
2010-09-23Add pppx(4) to the cdevs of the remaining archs.Claudio Jeker
OK dlg@
2010-09-23instead of running usb_explore() from individual kthreads for eachJacob Meuser
USB bus, make usb_explore() a usb_task. reduces races during normal USB device detach, since now usb_tasks and detach happen in the same process. ok yuo@, matthew@ helped with the task thread loop
2010-09-23If tunread() fails, we should increment if_oerrors, not if_ierrors.Matthew Dempsky
"yup" deraadt@
2010-09-23add a new IP level socket option IP_PIPEX. This option is used for L2TPYASUOKA Masahiko
support by pipex. OK henning@, "Carry on" blambert@
2010-09-23rename usb_discover to usb_explore for consistency.Jacob Meuser
OK krw
2010-09-22use audio(4)'s quiesce/resume for data i/o, and ac97_resume() for mixerJacob Meuser
suspend/resume support
2010-09-22autoconf activate, suspend/resume supportJacob Meuser
2010-09-22as dying flag didn't set in aue_detach(), set it.Yojiro Uo
ok jsg@
2010-09-22Support for AES-GCM-16 and ENCR_NULL_AUTH_AES_GMAC in ESP as perMike Belopuhov
RFC 4106 and 4543. Authentication hash key is set to be the same as an encryption key. The length that is specified for the authentication hash descriptor denotes the the length of Additional Authentication Data (AAD). The encryption transformation descriptor length denotes the length of the payload (to be encrypted and authenticated). ENCR_NULL_AUTH_AES_GMAC treats all input as AAD, thus the encryption length is set to zero. This also fixes padding for stream ciphers, so that payload will be 4-byte aligned.
2010-09-22Add a new interface pppx(4) -- the ppp multiplexer to be used with npppdClaudio Jeker
and pipex. pppx(4) creates an interface whenever a session is created so that altq and pf can work on these. Started by dlg@ debugged and made usable by myself OK dlg@ yasuoka@ deraadt@
2010-09-22Add AES-GCM Transform Identifiers as specified by IANA inMike Belopuhov
RFC 4106 and 4543. Please note that although IKEv1 and IKEv2 identifiers are different for ESP_NULL_AUTH_AES-GMAC (SADB_X_EALG_AESGMAC), we use the IKEv2 one only (which is 21). ipsecctl(8) will be taught to handle exported SA correctly.
2010-09-22Revert previous and let drivers register counterless interrupts;Miod Vallat
tc_intr_disestablish() prototype is changed to carry information whether the counter needs to be detached or not. This does not matter much since no driver ever calls tc_intr_disestablish().