aboutsummaryrefslogtreecommitdiff
path: root/sys
Commit message (Collapse)AuthorAgeFilesLines
* Revert MFC of r258821 - it was already handled by MFC of r239672.Peter Wemm2014-01-081-4/+2
| | | | | | | Pointy hat to: peter Notes: svn path=/stable/6/; revision=260438
* MFC r258821 - fix tcp simultaneous closePeter Wemm2014-01-071-2/+4
| | | | | | | PR: kern/99188 Notes: svn path=/stable/6/; revision=260422
* MFC r249846:Dimitry Andric2013-05-012-2/+2
| | | | | | | | | | | | | | When rebooting (exiting) from the BTX loader, make sure to restore the GDT from the correct segment, otherwise a triple fault would be caused. In some virtual environments (VMware, VirtualBox, etc) this could lead to a unhandled error or hang in the guest emulation software. Thanks to avg and jhb for a few hints in the right direction. Noticed by: Jeremy Chadwick <jdc@koitsu.org> (and many others) Notes: svn path=/stable/6/; revision=250151
* MFC r247334:Xin LI2013-03-011-1/+1
| | | | | | | | | | | | Correct a typo introduced in r153575, which gives inverted logic when handling blocking semantics when seeding. PR: kern/143298 Submitted by: James Juran <james juran baesystems com> Reviewed by: markm Notes: svn path=/stable/6/; revision=247511
* MFC r239672 (by rrs):Mark Johnston2013-02-211-0/+30
| | | | | | | | | | | | | | | | | This small change takes care of a race condition that can occur when both sides close at the same time. If that occurs, without this fix the connection enters FIN1 on both sides and they will forever send FIN|ACK at each other until the connection times out. This is because we stopped processing the FIN|ACK and thus did not advance the sequence and so never ACK'd each others FIN. This fix adjusts it so we *do* process the FIN properly and the race goes away ;-) Approved by: emaste (co-mentor) Notes: svn path=/stable/6/; revision=247136
* MFC 244900: Happy New Year 2013!David E. O'Brien2012-12-311-2/+2
| | | | | | | (and we're still making commits to 6.x!) Notes: svn path=/stable/6/; revision=244917
* MFC r232267 via stable/8 MFC r232354Sean Bruno2012-03-022-0/+10
| | | | | | | | | | | | | | | Workaround for PCIe 4GB boundary issue Enforce a boundary of no more than 4GB - transfers crossing a 4GB boundary can lead to data corruption due to PCIe limitations. This change is a less-intrusive workaround that can be quickly merged back to older branches; a cleaner implementation will arrive in HEAD later but may require KPI changes. This change is based on a suggestion by jhb@. Notes: svn path=/stable/6/; revision=232398
* Update if_de(4) to fix bugs - a combination of bitrot and busdma changes.Adrian Chadd2011-09-261-19/+20
| | | | | | | | | | This commit is a merge of 197465, 197464, 197463, 197461, 177937 and 170389. Submitted by: Andreas Longwitz <longwitz@incore.de> Reviewed by: jhb Notes: svn path=/stable/6/; revision=225767
* MFC r220247:Bjoern A. Zeeb2011-04-092-1/+47
| | | | | | | | | | | | Do not allow directly recursive RFC3173 IPComp payload. While IPv6 does count iterations over next headers in ip6_input, we still disallow directly recursive IPComp payload in the KAME code. Security: CVE-2011-1547 Notes: svn path=/stable/6/; revision=220485
* MFC: Use the 'cfg2' value for Intel chipsets to limit the number of channelsJohn Baldwin2010-11-021-52/+53
| | | | | | | | for non-SATA controllers. Specifically, limit the non-AHCI ICH7, 63XXESB2, and ICHM8 controllers to a single channel. Notes: svn path=/stable/6/; revision=214674
* MF revision 184327 except for the default algorithm.KATO Takenori2010-10-032-7/+112
| | | | | | | | | The improved IDE HDD geometry adjustment is merged but default algorithm is not changed in this branch. This commit allows 6-stable user to test new algorithm before complete upgrading to 7 or later. Notes: svn path=/stable/6/; revision=213393
* r201663 introduced a bug in stable/6 that prison_ip() might change theBjoern A. Zeeb2010-09-281-2/+7
| | | | | | | | | | | | | | | passed address argument, while we are only interested in whether it is a valid address of the jail. This can modify an address in the live interface address list with an address of the jail. Make a copy of the address for the call to prison_ip() to avoid this. Reported by: Andreas Longwitz (longwitz incore.de) Tested by: Andreas Longwitz (longwitz incore.de) PR: kern/114325 Notes: svn path=/stable/6/; revision=213249
* MFC r182959:Tijl Coosemans2010-08-301-9/+0
| | | | | | | | | | | | Remove warning about static LDT segment allocation. Applications continue using it after ~7 years since warning was introduced, and there is no reason to discourage them. PR: kern/124111 Approved by: kib (mentor) Notes: svn path=/stable/6/; revision=211995
* MFC r211316:Andre Oppermann2010-08-211-1/+2
| | | | | | | | Change the messages of the ICMP bad port bandwidth limiter from a kernel printf to a log output with the priority of LOG_NOTICE. Notes: svn path=/stable/6/; revision=211544
* MFC r211315:Andre Oppermann2010-08-211-1/+1
| | | | | | | Disable TCP inflight limiter by default. Notes: svn path=/stable/6/; revision=211541
* MFC r150132:Andre Oppermann2010-08-141-1/+1
| | | | | | | | | | | Increase boot-time DigiBIOS initialization timeout to allow for a larger number of chained port modules. PR: kern/55018 Submitted by: Cyrill Shevchuk <cyrill at cyrills.net> Notes: svn path=/stable/6/; revision=211321
* MFC r210686:Bjoern A. Zeeb2010-08-141-0/+20
| | | | | | | | | | | MFp4 @181628: Free the rtentry after we diconnected it from the FIB and are counting it as rttrash. There might still be a chance we leak it from a different code path but there is nothing we can do about this here. Notes: svn path=/stable/6/; revision=211298
* MFC 170866,176206:John Baldwin2010-08-062-5/+5
| | | | | | | | | If busdma is being used to realign dynamic buffers and the alignment is set to PAGE_SIZE or less, the bounce page counting logic was flawed and wouldn't reserve any pages. Adjust to be correct. Notes: svn path=/stable/6/; revision=210932
* MFC 210604:John Baldwin2010-08-051-1/+1
| | | | | | | | Fix test for double-nul characters that terminate the string table at the end of each SMBIOS/DMI structure. Notes: svn path=/stable/6/; revision=210897
* MFC CVS r1.30:Attilio Rao2010-08-041-3/+0
| | | | | | | | | | Remove a bogus KASSERT which will prevent rwlock to be acquired recursively in exclusive mode with debugging kernels. Reported by: rwatson Notes: svn path=/stable/6/; revision=210844
* MFC 210066:John Baldwin2010-07-231-49/+33
| | | | | | | | Rework the SMBIOS table walker to make it operate like other table walkers and remove a buffer overflow. Notes: svn path=/stable/6/; revision=210414
* MFC: r206264Attilio Rao2010-05-194-6/+20
| | | | | | | | | | | When OOM searches for a process to kill, ignore the processes already killed by OOM. When killed process waits for a page allocation, try to satisfy the request as fast as possible. Sponsored by: Sandvine Incorporated Notes: svn path=/stable/6/; revision=208319
* Fixup MFC. I should have done test build before committing this.Xin LI2010-05-041-1/+1
| | | | | | | Pointy hat to: delphij Notes: svn path=/stable/6/; revision=207597
* MFC r195724 (mav):Xin LI2010-05-041-0/+5
| | | | | | | | | | Limit IOCATAREQUEST ioctl data size to controller's maximum I/O size. It fixes kernel panic when requested size is too large (0xffffffff), PR: kern/136726 Notes: svn path=/stable/6/; revision=207591
* /boot/loader support doesn't exist for arm in FreeBSD 6.x, so relax theWarner Losh2010-04-251-1/+1
| | | | | | | post-install for arm too. Notes: svn path=/stable/6/; revision=207204
* MFC: r205223Jung-uk Kim2010-03-221-16/+13
| | | | | | | | | | Fix a long standing regression of readdir(3) in fdescfs(5) introduced in r1.48. We were stopping at the first null pointer when multiple file descriptors were opened and one in the middle was closed. This restores traditional behaviour of fdescfs. Notes: svn path=/stable/6/; revision=205470
* MFC: r204105Jung-uk Kim2010-03-221-6/+15
| | | | | | | | | | | Return partially filled buffer for non-blocking read(2) in non-immediate mode. PR: kern/143855 Submitted by: Guy Harris (guy at alum dot mit dot edu) Notes: svn path=/stable/6/; revision=205467
* MFC: r205092Jung-uk Kim2010-03-221-3/+6
| | | | | | | | | | | | | | Tidy up callout for select(2) and read timeout. - Add a missing callout_drain(9) before the descriptor deallocation.[1] - Prefer callout_init_mtx(9) over callout_init(9) and let the callout subsystem handle the mutex for callout function. PR: kern/144453 Submitted by: Alexander Sack (asack at niksun dot com)[1] Notes: svn path=/stable/6/; revision=205465
* MFC 205255: Fix 2 bugs in mxge_attach()Andrew Gallatin2010-03-221-3/+3
| | | | Notes: svn path=/stable/6/; revision=205446
* MFC 181019, 183474, 191277, and 191626:Attilio Rao2010-03-193-76/+105
| | | | | | | | | | | | | | | | | | - Move the code for doing out-of-memory grass from vm_pageout_scan() into the separate function vm_pageout_oom(). Supply a parameter for vm_pageout_oom() describing a reason for the call. - Call vm_pageout_oom() from the swp_pager_meta_build() when swap zone is exhausted. - In both pageout oom handler and vm_daemon, acquire the reference to the vmspace of the examined process instead of directly accessing its vmspace, that may change. Also, as an optimization, check for P_INEXEC flag before examining the process. Sponsored by: Sandvine Incorporated Reviewed by: emaste Notes: svn path=/stable/6/; revision=205349
* MFC: r204222Marius Strobl2010-03-151-1/+4
| | | | | | | | | | | | According to the Linux sungem driver, in case of Apple (K2) GMACs GEM_MIF_CONFIG_MDI0 cannot be trusted when the firmware has powered down the chip so the internal transceiver has to be hardcoded. This is also in line with the AppleGMACEthernet driver, which just doesn't distinguish between internal/external transceiver and MDIO/MDI1 respectively in the first place. Tested by: Andreas Tobler Notes: svn path=/stable/6/; revision=205191
* MFC: r204144Marius Strobl2010-03-152-0/+27
| | | | | | | | | | Add support for BCM54K2 found in combination with Apple K2 GMAC. Submitted by: Andreas Tobler Obtained from: OpenBSD Notes: svn path=/stable/6/; revision=205188
* Fix a bug where MSI interrupts on x86 were always routed to APIC ID 0 ratherJohn Baldwin2010-02-172-0/+4
| | | | | | | | | | than the APIC ID of the boot CPU prior to SI_SUB_SMP. This resulted in some storage controllers not being able to enumerate attached devices when using MSI/MSI-X interrupts. This only affects <= 7.x, so it is a direct commit to 7 rather than an MFC. Notes: svn path=/stable/6/; revision=204014
* MFC r162488:Ed Maste2010-02-081-0/+4
| | | | | | | | | Use __builtin_offsetof for GCC 4.1. Submitted by: Ryan Stone Notes: svn path=/stable/6/; revision=203674
* MFC r202469:Bjoern A. Zeeb2010-01-242-2/+0
| | | | | | | Garbage collect references to the no longer implemented tcp_fasttimo(). Notes: svn path=/stable/6/; revision=202946
* MFC r201898:Bjoern A. Zeeb2010-01-171-1/+18
| | | | | | | | | | | | Add comments trying to explain what bad things happen here, i.e. how hashed MD5/SHA are implemented, abusing Final() for padding and sw_octx to transport the key from the beginning to the end. Enlightened about what was going on here by: cperciva Reviewed by: cperciva Notes: svn path=/stable/6/; revision=202479
* MFC r187826:Bjoern A. Zeeb2010-01-171-1/+6
| | | | | | | | | | | | | While OpenBSD's crypto/ framework has sha1 and md5 implementations that can cope with a result buffer of NULL in the "Final" function, we cannot. Thus pass in a temporary buffer long enough for either md5 or sha1 results so that we do not panic. PR: bin/126468 Reviewed by: cperciva Notes: svn path=/stable/6/; revision=202476
* MFC r201688:Bjoern A. Zeeb2010-01-171-1/+1
| | | | | | | | | Correct a typo. Submitted by: sn_ (sn_ gmx.net) on hackers@ Notes: svn path=/stable/6/; revision=202472
* MFC: revision 200407Yoshihiro Takahashi2010-01-158-164/+18
| | | | | | | | | | | | | | Cleanups the boot2 for pc98. There is no functional change. - Make setting machine type and getting geom conditional for future. - Remove unused RAWBOOT and CDBOOT supports. - Remove unneeded include. - Fix warnings. This change is directly merged into stable/6 because stable/[78] have new boot2. Notes: svn path=/stable/6/; revision=202356
* MFC: revision 201339 and 201340Yoshihiro Takahashi2010-01-156-2/+132
| | | | | | | | - Add setting machine type support to the loader. - Don't use 15M-16M area on pc98. It's reserved for some devices. Notes: svn path=/stable/6/; revision=202345
* MFC: r200815, r200816Marius Strobl2010-01-137-3/+11
| | | | | | | Provide and consume missing module dependency information. Notes: svn path=/stable/6/; revision=202240
* MFC: r200914Marius Strobl2010-01-131-11/+11
| | | | | | | | | | Don't use an out register to hold the vector number across the call of the interrupt handler in intr_fast() as the handler might clobber it (no in-tree handler currently does but an upcoming one will). While at it, tidy the register usage in the interrupt counting code. Notes: svn path=/stable/6/; revision=202239
* MFC: r200880Marius Strobl2010-01-131-2/+2
| | | | | | | | | - Correct an off-by-one error when calculating the end of a child range. - Spell the PCI TLA in uppercase. Notes: svn path=/stable/6/; revision=202236
* MFC: Merge older mxge(4) fixes/improvements from head:Andrew Gallatin2010-01-112-6/+73
| | | | | | | | | | r193250: Set an rx jumbo cluster to the correct size for bus_dmamap_load_mbuf_sg() r194836: Initial mtu r195818: Rename hw.mxge.rss_hash_type -> hw.mxge.rss_hashtype r197391: Add support for TX throttling. Notes: svn path=/stable/6/; revision=202118
* MFC r186948 (w/o the IPv6 parts):Bjoern A. Zeeb2010-01-061-1/+9
| | | | | | | | | | | | | | | | | | | Make SIOCGIFADDR and related, jail-aware. Up to now we returned the first address of the interface for SIOCGIFADDR w/o an ifr_addr in the query. This caused problems for programs querying for an address but running inside a jail, as the address returned usually did not belong to the jail. If there was an ifr_addr given on v4, you could probe for more addresses on the interfaces that you were not allowed to see from inside a jail. Return an error (EADDRNOTAVAIL) in that case now unless the address is on the given interface and valid for the jail. PR: kern/114325 Thanks to: Axel Scheepers (axel.scheepers nl.clara.net) Notes: svn path=/stable/6/; revision=201663
* MFC r185583:Bjoern A. Zeeb2010-01-051-9/+16
| | | | | | | | | | | | | | | | Fix a credential reference leak. [1] Close subtle but relatively unlikely race conditions when propagating the vnode write error to other active sessions tracing to the same vnode, without holding a reference on the vnode anymore. [2] PR: kern/126368 [1] Submitted by: rwatson [2] Reviewed by: kib, rwatson (head) Notes: svn path=/stable/6/; revision=201625
* MFC 200845:Andrew Gallatin2010-01-041-2/+0
| | | | | | | | Don't take the driver mutex in mxge_tick(), as it is run with the mutex held. Notes: svn path=/stable/6/; revision=201511
* MFC r199947, 199950:Bjoern A. Zeeb2010-01-041-1/+1
| | | | | | | | | | | Enable IPcomp by default. (Note that fast_ipsec.4 was changed, rather than ipsec.4.) PR: kern/123587 Notes: svn path=/stable/6/; revision=201510
* MFC r199906:Bjoern A. Zeeb2010-01-041-1/+1
| | | | | | | | | | | | | | In case the compression result is the same size as the orignal version, the compression was useless as well. Make sure to not update the data and return, else we would waste resources when decompressing. This also avoids the copyback() changing data other consumers like xform_ipcomp.c would have ignored because of no win and sent out without noting that compression was used, resulting in invalid packets at the receiver. Notes: svn path=/stable/6/; revision=201508
* MFC r199905:Bjoern A. Zeeb2010-01-041-2/+1
| | | | | | | | Assimilate very similar input and output code paths (no real functional change). Notes: svn path=/stable/6/; revision=201506