summaryrefslogtreecommitdiffstats
path: root/sys/cam
Commit message (Collapse)AuthorAgeFilesLines
* Retire the MALLOC and FREE macros. They are an abomination unto style(9).des2008-10-231-9/+9
| | | | MFC after: 3 months
* Replace all calls to minor() with dev2unit().ed2008-09-273-6/+6
| | | | | | | | | | | | | | | After I removed all the unit2minor()/minor2unit() calls from the kernel yesterday, I realised calling minor() everywhere is quite confusing. Character devices now only have the ability to store a unit number, not a minor number. Remove the confusion by using dev2unit() everywhere. This commit could also be considered as a bug fix. A lot of drivers call minor(), while they should actually be calling dev2unit(). In -CURRENT this isn't a problem, but it turns out we never had any problem reports related to that issue in the past. I suspect not many people connect more than 256 pieces of the same hardware. Reviewed by: kib
* Remove unit2minor() use from kernel code.ed2008-09-264-6/+6
| | | | | | | | | | | | | | | When I changed kern_conf.c three months ago I made device unit numbers equal to (unneeded) device minor numbers. We used to require bitshifting, because there were eight bits in the middle that were reserved for a device major number. Not very long after I turned dev2unit(), minor(), unit2minor() and minor2unit() into macro's. The unit2minor() and minor2unit() macro's were no-ops. We'd better not remove these four macro's from the kernel, because there is a lot of (external) code that may still depend on them. For now it's harmless to remove all invocations of unit2minor() and minor2unit(). Reviewed by: kib
* Add a new cam_status CAM_SCSI_IT_NEXUS_LOST. This will be used by future ↵sbruno2008-09-181-0/+1
| | | | | | | | | patches for target mode that are forthcoming. Reviewed by: Scott Long MFC after: 2 days
* Fix a locking mistake in daopen(). If the open fails, which can happenscottl2008-08-291-6/+7
| | | | | | | | because the media was removed, the periph would get its refcount dropped and ultimately freed before getting unlocked. This created a dangling pointer that was easy to trip over. This fixes a common source of crashes with removaable media, but problems remain and will get tracked down.
* SCSI_DELAY is specified in milliseconds, not seconds.ken2008-08-161-1/+1
| | | | | Submitted by: Andre Albsmeier <Andre.Albsmeier@siemens.com> MFC after: 1 week
* Update SCSI opcodes and ASCs from t10.org.jkim2008-08-072-1227/+2398
| | | | | | | | | | | | http://www.t10.org/lists/1spc-lst.htm Note opcodes for scanner and communication devices are taken from the previous revision because they are not listed in the files any more. Also, note newly added ASCs are all marked with 'XXX TBD' and take SS_RDEF action for now. Some ASCs need SS_TUR for error recovery or SS_FATAL to prevent further retrials. We should deal with them later. Reviewed by: scottl, ken
* Fix whitespace.emaste2008-08-011-2/+2
|
* Add quirk for the Samsung YP-U3remko2008-07-091-0/+8
| | | | | | | PR: 125398 Submitted by: Tino Engel <goaengel at gmx dot net> Approved by: imp (mentor, implicit) MFC after: 1 week
* Locking in the ses_ioctl handler doesn't have to be so strict becausescottl2008-03-171-21/+25
| | | | | | | | the referenced data is only obtained/changed in the device open handler, and the ioctl handler can only run after the open handler. Also fix a few nearby style issues. Submitted by: Matt Jacob
* When probing a newly found device, don't automatically assume that thescottl2008-02-271-36/+95
| | | | | | | | device supports retrieving a serial number. Instead, first query the list of VPD pages it does support, and only query the serial number if it's supported, else silently move on. This eliminates a lot of noise during verbose booting, and will likely eliminate the need for most NOSERIAL quirks.
* Add a missing unlock to an error path fro XPT_DEBUG handling.scottl2008-02-261-0/+1
|
* Fix a couple of locking mistakes in the ses_ioctl path.scottl2008-02-201-3/+3
| | | | Submitted by: Matt Jacob
* Fix typo.raj2008-02-121-1/+1
| | | | Approved by: cognet (mentor)
* Correct the kernel config hint in a printf statement.brueffer2008-01-281-1/+1
| | | | | | | Submitted by: R.Mahmatkhanov <cvs-src@yandex.ru> Reviewed by: scottl Approved by: rwatson (mentor) MFC after: 3 days
* o Correct EasyMP3 EM732X usb 2.0 flash mp3 player revision:maxim2008-01-121-1/+1
| | | | | | | | it's 1.00 not 1.0. PR: usb/96546 Submitted by: Eugene Grosbein MFC after: 1 month
* style(9)obrien2008-01-021-73/+73
|
* Add a new 'why' argument to kdb_enter(), and a set of constants to userwatson2007-12-251-1/+1
| | | | | | | | | for that argument. This will allow DDB to detect the broad category of reason why the debugger has been entered, which it can use for the purposes of deciding which DDB script to run. Assign approximate why values to all current consumers of the kdb_enter() interface.
* Add a missing mutex unlock.scottl2007-12-161-0/+1
| | | | Reported by: Michael Jung
* Add quirks for Netac Onlydisk 2000 USB disk.davidxu2007-12-111-0/+4
|
* Fix a change in the previous commit that was actually a type-o.scottl2007-11-151-1/+1
|
* Rename the kthread_xxx (e.g. kthread_create()) callsjulian2007-10-201-1/+1
| | | | | | | | | | | to kproc_xxx as they actually make whole processes. Thos makes way for us to add REAL kthread_create() and friends that actually make theads. it turns out that most of these calls actually end up being moved back to the thread version when it's added. but we need to make this cosmetic change first. I'd LOVE to do this rename in 7.0 so that we can eventually MFC the new kthread_xxx() calls.
* Add a bunch of definitions and structures to support newer drivers.scottl2007-10-121-1/+110
|
* Do not forget to cam_periph_unhold the peripheral before exitingkan2007-07-211-2/+5
| | | | | | | | due to error. PR: kern/114636 Submitted by: Tijl Coosemans Approved by: re (hrs)
* After talking with njl@, change this wildcard entry to be a bit less wild.imp2007-07-011-1/+1
| | | | Approved by: re (blanket)
* Quirk for WD Mybook. Seems they do not like serial number queries.imp2007-06-301-0/+12
| | | | | | Submitted by: Jason Harris PR: 107495 Approved by: re@ (blanket)
* Quirk for ChipsBnk usb stickimp2007-06-301-0/+8
| | | | | | Submitted by: Mark Andrews PR: 103702 Approved by: re@ (blanket)
* Add quirk for JoyFly 128mb USB Flash Driveimp2007-06-301-0/+8
| | | | | | submitted by: Toni Schmidbauer PR: 96133 Approved by: re@ (blanket)
* quirk for I/O Magic USB flash drive "Giga Bank"imp2007-06-301-0/+8
| | | | | | Submitted by: Jeff Anton PR: 108810 Approved by: re@ (blanket)
* Samsung MP0402H quirkimp2007-06-301-0/+8
| | | | | | Submitted by: Gipsy<wint3r@securimail.com> PR: 108427 Approved by: re@ (blanket)
* Add support for JNC MP3 Playerimp2007-06-301-0/+8
| | | | | | Submitted by: User & <dhenin@cypries.cyclopes.org> PR: 94439 Approved by: re (blanket)
* Philips USB Key Audio KEY013imp2007-06-301-0/+8
| | | | | | Submitted by: Arnoud Engelfriet PR: 68412 Approved by: re (blanket)
* Support for iRiver U10 USB connectionimp2007-06-281-0/+8
| | | | | | PR: 92306 Submitted by: Soren Dossing Approved by: re (blanket)
* Quirk for Denver MP3 player usb.imp2007-06-281-0/+8
| | | | | | Submitted by: Ed Schouten PR: 107101 Approved by: re (blanket for device supprot)
* Prepare for future integration between CAM and newbus. xpt_bus_registerscottl2007-06-173-4/+6
| | | | | | | now takes a device_t to be the parent of the bus that is being created. Most SIMs have been updated with a reasonable argument, but a few exceptions just pass NULL for now. This argument isn't used yet and the newbus integration likely won't be ready until after 7.0-RELEASE.
* Revert an accidental change from the previous rev.scottl2007-06-161-2/+1
|
* Work around the other uses of M_WAITOK.scottl2007-06-162-4/+11
|
* Work around a malloc locking problem.scottl2007-06-161-1/+6
|
* Commit for Nate his "guidelines for submitting quirks".mjacob2007-06-101-2/+210
|
* Despite several examples in the kernel, the third argument ofdwmalone2007-06-042-2/+2
| | | | | | | | | | | | | sysctl_handle_int is not sizeof the int type you want to export. The type must always be an int or an unsigned int. Remove the instances where a sizeof(variable) is passed to stop people accidently cut and pasting these examples. In a few places this was sysctl_handle_int was being used on 64 bit types, which would truncate the value to be exported. In these cases use sysctl_handle_quad to export them and change the format to Q so that sysctl(1) can still print them.
* Add a placeholder document to be filled out by Nate which will describemjacob2007-05-291-0/+4
| | | | in detail the procedure for getting device quirks into the CAM subsystem.
* Back out 1.212 at Nate's request in order to go through themjacob2007-05-291-9/+0
| | | | actual formal process he's trying to get established for quirks..
* Use the Hitachi 2.5" HD, 120 GB as a USB device.mjacob2007-05-291-0/+9
| | | | | Submitted by: Joakim Bentholm` MFC after: 3 days
* Remove duplicate includes.cognet2007-05-232-3/+0
| | | | Submitted by: Cyril Nguyen Huu <cyril ci0 org>
* Zero scsi_readcapacity allocations so we can reallymjacob2007-05-181-4/+3
| | | | | | | tell if there has been data returned (for some broken residual checking points). MFC after: 3 days
* Release the bus reference that is acquired when doing a CAMIOCOMMANDscottl2007-05-161-0/+1
| | | | ioctl. This should make SIM removal a bit more robust.
* Remove an assertion in xpt_print_path() that makes debugging code much morescottl2007-05-161-1/+0
| | | | difficult.
* Add a helper function for registering async callbacks. Besidesscottl2007-05-1611-272/+70
| | | | eliminating a lot of duplicated code, this also fixes a locking edge case.
* Eliminate the use of M_TEMP.scottl2007-05-146-115/+122
|
* Only schedule the xpt_finishconfig_task once. This fixes some potentialscottl2007-04-271-4/+6
| | | | panics on boot.
OpenPOWER on IntegriCloud