scsi_da.c (302408) | scsi_da.c (305614) |
---|---|
1/*- 2 * Implementation of SCSI Direct Access Peripheral driver for CAM. 3 * 4 * Copyright (c) 1997 Justin T. Gibbs. 5 * All rights reserved. 6 * 7 * Redistribution and use in source and binary forms, with or without 8 * modification, are permitted provided that the following conditions --- 13 unchanged lines hidden (view full) --- 22 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 23 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 24 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 25 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 26 * SUCH DAMAGE. 27 */ 28 29#include <sys/cdefs.h> | 1/*- 2 * Implementation of SCSI Direct Access Peripheral driver for CAM. 3 * 4 * Copyright (c) 1997 Justin T. Gibbs. 5 * All rights reserved. 6 * 7 * Redistribution and use in source and binary forms, with or without 8 * modification, are permitted provided that the following conditions --- 13 unchanged lines hidden (view full) --- 22 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 23 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 24 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 25 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 26 * SUCH DAMAGE. 27 */ 28 29#include <sys/cdefs.h> |
30__FBSDID("$FreeBSD: stable/11/sys/cam/scsi/scsi_da.c 301568 2016-06-07 20:33:55Z cem $"); | 30__FBSDID("$FreeBSD: stable/11/sys/cam/scsi/scsi_da.c 305614 2016-09-08 15:05:25Z pfg $"); |
31 32#include <sys/param.h> 33 34#ifdef _KERNEL 35#include <sys/systm.h> 36#include <sys/kernel.h> 37#include <sys/bio.h> 38#include <sys/sysctl.h> --- 5674 unchanged lines hidden (view full) --- 5713 uint16_t features_out; 5714 uint32_t sectors_out, auxiliary; 5715 int retval; 5716 5717 retval = 0; 5718 5719 if (use_ncq == 0) { 5720 command_out = ATA_ZAC_MANAGEMENT_OUT; | 31 32#include <sys/param.h> 33 34#ifdef _KERNEL 35#include <sys/systm.h> 36#include <sys/kernel.h> 37#include <sys/bio.h> 38#include <sys/sysctl.h> --- 5674 unchanged lines hidden (view full) --- 5713 uint16_t features_out; 5714 uint32_t sectors_out, auxiliary; 5715 int retval; 5716 5717 retval = 0; 5718 5719 if (use_ncq == 0) { 5720 command_out = ATA_ZAC_MANAGEMENT_OUT; |
5721 features_out = (zm_action & 0xf) | (zone_flags << 8), | 5721 features_out = (zm_action & 0xf) | (zone_flags << 8); |
5722 ata_flags = AP_FLAG_BYT_BLOK_BLOCKS; 5723 if (dxfer_len == 0) { 5724 protocol = AP_PROTO_NON_DATA; 5725 ata_flags |= AP_FLAG_TLEN_NO_DATA; 5726 sectors_out = 0; 5727 } else { 5728 protocol = AP_PROTO_DMA; 5729 ata_flags |= AP_FLAG_TLEN_SECT_CNT | --- 98 unchanged lines hidden (view full) --- 5828 int retval; 5829 5830 retval = 0; 5831 ata_flags = AP_FLAG_TDIR_FROM_DEV | AP_FLAG_BYT_BLOK_BLOCKS; 5832 5833 if (use_ncq == 0) { 5834 command_out = ATA_ZAC_MANAGEMENT_IN; 5835 /* XXX KDM put a macro here */ | 5722 ata_flags = AP_FLAG_BYT_BLOK_BLOCKS; 5723 if (dxfer_len == 0) { 5724 protocol = AP_PROTO_NON_DATA; 5725 ata_flags |= AP_FLAG_TLEN_NO_DATA; 5726 sectors_out = 0; 5727 } else { 5728 protocol = AP_PROTO_DMA; 5729 ata_flags |= AP_FLAG_TLEN_SECT_CNT | --- 98 unchanged lines hidden (view full) --- 5828 int retval; 5829 5830 retval = 0; 5831 ata_flags = AP_FLAG_TDIR_FROM_DEV | AP_FLAG_BYT_BLOK_BLOCKS; 5832 5833 if (use_ncq == 0) { 5834 command_out = ATA_ZAC_MANAGEMENT_IN; 5835 /* XXX KDM put a macro here */ |
5836 features_out = (zm_action & 0xf) | (zone_flags << 8), 5837 sectors_out = dxfer_len >> 9, /* XXX KDM macro*/ | 5836 features_out = (zm_action & 0xf) | (zone_flags << 8); 5837 sectors_out = dxfer_len >> 9; /* XXX KDM macro */ |
5838 protocol = AP_PROTO_DMA; 5839 ata_flags |= AP_FLAG_TLEN_SECT_CNT; 5840 auxiliary = 0; 5841 } else { 5842 ata_flags |= AP_FLAG_TLEN_FEAT; 5843 5844 command_out = ATA_RECV_FPDMA_QUEUED; 5845 sectors_out = ATA_RFPDMA_ZAC_MGMT_IN << 8; --- 51 unchanged lines hidden --- | 5838 protocol = AP_PROTO_DMA; 5839 ata_flags |= AP_FLAG_TLEN_SECT_CNT; 5840 auxiliary = 0; 5841 } else { 5842 ata_flags |= AP_FLAG_TLEN_FEAT; 5843 5844 command_out = ATA_RECV_FPDMA_QUEUED; 5845 sectors_out = ATA_RFPDMA_ZAC_MGMT_IN << 8; --- 51 unchanged lines hidden --- |