ĥF220000 104 148 474 726 726 475 154 224 437 1164 593 328 532 532 194 588 209 136 161 608 376 435 153 388 153 123 367 291 365 253 345 355 638 317 249 205 153 210 340 1567 679 162 233 145 223 358 358 257 136 161 280 385 422 568 233 105 233 513 194 127 361 494 140 656 200 244 244 2179 2179 1849 1849 1073 1073 2904 2904 540 540 253 253 1394 1394 521 241 153 880 880 133 133 183 124 207 724 290 155 133 108 132 167 150 365 218 264 194 145 783 K 10 svn:author V 3 kib K 8 svn:date V 27 2011-03-25T14:01:18.616989Z K 7 svn:log V 56 Document O_CLOEXEC. Reviewed by: jhb MFC after: 1 week END K 10 svn:author V 3 kib K 8 svn:date V 27 2011-03-25T16:38:10.500341Z K 7 svn:log V 381 Handle the corner case in vm_fault_quick_hold_pages(). If supplied length is zero, and user address is invalid, function might return -1, due to the truncation and rounding of the address. The callers interpret the situation as EFAULT. Instead of handling the zero length in caller, filter it in vm_fault_quick_hold_pages(). Sponsored by: The FreeBSD Foundation Reviewed by: alc END K 10 svn:author V 3 mdf K 8 svn:date V 27 2011-03-25T18:16:36.786607Z K 7 svn:log V 633 MFC r218825. [The implementation change to kdb_sysctl_available() cannot be MFC'd as it requires a non-MFCable change (adding drains to sbuf)]. Modify kdb_trap() so that it re-calls the dbbe_trap function as long as the debugger back-end has changed. This means that switching from ddb to gdb no longer requires a "step" which can be dangerous on an already-crashed kernel. Also add a capability to get from the gdb back-end back to ddb, by typing ^C in the console window. While here, simplify kdb_sysctl_available() by using sbuf_new_for_sysctl(), and use strlcpy() instead of strncpy() since the strlcpy semantic is desired. END K 10 svn:author V 3 mdf K 8 svn:date V 27 2011-03-25T18:16:49.909763Z K 7 svn:log V 633 MFC r218825. [The implementation change to kdb_sysctl_available() cannot be MFC'd as it requires a non-MFCable change (adding drains to sbuf)]. Modify kdb_trap() so that it re-calls the dbbe_trap function as long as the debugger back-end has changed. This means that switching from ddb to gdb no longer requires a "step" which can be dangerous on an already-crashed kernel. Also add a capability to get from the gdb back-end back to ddb, by typing ^C in the console window. While here, simplify kdb_sysctl_available() by using sbuf_new_for_sysctl(), and use strlcpy() instead of strncpy() since the strlcpy semantic is desired. END K 10 svn:author V 3 avg K 8 svn:date V 27 2011-03-25T18:23:10.822158Z K 7 svn:log V 382 rtld: eliminate double call to close(2) that may occur in load_object The second close(2) call resulted in heisenbugs in some multi-threaded applications where e.g. dlopen(3) call in one thread could close a file descriptor for a file having been opened in other thread concurrently. My litmus test for this issue was an openoffice.org build. Reviewed by: jhb MFC after: 2 weeks END K 10 svn:author V 3 pjd K 8 svn:date V 27 2011-03-25T20:13:38.249424Z K 7 svn:log V 62 Use role2str() when setting process title. MFC after: 1 week END K 10 svn:author V 3 pjd K 8 svn:date V 27 2011-03-25T20:15:16.691071Z K 7 svn:log V 131 Use timeout from configuration file not only when sending and receiving, but also when establishing connection. MFC after: 1 week END K 10 svn:author V 3 pjd K 8 svn:date V 27 2011-03-25T20:19:15.355916Z K 7 svn:log V 344 Add mapsize to the header just before sending the packet. Before it could change later and we were sending invalid mapsize. Some time ago I added optimization where when nodes are connected for the first time and there were no writes to them yet, there is no initial full synchronization. This bug prevented it from working. MFC after: 1 week END K 10 svn:author V 3 mdf K 8 svn:date V 27 2011-03-25T20:51:20.437670Z K 7 svn:log V 1070 MFC r192908 (introduced before the stable/8 split from CURRENT): fail(9) support: Add support for kernel fault injection using KFAIL_POINT_* macros and fail_point_* infrastructure. Add example fail point in vfs_bio.c to simulate VM buf pressure. MFC r192978: Fix style/grammar issues in fail(9) man page. MFC r216616: Move the fail_point_entry definition from fail.h to kern_fail.c, which allows putting the enumeration constants of fail point types with the text string that matches them. MFC r216620: Initialize fp_location for explicitly managed fail points, and push the parentheses around the location for simple fail points into the location string. This makes the print on fail point set more consistent between the two versions. Also fix up fail.h a little for style(9): only use one of sys/param.h and sys/types.h, and use the existing __XSTRING() macro instead of rolling our own. Also fix up a few tabs on changed and nearby lines. Lastly, since KFAIL_POINT_{BEGIN,END} are not meant for use outside this file, just eliminate the macros entirely. END K 10 svn:author V 2 np K 8 svn:date V 27 2011-03-25T20:53:02.839037Z K 7 svn:log V 501 Update T3 firmware to 7.11.0 Changes since 7.8.0 (from the official changelog): - Fixed sporadic interrupt generation for associated CQ when processing a local invalidate work request - Changes to core scheduling to avoid starving requests from the host under heavy RDMA Read Request load (e.g. packets to the wire) - Programmed the tp tx resource limiter in function of the traffic (only affects iWarp) - Increased the egress NIC gather list length from 36 to 46 entries MFC after: 1 week END K 10 svn:author V 3 mdf K 8 svn:date V 27 2011-03-25T22:00:43.064277Z K 7 svn:log V 235 MFC r216058 and r216059: r216058: Use the SYSCTL_CHILDREN macro in kern_sysctl.c to help de-obfuscate the code. r216059: Slightly modify the logic in sysctl_find_oid to reduce the indentation. There should be no functional change. END K 10 svn:author V 3 mdf K 8 svn:date V 27 2011-03-25T22:11:39.480814Z K 7 svn:log V 439 MFC r216060. This differs from the original commit in that it preserves the KBI size of struct sysctl_oid. Also, on stable/8 the compiler thinks that 'len' in sysctl_sysctl_name2oid() is used uninitialized. Do not hold the sysctl lock across a call to the handler. This fixes a general LOR issue where the sysctl lock had no good place in the hierarchy. One specific instance is #284 on http://sources.zabbadoz.net/freebsd/lor.html . END K 10 svn:author V 3 mdf K 8 svn:date V 27 2011-03-25T22:11:54.560893Z K 7 svn:log V 439 MFC r216060. This differs from the original commit in that it preserves the KBI size of struct sysctl_oid. Also, on stable/8 the compiler thinks that 'len' in sysctl_sysctl_name2oid() is used uninitialized. Do not hold the sysctl lock across a call to the handler. This fixes a general LOR issue where the sysctl lock had no good place in the hierarchy. One specific instance is #284 on http://sources.zabbadoz.net/freebsd/lor.html . END K 10 svn:author V 3 mdf K 8 svn:date V 27 2011-03-25T22:17:24.868167Z K 7 svn:log V 101 Fix r220012 (MFC of r216060); the KBI of sysctl_oid was *supposed* to be preserved, but I was hasty. END K 10 svn:author V 3 kib K 8 svn:date V 27 2011-03-25T22:31:28.450097Z K 7 svn:log V 495 Report EBUSY instead of EROFS for attempt of deleting or renaming the root directory of msdosfs mount. The VFS code would handle deletion case itself too, assuming VV_ROOT flag is not lost. The msdosfs_rename() should also note attempt to rename root via doscheckpath() or different mount point check leading to EXDEV. Nonetheless, keep the checks for now. The change is inspired by NetBSD change referenced in PR, but return EBUSY like kern_unlinkat() does. PR: kern/152079 MFC after: 1 week END K 10 svn:author V 5 dougb K 8 svn:date V 27 2011-03-26T00:34:35.987263Z K 7 svn:log V 114 Add an example for the use of the entry to help others who are as slow as I am. Discussed with: gordon END K 10 svn:author V 4 jeff K 8 svn:date V 27 2011-03-26T00:54:01.184535Z K 7 svn:log V 43 - Implement wake-on-lan support in mlxen. END K 10 svn:author V 5 dougb K 8 svn:date V 27 2011-03-26T01:24:55.725550Z K 7 svn:log V 67 Add the svn:executable property to the scripts that are missing it END K 10 svn:author V 4 jkim K 8 svn:date V 27 2011-03-26T02:02:07.143085Z K 7 svn:log V 514 Improve CPU identifications of various IDT/Centaur/VIA, Rise and Transmeta CPUs. These CPUs need explicit MSR configuration to expose ceratin CPU capabilities (e.g., CMPXCHG8B) to work around compatibility issues with ancient software. Unfortunately, Rise mP6 does not set the CX8 bit in CPUID and there is no MSR to expose the feature although all mP6 processors are capable of CMPXCHG8B according to datasheets I found from the Net. Clean up and simplify VIA PadLock detection while I am in the neighborhood. END K 10 svn:author V 6 adrian K 8 svn:date V 27 2011-03-26T02:52:04.290702Z K 7 svn:log V 280 Update ath_hal.4 to include the latest chipset support. ath_hal needs a lot more work to encompass the list of supported cards, as the AR5416/AR9160/AR9280/AR9285 list is quite long and extensive. In addition, there's a lot of AR5212/AR5213 based cards that aren't on this list. END K 10 svn:author V 5 dougb K 8 svn:date V 27 2011-03-26T03:01:48.003001Z K 7 svn:log V 340 Add a daily period script to back up /var/db/pkg The final product contains work from the originator, and Florent Thoumie . The final product contains considerable re-working by me, so all responsibility for bugs rests under my pointy hat. PR: ports/145957 Submitted by: Eitan Adler END K 10 svn:author V 3 alc K 8 svn:date V 27 2011-03-26T06:21:05.355997Z K 7 svn:log V 61 Move an external declaration to the appropriate header file. END K 10 svn:author V 6 adrian K 8 svn:date V 27 2011-03-26T07:15:35.103076Z K 7 svn:log V 292 Shuffle around the HAL_RX_FILTER bits to be slightly more sensible. The phyerr, radar and bssid-match bits aren't real bits, they map to enabling bits in other registers. Move those out of the way of valid RX filter bits. Add a few new fields from ath9k - compba, ps-poll, mcast-bcast-all. END K 10 svn:author V 3 pjd K 8 svn:date V 27 2011-03-26T07:15:57.126484Z K 7 svn:log V 61 Follow style(9) in example code and handle opendir(3) error. END K 10 svn:author V 3 pjd K 8 svn:date V 27 2011-03-26T07:17:24.021291Z K 7 svn:log V 31 Don't calculate len too early. END K 10 svn:author V 6 adrian K 8 svn:date V 27 2011-03-26T07:29:48.903277Z K 7 svn:log V 271 Put these two back to mirror what ath9k does. Even though they map to setting the error filter register, ath9k also writes them untouched to AR_RX_FILTER. The Force-BSSID match bit can stay high, as it maps to a misc mode register setting rather than an RX filter bit. END K 10 svn:author V 7 dchagin K 8 svn:date V 27 2011-03-26T09:25:35.914930Z K 7 svn:log V 194 Export the correct AT_PLATFORM value. Since signal trampolines are copied to the shared page do not need to leave place on the stack for it. Forgotten in the previous commit. MFC after: 1 Week END K 10 svn:author V 6 adrian K 8 svn:date V 27 2011-03-26T10:47:17.413448Z K 7 svn:log V 269 Introduce hardware PS-POLL support in the HAL. Linux ath9k only enables this for AR9280 and later NICs; so create a capability for it so it isn't enabled for earlier NICs. Enabling hardware PS-POLL support will come in a later commit and will be disabled by default. END K 10 svn:author V 3 avg K 8 svn:date V 27 2011-03-26T10:51:56.148117Z K 7 svn:log V 160 linux compat: add non-dummy capget and capset system calls PR: kern/149168 Submitted by: John Wehle Reviewed by: netchild MFC after: 2 weeks END K 10 svn:author V 6 adrian K 8 svn:date V 27 2011-03-26T10:52:37.852398Z K 7 svn:log V 249 Add in the hardware PS-POLL frame reception setting, but leave it disabled by default. Adventourous souls with an AR9220/AR9280 or later and who have a device that sends PS-POLL frames may wish to try tinkering with this option and get back to me. END K 10 svn:author V 3 avg K 8 svn:date V 27 2011-03-26T10:59:24.259875Z K 7 svn:log V 262 linux compat: add non-dummy capget and capset system calls, regenerate And drop dummy definitions for those system calls. This may transiently break the build. PR: kern/149168 Submitted by: John Wehle Reviewed by: netchild MFC after: 2 weeks END K 10 svn:author V 3 avg K 8 svn:date V 27 2011-03-26T11:05:53.425594Z K 7 svn:log V 545 linux compat: improve and fix sendmsg/recvmsg compatibility - implement baseic stubs for capget, capset, prctl PR_GET_KEEPCAPS and prctl PR_SET_KEEPCAPS. - add SCM_CREDS support to sendmsg and recvmsg - modify sendmsg to ignore control messages if not using UNIX domain sockets This should allow linux pulse audio daemon and client work on FreeBSD and interoperate with native counter-parts modulo the differences in pulseaudio versions. PR: kern/149168 Submitted by: John Wehle Reviewed by: netchild MFC after: 2 weeks END K 10 svn:author V 3 avg K 8 svn:date V 27 2011-03-26T11:25:36.285410Z K 7 svn:log V 224 linux compat: add SO_PASSCRED option with basic handling This seems to have been a part of a bigger patch by dchagin that either haven't been committed or committed partially. Submitted by: dchagin, nox MFC after: 2 weeks END K 10 svn:author V 6 adrian K 8 svn:date V 27 2011-03-26T11:58:29.365791Z K 7 svn:log V 153 If 802.11n is enabled, bump the number of buffers used up to a larger level. This is important for AMPDU RX as each burst is multiple packets in a row. END K 10 svn:author V 6 adrian K 8 svn:date V 27 2011-03-26T11:59:18.468251Z K 7 svn:log V 109 This was missing from the previous HAL commit - it fixes a typo and introduces the PS-POLL hardware support. END K 10 svn:author V 6 adrian K 8 svn:date V 27 2011-03-26T13:06:43.828349Z K 7 svn:log V 58 .. And another missed commit - add the PSPOLL capability. END K 10 svn:author V 6 marius K 8 svn:date V 27 2011-03-26T13:07:07.246330Z K 7 svn:log V 114 MFC: r219577 Allocate the DMA memory shared between the host and the controller as coherent. Approved by: gibbs END K 10 svn:author V 10 nwhitehorn K 8 svn:date V 27 2011-03-26T13:58:44.198379Z K 7 svn:log V 239 Cause the release target to set up its object directory. It is designed to be a meta-target, and having it do this avoids it spewing files all over the source tree by default (and possible recursive tarring if distributing a src tarball). END K 10 svn:author V 6 marius K 8 svn:date V 27 2011-03-26T16:49:12.431151Z K 7 svn:log V 1470 - Merge the *_SET macros from fire(4) which generally print out the register changes when compiled with SCHIZO_DEBUG and take advantage of them. - Add support for the XMITS Fireplane/Safari to PCI-X bridges. I tought I'd need this for a Sun Fire 3800, which then turned out to not being equipped with such a bridge though. The support for these should be complete but given that it hasn't actually been tested probing is disabled for now. This required a way to alter the XMITS configuration in case a PCI-X device is found further down the device tree so the sparc64 specific ofw_pci kobj was revived with a ofw_pci_setup_device method, which is called by the ofw_pcibus code for every device added. - A closer inspection of the OpenSolaris code indicates that consistent DMA flushing/syncing as well as the block store workaround should be applied with every BUS_DMASYNC_POSTREAD instead of in a wrapper around interrupt handlers for devices behind PCI-PCI bridges only as suggested by the documentation (code for the latter actually exists in OpenSolaris but is disabled by default), which also makes more sense. - Add a workaround for Casinni/Skyhawk combinations. Chances are that this solves the crashes seen when using the the on-board Casinni NICs of Sun Fire V480 equipped with centerplanes other than 501-6780 or 501-6790. This also takes advantage of the ofw_pci_setup_device method. - Mark some unused parameters as such. END K 10 svn:author V 6 marius K 8 svn:date V 27 2011-03-26T16:52:31.873830Z K 7 svn:log V 583 - A closer inspection of the OpenSolaris code indicates that the DMA syncing for Hummingbird and Sabre bridges should be applied with every BUS_DMASYNC_POSTREAD instead of in a wrapper around interrupt handlers for devices behind PCI-PCI bridges only as suggested by the documentation (code for the latter actually exists in OpenSolaris but is disabled by default), which also makes more sense. - Take advantage of the ofw_pci_setup_device method introduced in r220038 for disabling bus parking for certain EBus bridges in order to - Mark some unused parameters as such. END K 10 svn:author V 2 jh K 8 svn:date V 27 2011-03-26T17:17:24.047340Z K 7 svn:log V 71 Fix some style issues in r219925. Reported by: bde MFC after: 1 month END K 10 svn:author V 2 ru K 8 svn:date V 27 2011-03-26T19:09:28.713860Z K 7 svn:log V 141 Fixed sockets display somewhat (-L, -T, -x, -Lx, with and without -A). (I didn't try to fix negative TCP timers with -x.) MFC after: 3 days END K 10 svn:author V 3 alc K 8 svn:date V 27 2011-03-26T20:40:33.245391Z K 7 svn:log V 53 Eliminate an unused definition. Reviewed by: marcel END K 10 svn:author V 3 kib K 8 svn:date V 27 2011-03-26T21:12:53.479972Z K 7 svn:log V 130 Print the raw value of si_code, that is esp. useful for undecoded values. Sponsored by: The FreeBSD Foundation MFC after: 1 week END K 10 svn:author V 7 yongari K 8 svn:date V 27 2011-03-26T21:29:39.706868Z K 7 svn:log V 261 MFC r219787: Correct broadcast frame handling. Setting bit6 of MCR0 register enables broadcast filtering. Make sure to clear the bit to receive broadcast frames. While I'm here rename the bit definition to reflect reality. Reported by: brad@OpenBSD END K 10 svn:author V 7 yongari K 8 svn:date V 27 2011-03-26T21:32:10.313923Z K 7 svn:log V 261 MFC r219787: Correct broadcast frame handling. Setting bit6 of MCR0 register enables broadcast filtering. Make sure to clear the bit to receive broadcast frames. While I'm here rename the bit definition to reflect reality. Reported by: brad@OpenBSD END K 10 svn:author V 6 marius K 8 svn:date V 27 2011-03-26T22:39:23.103182Z K 7 svn:log V 161 Wait until the DMA engine is stopped before unmapping buffers and descriptors, which fixes DMA errors seen on sparc64. Obtained from: OpenBSD MFC after: 1 week END K 10 svn:author V 3 kib K 8 svn:date V 27 2011-03-27T00:42:28.013175Z K 7 svn:log V 44 MFC r219804: Retire opt_ffs_broken_fixme.h. END K 10 svn:author V 5 dougb K 8 svn:date V 27 2011-03-27T03:03:29.139685Z K 7 svn:log V 67 Add svn:executable property on remaining period scripts without it END K 10 svn:author V 5 dougb K 8 svn:date V 27 2011-03-27T03:06:58.423335Z K 7 svn:log V 185 Hook the 220.backup-pkgdb script I added to the build unconditionally Hook up 610.ipf6denied based on MK_IPFILTER as 510.ipfdenied is now Poked by: Andrzej Tobola END K 10 svn:author V 2 np K 8 svn:date V 27 2011-03-27T05:09:21.502428Z K 7 svn:log V 293 MFC r219944 Do not over-allocate MSI interrupts for the case where each ingress queue has its own interrupt. If the exact number that we need is not a power of 2 and we're using MSI, then switch to interrupt multiplexing. While here, replace the magic numbers with something more readable. END K 10 svn:author V 6 adrian K 8 svn:date V 27 2011-03-27T08:32:47.644599Z K 7 svn:log V 326 Add some missing flags needed for AR913x/AR724x USB to correctly operate. The AR913x/AR724x USB lives at a different offset to the AR71xx USB, so this needs to be either adjusted for in a subsequent commit, or updated in hints for kernels compiled for those platforms. Submitted by: Luiz Otavio O Souzau END K 10 svn:author V 6 adrian K 8 svn:date V 27 2011-03-27T08:44:27.686245Z K 7 svn:log V 472 Add an option - AR71XX_REALMEM - which overrides the amount of memory detected from Redboot, or overrides the "otherwise" case if no Redboot information was found. Some AR71XX platforms don't use Redboot (eg TP-LINK devices using UBoot; some later Ubiquiti devices which apparently also use UBoot) and at least one plain out lies - the Ubiquiti LS-SR71A Redboot says there's 16mb of RAM when in fact there's 32mb. A more "clean" solution will be needed at a later date. END K 10 svn:author V 6 adrian K 8 svn:date V 27 2011-03-27T08:47:55.065973Z K 7 svn:log V 137 Rename AH_ENABLE_11N to ATH_ENABLE_11 - the HAL supports 11n by default but the ath driver doesn't. This is a much more consistent name. END K 10 svn:author V 6 adrian K 8 svn:date V 27 2011-03-27T10:35:39.281317Z K 7 svn:log V 10 Fix typo. END K 10 svn:author V 3 ume K 8 svn:date V 27 2011-03-27T12:53:20.041589Z K 7 svn:log V 140 getpwnam(3) may return NULL. Requested by: nork Reviewed by: Takeharu KATO , nork MFC after: 1 week END K 10 svn:author V 6 adrian K 8 svn:date V 27 2011-03-27T13:55:35.918857Z K 7 svn:log V 417 Refactor out the ar71xx mac address code into something that's just for Redboot. At some point we're going to need to build options for different boot environments - for example, the UBoot setups I've seen simply have the MAC address hard-coded at a fixed location in flash. The OpenWRT support simply yanks the if_arge MAC directly from that in code, rather than trying to find a uboot environment to pull it from. END K 10 svn:author V 8 jpaetzel K 8 svn:date V 27 2011-03-27T14:20:47.643125Z K 7 svn:log V 97 Increase size of boot partition to give breathing room in the future. Approved by: kib (mentor) END K 10 svn:author V 3 alc K 8 svn:date V 27 2011-03-27T16:18:51.106669Z K 7 svn:log V 35 Amd64 doesn't have a lazypmap ipi. END K 10 svn:author V 8 jpaetzel K 8 svn:date V 27 2011-03-27T16:57:54.437751Z K 7 svn:log V 263 Fix a syntax error in a little-used function. Replace expr with $(()) Replace grep > /dev/null with grep -q Replace "$?" = "0" with $? -eq 0 in tests Consolidate export statements with variable assignment Replace tests for ! -z with -n Approved by: kib (mentor) END K 10 svn:author V 6 marcel K 8 svn:date V 27 2011-03-27T19:27:57.283747Z K 7 svn:log V 398 Add the beginnings of a driver for the SHub ASIC. There's a SHub for each node in the system. The SHub serves as a crossbar between the FSB, supporting 1 or 2 CPUs, the memory, the 2 NUMAlink network interfaces and the Xtalk I/O interface. Since the PCI/PCI-X host controllers connect to the SHub via the Xtalk interfaces, the shub driver will become the parent of the pci host controller driver. END K 10 svn:author V 6 marcel K 8 svn:date V 27 2011-03-27T19:29:18.298844Z K 7 svn:log V 45 Compile the SGI SHub ASIC driver by default. END K 10 svn:author V 7 trociny K 8 svn:date V 27 2011-03-27T19:56:55.173025Z K 7 svn:log V 559 In g_gate_create() there is a window between when g_gate_softc is registered in g_gate_units array and when its sc_provider field is filled. If during this period g_gate_units is accessed by another thread that is checking for provider name collision the crash is possible. Fix this by adding sc_name field to struct g_gate_softc. In g_gate_create() when g_gate_softc is created but sc_provider is still not sc_name points to provider name stored in the local array. Approved by: pjd (mentor) Reported by: Freddie Cash MFC after: 1 week END K 10 svn:author V 2 ae K 8 svn:date V 27 2011-03-27T20:35:32.655571Z K 7 svn:log V 108 MFC r219573: Document GEOM_PART_EBR_COMPAT option. MFC r219581: Fix grammar. Pointed out: Ben Kaduk END K 10 svn:author V 7 yongari K 8 svn:date V 27 2011-03-27T22:12:51.111809Z K 7 svn:log V 147 MFC r218786: Always check memory allocation failure. If driver encounter memory allocation error, do not attach driver. Reviewed by: marius END K 10 svn:author V 7 yongari K 8 svn:date V 27 2011-03-27T22:14:14.170753Z K 7 svn:log V 147 MFC r218786: Always check memory allocation failure. If driver encounter memory allocation error, do not attach driver. Reviewed by: marius END K 10 svn:author V 7 yongari K 8 svn:date V 27 2011-03-27T22:20:44.734527Z K 7 svn:log V 2081 MFC r213841,218787-218788: r213841: It seems some multi-port dc(4) controllers shares SROM of the first port such that reading station address from second port always returned 0xFF:0xFF:0xFF:0xFF:0xFF:0xFF Unfortunately it seems there is no easy way to know whether SROM is shared or not. Workaround the issue by traversing dc(4) device list and see whether we're using second port and use station address of controller 0 as base station address of second port. PR: kern/79262 r218787: When driver have to use base softc due to lack of SROM on second port, copy SROM information from base softc as well and run SROM parser again. This change is necessary for some dual port controllers to make dc(4) correctly detect PHY media based on first port configuration table. While I'm here add a check for validity of the base softc before duplicating SROM contents from base softc. If driver failed to attach to the first port it can access invalid area. PR: kern/79262 Reviewed by: marius r218788: Apply special PHY initialization code for 21143 controllers before any other media configuration. Otherwise some 21143 controller cannot establish a link. While I'm here remove the PHY initialization code in dc_setcfg(). Since dc_setcfg() is called whenever link state is changed, having the PHY initialization code in dc_setcfg() resulted in continuous link flips. After driver resets SIA, use default SIA transmit/receive configuration instead of disabling autosense/autonegotiation. Otherwise, controller fails to establish a link as well as losing auto-negotiation capability. For manual media configuration, always configure 21143 controller with specified media to ensure media change. This change makes ANA-6922 establish link with/without auto-negotiation. While I'm here be more strict on link UP/DOWN detection logic. Many thanks to marius who fixed several bugs in initial patch and even tested the patch on a couple of dc(4) controllers. PR: kern/79262 Reviewed by: marius Tested by: marius END K 10 svn:author V 7 yongari K 8 svn:date V 27 2011-03-27T22:21:52.126288Z K 7 svn:log V 2081 MFC r213841,218787-218788: r213841: It seems some multi-port dc(4) controllers shares SROM of the first port such that reading station address from second port always returned 0xFF:0xFF:0xFF:0xFF:0xFF:0xFF Unfortunately it seems there is no easy way to know whether SROM is shared or not. Workaround the issue by traversing dc(4) device list and see whether we're using second port and use station address of controller 0 as base station address of second port. PR: kern/79262 r218787: When driver have to use base softc due to lack of SROM on second port, copy SROM information from base softc as well and run SROM parser again. This change is necessary for some dual port controllers to make dc(4) correctly detect PHY media based on first port configuration table. While I'm here add a check for validity of the base softc before duplicating SROM contents from base softc. If driver failed to attach to the first port it can access invalid area. PR: kern/79262 Reviewed by: marius r218788: Apply special PHY initialization code for 21143 controllers before any other media configuration. Otherwise some 21143 controller cannot establish a link. While I'm here remove the PHY initialization code in dc_setcfg(). Since dc_setcfg() is called whenever link state is changed, having the PHY initialization code in dc_setcfg() resulted in continuous link flips. After driver resets SIA, use default SIA transmit/receive configuration instead of disabling autosense/autonegotiation. Otherwise, controller fails to establish a link as well as losing auto-negotiation capability. For manual media configuration, always configure 21143 controller with specified media to ensure media change. This change makes ANA-6922 establish link with/without auto-negotiation. While I'm here be more strict on link UP/DOWN detection logic. Many thanks to marius who fixed several bugs in initial patch and even tested the patch on a couple of dc(4) controllers. PR: kern/79262 Reviewed by: marius Tested by: marius END K 10 svn:author V 7 yongari K 8 svn:date V 27 2011-03-27T22:31:17.402429Z K 7 svn:log V 1751 MFC r218789,218820,218826-218828: r218789: Remove use case of DC_TX_ONE. It was used to limit queue just 1 TX frame in DM910x controllers. In r67595(more than 10 years ago) it was replaced to use "Store and Forward" mode and made controller generate TX completion interrupt for every frame. r218820: For controllers that have TX interrupt moderation capability, request TX completion interrupt for every 8-th frames. Previously dc(4) requested TX completion interrupt if number of queued TX descriptors is greater than 64. This caused a lot of TX completion interrupt under high TX load once driver queued more than 64 TX descriptors. It's quite normal to see more than 64 queued TX descriptors under high TX load. This change reduces the number of TX completion interrupts to be less than 17k under high TX load. Because this change does not generate TX completion interrupt for each frame, add reclaiming transmitted buffers in dc_tick not to generate false watchdog timeouts. While I'm here add check for queued descriptors in dc_txeof() since there is no more work to do when there is no pending descriptors. r218826: Make sure to clear status word of TX descriptor in dc_list_tx_init(). Do not update if_opackets if the transmission had failed. r218827: There is no need to execute filter configuration when driver is not running. Remove wrong driver state change in dc_setfilt_xircom(). While I'm here nuke unnecessary assignments. r218828: Fix a long standing bug where driver handed over RX descriptor ownership to controller before completion of access to the descriptor. Driver is faking up status word so it should not give ownership to controller until it completes RX processing. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2011-03-27T22:32:14.099900Z K 7 svn:log V 1751 MFC r218789,218820,218826-218828: r218789: Remove use case of DC_TX_ONE. It was used to limit queue just 1 TX frame in DM910x controllers. In r67595(more than 10 years ago) it was replaced to use "Store and Forward" mode and made controller generate TX completion interrupt for every frame. r218820: For controllers that have TX interrupt moderation capability, request TX completion interrupt for every 8-th frames. Previously dc(4) requested TX completion interrupt if number of queued TX descriptors is greater than 64. This caused a lot of TX completion interrupt under high TX load once driver queued more than 64 TX descriptors. It's quite normal to see more than 64 queued TX descriptors under high TX load. This change reduces the number of TX completion interrupts to be less than 17k under high TX load. Because this change does not generate TX completion interrupt for each frame, add reclaiming transmitted buffers in dc_tick not to generate false watchdog timeouts. While I'm here add check for queued descriptors in dc_txeof() since there is no more work to do when there is no pending descriptors. r218826: Make sure to clear status word of TX descriptor in dc_list_tx_init(). Do not update if_opackets if the transmission had failed. r218827: There is no need to execute filter configuration when driver is not running. Remove wrong driver state change in dc_setfilt_xircom(). While I'm here nuke unnecessary assignments. r218828: Fix a long standing bug where driver handed over RX descriptor ownership to controller before completion of access to the descriptor. Driver is faking up status word so it should not give ownership to controller until it completes RX processing. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2011-03-27T22:36:16.443629Z K 7 svn:log V 976 MFC r218830-218831: r218830: Send frames only when there is a valid link and driver is running as well as controller has enough free TX descriptors. Remove check for number of queued frames before attempting to transmit. I guess it was added to allow draining queued frames even if there is no link. I'm under the impression this type of check should be done in upper layer. No other drivers in tree do that. r218831: Rearrange interrupt handler a bit and remove forever loop. Previously dc(4) always checked whether there is pending interrupts and this consumed a lot of CPU cycles in interrupt handler. Limit the number of processing for TX/RX frames to 16. Also allow sending frames in the loop not to starve TX under high RX load. Reading DC_ISR register should be protected with driver lock, otherwise interrupt handler could be run(e.g. link state change) before the completion of dc_init_locked(). While I'm here remove unneeded code. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2011-03-27T22:37:28.663815Z K 7 svn:log V 976 MFC r218830-218831: r218830: Send frames only when there is a valid link and driver is running as well as controller has enough free TX descriptors. Remove check for number of queued frames before attempting to transmit. I guess it was added to allow draining queued frames even if there is no link. I'm under the impression this type of check should be done in upper layer. No other drivers in tree do that. r218831: Rearrange interrupt handler a bit and remove forever loop. Previously dc(4) always checked whether there is pending interrupts and this consumed a lot of CPU cycles in interrupt handler. Limit the number of processing for TX/RX frames to 16. Also allow sending frames in the loop not to starve TX under high RX load. Reading DC_ISR register should be protected with driver lock, otherwise interrupt handler could be run(e.g. link state change) before the completion of dc_init_locked(). While I'm here remove unneeded code. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2011-03-27T22:48:58.936253Z K 7 svn:log V 2806 MFC r218832: Split common TX/RX descriptor DMA tag to TX and RX DMA tags respectively and fix all bus_dma(9) issues seen when bounce buffers are used. o Setup frame handling had no bus_dmamap_sync(9) which prevented driver from configuring RX filter. Add missing bus_dmamap_sync(9) in both dc_setfilt_21143()/dc_setfilt_xircom() and dc_txeof(). o Use bus_addr_t for DMA segment instead of using u_int32_t. o Introduce dc_dma_alloc()/dc_dma_free() functions to allocate/free DMA'able memory. o Create two DMA descriptor list for each TX/RX lists. This change will minimize the size of bounce buffers that would be used in each TX/RX path. Previously driver had to copy both TX/RX lists when bounce buffer is active. o 21143 data sheet says descriptor list requires 4 bytes alignment. Remove PAGE_SIZE alignment restriction and use sizeof(struct dc_dec). o Setup frame requires 4 bytes alignment. Remove PAGE_SIZE alignment restriction and use sizeof(struct dc_dec). o Add missing DMA map unload for both setup frame and TX/RX descriptor list. o Overhaul RX handling logic such that make driver always allocate new RX buffer with dc_newbuf(). Previously driver allowed to copy received frame with m_devget(9) after passing the descriptor ownership to controller. This can lead to passing wrong frame to upper stack. o Introduce dc_discard_rxbuf() which will discard received frame and reuse loaded DMA map and RX mbuf. o Correct several wrong bus_dmamap_sync(9) usage in dc_rxeof and dc_txeof. The TX/RX descriptor lists are updated by both driver and HW so READ/WRITE semantics should be used. o If driver failed to allocate new RX buffer, update if_iqdrops counter instead of if_ierrors since driver received the frame without errors. o Make sure to unload loaded setup frame DMA map in dc_txeof and clear the mark of setup frame of the TX descriptor in dc_txeof(). o Add check for possible TX descriptor overruns in dc_encap() and move check for free buffer to caller, dc_start_locked(). o Swap the loaded DMA map and the last DMA map for multi-segmented frames. Since dc_txeof() assumes the last descriptor of the frame has the DMA map, driver should swap the first and the last DMA map in dc_encap(). Previously driver tried to unload not-yet-loaded DMA map such that the loaded DMA map was not unloaded at all for multi-segmented frames. o Rewrite DC_RXDESC/DC_TXDESC macro to simpler one. o Remove definition of ETHER_ALIGN, it's already defined in ethernet.h. With this changes, dc(4) works with bounce buffers and it shall also fix issues which might have shown in PAE environments. Tested by: marius END K 10 svn:author V 7 yongari K 8 svn:date V 27 2011-03-27T22:50:09.981721Z K 7 svn:log V 2806 MFC r218832: Split common TX/RX descriptor DMA tag to TX and RX DMA tags respectively and fix all bus_dma(9) issues seen when bounce buffers are used. o Setup frame handling had no bus_dmamap_sync(9) which prevented driver from configuring RX filter. Add missing bus_dmamap_sync(9) in both dc_setfilt_21143()/dc_setfilt_xircom() and dc_txeof(). o Use bus_addr_t for DMA segment instead of using u_int32_t. o Introduce dc_dma_alloc()/dc_dma_free() functions to allocate/free DMA'able memory. o Create two DMA descriptor list for each TX/RX lists. This change will minimize the size of bounce buffers that would be used in each TX/RX path. Previously driver had to copy both TX/RX lists when bounce buffer is active. o 21143 data sheet says descriptor list requires 4 bytes alignment. Remove PAGE_SIZE alignment restriction and use sizeof(struct dc_dec). o Setup frame requires 4 bytes alignment. Remove PAGE_SIZE alignment restriction and use sizeof(struct dc_dec). o Add missing DMA map unload for both setup frame and TX/RX descriptor list. o Overhaul RX handling logic such that make driver always allocate new RX buffer with dc_newbuf(). Previously driver allowed to copy received frame with m_devget(9) after passing the descriptor ownership to controller. This can lead to passing wrong frame to upper stack. o Introduce dc_discard_rxbuf() which will discard received frame and reuse loaded DMA map and RX mbuf. o Correct several wrong bus_dmamap_sync(9) usage in dc_rxeof and dc_txeof. The TX/RX descriptor lists are updated by both driver and HW so READ/WRITE semantics should be used. o If driver failed to allocate new RX buffer, update if_iqdrops counter instead of if_ierrors since driver received the frame without errors. o Make sure to unload loaded setup frame DMA map in dc_txeof and clear the mark of setup frame of the TX descriptor in dc_txeof(). o Add check for possible TX descriptor overruns in dc_encap() and move check for free buffer to caller, dc_start_locked(). o Swap the loaded DMA map and the last DMA map for multi-segmented frames. Since dc_txeof() assumes the last descriptor of the frame has the DMA map, driver should swap the first and the last DMA map in dc_encap(). Previously driver tried to unload not-yet-loaded DMA map such that the loaded DMA map was not unloaded at all for multi-segmented frames. o Rewrite DC_RXDESC/DC_TXDESC macro to simpler one. o Remove definition of ETHER_ALIGN, it's already defined in ethernet.h. With this changes, dc(4) works with bounce buffers and it shall also fix issues which might have shown in PAE environments. Tested by: marius END K 10 svn:author V 7 yongari K 8 svn:date V 27 2011-03-27T23:02:12.588491Z K 7 svn:log V 443 MFC r218833,218964: r218833: Count how many frames driver lost in interrupt handler. This register is cleared on read so make sure to clear it in driver initialization phase. r218964: Remove unnecessary controller reinitialization which resulted in link flips during alias address insertion or dhclient operation. While I'm here remove dc_reset() in DC_ISR_BUS_ERR case. Device is fully reinitialized again in dc_init_locked(). END K 10 svn:author V 7 yongari K 8 svn:date V 27 2011-03-27T23:03:15.349543Z K 7 svn:log V 443 MFC r218833,218964: r218833: Count how many frames driver lost in interrupt handler. This register is cleared on read so make sure to clear it in driver initialization phase. r218964: Remove unnecessary controller reinitialization which resulted in link flips during alias address insertion or dhclient operation. While I'm here remove dc_reset() in DC_ISR_BUS_ERR case. Device is fully reinitialized again in dc_init_locked(). END K 10 svn:author V 7 yongari K 8 svn:date V 27 2011-03-27T23:08:01.858479Z K 7 svn:log V 156 MFC r218834-218835: r218834: Consistently use a tab character instead of space after #define. No functional changes. r218835: s/u_intXX_t/uintXX_t/g END K 10 svn:author V 7 yongari K 8 svn:date V 27 2011-03-27T23:09:09.597750Z K 7 svn:log V 156 MFC r218834-218835: r218834: Consistently use a tab character instead of space after #define. No functional changes. r218835: s/u_intXX_t/uintXX_t/g END K 10 svn:author V 7 yongari K 8 svn:date V 27 2011-03-27T23:13:02.238336Z K 7 svn:log V 1296 MFC r219407: Rearrange dc_tx_underrun() a bit to correctly set TX FIFO threshold value. Controllers that always require "store and forward" mode( Davicom and PNIC 82C168) have no way to recover from TX underrun except completely reinitializing hardware. Previously only Davicom was reinitialized and the TX FIFO threshold was changed not to use "store and forward" mode after reinitialization since the default FIFO threshold value was 0. This effectively disabled Davicom controller's "store and forward" mode once it encountered TX underruns. In theory, this can cause watchodg timeouts. Intel 21143 controller requires TX MAC should be idle before changing TX FIFO threshold. So driver tried to disable TX MAC and checked whether it saw the idle state of TX MAC. Driver should perform full hardware reinitialization on failing to enter to idle state and it should not touch TX MAC again once it performed full reinitialization. While I'm here remove resetting TX FIFO threshold to 0 when interface is put into down state. If driver ever encountered TX underrun, it's likely to trigger TX underrun again whenever interface is brought to up again. Keeping old/learned TX FIFO threshold value shall reduce the chance of seeing TX underrns in next run. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2011-03-27T23:14:02.303132Z K 7 svn:log V 1296 MFC r219407: Rearrange dc_tx_underrun() a bit to correctly set TX FIFO threshold value. Controllers that always require "store and forward" mode( Davicom and PNIC 82C168) have no way to recover from TX underrun except completely reinitializing hardware. Previously only Davicom was reinitialized and the TX FIFO threshold was changed not to use "store and forward" mode after reinitialization since the default FIFO threshold value was 0. This effectively disabled Davicom controller's "store and forward" mode once it encountered TX underruns. In theory, this can cause watchodg timeouts. Intel 21143 controller requires TX MAC should be idle before changing TX FIFO threshold. So driver tried to disable TX MAC and checked whether it saw the idle state of TX MAC. Driver should perform full hardware reinitialization on failing to enter to idle state and it should not touch TX MAC again once it performed full reinitialization. While I'm here remove resetting TX FIFO threshold to 0 when interface is put into down state. If driver ever encountered TX underrun, it's likely to trigger TX underrun again whenever interface is brought to up again. Keeping old/learned TX FIFO threshold value shall reduce the chance of seeing TX underrns in next run. END K 10 svn:author V 10 nwhitehorn K 8 svn:date V 27 2011-03-27T23:43:32.123745Z K 7 svn:log V 420 Add mirror selection for FTP installs. To support TBEMD installs (e.g. powerpc64), this looks in a slightly different default path than now, specifying both $MACHINE and $MACHINE_ARCH: MIRROR/pub/FreeBSD/releases/`uname -p`/`uname -m`/`uname -r` How to handle TBEMD properly probably merits some more discussion, but, since no such 9.0-CURRENT distfiles exist at the moment, all existing mirrors presently fail anyway. END K 10 svn:author V 10 nwhitehorn K 8 svn:date V 27 2011-03-27T23:46:12.406061Z K 7 svn:log V 140 Add infrastructure for generation of boot-only ISO images. These have a reduced world, though still reasonably complete for fixit purposes. END K 10 svn:author V 10 nwhitehorn K 8 svn:date V 27 2011-03-27T23:46:52.988058Z K 7 svn:log V 53 Copy all generated ISO images into the release area. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2011-03-28T00:13:41.938250Z K 7 svn:log V 783 MFC r219701: Remove too expensive bus_dmamap_sync(9) call in dc_rx_resync(). With this change, driver may not notice updated descriptor status change when bounce buffers are active. However, rxeof() in next run will handle the synchronization. Change dc_rxeof() a bit to return the number of processed frames in RX descriptor ring. Previously it returned the number of frames that were successfully passed to upper stack which in turn means it ignored frames that were discarded due to errors. The number of processed frames in RX descriptor ring is used to detect whether driver is out of sync with controller's current descriptor pointer. Returning number of processed frames reduces unnecessary (probably wrong) re-synchronization. Reviewed by: marius END K 10 svn:author V 7 yongari K 8 svn:date V 27 2011-03-28T00:14:56.249228Z K 7 svn:log V 783 MFC r219701: Remove too expensive bus_dmamap_sync(9) call in dc_rx_resync(). With this change, driver may not notice updated descriptor status change when bounce buffers are active. However, rxeof() in next run will handle the synchronization. Change dc_rxeof() a bit to return the number of processed frames in RX descriptor ring. Previously it returned the number of frames that were successfully passed to upper stack which in turn means it ignored frames that were discarded due to errors. The number of processed frames in RX descriptor ring is used to detect whether driver is out of sync with controller's current descriptor pointer. Returning number of processed frames reduces unnecessary (probably wrong) re-synchronization. Reviewed by: marius END K 10 svn:author V 7 yongari K 8 svn:date V 27 2011-03-28T00:18:02.614318Z K 7 svn:log V 37 MFC r201449: Fix CardBus spelling. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2011-03-28T00:19:01.096650Z K 7 svn:log V 37 MFC r201449: Fix CardBus spelling. END K 10 svn:author V 5 kevlo K 8 svn:date V 27 2011-03-28T01:24:20.926414Z K 7 svn:log V 89 MFC r219982: Fix panic while associating access point. While here, add the SMC SMCWUSB-G END K 10 svn:author V 10 nwhitehorn K 8 svn:date V 27 2011-03-28T02:37:05.736897Z K 7 svn:log V 24 Improve error handling. END K 10 svn:author V 10 nwhitehorn K 8 svn:date V 27 2011-03-28T04:29:50.659644Z K 7 svn:log V 106 Committing while tired is never a good idea. Remove an unconditional error exit left over from debugging. END K 10 svn:author V 3 alc K 8 svn:date V 27 2011-03-28T06:35:17.888806Z K 7 svn:log V 631 The new binutils has correctly redefined MAXPAGESIZE on amd64 as 0x200000 instead of 0x100000. As a side effect, an amd64 kernel now loads at physical address 0x200000 instead of 0x100000. This is probably for the best because it avoids the use of a 2MB page mapping for the first 1MB of the kernel that also spans the fixed MTRRs. However, getmemsize() still thinks that the kernel loads at 0x100000, and so the physical memory between 0x100000 and 0x200000 is lost. Fix this problem by replacing the hard-wired constant in getmemsize() by a symbol "kernphys" that is defined by the linker script. In collaboration with: kib END K 10 svn:author V 2 mr K 8 svn:date V 27 2011-03-28T07:00:41.186499Z K 7 svn:log V 198 Use ${NANO_WORLDDIR}/var/empty as copy source since it has no schg flag set. Copying over /var/empty's schg flag had unpleasant side effects (schg flag on /etc and /cfg) during nanobsd boot before. END K 10 svn:author V 3 kib K 8 svn:date V 27 2011-03-28T08:22:13.635363Z K 7 svn:log V 63 MFC r219986: Fix file leakage in the freebsd32_ioctl routines. END K 10 svn:author V 3 kib K 8 svn:date V 27 2011-03-28T08:23:45.999534Z K 7 svn:log V 41 MFC r219987: Remove unneccessary panics. END K 10 svn:author V 8 martymac K 8 svn:date V 27 2011-03-28T08:37:48.210081Z K 7 svn:log V 11 Add myself END K 10 svn:author V 8 martymac K 8 svn:date V 27 2011-03-28T09:05:43.233156Z K 7 svn:log V 35 Add myself to committers-ports.dot END K 10 svn:author V 6 adrian K 8 svn:date V 27 2011-03-28T09:10:59.748274Z K 7 svn:log V 72 The previous commit didn't completely rename this to what it should be. END K 10 svn:author V 3 mav K 8 svn:date V 27 2011-03-28T11:08:58.697453Z K 7 svn:log V 58 Update mvs(4) driver to work over FDT's simplebus(4) bus. END K 10 svn:author V 6 adrian K 8 svn:date V 27 2011-03-28T11:48:49.092301Z K 7 svn:log V 269 Add in HT protection but disable it by default. I'll clear how it's supposed to work with Bernhard and then look at enabling this in the correct situations. But this -does- enable HT RTS protection (using the appropriate legacy rates) if this bit of code is enabled. END K 10 svn:author V 3 kib K 8 svn:date V 27 2011-03-28T12:39:48.288051Z K 7 svn:log V 125 Fix the softdep_request_cleanup() function definition for !SOFTUPDATES case. Submitted by: Aleksandr Rybalko END K 10 svn:author V 3 kib K 8 svn:date V 27 2011-03-28T12:48:33.277822Z K 7 svn:log V 171 Promote ksyms_map() and ksyms_unmap() to general facility copyout_map() and copyout_unmap() interfaces. Submitted by: John Wehle , nox MFC after: 2 weeks END K 10 svn:author V 3 kib K 8 svn:date V 27 2011-03-28T13:21:26.464659Z K 7 svn:log V 101 Handle zero length in copyout_unmap(). Submitted by: John Wehle MFC after: 2 weeks END K 10 svn:author V 3 kib K 8 svn:date V 27 2011-03-28T13:28:23.035408Z K 7 svn:log V 53 Trim white spaces, adjust style. MFC after: 2 weeks END K 10 svn:author V 7 yongari K 8 svn:date V 27 2011-03-28T16:58:48.392736Z K 7 svn:log V 686 Normally fxp(4) does not receive bad frames but promiscuous mode makes controller to receive bad frames and i82557 will also receive bad frames since fxp(4) have to receive VLAN oversized frames. If fxp(4) encounter DMA overrun error, the received frame size would be 0 so the actual frame size after checksum field extraction the length would be negative(-2). Due to signed/unsigned comparison used in driver, frame length check did not work for DMA overrun frames. Correct this by casting it to int. While I'm here explicitly check DMA overrun error and discard the frame regardless of result of received frame length check. Reported by: n_hibma Tested by: n_hibma MFC after: 1 week END