summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Add `local' and `return' to the list of built-ins.jcamou2005-11-031-0/+8
| | | | | Submitted by: garys Approved by: trhodes (mentor)
* Small changes in the AlphaStation 200 and PC14 area. PC164 SRM doeswilko2005-11-021-3/+3
| | | | | | not work with 53C896 SCSI chips. Submitted by: Owen Mann <owen@mann.org>
* Calling setrlimit from 32bit apps could potentially increase certainps2005-11-025-8/+14
| | | | | | | limits beyond what should be capiable in a 32bit process, so we must fixup the limits. Reviewed by: jhb
* Change the x86 code to allocate IDT vectors on-demand when an interruptjhb2005-11-028-191/+433
| | | | | | | | | | | | | | | | source is first enabled similar to how intr_event's now allocate ithreads on-demand. Previously, we would map IDT vectors 1:1 to IRQs. Since we only have 191 available IDT vectors for I/O interrupts, this limited us to only supporting IRQs 0-190 corresponding to the first 190 I/O APIC intpins. On many machines, however, each PCI-X bus has its own APIC even though it only has 1 or 2 devices, thus, we were reserving between 24 and 32 IRQs just for 1 or 2 devices and thus 24 or 32 IDT vectors. With this change, a machine with 100 IRQs but only 5 in use will only use up 5 IDT vectors. Also, this change provides an API (apic_alloc_vector() and apic_free_vector()) that will allow a future MSI interrupt source driver to request IDT vectors for use by MSI interrupts on x86 machines. Tested on: amd64, i386
* Tests with my dual Opteron system have shown that it's possiblewpaul2005-11-027-99/+55
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | for code to start out on one CPU when thunking into Windows mode in ctxsw_utow(), and then be pre-empted and migrated to another CPU before thunking back to UNIX mode in ctxsw_wtou(). This is bad, because then we can end up looking at the wrong 'thread environment block' when trying to come back to UNIX mode. To avoid this, we now pin ourselves to the current CPU when thunking into Windows code. Few other cleanups, since I'm here: - Get rid of the ndis_isr(), ndis_enable_interrupt() and ndis_disable_interrupt() wrappers from kern_ndis.c and just invoke the miniport's methods directly in the interrupt handling routines in subr_ndis.c. We may as well lose the function call overhead, since we don't need to export these things outside of ndis.ko now anyway. - Remove call to ndis_enable_interrupt() from ndis_init() in if_ndis.c. We don't need to do it there anyway (the miniport init routine handles it, if needed). - Fix the logic in NdisWriteErrorLogEntry() a little. - Change some NDIS_STATUS_xxx codes in subr_ntoskrnl.c into STATUS_xxx codes. - Handle kthread_create() failure correctly in PsCreateSystemThread().
* Mandatory mbuf cluster reference counting and groundwork for UMAandre2005-11-024-179/+270
| | | | | | | | | | | | | | | | | | | | | | | | based jumbo 9k and jumbo 16k cluster support. All mbuf's with external storage attached are mandatory reference counted. For clusters and jumbo clusters UMA provides the refcnt storage directly. It does not have to be separatly allocated. Any other type of external storage gets its own refcnt allocated from an UMA mbuf refcnt zone instead of normal kernel malloc. The refcount API MEXT_ADD_REF() and MEXT_REM_REF() is no longer publically accessible. The proper m_* functions have to be used. mb_ctor_clust() and mb_dtor_clust() both handle normal 2K as well as 9k and 16k clusters. Clusters and jumbo clusters may be obtained without attaching it immideatly to an mbuf. This is for high performance cluster allocation in network drivers where mbufs are attached after the cluster has been filled. Tested by: rwatson Sponsored by: TCP/IP Optimizations Fundraise 2005
* Fix several races between socket closure and node/hookglebius2005-11-021-77/+97
| | | | | | | | | | | | | destruction: - Backout 1.62, since it doesn't fix all possible problems. - Upon node creation, put an additional reference on node. - Add a mutex and refcounter to struct ngsock. Netgraph node, control socket and data socket all count as references. - Introduce ng_socket_free_priv() which removes one reference from ngsock, and frees it when all references has gone. - No direct pointers between pcbs and node, all pointing is done via struct ngsock and protected with mutex.
* Fix two races which happen when netgraph is restructuring:glebius2005-11-021-8/+47
| | | | | | | | | | | | - Introduce ng_topo_mtx, a mutex to protect topology changes. - In ng_destroy_node() protect with ng_topo_mtx the process of checking and pointing at ng_deadnode. [1] - In ng_con_part2() check that our peer is not a ng_deadnode, and protect the check with ng_topo_mtx. - Add KASSERTs to ng_acquire_read/write, to make more understandible synopsis in case if called on ng_deadnode. Reported by: Roselyn Lee [1]
* Rework the ng_item queueing on nodes:glebius2005-11-022-124/+118
| | | | | | | | | | | | | - Introduce a new flags NGQF_QREADER and NGQF_QWRITER, which tell how the item should be actually applied, overriding NGQF_READER/NGQF_WRITER flags. - Do not differ between pending reader or writer. Use only one flag that is raised, when there are pending items. - Schedule netgraph ISR in ng_queue_rw(), so that callers do not need to do this job. - Fix several comments. Submitted by: julian
* Remove a redundant _get_curthread() call.davidxu2005-11-021-1/+0
|
* This commit was generated by cvs2svn to compensate for changes in r151970,harti2005-11-021-3/+17
|\ | | | | | | which included commits to RCS files with non-trunk default branches.
| * Vendor patch: fix the reporting of ifOperStatus. We now consider anharti2005-11-021-3/+17
| | | | | | | | | | | | | | | | | | | | interface up when it is running AND the link is not down (that is, it is up or unknown). If the interface is running but the link is down, we return state 'dormant', because we're waiting for an external event. Otherwise the interface is 'down'. Submitted by: csjp Reviewed by: glebius
* | Moved the optimization for tiny x from __kernel_tan[f](x) to tan[f](x)bde2005-11-024-46/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | so that it can be faster for tiny x and avoided for reduced x. This improves things a little differently than for cosine and sine. We still need to reclassify x in the "kernel" functions, but we get an extra optimization for tiny x, and an overall optimization since tiny reduced x rarely happens. We also get optimizations for space and style. A large block of poorly duplicated code to fix a special case is no longer needed. This supersedes the fixes in k_sin.c revs 1.9 and 1.11 and k_sinf.c 1.8 and 1.10. Fixed wrong constant for the cutoff for "tiny" in tanf(). It was 2**-28, but should be almost the same as the cutoff in sinf() (2**-12). The incorrect cutoff protected us from the bugs fixed in k_sinf.c 1.8 and 1.10, except 4 cases of reduced args passed the cutoff and needed special handling in theory although not in practice. Now we essentially use a cutoff of 0 for the case of reduced args, so we now have 0 special args instead of 4. This change makes no difference to the results for sinf() (since it only changes the algorithm for the 4 special args and the results for those happen not to change), but it changes lots of results for sin(). Exhaustive testing is impossible for sin(), but exhaustive testing for sinf() (relative to a version with the old algorithm and a fixed cutoff) shows that the changes in the error are either reductions or from 0.5-epsilon ulps to 0.5+epsilon ulps. The new method just uses some extra terms in approximations so it tends to give more accurate results, and there are apparently no problems from having extra accuracy. On amd64 with -O1, on all float args the error range in ulps is reduced from (0.500, 0.665] to [0.335, 0.500) in 24168 cases and increased from 0.500-epsilon to 0.500+epsilon in 24 cases. Non- exhaustive testing by ucbtest shows no differences.
* | In raise(), use a shortcut to directly send signal to current thread.davidxu2005-11-021-7/+2
| |
* | Retire MT_HEADER mbuf type and change its users to use MT_DATA.andre2005-11-0221-41/+35
| | | | | | | | | | | | | | | | | | | | | | | | Having an additional MT_HEADER mbuf type is superfluous and redundant as nothing depends on it. It only adds a layer of confusion. The distinction between header mbuf's and data mbuf's is solely done through the m->m_flags M_PKTHDR flag. Non-native code is not changed in this commit. For compatibility MT_HEADER is mapped to MT_DATA. Sponsored by: TCP/IP Optimization Fundraise 2005
* | Updated the comment about the optimization for tiny x (the previousbde2005-11-021-2/+4
| | | | | | | | | | | | | | | | | | | | commit moved it). This includes a comment that the "kernel" sine no longer works on arg -0, so callers must now handle this case. The kernel sine still works on all other tiny args; without the optimization it is just a little slower on these args. I intended it to keep working on all tiny args, but that seems to be impossible without losing efficiency or accuracy. (sin(x) ~ x * (1 + S1*x**2 + ...) would preserve -0, but the approximation must be written as x + S1*x**3 + ... for accuracy.)
* | o Update list of holidays in Russia.maxim2005-11-021-7/+10
| | | | | | | | | | Submitted by: osa MFC after: 1 week
* | Instead of a panic()ing in pmap_insert_entry() if get_pv_entry() fails,alc2005-11-021-1/+50
| | | | | | | | reclaim a pv entry by destroying a mapping to an inactive page.
* | Removed dead code for handling tan[f]() on odd multiples of pi/2. Thisbde2005-11-022-6/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | case never occurs since pi/2 is irrational so no multiple of it can be represented as a float and we have precise arg reduction so we never end up with a remainder of 0 in the "kernel" function unless the original arg is 0. If this case occurs, then we would now fall through to general code that returns +-Inf (depending on the sign of the reduced arg) instead of forcing +Inf. The correct handling would be to return NaN since we would have lost so much precision that the correct result can be anything _except_ +-Inf. Don't reindent the else clause left over from this, although it was already bogusly indented ("if (foo) return; else ..." just marches the indentation to the right), since it will be removed too. Index: k_tan.c =================================================================== RCS file: /home/ncvs/src/lib/msun/src/k_tan.c,v retrieving revision 1.10 diff -r1.10 k_tan.c 88,90c88 < if (((ix | low) | (iy + 1)) == 0) < return one / fabs(x); < else { --- > {
* | Fix an erroneous description of the file descriptor assignments forjdp2005-11-021-5/+3
| | | | | | | | | | | | the "~C" command. MFC After: 1 week
* | Fixed some of the silliness related to rev.1.8. In 1.8, "double" inbde2005-11-021-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | a declaration was not translated to "float" although bit fiddling on double variables was translated. This resulted in garbage being put into the low word of one of the doubles instead of non-garbage being put into the only word of the intended float. This had no effect on any result because: - with doubles, the algorithm for calculating -1/(x+y) is unnecessarily complicated. Just returning -1/((double)x+y) would work, and the misdeclaration gave something like that except for messing up some low bits with the bit fiddling. - doubles have plenty of bits to spare so messing up some of the low bits is unlikely to matter. - due to other bugs, the buggy code is reached for a whole 4 args out of all 2**32 float args. The bug fixed by 1.8 only affects a small percentage of cases and a small percentage of 4 is 0. The 4 args happen to cause no problems without 1.8, so they are even less likely to be affected by the bug in 1.8 than average args; in fact, neither 1.8 nor this commit makes any difference to the result for these 4 args (and thus for all args). Corrections to the log message in 1.8: the bug only applies to tan() and not tanf(), not because the float type can't represent numbers large enough to trigger the problem (e.g., the example in the fdlibm-5.3 readme which is > 1.0e269), but because: - the float type can't represent small enough numbers. For there to be a possible problem, the original arg for tanf() must lie very near an odd multiple of pi/2. Doubles can get nearer in absolute units. In ulps there should be little difference, but ... - ... the cutoff for "small" numbers is bogus in k_tanf.c. It is still the double value (2**-28). Since this is 32 times smaller than FLT_EPSILON and large float values are not very uniformly distributed, only 6 args other than ones that are initially below the cutoff give a reduced arg that passes the cutoff (the 4 problem cases mentioned above and 2 non-problem cases). Fixing the cutoff makes the bug affect tanf() and much easier to detect than for tan(). With a cutoff of 2**-12 on amd64 with -O1, 670102 args pass the cutoff; of these, there are 337604 cases where there might be an error of >= 1 ulp and 5826 cases where there is such an error; the maximum error is 1.5382 ulps. The fix in 1.8 works with the reduced cutoff in all cases despite the bug in it. It changes the result in 84492 cases altogether to fix the 5826 broken cases. Fixing the fix by translating "double" to "float" changes the result in 42 cases relative to 1.8. In 24 cases the (absolute) error is increased and in 18 cases it is reduced, but it remains less than 1 ulp in all cases.
* | Rate limit vnode_pager_putpages printfs to once a second.ps2005-11-011-3/+8
| |
* | Throw the switch and turn on STOP_NMI on in GENERIC for amd64 and i386.jhb2005-11-012-0/+2
| | | | | | | | | | Requested by: kris Ok'd by: scottl
* | Catch up with ACPI-CA 20051021 importjkim2005-11-0114-259/+343
| |
* | Update to reflect import of ACPI-CA 20051021 with includes fixupsjkim2005-11-011-27/+30
| |
* | Local change: remove unnecessary __cdecljkim2005-11-012-2/+2
| |
* | Local change: remove compilation warningsjkim2005-11-014-10/+10
| |
* | Fix conflicts from import of Intel ACPI-CA 20051021jkim2005-11-018-497/+968
| |
* | Unchanged files that are off the vendor branchjkim2005-11-0113-1679/+639
| |
* | This commit was generated by cvs2svn to compensate for changes in r151940,jkim2005-11-012-1/+3
|\ \ | | | | | | | | | which included commits to RCS files with non-trunk default branches.
| * | Fix few compilation problems on vendor branch.jkim2005-11-013-1/+6
| | | | | | | | | | | | These fixes will be submitted vendor.
* | | This commit was generated by cvs2svn to compensate for changes in r151937,jkim2005-11-01175-14401/+22437
|\ \ \ | |/ / | | | | | | which included commits to RCS files with non-trunk default branches.
| * | Vendor import of Intel ACPI-CA 20051021jkim2005-11-01196-16596/+24058
| | |
| * | Remove old ACPICA files from the INTEL vendor branch. They were removedjhb2005-10-27141-84217/+0
| | | | | | | | | | | | | | | from HEAD about 4 years ago when we started flattening out the ACPICA distribution.
* | | Quick kill links to the nsmb(8) manual page, there is no suchtrhodes2005-11-011-6/+0
| | | | | | | | | | | | utility that I can find.
* | | Move HPET debugging under ACPI_TIMER in order to save a bitfield.scottl2005-11-012-2/+1
| | |
* | | Xref setlocale(3), bump document date.trhodes2005-11-011-1/+3
| | |
* | | Note which options are not part of the standards.trhodes2005-11-011-1/+12
| | | | | | | | | | | | | | | | | | | | | Xref locale(1) and bump document date. Reviewed by: keramida No Objections: -standards
* | | Push down Giant into fdfree() and remove it from two of the callers.jhb2005-11-013-13/+24
| | | | | | | | | | | | | | | | | | | | | Other callers such as some rfork() cases weren't locking Giant anyway. Reviewed by: csjp MFC after: 1 week
* | | Add proper debugging infrastructure for acpi_hpet.c.scottl2005-11-012-0/+5
| | |
* | | Add a "-H" argument to kdump, which causes kdump to print an additionalrwatson2005-11-012-6/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | field holding the threadid. This is more useful for libthr than libpthread, but still quite useful in libpthread as it can be used to process interlaced records from multiple threads over the course of a system call. Detect old ktr_buffer values using the heuristic "if it's negative, then it must not be a valid threadid". This may leave something to be desired. MFC after: 1 month Reviewed by: davidxu
* | | Reuse ktr_unused field in ktr_header structure as ktr_tid; populaterwatson2005-11-012-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | ktr_tid as part of gathering of ktr header data for new ktrace records. The continued use of intptr_t is required for file layout reasons, and cannot be changed to lwpid_t at this point. MFC after: 1 month Reviewed by: davidxu
* | | Fix some comments, eliminate a memory leak.davidxu2005-11-011-6/+13
| | |
* | | Replace ktr_buffer pointer in struct ktr_header with a ktr_unusedrwatson2005-11-012-10/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | intptr_t. The buffer length needs to be written to disk as part of the trace log, but the kernel pointer for the buffer does not. Add a new ktr_buffer pointer to the kernel-only ktrace request structure to hold that pointer. This frees up an integer in the ktrace record format that can be used to hold the threadid, although older ktrace files will have a garbage ktr_buffer field (or more accurately, a kernel pointer value). MFC after: 2 weeks Space requested by: davidxu
* | | o OpenBSD 3.8 added.maxim2005-11-011-0/+2
| | |
* | | Clean up one remaining 'multiple DPC thread' bogon: only bzero() onewpaul2005-11-011-0/+4
| | | | | | | | | | | | sizeof(kq_queue), not sizeof(kq_queue) * mp_ncpus.
* | | Use TIMERS_UNLOCK.davidxu2005-11-011-1/+1
| | |
* | | Add code to handle timer_delete(). The timer wrapper code is completelydavidxu2005-11-014-68/+268
| | | | | | | | | | | | | | | | | | rewritten, now timers created with same sigev_notify_attributes will run in same thread, this allows user to organize which timers can run in same thread to save some thread resource.
* | | In mode 'u', check for an error return from archive_read_open.kientzle2005-11-011-2/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This causes attempts to update a non-existent file to report an actual error instead of triggering an assertion failure. PR: bin/87911 Thanks to: roemer.ulrich MFC after: 3 days Note: This does not entirely fix bin/87911. I need to decide on the "correct" response when someone tries to update a non-existent archive file.
* | | Include <sys/param.h> in order to get current __FreeBSD_versionkientzle2005-11-011-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | in order to properly set HAVE_NL_LANGINFO. <whew!> Thanks to: Andrey Chernov PR: bin/88013 MFC after: 3 days
OpenPOWER on IntegriCloud