summaryrefslogtreecommitdiffstats
path: root/sys/dev
Commit message (Collapse)AuthorAgeFilesLines
* Change the interrupt handler a bit so that we call the nge_rxeof() handlerwpaul2001-07-161-3/+2
| | | | | | when we get an RX_ERR interrupt rather than the nge_rxeoc() handler. The rxeoc (end of channel) handler attempts to reinitialize the whole NIC, which we don't want to do if we only received a bad packet.
* Hrmpf. nyan's rev 1.25 commit to fdc.h crossed with my removal of it.joerg2001-07-141-0/+17
| | | | Back-integrate his (PC98) changes into fd.c.
* Yet another large non-function change.joerg2001-07-141-142/+271
| | | | | | | | | | | | | | | | | | | | . Integrate fdc.h into fd.c, with the removal of ft(4) there's no longer a reason to scatter things across two files. . Sanitize comments. Convert them into the style(9)-recommended multi-line form, make them sentences where apprpriate, etc. . Declare all functions on top, and declare them in the order they appear in the file. This order is totally chaotic, but Bruce convinced me that reordering the file wouldn't make it better either. . Kill a `possibly uninitialized' warning (only seen with -O2) in fd_read_status(). . Make the comments at return (0|1) statements in fdstate() consistent. . Nuke a ``keep the compiler happy'' dummy return at the end of fdstate(), gcc is smart enough to detect that it would never be reached anyway.
* Catch up with NetBSD/pc98.non2001-07-1421-1545/+3281
| | | | | | | | | | | | | | | | | | | | | | | o Much cleanly separate NetBSD(XS) / FreeBSD(CAM) codes. o Improve tagged queing support (full QTAG). o Improve quirk support. o Improve parity error retry. o Impliment wide negotheation. o Cmd link support. o Add copyright of CAM part. o Change for CAM_NEW_TRAN_CODE. o Work around for buggy KME UJDCD450. o stg: add disconnet condition. o nsp: use suspend I/O. and more. I thank Honda-san. conf/options.pc98: add CT_USE_RELOCATE_OFFSET and CT_BUS_WEIGHT dev/{ct,ncv,nsp,stg}/*_{pccard,isa}.c: add splcam() before calling attach/detach functions. Tested by: bsd-nomads Obtained from: NetBSD/pc98
* Merge with latest version of the Mylex 6+ driver.msmith2001-07-146-1420/+1318
| | | | | | | | | | | | | | - All sources are built in a single object, reducing namespace pollution. - Kill the ready queue, and handle a busy response to mly_start in callers rather than deferring the command. - Improve our interaction with CAM: - Don't advertise physical channels as SCSI busses by default. - use the SIM queue freeze capability rather than queueing CDBs internally. - force bus reprobe at module load time. - Clean up more resources in mly_free. - Tidy up debugging levels. - Tidy up handling of events (mostly just code cleanliness). - Use explanatory macros for operations on bus/target/channel numbers.
* Deal with the condition where we lose link in the middle of transmittingwpaul2001-07-121-1/+1
| | | | | | | | | | | | | | | a bunch of frames. In this case, the dc_link flag is cleared, and dc_start() stops draining the if_snd send queue, which results in lots of 'no buffers available' errors being reported to applications. The whole idea behind not draining the send queue until the link comes up was to avoid having the gratuitous ARP being lost while we're waiting for autoneg to complete after the interface is first brought up. As an optimization, change the test in dc_start() so that we only bail if dc_link is not set _and_ there are less than 10 packets in the send queue. If the queue has many frames in it, we need to drain them. If the queue has a small number of frames in it, we can hold off on sending them until the link comes up. MFC after: 1 week
* - Define a convenience macro ISTTYOPEN().yokota2001-07-121-21/+28
| | | | | | | - Slightly refine screen saver logic. No functional change. MFC after: 2 weeks
* Hmm. Let's try this on for size...mjacob2001-07-111-5/+11
| | | | | | | | | | | | | | | | | | | | We originally had it such that if the connection topology was FL-loop (public loop), we never looked at any local loop addresses. The reason for not doing that was fear or concern that we'd see the same local loop disks reflected from the name server and we'd attach them twice. However, when I recently hooked up a JBOD and a system to an ANCOR SA-8 switch, the disks did *not* show up on the fabric. So at least the ANCOR is screening those disks from appearing on the fabric. Now, it's possible this is a 'feature' of the ANCOR. When I get a chance, I'll check the Brocade (it's hard to do this on a low budget). In any case, if they *do* also show up on the fabric, we should simply elect to not log into them because we already have an entry for the local loop. There is relatively unexercised code just for this case. MFC after: 2 weeks
* Two optimizations:wpaul2001-07-101-10/+35
| | | | | | | | | | | | | 1) Bite the bullet, and allow unaligned accesses without buffer copies on the i386 platform. According to some tests run by Andrew Gallatin, the buffer copy performance hit is greater than the unaligned access performance hit (especially with jumbo frames). We still need to copy everywhere else. 2) Enable interrupt moderation with a 100us timeout. Submitted by: Andrew Gallatin <no longer at duke.edu> MFC after: 1 week
* Fix dependencies between kernel options:yokota2001-07-105-17/+26
| | | | | | | | | | - When both SC_PIXEL_MODE and SC_NO_FONT_LOADING are defined, quietly drop SC_NO_FONT_LOADING, because the pixel(raster) console requires font. - When SC_NO_FONT_LOADING is defined, force SC_ALT_MOUSE_IMAGE. Without font, the arrow-shaped mouse cursor cannot be drawn. - Fiddle and simplify some internal macros. MFC after: 2 weeks
* Somehow I missed this. Use INTR_TYPE_AV (high priority) instead ofpeter2001-07-091-1/+1
| | | | INTR_TYPE_TTY (lowest priority).
* Whoops; we get an ACPI_OBJECT back from evaluating a method, notmsmith2001-07-091-8/+6
| | | | | | an ACPI_OPERAND_OBJECT. Fix this so that the power resource type can be properly checked, and we can get the system level and resource order.
* Log when the user is turning debugging on/off.joerg2001-07-091-5/+9
| | | | | | | Also sanitize the TRACE* macros a bit so they syntactically behave like single C statements (even inside in `if' statement). Submitted by: des
* Hmpf, remove two variables that got unused by rev 1.214.joerg2001-07-091-2/+1
|
* Ouch, calculate correctly. With 300 rpm and 25 retries, it's 5 secondsjoerg2001-07-091-1/+1
| | | | till timeout.
* Remove parts of rev 1.211 again: do not delete our children iff theyjoerg2001-07-091-7/+0
| | | | | | haven't been probed successfully. It's a known bug that ISA hints processing instantiates those devices, and prematurely killing them has other unwanted side-effects.
* As des' example shows us, DMA overruns could happen in a situationjoerg2001-07-091-9/+37
| | | | | | | | where they will never succeed. Add a stop-gap measure that will at least eventually timeout the operation instead of retrying it indefinately. MFC after: 1 month
* Apply patch supplied by Jonathan Chen: use the correct arguments towpaul2001-07-097-13/+13
| | | | | pci_enable_io(). We need to use SYS_RES_IOPORT/SYS_RES_MEMORY instead of PCIM_CMD_PORTEN/PCIM_CMD_MEMEN.
* Another large patchset from Bruce.joerg2001-07-081-158/+113
| | | | | | | | | | | | | | | Despite of a few cosmetic things like adding ``irritating silly parentheses'' around all return values, this mainly improves FDC reset handling by no longer gratuitously resetting the FDC all the time (which causes it to lose the notion of the current track) but only in case of errors, and it sanitizes the block and offset calculations in fdstrategy() and fdstate(). Some additional cleanup added by me, in particular the large switch in fdstate() now always uses return to break out, and no branch falls off the end of the switch statement anymore. Per Bruce's suggestion, removed M_NOWAIT from the malloc()s to simplify things. Submitted by: bde (mostly)
* Do not set the MODE_1000 bit unless we actually have a gigabit link.wpaul2001-07-081-1/+9
| | | | | | | | | | Previously, I had the MODE_1000 bit in the global config register set unconditionally, which was wrong: we have to turn it off if we have a 10/100 link. This is now handled in the nge_miibus_statchg() routine. Discovered by: Nathan Binkert <binkertn@eecs.umich.edu> (Note: this commit is being done from JFK airport. :P )
* Nuke the ACPI APIC driver. The ACPI CA infrastructure it depended onmsmith2001-07-071-164/+0
| | | | | is gone, and it's not coming back, and the whole driver needed to be rethrought to deal with a major chicken-and-egg consideration.
* Fix typo in acpi_cpu_attach() and correct range checking iniwasaki2001-07-071-2/+2
| | | | acpi_cpu_speed_sysctl().
* Kill the old processor driver; the ACPI CA functions it depended onmsmith2001-07-072-669/+388
| | | | | are not coming back any time soon. Implement a new 'acpi_cpu' driver with support for CPU throttling and power policies.
* Add acpi_GetTableIntoBuffer, to aid in fetching tables.msmith2001-07-072-3/+25
|
* Get the ACPI softc before we potentially dereference it.msmith2001-07-071-5/+5
|
* Quiet the complaint about the _SCP method if it doesn't exist; it'smsmith2001-07-071-2/+3
| | | | not mandatory.
* Oops, have to use AcpiSetCurrentResources, not invoke the _SRS methodmsmith2001-07-072-8/+2
| | | | directly.
* Add support for user-requested override of cooling levels.msmith2001-07-071-80/+189
| | | | | | | | Monitor the system power profile, and use _SCP to adjust thermal zones accordingly. Simplify the behaviour of the timeout routine, and add some temporary debugging.
* Add support for system power profiles; select "performance" when AC powermsmith2001-07-072-2/+18
| | | | is available and "economy" when it is not.
* Support for system "power profiles". Currently we support two profiles;msmith2001-07-071-0/+64
| | | | "economy" and "performance".
* This was only half-implemented when I committed it, and certainly didn'tmsmith2001-07-061-30/+92
| | | | work. Now it's implemented and seems to work.
* Call ttymalloc() when sysmouse is opened, rather thanyokota2001-07-061-1/+1
| | | | | when the driver is attached. MFC after: 2 weeks
* Make these compile again by adding proc.h include for GIANT_REQUIREDjhb2001-07-056-0/+6
| | | | that is in included vm headers.
* Oops- missed a CAMLOCK_2_ISP case.mjacob2001-07-051-0/+1
|
* Things have become cinched down more tightly about assertions for Giant.mjacob2001-07-051-4/+22
| | | | | This uncovered some missing spots where I trade off between isp's lock and Giant as I enter CAM.
* Set vendor string correctly for the Apple KeyLargo.benno2001-07-051-0/+4
| | | | | Forgotten by: benno Spotted by: n_hibma
* Pull in the current version of NetBSD's ulpt.c, supporting bidirectionaln_hibma2001-07-051-83/+201
| | | | communication with printers.
* Regen.n_hibma2001-07-052-55/+353
|
* Pull in the most recent version of usb_quirks.h and propagate the necessaryn_hibma2001-07-058-194/+161
| | | | | | changes to the various files. Also, pull in most of the current usb_subr.c file.
* Make the string argument a const.n_hibma2001-07-051-2/+2
|
* Update with NetBSD versionn_hibma2001-07-051-20/+66
| | | | | | | Remove duplicates NOTE: USB_PRODUCT_SANDISK_IMAGEMATE has changed to USB_PRODUCT_SANDISK_SDDR05A
* Improve some error messages slightly.msmith2001-07-051-2/+5
|
* Implement PCI interrupt routing using the ACPI data attached to themsmith2001-07-052-10/+510
| | | | | | | | | PCI bus object. This should deal both with already-routed interrupts as well as devices that need an interrupt routed. Note that it *doesn't* deal with interlocked interrupt dependancies, nor does it select between interrupt options in a smart way. These are optimisations that need further work.
* Fix a couple of misunderstandings in the monitor code. Passive coolingmsmith2001-07-051-50/+131
| | | | | | | | | | is a parallel adjunct to active cooling, not a lesser evil. The _ACx levels sort from 0 being hottest, not coolest. Sanity check the returned temperature values, since we are having trouble reading them on some systems. Rearrange sysctl nodes a bit; this is probably close to the final layout.
* Add a new helper function for finding resources in resource buffers.msmith2001-07-053-198/+275
| | | | Move the ACPI generic battery code into a new file.
* Sync to pccarddevs 1.12imp2001-07-051-7/+68
|
* Merge from NetBSD:imp2001-07-051-4/+31
| | | | | | | | | | | | | | | | | | | | 1.131: crhistos; cn40bc ne clone 1.130: ichiro; COREGA FEther PCC-TXF 1.129: ichiro; nits 1.128: ichiro; National Instruments pcmcia GPIB 1.127: jhawk; Socket EA ethernet 1.126: ichiro; Intel PRO/Wireless 2001 LAN PC Card 1.125: ichiro; BUFFALO AirStation 11Mbps WLAN Card 1.124: ichiro; Corega FEther PCC-TXD 1.123: onoe; Cisco Aironet 350 Series 1.122: ichiro; I-O DATA WN-B11/PCM wlan 1.121: aymeric; Synergy 21 S21810+ 1.120: thorpej; D-LINK DMF-560TX 1.119: ichiro; typo 1.118: ichiro; some wavelan card 1.117: ichiro; Contec FLEXLAN/FX-DS100-PCC wavelan 1.116: ichiro; COMPAQ Wireless CARD NC5004(Prism2) 1.114: thorpej; Xircom CreditCard Token Ring II
* More cleanup when detaching. Clone device entries will now bejoerg2001-07-041-17/+41
| | | | | | | | | | | | | | | | | | | | | destroyed properly (otherwise bad things would happen after a clone dev had been created, and the module was kldunloaded). Allocated children that have not successfully probed are being deleted again (otherwise fd0 and fd1 have always been allocated, even if only fd0 was acutally present, and fd1 even survived kldunloading the module). Still, kldunloading leaves remnants of the previously existing devices intact. Why doesn't it destroy all the devices? As a consequence, since dev->descr now points into no longer allocated memory, the system panics deep inside printf(9) when running devinfo(1) after kldunloading the module. Ideas sought... Also, when kldloading the module on a hints-populated isab0, this bus somehow has already created an fdc0 entry (a dummy) so the load attempt fails and will register fdc1 instead. What are those dummy entries for? Loading the module from the bootloader works, and it can be unloaded an re-loaded then later.
* Add CAM_NEW_TRAN_CODE support. Use correct CAMLOCK_2_ISPLOCK macros.mjacob2001-07-041-31/+234
| | | | | | | | | For fibre channel, start going for the gusto and using AC_FOUND_DEVICE and AC_LOST_DEVICE calls to xpt_async when devices appear and disappear as the loop or fabric changes. ISPASYNC_FW_CRASH is the async event code where the platform layer deals with a firmware crash.
* Macroize request/response in/out queue pointer access.mjacob2001-07-041-1/+1
|
OpenPOWER on IntegriCloud