Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d68b3e01 authored by Armen Baloyan's avatar Armen Baloyan Committed by James Bottomley
Browse files

[SCSI] qla2xxx: Add changes in the IOCB structures to adjust driver source...


[SCSI] qla2xxx: Add changes in the IOCB structures to adjust driver source codes to ISPFX00 firmware spec.

Signed-off-by: default avatarArmen Baloyan <armen.baloyan@qlogic.com>
Signed-off-by: default avatarSaurav Kashyap <saurav.kashyap@qlogic.com>
Signed-off-by: default avatarJames Bottomley <JBottomley@Parallels.com>
parent 06aec108
Loading
Loading
Loading
Loading
+5 −5
Original line number Original line Diff line number Diff line
@@ -2343,8 +2343,7 @@ qlafx00_ioctl_iosb_entry(scsi_qla_host_t *vha, struct req_que *req,
		fstatus.ioctl_flags = pkt->fw_iotcl_flags;
		fstatus.ioctl_flags = pkt->fw_iotcl_flags;
		fstatus.ioctl_data = pkt->dataword_r;
		fstatus.ioctl_data = pkt->dataword_r;
		fstatus.adapid = pkt->adapid;
		fstatus.adapid = pkt->adapid;
		fstatus.adapid_hi = pkt->adapid_hi;
		fstatus.reserved_2 = pkt->dataword_r_extra;
		fstatus.reserved_2 = pkt->reserved_1;
		fstatus.res_count = pkt->residuallen;
		fstatus.res_count = pkt->residuallen;
		fstatus.status = pkt->status;
		fstatus.status = pkt->status;
		fstatus.seq_number = pkt->seq_no;
		fstatus.seq_number = pkt->seq_no;
@@ -3262,7 +3261,9 @@ qlafx00_start_scsi(srb_t *sp)
	memset(&lcmd_pkt, 0, REQUEST_ENTRY_SIZE);
	memset(&lcmd_pkt, 0, REQUEST_ENTRY_SIZE);


	lcmd_pkt.handle = MAKE_HANDLE(req->id, sp->handle);
	lcmd_pkt.handle = MAKE_HANDLE(req->id, sp->handle);
	lcmd_pkt.handle_hi = 0;
	lcmd_pkt.reserved_0 = 0;
	lcmd_pkt.port_path_ctrl = 0;
	lcmd_pkt.reserved_1 = 0;
	lcmd_pkt.dseg_count = cpu_to_le16(tot_dsds);
	lcmd_pkt.dseg_count = cpu_to_le16(tot_dsds);
	lcmd_pkt.tgt_idx = cpu_to_le16(sp->fcport->tgt_id);
	lcmd_pkt.tgt_idx = cpu_to_le16(sp->fcport->tgt_id);


@@ -3342,8 +3343,7 @@ qlafx00_tm_iocb(srb_t *sp, struct tsk_mgmt_entry_fx00 *ptm_iocb)
	tm_iocb.entry_type = TSK_MGMT_IOCB_TYPE_FX00;
	tm_iocb.entry_type = TSK_MGMT_IOCB_TYPE_FX00;
	tm_iocb.entry_count = 1;
	tm_iocb.entry_count = 1;
	tm_iocb.handle = cpu_to_le32(MAKE_HANDLE(req->id, sp->handle));
	tm_iocb.handle = cpu_to_le32(MAKE_HANDLE(req->id, sp->handle));
	tm_iocb.handle_hi = 0;
	tm_iocb.reserved_0 = 0;
	tm_iocb.timeout = cpu_to_le16(qla2x00_get_async_timeout(vha) + 2);
	tm_iocb.tgt_id = cpu_to_le16(sp->fcport->tgt_id);
	tm_iocb.tgt_id = cpu_to_le16(sp->fcport->tgt_id);
	tm_iocb.control_flags = cpu_to_le32(fxio->u.tmf.flags);
	tm_iocb.control_flags = cpu_to_le32(fxio->u.tmf.flags);
	if (tm_iocb.control_flags == cpu_to_le32((uint32_t)TCF_LUN_RESET)) {
	if (tm_iocb.control_flags == cpu_to_le32((uint32_t)TCF_LUN_RESET)) {
+13 −13
Original line number Original line Diff line number Diff line
@@ -22,13 +22,16 @@ struct cmd_type_7_fx00 {
	uint8_t entry_status;		/* Entry Status. */
	uint8_t entry_status;		/* Entry Status. */


	uint32_t handle;		/* System handle. */
	uint32_t handle;		/* System handle. */
	uint32_t handle_hi;
	uint8_t reserved_0;
	uint8_t port_path_ctrl;
	uint16_t reserved_1;


	__le16 tgt_idx;		/* Target Idx. */
	__le16 tgt_idx;		/* Target Idx. */
	uint16_t timeout;		/* Command timeout. */
	uint16_t timeout;		/* Command timeout. */


	__le16 dseg_count;		/* Data segment count. */
	__le16 dseg_count;		/* Data segment count. */
	uint16_t scsi_rsp_dsd_len;
	uint8_t	scsi_rsp_dsd_len;
	uint8_t reserved_2;


	struct scsi_lun lun;		/* LUN (LE). */
	struct scsi_lun lun;		/* LUN (LE). */


@@ -55,7 +58,7 @@ struct sts_entry_fx00 {
	uint8_t entry_status;		/* Entry Status. */
	uint8_t entry_status;		/* Entry Status. */


	uint32_t handle;		/* System handle. */
	uint32_t handle;		/* System handle. */
	uint32_t handle_hi;		/* System handle. */
	uint32_t reserved_3;		/* System handle. */


	__le16 comp_status;		/* Completion status. */
	__le16 comp_status;		/* Completion status. */
	uint16_t reserved_0;		/* OX_ID used by the firmware. */
	uint16_t reserved_0;		/* OX_ID used by the firmware. */
@@ -78,7 +81,7 @@ struct sts_entry_fx00 {


struct multi_sts_entry_fx00 {
struct multi_sts_entry_fx00 {
	uint8_t entry_type;		/* Entry type. */
	uint8_t entry_type;		/* Entry type. */
	uint8_t sys_define;		/* System defined. */
	uint8_t entry_count;		/* Entry count. */
	uint8_t handle_count;
	uint8_t handle_count;
	uint8_t entry_status;
	uint8_t entry_status;


@@ -94,15 +97,13 @@ struct tsk_mgmt_entry_fx00 {


	__le32 handle;		/* System handle. */
	__le32 handle;		/* System handle. */


	uint32_t handle_hi;		/* System handle. */
	uint32_t reserved_0;


	__le16 tgt_id;		/* Target Idx. */
	__le16 tgt_id;		/* Target Idx. */


	uint16_t reserved_1;
	uint16_t reserved_1;

	uint16_t reserved_3;
	uint16_t delay;			/* Activity delay in seconds. */
	uint16_t reserved_4;

	__le16 timeout;		/* Command timeout. */


	struct scsi_lun lun;		/* LUN (LE). */
	struct scsi_lun lun;		/* LUN (LE). */


@@ -120,13 +121,13 @@ struct abort_iocb_entry_fx00 {
	uint8_t entry_status;		/* Entry Status. */
	uint8_t entry_status;		/* Entry Status. */


	__le32 handle;		/* System handle. */
	__le32 handle;		/* System handle. */
	__le32 handle_hi;		/* System handle. */
	__le32 reserved_0;


	__le16 tgt_id_sts;		/* Completion status. */
	__le16 tgt_id_sts;		/* Completion status. */
	__le16 options;
	__le16 options;


	__le32 abort_handle;		/* System handle. */
	__le32 abort_handle;		/* System handle. */
	__le32 abort_handle_hi;	/* System handle. */
	__le32 reserved_2;


	__le16 req_que_no;
	__le16 req_que_no;
	uint8_t reserved_1[38];
	uint8_t reserved_1[38];
@@ -147,8 +148,7 @@ struct ioctl_iocb_entry_fx00 {


	__le32 dataword_r;		/* Data word returned */
	__le32 dataword_r;		/* Data word returned */
	uint32_t adapid;		/* Adapter ID */
	uint32_t adapid;		/* Adapter ID */
	uint32_t adapid_hi;		/* Adapter ID high */
	uint32_t dataword_r_extra;
	uint32_t reserved_1;


	__le32 seq_no;
	__le32 seq_no;
	uint8_t reserved_2[20];
	uint8_t reserved_2[20];