summaryrefslogtreecommitdiffstats
path: root/sys/cam
Commit message (Collapse)AuthorAgeFilesLines
* MFC r313736: Fix panic on shutdown of ramdisk LU with zero capacity.mav2017-02-211-1/+3
|
* MFC 313895:ken2017-02-201-0/+3
| | | | | | | | | | | | | | | ------------------------------------------------------------------------ r313895 | ken | 2017-02-17 13:15:27 -0700 (Fri, 17 Feb 2017) | 9 lines Make ctl(4) build with CTL_IO_DELAY defined. sys/cam/ctl/ctl.c: In ctl_datamove(), inside CTL_IO_DELAY, add a lun variable and fill it in before trying to dereference it. Sponsored by: Spectra Logic ------------------------------------------------------------------------
* MFC r312694: Make CTL ramdisk backend a real RAM disk.mav2017-02-071-205/+637
| | | | | | | | | | | | | | | | | If "capacity" LU option is set, ramdisk backend now implements featured thin provisioned disk, storing data in malloc(9) allocated memory blocks of pblocksize bytes (default PAGE_SIZE or 4KB). Additionally ~0.2% of LU size is used for indirection tree (bigger pblocksize reduce the overhead). Backend supports all unmap and anchor operations. If configured capacity is overflowed, proper error conditions are reported. If "capacity" LU option is not set, the backend operates mostly the same as before without allocating real storage: writes go to nowhere, reads return zeroes, reporting that all LBAs are unmapped. This backend is still mostly oriented on testing and benchmarking (it is still a volatile RAM disk), but now it should allow to run real FS tests, not only simple dumb dd.
* MFC r312603: Add initial support for CTL module unloading.mav2017-02-0713-196/+264
| | | | | | It is only a first step and not perfect, but better then nothing. The main blocker is CAM target frontend, that can not be unloaded, since CAM does not have mechanism to unregister periph driver now.
* MFC r312348: Remove writing 'residual' field of struct ctl_scsiio.mav2017-02-073-353/+75
| | | | | | | | | | This field has no practical use and never readed. Initiators already receive respective residual size from frontends. Removed field had different semantics, which looks useless, and was never passed through by any frontend. While there, fix kern_data_resid field support in case of HA, missed in r312291.
* MFC r312291, r312669:mav2017-02-0712-196/+122
| | | | | | | | | | | | | | Make CTL frontends report kern_data_resid for under-/overruns. It seems like kern_data_resid was never really implemented. This change finally does it. Now frontends update this field while transferring data, while CTL/backends getting it can more flexibly handle the result. At this point behavior should not change significantly, still reporting errors on write overrun, but that may be changed later, if we decide so. CAM target frontend still does not properly handle overruns due to CAM API limitations. We may need to add some fields to struct ccb_accept_tio to pass information about initiator requested transfer size(s).
* MFC r312343: Improve error message on duplicate iSCSI port.mav2017-02-071-1/+2
|
* MFC r296891 (by imp):mav2017-01-261-0/+7
| | | | | | | Make sure we check for CAM_CDB_POINTER for all drivers. Also, for the drivers I've touched, filter out CAM_CDB_PHYS. Differential Revision: https://reviews.freebsd.org/D5585
* MFC r312232: Add under-/overrun support to IOCTL and CAM SIM frontends.mav2017-01-262-13/+32
|
* MFC r312231: When in kernel, map ctl_scsi_zero_io() to ctl_zero_io().mav2017-01-262-4/+4
|
* MFC r312026: Improve CAM_CDB_POINTER support.mav2017-01-265-29/+18
|
* MFC r311873: Fix malloc(M_WAITOK) under mutex, introduced at r311787.mav2017-01-261-21/+17
|
* MFC r311804: Rewrite CTL statistics in more simple and scalable way.mav2017-01-266-130/+242
| | | | | | | | | | | | | Instead of collecting statistics for each combination of ports and logical units, that consumed ~45KB per LU with present number of ports, collect separate statistics for every port and every logical unit separately, that consume only 176 bytes per each single LU/port. This reduces struct ctl_lun size down to just 6KB. Also new IOCTL API/ABI does not hardcode number of LUs/ports, and should allow handling of very large quantities. Old API is still enabled in stable branches for compatibility reasons.
* MFC r311787: Allocate memory for prevent flags only for removable LUs.mav2017-01-262-5/+12
| | | | | This array takes 64KB of RAM now, that was more then half of struct ctl_lun size. If at some point we support more ports, this may need another tune.
* MFC r311680: Make CTL_GETSTATS ioctl return partial data if buffer is small.mav2017-01-261-12/+9
|
* MFC r310778, r310782: Improve use of I/O's private area.mav2017-01-266-286/+144
| | | | | | - Since I/Os are allocates from per-port pools, make allocations store pointer to CTL softc there, and use it where needed instead of global. - Created bunch of helper macros to access LUN, port and CTL softc.
* MFC r311892: Do not wait for HA thread shutdown if scheduler is stopped.mav2017-01-211-1/+1
| | | | This wait loop made system hang on panic instead of reboot.
* MFC r310649: Allow more efficient use of private area.mav2017-01-212-11/+16
| | | | There are 16 bytes of space, so we may store two pointers in one.
* MFC r310646: Do not update "saved" mode page on every MODE SELECT.mav2017-01-211-4/+1
| | | | | | We do not have non-volatile memory to really save those values, so we neither report nor support this capability. Also saved mode pages are not replicated between HA peers now.
* MFC r310644: Fix/synchronize field types in struct ctl_modepage_header.mav2017-01-212-3/+3
|
* MFC r310640, r310643:mav2017-01-214-10/+39
| | | | Add support for revert to defaults (RTD) bit in MODE SELECT.
* MFC r310635: Decouple limits on number of LUNs per port and LUs per CTL.mav2017-01-214-28/+49
| | | | | | | | Those two values are not directly related, so make them independent. This does not change any limits immediately, but makes number of LUNs per port controllable via tunable/sysctl kern.cam.ctl.lun_map_size. After this change increasing CTL_MAX_LUNS should be pretty cheap, and even making it tunable should be easy.
* MFC r310575: Fix improperly used nexus.targ_lun.mav2017-01-211-3/+3
|
* MFC r310555: Some random code cleaning.mav2017-01-211-189/+147
| | | | | | - Reduce indentation. - Remove extra braces. - Add few missing savety checks.
* MFC r310539: Remove CTL_MAX_LUNS from places where it is not required.mav2017-01-214-33/+34
|
* MFC r311636: Make 'camcontrol modepage' support subpages.mav2017-01-213-31/+46
|
* MFC r299864,r303166:ngie2017-01-171-2/+0
| | | | | | | | | | r299864 (by markj): opt_kdtrace.h is not needed for SDT probes as of r258541. r303166 (by imp): Add opt_ddb.h.
* MFC r311446: Fix bootverbose affecting code logic in r294558.mav2017-01-081-2/+3
| | | | Reported by: Jilles Tjoelker <jilles@stack.nl>
* MFC r305591: Decode ATA Status Return descriptor.mav2017-01-052-0/+75
|
* MFC r297756: Add couple new constants from SPC5r08.mav2017-01-051-0/+2
|
* MFC r310534: Improve third-party copy error reporting.mav2017-01-051-39/+155
| | | | | | | | | | For EXTENDED COPY: - improve parameters checking to report some errors before copy start; - forward sense data from copy target as descriptor in case of error; - report which CSCD reported error in sense key specific information. For WRITE USING TOKEN: - pass through real sense data from copy target instead of reporting our copy error, since for initiator its a "simple" write, not a copy.
* MFC r310524: Improve length handling when writing sense data.mav2017-01-056-328/+313
| | | | | | | - Allow maximal sense size limitation via Control Extension mode page. - When sense size limited, include descriptors atomically: whole or none. - Set new SDAT_OVFL bit if some descriptors don't fit the limit. - Report real written sense length instead of static maximal 252 bytes.
* MFC r310489: Implement printing forwarded sense data.mav2017-01-052-1/+28
|
* MFC r310478: Add place-holders for TAPE STREAM MIRRORING subcommands of XCOPY.mav2017-01-051-1/+50
| | | | We do not support tapes, so this is only a comments.
* MFC r310390: Add support for REPD bit in RSTMF command.mav2017-01-053-6/+47
| | | | We have no real timeout values to report there, but its better then error.
* MFC r310389:mav2017-01-052-45/+327
| | | | | | | Fix REPORT SUPPORTED OPERATION CODES for READ/WRITE BUFFER commands. Specifications require MODE parameter of those commands to be treated the same as SERVICE ACTION parameter of other commands.
* MFC r310373:mav2017-01-052-0/+15
| | | | Add support for REPORTING OPTIONS == 3 in REPORT SUPPORTED OPERATION CODES.
* MFC r310366: Add support for SITUA bit in Logical Block Provisioning mode page.mav2017-01-053-14/+21
| | | | | | | | | | VMware tries to enable this bit to avoid multiple threshold notifications in case of multiple initiators connected to the same LUN. Unfortunately their code sends MODE SELECT(6) request with parameter length hardcoded for the page without any thresholds. Since we have four threshold and our page is bigger, this attempt fails, that is correct in my understanding. So all we can do about this now is to report proper error code and hope VMware fix their code one day.
* MFC r310360, r310361: Report UUID and MD5 LUN IDs.mav2017-01-053-1/+46
|
* MFC r310356: Add support for locally assigned RFC 4122 UUID LUN identifiers.mav2017-01-051-1/+17
|
* MFC r310339: Bump specifications support to SAM-6/SPC-5.mav2017-01-052-5/+6
|
* MFC r310298: Improve error handling when I/O split between several BIOs.mav2017-01-051-4/+10
| | | | If we get several error codes, handle one with lowest offset.
* MFC r310285:mav2017-01-054-17/+34
| | | | | When reporting "Logical block address out of range" error, report the LBA in sense data INFORMATION field.
* MFC r310284:mav2017-01-051-5/+11
| | | | | | When writing fixed format sense data, set VALID bit only if provided value for INFORMATION field fit into available 4 bytes (has no non-zero bytes except last 4), as explicitly required by SPC-5 specification.
* MFC r310275: Fix typo in function name.mav2017-01-051-3/+3
|
* MFC r310272: Add new bits into Extended Inquiry VPD page.mav2017-01-052-5/+18
|
* MFC r310266: Add support for NUAR bit in Control mode page.mav2017-01-051-9/+9
|
* MFC r310265: Add set of macros to simplify code access to mode pages fields.mav2017-01-053-37/+33
|
* MFC r310259:mav2017-01-051-46/+34
| | | | | Following SPC-5, make REQUEST SENSE report "Logical unit not supported" in returned parameter data for not accessible LUNs.
* MFC r310257: Improve support for informational exceptions.mav2017-01-056-238/+240
| | | | | | | | | While CTL still has no real events to report in this way (like SMART), it is possible to trigger false event by manually setting TEST bit in Informational Exceptions Control mode page, that can be useful for initiator testing. This code supports all flavours of IE reporting: UNIT ATTENTION, RECOVERED ERROR and NO SENSE sense keys, REQUEST SENSE command and Informational Exceptions log page.
OpenPOWER on IntegriCloud