summaryrefslogtreecommitdiff
path: root/sys/dev/ic
AgeCommit message (Collapse)Author
2011-05-24Move wdc_cd from ata/ata_wdc.c to ic/wdc.c so that you can compile aMatthew Dempsky
kernel without the former. Also, eliminate two dead stores in wdcattach(). ok dlg@
2011-05-23Fix after poolification. For reasons not completely understood, theOtto Moerbeek
fifo full check has to be protected by the mutex. ok dlg@ krw@
2011-05-22Fix a problem found where one SOC has a uart implementation that causes busDale Rahn
errors if the fifo is read when the fifo is empty. Dont read an empty fifo. ok deraaadt@ fgsch@
2011-05-20Avoid double scsi_done(xs) in error path; ok dlg@ krw@Otto Moerbeek
2011-05-09Refactor queue allocation and initialization into a wdc_alloc_queue()Matthew Dempsky
function, and let attachment code calls this rather than malloc(9). This prevents re-initialization of the queue in shared queue chipsets. Also, add wdc_free_queue() as a complementary function. Earlier version (without wdc_free_queue()) tested by sthen@ and Amit Kulkarni on various pciide(4) chips. ok dlg@
2011-05-09Initialize the wdc ata_drive_datas structs earlier in wdcattach() soMatthew Dempsky
that chip-specific drv_probe routines can assume they've already been initialized. Tested by sthen@ on i386, armish, and amd64, with both affected and non-affected pciide(4) chips. ok dlg@
2011-05-08Move ata_put_xfer() from ata_xfer to atascsi_methods. It's just sillyMatthew Dempsky
to have a non-changing function pointer be part of an object rather than it's virtual method table. ok dlg@; tested on ahci(4) by Mattieu Baptiste, jasper@, and Jason Crawford; no sili(4) testers, but identical changes to ahci(4)
2011-05-08Eliminate a few unused wdc capability flags (WDC_CAPABILITY_HWLOCK,Matthew Dempsky
WDC_CAPABILITY_ATA_NOSTREAM, and WDC_CAPABILITY_ATAPI_NOSTREAM). ok dlg@, jsg@, krw@
2011-04-27kill a !__NetBSD__ ifdef which just confusesTheo de Raadt
2011-04-27if getting the RAID header fails, dont stop the midlayer from trying toDavid Gwynne
issues scsi commands against that target. it might be a normal device and the firmware is just being picky about which headers you can fetch. tested by and ok deraadt@
2011-04-27configure fc controllers to fail io as fast as possible when cables areDavid Gwynne
yanked. we want to reschedule them down active paths rather than wait for a minute while mpi decides that a path isnt coming back. discussed with and tested by deraadt@
2011-04-27return XS_RESET to the midlayer if the command was killed for some reasonDavid Gwynne
rather than the default of XS_DRIVER_STUFFUP. mpath(4) likes this better when you unplug paths.
2011-04-27rework the scanning of fibre channel ports to match how linux does it.David Gwynne
some fc parts dont like the header requests against missing devices with bus addressing, so now we do the magic iteration over active ports. the original problem was reported by deraadt@ lots of testing and debugging by deraadt@ tested on fc929 and fc949 adapters
2011-04-27No need to splbio/splx in the interrupt routine. It's alreadyKenneth R Westerback
done around the manual invocation. Prompted by dlg@.
2011-04-26No point in a per-attachment scsi_adapter; move to global dpt_switchMatthew Dempsky
like we do in other SCSI drivers.
2011-04-26A plausible attempt at iopoolifying dpt(4).Matthew Dempsky
ok dlg@; miod@ warns me to not hold my breath on anyone testing this diff though...
2011-04-26Make dpt(4) compile on 64-bit arches; no binary change on i386.Matthew Dempsky
2011-04-26Get rid of NetBSD/OpenBSD ifdefs; our SCSI stacks have diverged tooMatthew Dempsky
much for them to make sense anymore. Diff prepared with sed; no change to dpt.o on i386.
2011-04-26Iopoolification. Installed snapshot over it and it even booted.Kenneth R Westerback
ok dlg@ matthew@
2011-04-21A plausible iopoolification. Utter dearth of interested partiesKenneth R Westerback
after more than a year of grovelling emails shows further effort is pointless. ok matthew@ dlg@
2011-04-19Iopoolification. Much simpler version than the one revived at k2k11.Kenneth R Westerback
This one works. For me at least. Botch spotted by matthew@. ok matthew@ dlg@
2011-04-19Fix potential null dereference.Charles Longeau
Found by LLVM/Clang Static Analyzer. ok marco@ krw@
2011-04-19Cease to pretend RAW SCSI mode exists. Eradicate all traces.Kenneth R Westerback
2011-04-18keep an eye out for wdc registers returning 0xff. if they return 0xff,Theo de Raadt
this probably means the controller is dead -- as in, a hot plug eject event. in that case, mark the driver dead and try harder to return -1 in the interrupt handler. tested by many ok dlg, miod did not object
2011-04-17Add wol support to xl(4). Not really tested, but hopefully someone willStefan Sperling
test it now that it's in-tree. ok deraadt ("It causes no harm")
2011-04-17Don't increase if_oerrors for every multicast frame leaving the interface.Stefan Sperling
ok deraadt
2011-04-16Initialize variables before use.Kenneth R Westerback
2011-04-15Change wdc_reset_channel() to take a `no wait' argument. Pass in turn thisMiod Vallat
argument to wdcreset(), to have it skip waiting until active channels see their BUSY bit clear in the status register. Use this feature in the resume path, during the first reset operation. The first reset is supposed to only wake up the controller, and the disks don't come back until the second reset is issued, therefore waiting for them to report themselves as ready after the first reset, but before the second, is moot - and as a matter of fact some controllers, such as the AMD 754 and clones/offspring (e.g. Geode) keep the BUSY bit asserted after the first reset. Last, but not least, make sure wd@ata invokes wd_get_params() again before returning from the resume code, as we will still be using polled transfers for a short while. This causes the Lemote Yeelong to resume within less than one second, instead of the lousy 30 seconds wait between the two resets; and the wd_get_params() voodoo prevents it from getting spurious ide interrupts afterwards. wd_get_params() magic from dlg; rest of the work by yours truly after enough prodding by dlg@ and pirofti@, among others. ok deraadt@ dlg@
2011-04-14Add several additional adapter types and correct definition ofJonathan Gray
RTL8103E, from FreeBSD. ok sthen@
2011-04-11Fix SPL handling when PCDISPLAY_SOFTCURSOR is enabled.Matthew Dempsky
Discovered, narrowed down, and tested by jmc@. "definitely commit that" deraadt@, ok miod@
2011-04-09add all 64 bit dma plumbing but stick with 32 for now by default.Marco Peereboom
ok deraadt
2011-04-09make sure the upper 32 bits are always written to instead of assuming itMarco Peereboom
is 0. ok deraadt.
2011-04-08more spacesMarco Peereboom
2011-04-08kill some stray spacesMarco Peereboom
2011-04-08rename wiat channel to something less than 8 chars.Marco Peereboom
prompted by deraadt
2011-04-08use dma_alloc for transient management commands.Marco Peereboom
prodded and ok deraadt
2011-04-07Do not use NULL in integer comparisons. No functional change.Miod Vallat
ok matthew@ tedu@, also eyeballed by at least krw@ oga@ kettenis@ jsg@
2011-04-07Make sure the eeprom pointer is correctly initialized inMiod Vallat
ar9380_spur_mitigate_ofdm().
2011-04-06Correctly protect the arguments of the AIC_ASSERT() macro.Miod Vallat
2011-04-05pull the dmamam wrapper in from all my other drivers and use it to replaceDavid Gwynne
the siop command buffers and add dmaable buffers for sense data. matthew@ found that siop used to try to dma to the xs->sense bufer, which is not guaranteed to be dma safe. tested by matthew@ kettenis@
2011-04-05wd_hibernate_io() is a standalone disk io writer which tries to notTheo de Raadt
damage kernel memory very much while doing the job. It is not very pretty yet, but improving it will need some MI work. ok mlarkin jsg dlg
2011-04-05- use nitems() no binary change on amd64Jasper Lievisse Adriaanse
"reads OK" claudio@
2011-04-05mechanic rename M_{TCP|UDP}V4_CSUM_OUT -> M_{TCP|UDP}_CSUM_OUTHenning Brauer
ok claudio krw
2011-04-05add a scsi probe routine so isp(4) can reject high luns when the midlayerDavid Gwynne
is probing, rather than every time it issues an io. ok krw@
2011-04-05Deep below wdc_ioc_ata_cmd() it is possible that some controller (present orTheo de Raadt
future) will try to dma the command buffer to the disk in some way. Use dma_alloc() to get ahead of this potential failure path. ok dlg krw
2011-04-04Kill some #if 0'ed code (the 'raw' scsi path). Move splx()Kenneth R Westerback
to before scsi_done(). This doesn't mean aac will ever enabled! ok dlg@
2011-04-03move twe over to iopools so we can get rid of another NO_CCB user. thisDavid Gwynne
also cuts the aen drain over to using an iohandler so it can be made reliable. this compiles, but i havent got hardware to test with. its going in as a way to force testing. if there's a problem with the code then let me know or back it out. "man up" k2k11
2011-04-03Sprinkle spltty around code which plays with either the video memory orMiod Vallat
the backing store. The state of a VT is only coherent if both the active flag and the backing store are in order, which is not the case during VT switches. This fixes display glitches occuring during VT switches if one of the VT involved is doing a lot of tty updates. Noticed by deraadt@ on a machine too fast for mere mortals.
2011-04-03Iopoolification of some less common scsi drivers.Kenneth R Westerback
ok dlg@ ("miod will not object" dlg@)
2011-03-23only read from the UART if there is something to read. fix beagle, otherwiseFederico G. Schwindt
it will crash with 'External Non-Linefetch Abort (S)'. similar diff provided by drahn@. tested by jasper@, deraadt@ ok.