1e76d6180SDave Jiang /* 2e76d6180SDave Jiang * This file is provided under a dual BSD/GPLv2 license. When using or 3e76d6180SDave Jiang * redistributing this file, you may do so under either license. 4e76d6180SDave Jiang * 5e76d6180SDave Jiang * GPL LICENSE SUMMARY 6e76d6180SDave Jiang * 7e76d6180SDave Jiang * Copyright(c) 2008 - 2011 Intel Corporation. All rights reserved. 8e76d6180SDave Jiang * 9e76d6180SDave Jiang * This program is free software; you can redistribute it and/or modify 10e76d6180SDave Jiang * it under the terms of version 2 of the GNU General Public License as 11e76d6180SDave Jiang * published by the Free Software Foundation. 12e76d6180SDave Jiang * 13e76d6180SDave Jiang * This program is distributed in the hope that it will be useful, but 14e76d6180SDave Jiang * WITHOUT ANY WARRANTY; without even the implied warranty of 15e76d6180SDave Jiang * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 16e76d6180SDave Jiang * General Public License for more details. 17e76d6180SDave Jiang * 18e76d6180SDave Jiang * You should have received a copy of the GNU General Public License 19e76d6180SDave Jiang * along with this program; if not, write to the Free Software 20e76d6180SDave Jiang * Foundation, Inc., 51 Franklin St - Fifth Floor, Boston, MA 02110-1301 USA. 21e76d6180SDave Jiang * The full GNU General Public License is included in this distribution 22e76d6180SDave Jiang * in the file called LICENSE.GPL. 23e76d6180SDave Jiang * 24e76d6180SDave Jiang * BSD LICENSE 25e76d6180SDave Jiang * 26e76d6180SDave Jiang * Copyright(c) 2008 - 2011 Intel Corporation. All rights reserved. 27e76d6180SDave Jiang * All rights reserved. 28e76d6180SDave Jiang * 29e76d6180SDave Jiang * Redistribution and use in source and binary forms, with or without 30e76d6180SDave Jiang * modification, are permitted provided that the following conditions 31e76d6180SDave Jiang * are met: 32e76d6180SDave Jiang * 33e76d6180SDave Jiang * * Redistributions of source code must retain the above copyright 34e76d6180SDave Jiang * notice, this list of conditions and the following disclaimer. 35e76d6180SDave Jiang * * Redistributions in binary form must reproduce the above copyright 36e76d6180SDave Jiang * notice, this list of conditions and the following disclaimer in 37e76d6180SDave Jiang * the documentation and/or other materials provided with the 38e76d6180SDave Jiang * distribution. 39e76d6180SDave Jiang * * Neither the name of Intel Corporation nor the names of its 40e76d6180SDave Jiang * contributors may be used to endorse or promote products derived 41e76d6180SDave Jiang * from this software without specific prior written permission. 42e76d6180SDave Jiang * 43e76d6180SDave Jiang * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 44e76d6180SDave Jiang * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 45e76d6180SDave Jiang * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 46e76d6180SDave Jiang * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 47e76d6180SDave Jiang * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 48e76d6180SDave Jiang * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 49e76d6180SDave Jiang * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 50e76d6180SDave Jiang * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 51e76d6180SDave Jiang * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 52e76d6180SDave Jiang * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 53e76d6180SDave Jiang * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 54e76d6180SDave Jiang */ 55e76d6180SDave Jiang 56e76d6180SDave Jiang #ifndef _SCI_SAS_H_ 57e76d6180SDave Jiang #define _SCI_SAS_H_ 58e76d6180SDave Jiang /* 59e76d6180SDave Jiang * SATA FIS Types These constants depict the various SATA FIS types devined in 60e76d6180SDave Jiang * the serial ATA specification. 61e76d6180SDave Jiang * XXX: This needs to go into <scsi/sas.h> 62e76d6180SDave Jiang */ 63e76d6180SDave Jiang #define FIS_REGH2D 0x27 64e76d6180SDave Jiang #define FIS_REGD2H 0x34 65e76d6180SDave Jiang #define FIS_SETDEVBITS 0xA1 66e76d6180SDave Jiang #define FIS_DMA_ACTIVATE 0x39 67e76d6180SDave Jiang #define FIS_DMA_SETUP 0x41 68e76d6180SDave Jiang #define FIS_BIST_ACTIVATE 0x58 69e76d6180SDave Jiang #define FIS_PIO_SETUP 0x5F 70e76d6180SDave Jiang #define FIS_DATA 0x46 71e76d6180SDave Jiang 72*af5ae893SDave Jiang /**************************************************************************/ 73*af5ae893SDave Jiang #define SSP_RESP_IU_MAX_SIZE 280 74*af5ae893SDave Jiang 750cfa890eSDave Jiang /* 760cfa890eSDave Jiang * contents of the SSP COMMAND INFORMATION UNIT. 770cfa890eSDave Jiang * For specific information on each of these individual fields please 780cfa890eSDave Jiang * reference the SAS specification SSP transport layer section. 790cfa890eSDave Jiang * XXX: This needs to go into <scsi/sas.h> 800cfa890eSDave Jiang */ 810cfa890eSDave Jiang struct ssp_cmd_iu { 820cfa890eSDave Jiang u8 LUN[8]; 830cfa890eSDave Jiang u8 add_cdb_len:6; 840cfa890eSDave Jiang u8 _r_a:2; 850cfa890eSDave Jiang u8 _r_b; 860cfa890eSDave Jiang u8 en_fburst:1; 870cfa890eSDave Jiang u8 task_prio:4; 880cfa890eSDave Jiang u8 task_attr:3; 890cfa890eSDave Jiang u8 _r_c; 900cfa890eSDave Jiang 910cfa890eSDave Jiang u8 cdb[16]; 920cfa890eSDave Jiang } __packed; 930cfa890eSDave Jiang 940cfa890eSDave Jiang /* 950cfa890eSDave Jiang * contents of the SSP TASK INFORMATION UNIT. 960cfa890eSDave Jiang * For specific information on each of these individual fields please 970cfa890eSDave Jiang * reference the SAS specification SSP transport layer section. 980cfa890eSDave Jiang * XXX: This needs to go into <scsi/sas.h> 990cfa890eSDave Jiang */ 1000cfa890eSDave Jiang struct ssp_task_iu { 1010cfa890eSDave Jiang u8 LUN[8]; 1020cfa890eSDave Jiang u8 _r_a; 1030cfa890eSDave Jiang u8 task_func; 1040cfa890eSDave Jiang u8 _r_b[4]; 1050cfa890eSDave Jiang u16 task_tag; 1060cfa890eSDave Jiang u8 _r_c[12]; 1070cfa890eSDave Jiang } __packed; 1080cfa890eSDave Jiang 109e76d6180SDave Jiang #endif 110