summaryrefslogtreecommitdiffstats
path: root/sys/dev
Commit message (Collapse)AuthorAgeFilesLines
...
* Add support for the P212, P410, P410i, P411, and P812 HP Smart Arrayps2008-06-101-0/+5
| | | | | | controllers. Submitted by: Scott Benesh at HP
* >From NetBSD:kevlo2008-06-102-46/+0
| | | | | | | | Remove the code which disables port status change interrupts for 1s when one occured -- this makes that events get lost or delayed until the next change. Obtained from: NetBSD
* - Fixed kern/123696 by increasing firmware timeout value from 100 to 1000.davidch2008-06-102-54/+193
| | | | | | | | | | - Fixed a problem on i386 architecture when using split header/jumbo frame firmware caused by hardware alignment requirements. - Added #define BCE_USE_SPLIT_HEADER to allow the feature to be enabled/ disabled. Enabled by default. PR: kern/123696 MFC after: 2 weeks
* Remove sicontrol(8)'s "ttystat".ed2008-06-092-6/+0
| | | | | | | | | | | | | | | | | In the FreeBSD base system, there are only two utilities that use struct tty, namely pstat and sicontrol. The sicontrol utility calls the TCSI_TTY ioctl(), which copies struct tty back to userspace. sicontrol should not have this functionality. The same data is already provided by pstat. If we really want to be able to export these numbers through a file descriptor to userspace, we can export struct xtty, which should provide a better abstraction. The ttystat option was only used as a debugging aid. This makes sicontrol compile in the mpsafetty branch. Reviewed by: peter Approved by: philip (mentor)
* Fix typo in comment.rpaulo2008-06-081-1/+1
|
* Ethernet hardware address stored in DC_AL_PAR0/DC_AL_PAR1 registeryongari2008-06-081-6/+14
| | | | | | | | | | | | is in little endian form. Likewise setting DC_AL_PAR0/DC_AL_PAR1 register expect the address to be in little endian form. For big endian architectures the address should be swapped to get correct one. Change setting/getting ethernet hardware address to big endian architecture frendly. Reported by: Robert Murillo ( billypilgrim782001 at yahoo dot com ) Tested by: Robert Murillo ( billypilgrim782001 at yahoo dot com )
* Add support for the Apple Big Mac (BMAC) Ethernet controller,marcel2008-06-074-0/+1765
| | | | | | found on various Apple G3 models. Submitted by: Nathan Whitehorn
* Change the calling convention for ic_node_alloc to deal withsam2008-06-079-22/+35
| | | | | | | | | | | | some longstanding issues: o pass the vap since it's now the "coin of the realm" and required to do things like set initial tx parameters in private node state for use prior to association o pass the mac address as cards that maintain outboard station tables require this to create an entry (e.g. in ibss mode) o remove the node table reference, we only have one node table and it's unlikely this will change so this is not needed to find the com structure
* - Store the device_t of the smbX device in the softc.jhb2008-06-061-37/+22
| | | | | | | | | | | | | - Store the softc of the device in the 'si_drv1' of the cdev. - Lookup the softc via 'si_drv1' in cdev methods rather than using the minor number as a unit for devclass_get_softc(). - Lookup the device_t via the softc field in cdev methods rather than using the minor number as a unit for devclass_get_device(). - Add a mutex to the softc to protect 'sc_opened'. - Remove D_NEEDGIANT as all the smbus drivers are now MPSAFE and this driver is now MPSAFE. - Remove some checks for NULL softc pointers that can't happen and don't bzero the softc during attach.
* Explicitly lock Giant in smbus_if methods in the bktr_i2c and iicsmbjhb2008-06-062-9/+67
| | | | | drivers for now. This can be replaced with driver locks when these drivers are locked.
* - Use bus_foo() rather than bus_space_foo() and remove bus space tag/handlejhb2008-06-063-67/+63
| | | | | | from softc. - Mark interrupt handlers MPSAFE as these drivers have been locked for a while.
* Tweak a comment and a constant to restore old 30ms upper bound.imp2008-06-061-3/+3
| | | | cs_readreg takes ~2us not ~1us to run.
* o Remove unused cs_debug tunable. I think I added it and then nothing withimp2008-06-061-10/+22
| | | | | | | | | | | it. Bad imp. Removing us dips us under 10,000 in size too. o Replace an unconditional 30ms DELAY (yes, busy wait) with a check of the SIBUSY bit in the SelfST register before accessing the eeprom. This changes the time to read the EEPROM from 2 * 20 * 30ms (1.2s) to < 20*25us (.0005s) and make the attach of the card tolerable when ethernet media is present. Include data from the datasheet about why this works. While this is a 2500x speed increase, it doesn't really matter at all once the card is probed... o set dev earlier in softc.
* Forgot to commit these files too :-(imp2008-06-062-3/+3
|
* Minor clean up to shave about 1.5k off the size of the driver:imp2008-06-064-95/+12
| | | | | | | | | o remove unused fields from softc and args from cs_alloc_irq o remove some commented code that will never be implemented. o Don't try to send a packet and see if it worked. We don't need this anymore, and it doesn't add any value. o tweaks for BNC and AUI. o limit possible time hung in the kernel to 4s rather than 40s.
* Simplify error checking when reading the function....imp2008-06-061-3/+1
|
* cs has detach, remove bogus ifdef.imp2008-06-061-3/+1
| | | | Remove dedundant initialization of error to 0.
* This is a rewritten driver for the SMSC LAN91C111. It's based in part on thebenno2008-06-065-0/+1929
| | | | | | | | | | | | | | | sn(4) driver and also looking at newer drivers. The reason for the rewrite is to support MII and to try and resolve some performance issues found when trying to use the sn(4) driver on the Gumstix network boards. For reference, the SMSC LAN91C111 is a non-PCI ethernet part whose lineage dates back to Ye Olde Days of ISA. It seems to get some use in the embedded space these days on parts lacking on-board MACs or on-board PCI controllers, such as the XScale PXA line of ARM CPUs. This also includes a driver for the SMSC LAN83C183 10/100 PHY. Man page to follow.
* Remove unused fields in softc. If they are ever really needed again,imp2008-06-064-27/+3
| | | | | | they can re-added. Remove CS_NAME. Don't whine when there's an ignored checksum error: User has said STFU, so we should S the FU. (remove mandated properties).
* Checkpoint what I've been running for the last year. Tidy up apeter2008-06-062-73/+82
| | | | bunch of loose ends that "can't happen" any more, if they ever could.
* Add the support for the Globetrotter Max 3.6 HSDPA Modem.attilio2008-06-052-0/+3
| | | | | PR: usb/118374 Submitted by: Greg Rivers <gcr at tharned dot org>
* Make the cs(4) driver MPSAFE:jhb2008-06-054-67/+118
| | | | | | | | | - Add a mutex to the softc to protect the softc and the device hardware. - Add a private timer to manage transmit watchdogs rather than using if_timer/if_watchdog. - Setup the interrupt handler after ether_ifattach(). Tested by: imp
* Rename the ie_EE16 module to just 'ie' so that at least one of the modulesjhb2008-06-051-1/+7
| | | | | | | | for this driver is called 'ie'. Otherwise, ifconfig(8) doesn't recognize any of the modules as being the ie(4) driver and will always try to kldload the driver even when it is already present in the kernel. Reported by: Thierry Herbelot
* - Fix two calls to ieinit() in ieioctl() to call ieinit_locked() instead tojhb2008-06-051-3/+3
| | | | | avoid recursing on the lock. - Use IFQ_SET_MAXLEN().
* Fix the media auto code by breaking it :-). Auto now just means 'useimp2008-06-051-19/+8
| | | | | | | | | | | | 10BaseT' since it required 10BaseT to have carrier to switch to it. This chip makes it hard to do proper auto, so we don't do it. We can't test carrier on things easily. Don't insist on carrier when we set the media. Don't report failures. Remove a 1s! delay that appears to not be needed. With these patches, and John Baldwin's patches, I'm able to pass packets on my IBM EtherJet card again.
* Style(9) xe(4). The MD5 sums are different, but comparing the dissassembliesjhb2008-06-043-1566/+1621
| | | | the only changes are from gcc moving some global variables around slightly.
* Gah, always reset the timer for the watchdog check.jhb2008-06-041-1/+1
|
* - Split the interrupt handler up into separate subroutines for rx, tx, andjhb2008-06-042-61/+79
| | | | | | | MAC events. - Use bus_*() rather than bus_space_*() and remove the bus space tag and handle from the softc. - Retire unused macros for examining CIS tuples.
* Add device IDs for Ricoh R5U870-based OEM cameraskevlo2008-06-041-0/+8
|
* o Improve the probe code dealing with interrupts.imp2008-06-041-83/+54
| | | | | | | | | | | | | | | | | | | | | | | | | o When forced to be 10baseT, don't require that the 10baseT interface have link to succeed. Still require it for IFM_AUTO, however, since it appears that there's no way to tell if a specific type of interface worked. I'm doing a web search for a datasheet now to see if there's anything obvious. o Minor incidental formatting nits, including collapsing code of the form if (foo) { bar(); } else { if (baz) bing(); } into: if (foo) { bar(); } else if (baz) { bing(); } to save an indentation level. o Remove stray reference to 3.x config file syntax. # I believe John's patches still apply after this...
* - Change the watchdog timer logic to match other drivers that use their ownjhb2008-06-032-10/+17
| | | | | | | timer by keeping a once-a-second timer running that decrements a counter similar to if_timer and reset the chip if it gets down to zero via the decrement. - Use IFQ_SET_MAXLEN().
* Correct logic error that would prevent cs pccards from working onimp2008-06-031-8/+8
| | | | | | | | | systems where the CardBus bridge was connected to a APIC. The case where the probe routine is told to not setup the IRQ was mishandled but the error was masked in the case where the IRQ was a valid one for the card. MFC after: 1 week
* Add device ID for AnyDATA ADU-500A EV-DO modem.kan2008-06-032-0/+3
| | | | | Submitted by: Oleksandr Tatmanyants PR: 118479
* Add vendor/device IDs for Novatel U740 repackaged by Dell.kan2008-06-032-0/+3
| | | | | Submitted by: David Gilbert PR: 122803
* Update if_ndis to remove the legacy if_watchdog interface andcokane2008-06-032-44/+33
| | | | | | | | | | | bring it more up to date. The watchdog timer, and its associated code, is all collapsed into the ndis_tick function that was implemented for the NDIS-subsystem watchdog. This implementation is similar to what numerous other drivers use to implement the watchdog. Reviewed by: thompsa, jhb MFC after: 2 weeks
* Make fe(4) MPSAFE:jhb2008-06-023-44/+86
| | | | | | | | | - Add a mutex to the softc to protect the softc and device hardware. - Don't leak bus resources if if_alloc() fails during attach. - Setup the interrupt handler after calling ether_ifattach(). - Use a private timer to manage the transmit watchdog. Tested by: WATANABE Kazuhiro CQG00620 of nifty.ne.jp
* Add locking and make xe(4) MPSAFE:jhb2008-06-023-73/+104
| | | | | | | | | | | - Add a mutex to protect the softc and device hardware. - Use a callout rather than a callout_handle for the media timer. - Use a dedicated timer for managing the tx watchdog rather than if_timer. - Fix some resource leaks if xe_attach() fails. - Shutdown the device before detaching the driver. - Setup the interrupt handler after ether_ifattach(). Tested by: Ian FREISLICH ianf of clue.co.za
* Make ie(4) MPSAFE:jhb2008-06-023-81/+75
| | | | | | | | | | | | | | | | | | | - Add a mutex to the softc and use it to protect the softc and device. - Setup the interrupt handler in the common code instead of in each front end and do it after ether_ifattach(). - Use ie_stop() and ieinit_locked() in iereset() rather than frobbing IFF_UP and invoking ieioctl(). - Use DELAY() to implement a spin loop on a register with a timeout rather than scheduling a timeout and then doing a tight spin on the register. In the non-MPSAFE case this would never have worked because the spinning code held Giant and the timeout routine would have been blocked on Giant forever. The same approach would not worke in the MPSAFE case either for the same reason, hence use a loop around DELAY(). - Clear IFF_DRV_(RUNNING|OACTIVE) in ie_stop() rather than in callers. - Call ieinit_locked() directly rather than ieioctl(!) from ie_mc_reset(). - Don't leak the rx frame buffer on detach. Tested by: Thierry Herbelot thierry of herbelot.com
* Slight simplification of the power parsing code, as well as usingimp2008-06-011-45/+27
| | | | | | autoincrement in some places where it makes sense. This makes this .o about 180 bytes smaller on x86 and amd64 with no apparent functional changes.
* Try to detect a Synaptics touchpad before IntelliMouse. Some touchpads willphilip2008-06-011-2/+2
| | | | | | | | | | | | | pretend to be IntelliMouse (which have a few more features than generic mice) causing the IntelliMouse probe to work and the Synaptics code never to be called. This should not break "real" IntelliMouse because the Synaptics detection code is fairly specific. PR: kern/120833 Submitted by: Eygene Ryabinkin <rea-fbsd -at- codelabs.ru> MFC after: 1 week
* 5416 and similar chips grew another region in the pci clock domainsam2008-05-311-2/+6
| | | | | | | where register accesses do not pass through the byte-lane hardware; extend the register op macros to deal with this MFC after: 1 week
* Import rewritten nve device id's, which brings this moreremko2008-05-312-41/+79
| | | | | | | | | inline with if_nfe. PR: 110883 Submitted by: Claudel <regis at claudel dot ch> Approved by: imp (mentor, implicit) MFC after: 1 week
* Remove various and sundry NetBSDism's in preparation for adding locking.jhb2008-05-304-136/+77
|
* Trim an extra semi-colon.jhb2008-05-301-1/+1
|
* Fix build with DEBUG defined.jhb2008-05-301-4/+4
| | | | Reported by: tinderbox
* Fix a panic that it's occurred when NDIS init handler returned a errorweongyo2008-05-301-5/+8
| | | | | by unknown reasons. In this case, sc->ifp is still NULL so it will cause a page fault during calling ndis_detach()
* The XScale PXA255 has three generally ns16x50 compatible UARTs. One of thebenno2008-05-301-5/+31
| | | | | | | | | | | | | | | variations from normal 16x50 behaviour however is the the use of a normally unused bit of IER to control RX timeout interrupts independently of the generally used RXRDY bit. If this bit is not enabled, we only ever get interrupts when the FIFO is full, never before. This is not very useful when the UART is being used as a console. In order to support this without causing potential problems on more "normal" 16x50 variants, this change introduces two hints for the uart device, ier_mask and ier_rxbits. These can be used to override which bits get set and cleared when we're enabling and disabling RX interrupts. Reviewed by: marcel
* Use if_printf() and if_xname and retire 'unit' from the softc.jhb2008-05-292-48/+48
|
* Remove the distinction between device minor and unit numbers.ed2008-05-293-3/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Even though we got rid of device major numbers some time ago, device drivers still need to provide unique device minor numbers to make_dev(). These numbers are only used inside the kernel. They are not related to device major and minor numbers which are visible in devfs. These are actually based on the inode number of the device. It would eventually be nice to remove minor numbers entirely, but we don't want to be too agressive here. Because the 8-15 bits of the device number field (si_drv0) are still reserved for the major number, there is no 1:1 mapping of the device minor and unit numbers. Because this is now unused, remove the restrictions on these numbers. The MAXMAJOR definition was actually used for two purposes. It was used to convert both the userspace and kernelspace device numbers to their major/minor pair, which is why it is now named UMINORMASK. minor2unit() and unit2minor() have now become useless. Both minor() and dev2unit() now serve the same purpose. We should eventually remove some of them, at least turning them into macro's. If devfs would become completely minor number unaware, we could consider using si_drv0 directly, just like si_drv1 and si_drv2. Approved by: philip (mentor)
* The SIIG 4 port serial card based on the Oxford OX16PCI954 ismckusick2008-05-291-4/+4
| | | | | | | | | | clocked at 10x normal speed. That is, when you set it for 9600 baud, it actually does 96000 baud. In order to make it plug and play with other serial ports, it has to have its clock rate reduced by a factor of 10. Discussed with: Marcel Moolenaar MFC after: 2 weeks
OpenPOWER on IntegriCloud