linux/drivers/scsi/esas2r/atioctl.h

/*  linux/drivers/scsi/esas2r/atioctl.h
 *      ATTO IOCTL Handling
 *
 *  Copyright (c) 2001-2013 ATTO Technology, Inc.
 *  (mailto:[email protected])
 */
/*=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=*/
/*
 *  This program is free software; you can redistribute it and/or modify
 *  it under the terms of the GNU General Public License as published by
 *  the Free Software Foundation; version 2 of the License.
 *
 *  This program is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *  GNU General Public License for more details.
 *
 *  NO WARRANTY
 *  THE PROGRAM IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR
 *  CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT
 *  LIMITATION, ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT,
 *  MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is
 *  solely responsible for determining the appropriateness of using and
 *  distributing the Program and assumes all risks associated with its
 *  exercise of rights under this Agreement, including but not limited to
 *  the risks and costs of program errors, damage to or loss of data,
 *  programs or equipment, and unavailability or interruption of operations.
 *
 *  DISCLAIMER OF LIABILITY
 *  NEITHER RECIPIENT NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY
 *  DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
 *  DAMAGES (INCLUDING WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND
 *  ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
 *  TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE
 *  USE OR DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED
 *  HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES
 *
 *  You should have received a copy of the GNU General Public License
 *  along with this program; if not, write to the Free Software
 *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 */
/*=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=*/

#include "atvda.h"

#ifndef ATIOCTL_H
#define ATIOCTL_H

#define EXPRESS_IOCTL_SIGNATURE
#define EXPRESS_IOCTL_SIGNATURE_SIZE

/* structure definitions for IOCTls */

struct __packed atto_express_ioctl_header {};

/*
 * NOTE - if channel == 0xFF, the request is
 * handled on the adapter it came in on.
 */
#define MAX_NODE_NAMES

struct __packed atto_firmware_rw_request {};

struct __packed atto_param_rw_request {};

#define MAX_CHANNEL

struct __packed atto_channel_list {};

struct __packed atto_channel_info {};

/*
 * CSMI control codes
 * class independent
 */
#define CSMI_CC_GET_DRVR_INFO
#define CSMI_CC_GET_CNTLR_CFG
#define CSMI_CC_GET_CNTLR_STS
#define CSMI_CC_FW_DOWNLOAD

/* RAID class */
#define CSMI_CC_GET_RAID_INFO
#define CSMI_CC_GET_RAID_CFG

/* HBA class */
#define CSMI_CC_GET_PHY_INFO
#define CSMI_CC_SET_PHY_INFO
#define CSMI_CC_GET_LINK_ERRORS
#define CSMI_CC_SMP_PASSTHRU
#define CSMI_CC_SSP_PASSTHRU
#define CSMI_CC_STP_PASSTHRU
#define CSMI_CC_GET_SATA_SIG
#define CSMI_CC_GET_SCSI_ADDR
#define CSMI_CC_GET_DEV_ADDR
#define CSMI_CC_TASK_MGT
#define CSMI_CC_GET_CONN_INFO

/* PHY class */
#define CSMI_CC_PHY_CTRL

/*
 * CSMI status codes
 * class independent
 */
#define CSMI_STS_SUCCESS
#define CSMI_STS_FAILED
#define CSMI_STS_BAD_CTRL_CODE
#define CSMI_STS_INV_PARAM
#define CSMI_STS_WRITE_ATTEMPTED

/* RAID class */
#define CSMI_STS_INV_RAID_SET

/* HBA class */
#define CSMI_STS_PHY_CHANGED
#define CSMI_STS_PHY_UNCHANGEABLE
#define CSMI_STS_INV_LINK_RATE
#define CSMI_STS_INV_PHY
#define CSMI_STS_INV_PHY_FOR_PORT
#define CSMI_STS_PHY_UNSELECTABLE
#define CSMI_STS_SELECT_PHY_OR_PORT
#define CSMI_STS_INV_PORT
#define CSMI_STS_PORT_UNSELECTABLE
#define CSMI_STS_CONNECTION_FAILED
#define CSMI_STS_NO_SATA_DEV
#define CSMI_STS_NO_SATA_SIGNATURE
#define CSMI_STS_SCSI_EMULATION
#define CSMI_STS_NOT_AN_END_DEV
#define CSMI_STS_NO_SCSI_ADDR
#define CSMI_STS_NO_DEV_ADDR

/* CSMI class independent structures */
struct atto_csmi_get_driver_info {};

struct atto_csmi_get_pci_bus_addr {};

struct atto_csmi_get_cntlr_cfg {};

struct atto_csmi_get_cntlr_sts {};

struct atto_csmi_fw_download {};

/* CSMI RAID class structures */
struct atto_csmi_get_raid_info {};

