summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* fix poor indentation resulting from a mergeluigi2009-12-241-14/+14
|
* Implement RX interrupt moderation using one-shot timer interrupt.yongari2009-12-242-27/+74
| | | | | | | | | | | | | | | | | | | | | | | | | | Unlike TX interrupt, ST201 does not provide any mechanism to suppress RX interrupts. ste(4) can generate more than 70k RX interrupts under heavy RX traffics such that these excessive interrupts make system useless to process other useful things. Maybe this was the major reason why polling support code was introduced to ste(4). The STE_COUNTDOWN register provides a programmable counter that will generate an interrupt upon its expiration. We program STE_DMACTL register to use 3.2us clock rate to drive the counter register. Whenever ste(4) serves RX interrupt, the driver rearm the timer to expire after STE_IM_RX_TIMER_DEFAULT time and disables further generation of RX interrupts. This trick seems to work well and ste(4) generates less than 8k RX interrupts even under 64 bytes UDP torture test. Combined with TX interrupts, the total number of interrupts are less than 10k which looks reasonable on heavily loaded controller. The default RX interrupt moderation time is 150us. Users can change the value at any time with dev.ste.%d.int_rx_mod sysctl node. Setting it 0 effectively disables the RX interrupt moderation feature. Now we have both TX/RX interrupt moderation code so remove loop of interrupt handler which resulted in sub-optimal performance as well as more register accesses.
* Merge from amd64/i386:marius2009-12-245-3/+67
| | | | Implement support for interrupt descriptions.
* Add missing locking in intr_bind().marius2009-12-241-2/+8
|
* Execute the cleanup handlers before jumping to the kernel justmarius2009-12-241-0/+2
| | | | like the other architectures do.
* - Consistently wrap debugging in NETIF_DEBUG. This basically mergesmarius2009-12-241-6/+22
| | | | | NetBSD rev 1.19. - Make the functions match their prototypes regarding static.
* Revert r183628 as with the current ata(4) ATAPI DMA with AcerLabsmarius2009-12-241-1/+0
| | | | | | M5229 appears to be once again fixed. If this happens to return we probably should disable ATAPI DMA in ataacerlabs(4) instead just like the Linux libATA does.
* sh: Remove setting variables from dotcmd/exportcmd.jilles2009-12-242-5/+0
| | | | | | | | | | | | It is already done by evalcommand(), unless special-ness has been removed, in which case variable assignments should not persist. (These are currently always special builtins, but this will change later: command builtin, command substitution.) This also fixes a memory leak when calling . with variable assignments. Example: valgrind --leak-check=full sh -c 'x=1 . /dev/null; x=2'
* Make geom_concat to passthrough stripe parameters of the first component,mav2009-12-241-5/+8
| | | | hoping that rest will fit.
* Add a new tool which attempts to check for kernel configuration options thatjhb2009-12-243-0/+367
| | | | are missing from NOTES files.
* As soon as geom_raid3 reports it's own stripe as sector size, report largestmav2009-12-241-0/+14
| | | | | underlying provider's stripe, multiplied by number of data disks in array, due to transformation done, as array stripe.
* - Don't check for a valid interrupt controller on every interruptmarius2009-12-241-2/+3
| | | | | | | | | | | in intr_execute_handlers(). If we managed to get here without an associated interrupt controller we have way bigger problems. While at it predict stray vector interrupts as false as they are rather unlikely. - Don't blindly call the clear function of an interrupt controller when adding a handler in inthand_add() as interrupt controllers like the one driven by upa(4) are auto-clearing and thus provide NULL instead.
* As soon as mirror has no own stripes, report largest stripe of unrerlyingmav2009-12-241-0/+9
| | | | components, hoping others fit, if they are not equal.
* Add two disk ioctls, giving user-level tools information about disk/arraymav2009-12-242-1/+18
| | | | stripe (optimal access block) size and offset.
* Make geom_stripe report it's stripe size to upper layers.mav2009-12-241-0/+2
|
* Adapt OpenBSD pf's "sloopy" TCP state machine which is useful for Directdelphij2009-12-248-179/+341
| | | | | | | | | | | | | | | Server Return mode, where not all packets would be visible to the load balancer or gateway. This commit should be reverted when we merge future pf versions. The benefit it would provide is that this version does not break any existing public interface and thus won't be a problem if we want to MFC it to earlier FreeBSD releases. Discussed with: mlaier Obtained from: OpenBSD Sponsored by: iXsystems, Inc. MFC after: 1 month
* Add hwpmc_arm.crpaulo2009-12-231-0/+1
|
* Intel XScale hwpmc(4) support.rpaulo2009-12-2311-26/+940
| | | | | | | | | | | This brings hwpmc(4) support for 2nd and 3rd generation XScale cores. Right now it's enabled by default to make sure we test this a bit. When the time comes it can be disabled by default. Tested on Gateworks boards. A man page is coming. Obtained from: //depot/user/rpaulo/xscalepmc/...
* Recognize the NS16552 found in PCIe-based sun4u machines.marius2009-12-232-2/+3
|
* - By re-arranging the code in OF_decode_addr() somewhat and acceptingmarius2009-12-231-33/+33
| | | | | | | a bit of a detour we can just iterate through the banks array instead of having to calculate every offset. This change is inspired by the powerpc version of this function. - Add support for the JBus to EBus bridges which hang off of nexus(4).
* Style changes.marius2009-12-231-14/+12
|
* - Add support for the IOMMUs of Fire JBus to PCIe and Oberon Uranusmarius2009-12-233-43/+166
| | | | | | | | | to PCIe bridges. - Add support for talking the PROM mappings over to the kernel IOTSB just like we do with the kernel TSB in order to allow OFW drivers to continue to work. - Change some members, parameters and variables to unsigned where more appropriate.
* Fix whitespace according to style(9).marius2009-12-231-29/+29
|
* - Add quirk handling for ALi M5229, mainly setting the magic "forcemarius2009-12-231-3/+24
| | | | | | | | enable IDE I/O" bit which prevents data access traps with revision 0xc8 in Fire-based machines when pci(4) enables PCIM_CMD_PORTEN. - Like for sun4v also don't add the PCI side of host-PCIe bridges to the bus on sun4u as they don't have configuration space implement there either.
* - Sort the prototypes.marius2009-12-231-24/+23
| | | | | - Add macros to ease the access of device configuration space in ofw_pcibus_setup_device().
* Fix a bug in gzipfs that prevented lseek() from working and add lseek()jhb2009-12-232-16/+67
| | | | | | | | support to bzip2fs. This fixes problems with loading compressed amd64 kernel modules containing debug symbols. Submitted by: David Naylor naylor.b.david (gmail) MFC after: 1 week
* Add structures for OFW MSI/MSI-X support. These are identical formarius2009-12-231-0/+25
| | | | both sun4u and sun4v.
* Hook ebus(4) and isa(4) up to the sun4v LINT build in order tomarius2009-12-232-1/+5
| | | | | ensure that their compilation doesn't break as they are expected to work as-is now (but aren't actually run-time tested).
* - Remove devices which are/were only relevant for sun4u.marius2009-12-231-19/+0
|
* Don't probe the bq4802 variant found in Ultra 25 and 45 for now asmarius2009-12-231-4/+9
| | | | | this chip isn't MC146818 compatible and requires different handlers (but which I can't test due to lack of such hardware).
* Don't use an out register to hold the vector number across the callmarius2009-12-231-11/+11
| | | | | | 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.
* We don't need to generate DMA complete interrupt for everyyongari2009-12-232-1/+18
| | | | | | | | | | | transmitted frames. So request interrupt for every 16th frames. Due to the limitation of hardware we can't suppress the interrupt as driver should have to check TX status register. The TX status register can store up to 31 TX status so driver can't send more than 31 frames without reading TX status register. With this change controller would not generate TX completion interrupt for every frame, so reclaim transmitted frames in ste_tick().
* Correct STE_COUNTDOWN register offset. The datasheet was wrong.yongari2009-12-231-1/+1
|
* Remove unused duplicated register definition. It seems theyongari2009-12-231-12/+0
| | | | | | definition was made to access STE_ASICCTL register as 16bits but ste(4) always access the register as 32bits so it was never used before.
* Implement hardware MAC statistics counter support. The countersyongari2009-12-232-25/+169
| | | | could be accessed with dev.ste.0.stats sysctl node.
* mostly style changes, such as removal of trailing whitespace,luigi2009-12-231-183/+152
| | | | | | | | | | | reformatting to avoid unnecessary line breaks, small block restructuring to avoid unnecessary nesting, replace macros with function calls, etc. As a side effect of code restructuring, this commit fixes one bug: previously, if a realloc() failed, memory was leaked. Now, the realloc is not there anymore, as we first count how much memory we need and then do a single malloc.
* Report the correct result of mii_mediachg(). Previously it alwaysyongari2009-12-231-19/+12
| | | | | | | used to return success without respect to the result. While I'm here use mii_mediachg() in ste_init_locked which allows driver to use currently configured media. ste_ifmedia_upd() is supposed to be called whenever user changes current media settings.
* Don't report link status if driver is not running.yongari2009-12-231-0/+4
|
* Overhaul RX filter programming.yongari2009-12-231-62/+38
| | | | | | | | | | | | | | | | o Let RX filter handler program promiscuous/multicast filter as well as broadcasting. o Remove unnecessary register access. o Simplify ioctl handler and have set_rxfilter to handle IFF_PROMISC and IFF_ALLMULTI change instead of directly programming the controller. o Removed unnecessary error variable reinitialization in ioctl handler. o Add IFF_DRV_RUNNING check before programming multicast filter. o Configure maximum allowed frame length before enabling MAC. Datasheet didn't say the exact ordering of programming sequence but it looks more natural to set maximum allowed frame length first prior to enabling controller.
* Reimplement controller reset. Datasheet says full reset takes aboutyongari2009-12-231-8/+15
| | | | | | | 1ms. Since we switched to memory register mapping make sure to flush PCI posted write by reading the register again. While I'm here add additional delays in loop while driver waits the completion of the reset.
* Don't reinitialize controller if driver is already running. Thisyongari2009-12-231-2/+11
| | | | reduces number of link state UP/DOWN changes.
* Allow proper tracing of posix_openpt(2).ed2009-12-231-0/+2
|
* When warning about possible netisr configuration problems during boot,rwatson2009-12-231-4/+4
| | | | | | | report using "netisr_init" rather than "netisr2", which was the development name for the project. MFC after: 3 days
* Refine netisr.c comments a bit.rwatson2009-12-231-20/+28
|
* fix build with the new fast lookup structure.luigi2009-12-231-79/+56
| | | | Also remove some unnecessary headers
* fix build on 64-bit architectures.luigi2009-12-231-15/+15
| | | | Also fix the indentation on a few lines.
* Calculate the average CPU clock frequency and export that throughmarcel2009-12-231-0/+14
| | | | | the hw.freq.cpu sysctl variable. This can be used by ports that need to know "the" CPU frequency.
* Export the bus, cpu and itc frequencies under the hw.freq sysctl node.marcel2009-12-234-27/+43
| | | | | | | | | | | | The frequencies are in MHz (i.e. a value of 1000 represents 1GHz). The frequencies are rounded to the nearest whole MHz. While here, rename and re-type bus_frequency, processor_frequency and itc_frequency to bus_freq, cpu_freq and itc_freq and make them static. As unsigned integers, the hw.freq.cpu sysctl can more easily be made generic (across all architectures) making porting easier. MFC after: 3 days
* Add a bit definition for invalid timestamp in the record header.marcel2009-12-231-0/+1
|
* Shorten the USB_QUIRK_ENTRY macro and undef it at the end, its only internal.thompsa2009-12-231-238/+235
|
OpenPOWER on IntegriCloud