struct atto_csmi_raid_drives {};

struct atto_csmi_get_raid_cfg {};

/* CSMI HBA class structures */
struct atto_csmi_phy_entity {};

struct atto_csmi_get_phy_info {};

struct atto_csmi_set_phy_info {};

struct atto_csmi_get_link_errors {};

struct atto_csmi_smp_passthru {};

struct atto_csmi_ssp_passthru_sts {};

struct atto_csmi_ssp_passthru {};

struct atto_csmi_stp_passthru_sts {};

struct atto_csmi_stp_passthru {};

struct atto_csmi_get_sata_sig {};

struct atto_csmi_get_scsi_addr {};

struct atto_csmi_get_dev_addr {};

struct atto_csmi_task_mgmt {};

struct atto_csmi_get_conn_info {};

/* CSMI PHY class structures */
struct atto_csmi_character {};

struct atto_csmi_pc_ctrl {};

struct atto_csmi_phy_ctrl {};

atto_ioctl_csmi;

struct atto_csmi {};

struct atto_module_info {};

#define ATTO_FUNC_GET_ADAP_INFO
#define ATTO_VER_GET_ADAP_INFO0
#define ATTO_VER_GET_ADAP_INFO

struct __packed atto_hba_get_adapter_info {};

#define ATTO_FUNC_GET_ADAP_ADDR
#define ATTO_VER_GET_ADAP_ADDR0
#define ATTO_VER_GET_ADAP_ADDR

struct __packed atto_hba_get_adapter_address {};

#define ATTO_FUNC_MEM_RW
#define ATTO_VER_MEM_RW0
#define ATTO_VER_MEM_RW

struct __packed atto_hba_memory_read_write {};

#define ATTO_FUNC_TRACE
#define ATTO_VER_TRACE0
#define ATTO_VER_TRACE1
#define ATTO_VER_TRACE

struct __packed atto_hba_trace {};

#define ATTO_FUNC_SCSI_PASS_THRU
#define ATTO_VER_SCSI_PASS_THRU0
#define ATTO_VER_SCSI_PASS_THRU

struct __packed atto_hba_scsi_pass_thru {};

#define ATTO_FUNC_GET_DEV_ADDR
#define ATTO_VER_GET_DEV_ADDR0
#define ATTO_VER_GET_DEV_ADDR

struct __packed atto_hba_get_device_address {};

/* The following functions are supported by firmware but do not have any
 * associated driver structures
 */
#define ATTO_FUNC_PHY_CTRL
#define ATTO_FUNC_CONN_CTRL
#define ATTO_FUNC_ADAP_CTRL
#define ATTO_VER_ADAP_CTRL0
#define ATTO_VER_ADAP_CTRL

struct __packed atto_hba_adap_ctrl {};

#define ATTO_FUNC_GET_DEV_INFO
#define ATTO_VER_GET_DEV_INFO0
#define ATTO_VER_GET_DEV_INFO

struct __packed atto_hba_sas_device_info {};

atto_hba_device_info;

struct __packed atto_hba_get_device_info {};

struct atto_ioctl {};

struct __packed atto_ioctl_vda_scsi_cmd {};

struct __packed atto_ioctl_vda_flash_cmd {};

struct __packed atto_ioctl_vda_diag_cmd {};

struct __packed atto_ioctl_vda_cli_cmd {};

struct __packed atto_ioctl_vda_smp_cmd {};

struct __packed atto_ioctl_vda_cfg_cmd {};

struct __packed atto_ioctl_vda_mgt_cmd {};

struct __packed atto_ioctl_vda_gsv_cmd {};

struct __packed atto_ioctl_vda {};

struct __packed atto_ioctl_smp {};

struct __packed atto_express_ioctl {};

/* The struct associated with the code is listed after the definition */
#define EXPRESS_IOCTL_MIN
#define EXPRESS_IOCTL_RW_FIRMWARE
#define EXPRESS_IOCTL_READ_PARAMS
#define EXPRESS_IOCTL_WRITE_PARAMS
#define EXPRESS_IOCTL_FC_API
#define EXPRESS_IOCTL_GET_CHANNELS
#define EXPRESS_IOCTL_CHAN_INFO
#define EXPRESS_IOCTL_DEFAULT_PARAMS
#define EXPRESS_ADDR_MEMORY
#define EXPRESS_RW_MEMORY
#define EXPRESS_TSDK_DUMP
#define EXPRESS_IOCTL_SMP
#define EXPRESS_CSMI
#define EXPRESS_IOCTL_HBA
#define EXPRESS_IOCTL_VDA
#define EXPRESS_IOCTL_GET_ID
#define EXPRESS_IOCTL_GET_MOD_INFO
#define EXPRESS_IOCTL_MAX

#endif