1 /* 57xx_iscsi_hsi.h: Broadcom NetXtreme II iSCSI HSI.
3 * Copyright (c) 2006 - 2010 Broadcom Corporation
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation.
9 * Written by: Anil Veerabhadrappa (anilgv@broadcom.com)
10 * Maintained by: Eddie Wai (eddie.wai@broadcom.com)
12 #ifndef __57XX_ISCSI_HSI_LINUX_LE__
13 #define __57XX_ISCSI_HSI_LINUX_LE__
18 struct bnx2i_async_msg
{
19 #if defined(__BIG_ENDIAN)
23 #elif defined(__LITTLE_ENDIAN)
32 #if defined(__BIG_ENDIAN)
36 #elif defined(__LITTLE_ENDIAN)
43 #if defined(__BIG_ENDIAN)
47 #elif defined(__LITTLE_ENDIAN)
52 #if defined(__BIG_ENDIAN)
55 #elif defined(__LITTLE_ENDIAN)
65 * iSCSI Buffer Descriptor (BD)
70 #if defined(__BIG_ENDIAN)
73 #elif defined(__LITTLE_ENDIAN)
77 #if defined(__BIG_ENDIAN)
80 #define ISCSI_BD_RESERVED1 (0x3F<<0)
81 #define ISCSI_BD_RESERVED1_SHIFT 0
82 #define ISCSI_BD_LAST_IN_BD_CHAIN (0x1<<6)
83 #define ISCSI_BD_LAST_IN_BD_CHAIN_SHIFT 6
84 #define ISCSI_BD_FIRST_IN_BD_CHAIN (0x1<<7)
85 #define ISCSI_BD_FIRST_IN_BD_CHAIN_SHIFT 7
86 #define ISCSI_BD_RESERVED2 (0xFF<<8)
87 #define ISCSI_BD_RESERVED2_SHIFT 8
88 #elif defined(__LITTLE_ENDIAN)
90 #define ISCSI_BD_RESERVED1 (0x3F<<0)
91 #define ISCSI_BD_RESERVED1_SHIFT 0
92 #define ISCSI_BD_LAST_IN_BD_CHAIN (0x1<<6)
93 #define ISCSI_BD_LAST_IN_BD_CHAIN_SHIFT 6
94 #define ISCSI_BD_FIRST_IN_BD_CHAIN (0x1<<7)
95 #define ISCSI_BD_FIRST_IN_BD_CHAIN_SHIFT 7
96 #define ISCSI_BD_RESERVED2 (0xFF<<8)
97 #define ISCSI_BD_RESERVED2_SHIFT 8
104 * iSCSI Cleanup SQ WQE
106 struct bnx2i_cleanup_request
{
107 #if defined(__BIG_ENDIAN)
111 #elif defined(__LITTLE_ENDIAN)
117 #if defined(__BIG_ENDIAN)
120 #define ISCSI_CLEANUP_REQUEST_INDEX (0x3FFF<<0)
121 #define ISCSI_CLEANUP_REQUEST_INDEX_SHIFT 0
122 #define ISCSI_CLEANUP_REQUEST_TYPE (0x3<<14)
123 #define ISCSI_CLEANUP_REQUEST_TYPE_SHIFT 14
124 #elif defined(__LITTLE_ENDIAN)
126 #define ISCSI_CLEANUP_REQUEST_INDEX (0x3FFF<<0)
127 #define ISCSI_CLEANUP_REQUEST_INDEX_SHIFT 0
128 #define ISCSI_CLEANUP_REQUEST_TYPE (0x3<<14)
129 #define ISCSI_CLEANUP_REQUEST_TYPE_SHIFT 14
133 #if defined(__BIG_ENDIAN)
137 #elif defined(__LITTLE_ENDIAN)
148 struct bnx2i_cleanup_response
{
149 #if defined(__BIG_ENDIAN)
153 #elif defined(__LITTLE_ENDIAN)
160 #if defined(__BIG_ENDIAN)
164 #elif defined(__LITTLE_ENDIAN)
170 #if defined(__BIG_ENDIAN)
173 #define ISCSI_CLEANUP_RESPONSE_INDEX (0x3FFF<<0)
174 #define ISCSI_CLEANUP_RESPONSE_INDEX_SHIFT 0
175 #define ISCSI_CLEANUP_RESPONSE_TYPE (0x3<<14)
176 #define ISCSI_CLEANUP_RESPONSE_TYPE_SHIFT 14
177 #elif defined(__LITTLE_ENDIAN)
179 #define ISCSI_CLEANUP_RESPONSE_INDEX (0x3FFF<<0)
180 #define ISCSI_CLEANUP_RESPONSE_INDEX_SHIFT 0
181 #define ISCSI_CLEANUP_RESPONSE_TYPE (0x3<<14)
182 #define ISCSI_CLEANUP_RESPONSE_TYPE_SHIFT 14
190 * SCSI read/write SQ WQE
192 struct bnx2i_cmd_request
{
193 #if defined(__BIG_ENDIAN)
196 #define ISCSI_CMD_REQUEST_TASK_ATTR (0x7<<0)
197 #define ISCSI_CMD_REQUEST_TASK_ATTR_SHIFT 0
198 #define ISCSI_CMD_REQUEST_RESERVED1 (0x3<<3)
199 #define ISCSI_CMD_REQUEST_RESERVED1_SHIFT 3
200 #define ISCSI_CMD_REQUEST_WRITE (0x1<<5)
201 #define ISCSI_CMD_REQUEST_WRITE_SHIFT 5
202 #define ISCSI_CMD_REQUEST_READ (0x1<<6)
203 #define ISCSI_CMD_REQUEST_READ_SHIFT 6
204 #define ISCSI_CMD_REQUEST_FINAL (0x1<<7)
205 #define ISCSI_CMD_REQUEST_FINAL_SHIFT 7
207 #elif defined(__LITTLE_ENDIAN)
210 #define ISCSI_CMD_REQUEST_TASK_ATTR (0x7<<0)
211 #define ISCSI_CMD_REQUEST_TASK_ATTR_SHIFT 0
212 #define ISCSI_CMD_REQUEST_RESERVED1 (0x3<<3)
213 #define ISCSI_CMD_REQUEST_RESERVED1_SHIFT 3
214 #define ISCSI_CMD_REQUEST_WRITE (0x1<<5)
215 #define ISCSI_CMD_REQUEST_WRITE_SHIFT 5
216 #define ISCSI_CMD_REQUEST_READ (0x1<<6)
217 #define ISCSI_CMD_REQUEST_READ_SHIFT 6
218 #define ISCSI_CMD_REQUEST_FINAL (0x1<<7)
219 #define ISCSI_CMD_REQUEST_FINAL_SHIFT 7
222 #if defined(__BIG_ENDIAN)
223 u16 ud_buffer_offset
;
224 u16 sd_buffer_offset
;
225 #elif defined(__LITTLE_ENDIAN)
226 u16 sd_buffer_offset
;
227 u16 ud_buffer_offset
;
230 #if defined(__BIG_ENDIAN)
233 #define ISCSI_CMD_REQUEST_INDEX (0x3FFF<<0)
234 #define ISCSI_CMD_REQUEST_INDEX_SHIFT 0
235 #define ISCSI_CMD_REQUEST_TYPE (0x3<<14)
236 #define ISCSI_CMD_REQUEST_TYPE_SHIFT 14
237 #elif defined(__LITTLE_ENDIAN)
239 #define ISCSI_CMD_REQUEST_INDEX (0x3FFF<<0)
240 #define ISCSI_CMD_REQUEST_INDEX_SHIFT 0
241 #define ISCSI_CMD_REQUEST_TYPE (0x3<<14)
242 #define ISCSI_CMD_REQUEST_TYPE_SHIFT 14
245 u32 total_data_transfer_length
;
252 #if defined(__BIG_ENDIAN)
254 u8 sd_start_bd_index
;
255 u8 ud_start_bd_index
;
257 #elif defined(__LITTLE_ENDIAN)
259 u8 ud_start_bd_index
;
260 u8 sd_start_bd_index
;
267 * task statistics for write response
269 struct bnx2i_write_resp_task_stat
{
274 * task statistics for read response
276 struct bnx2i_read_resp_task_stat
{
277 #if defined(__BIG_ENDIAN)
280 #elif defined(__LITTLE_ENDIAN)
287 * task statistics for iSCSI cmd response
289 union bnx2i_cmd_resp_task_stat
{
290 struct bnx2i_write_resp_task_stat write_stat
;
291 struct bnx2i_read_resp_task_stat read_stat
;
297 struct bnx2i_cmd_response
{
298 #if defined(__BIG_ENDIAN)
301 #define ISCSI_CMD_RESPONSE_RESERVED0 (0x1<<0)
302 #define ISCSI_CMD_RESPONSE_RESERVED0_SHIFT 0
303 #define ISCSI_CMD_RESPONSE_RESIDUAL_UNDERFLOW (0x1<<1)
304 #define ISCSI_CMD_RESPONSE_RESIDUAL_UNDERFLOW_SHIFT 1
305 #define ISCSI_CMD_RESPONSE_RESIDUAL_OVERFLOW (0x1<<2)
306 #define ISCSI_CMD_RESPONSE_RESIDUAL_OVERFLOW_SHIFT 2
307 #define ISCSI_CMD_RESPONSE_BR_RESIDUAL_UNDERFLOW (0x1<<3)
308 #define ISCSI_CMD_RESPONSE_BR_RESIDUAL_UNDERFLOW_SHIFT 3
309 #define ISCSI_CMD_RESPONSE_BR_RESIDUAL_OVERFLOW (0x1<<4)
310 #define ISCSI_CMD_RESPONSE_BR_RESIDUAL_OVERFLOW_SHIFT 4
311 #define ISCSI_CMD_RESPONSE_RESERVED1 (0x7<<5)
312 #define ISCSI_CMD_RESPONSE_RESERVED1_SHIFT 5
315 #elif defined(__LITTLE_ENDIAN)
319 #define ISCSI_CMD_RESPONSE_RESERVED0 (0x1<<0)
320 #define ISCSI_CMD_RESPONSE_RESERVED0_SHIFT 0
321 #define ISCSI_CMD_RESPONSE_RESIDUAL_UNDERFLOW (0x1<<1)
322 #define ISCSI_CMD_RESPONSE_RESIDUAL_UNDERFLOW_SHIFT 1
323 #define ISCSI_CMD_RESPONSE_RESIDUAL_OVERFLOW (0x1<<2)
324 #define ISCSI_CMD_RESPONSE_RESIDUAL_OVERFLOW_SHIFT 2
325 #define ISCSI_CMD_RESPONSE_BR_RESIDUAL_UNDERFLOW (0x1<<3)
326 #define ISCSI_CMD_RESPONSE_BR_RESIDUAL_UNDERFLOW_SHIFT 3
327 #define ISCSI_CMD_RESPONSE_BR_RESIDUAL_OVERFLOW (0x1<<4)
328 #define ISCSI_CMD_RESPONSE_BR_RESIDUAL_OVERFLOW_SHIFT 4
329 #define ISCSI_CMD_RESPONSE_RESERVED1 (0x7<<5)
330 #define ISCSI_CMD_RESPONSE_RESERVED1_SHIFT 5
338 #if defined(__BIG_ENDIAN)
342 #elif defined(__LITTLE_ENDIAN)
348 union bnx2i_cmd_resp_task_stat task_stat
;
350 #if defined(__BIG_ENDIAN)
353 #define ISCSI_CMD_RESPONSE_INDEX (0x3FFF<<0)
354 #define ISCSI_CMD_RESPONSE_INDEX_SHIFT 0
355 #define ISCSI_CMD_RESPONSE_TYPE (0x3<<14)
356 #define ISCSI_CMD_RESPONSE_TYPE_SHIFT 14
357 #elif defined(__LITTLE_ENDIAN)
359 #define ISCSI_CMD_RESPONSE_INDEX (0x3FFF<<0)
360 #define ISCSI_CMD_RESPONSE_INDEX_SHIFT 0
361 #define ISCSI_CMD_RESPONSE_TYPE (0x3<<14)
362 #define ISCSI_CMD_RESPONSE_TYPE_SHIFT 14
371 * firmware middle-path request SQ WQE
373 struct bnx2i_fw_mp_request
{
374 #if defined(__BIG_ENDIAN)
378 #elif defined(__LITTLE_ENDIAN)
385 #if defined(__BIG_ENDIAN)
388 #define ISCSI_FW_MP_REQUEST_INDEX (0x3FFF<<0)
389 #define ISCSI_FW_MP_REQUEST_INDEX_SHIFT 0
390 #define ISCSI_FW_MP_REQUEST_TYPE (0x3<<14)
391 #define ISCSI_FW_MP_REQUEST_TYPE_SHIFT 14
392 #elif defined(__LITTLE_ENDIAN)
394 #define ISCSI_FW_MP_REQUEST_INDEX (0x3FFF<<0)
395 #define ISCSI_FW_MP_REQUEST_INDEX_SHIFT 0
396 #define ISCSI_FW_MP_REQUEST_TYPE (0x3<<14)
397 #define ISCSI_FW_MP_REQUEST_TYPE_SHIFT 14
401 u32 resp_bd_list_addr_lo
;
402 u32 resp_bd_list_addr_hi
;
404 #define ISCSI_FW_MP_REQUEST_RESP_BUFFER_LENGTH (0xFFFFFF<<0)
405 #define ISCSI_FW_MP_REQUEST_RESP_BUFFER_LENGTH_SHIFT 0
406 #define ISCSI_FW_MP_REQUEST_NUM_RESP_BDS (0xFF<<24)
407 #define ISCSI_FW_MP_REQUEST_NUM_RESP_BDS_SHIFT 24
408 #if defined(__BIG_ENDIAN)
412 #define ISCSI_FW_MP_REQUEST_RESERVED1 (0x1<<0)
413 #define ISCSI_FW_MP_REQUEST_RESERVED1_SHIFT 0
414 #define ISCSI_FW_MP_REQUEST_LOCAL_COMPLETION (0x1<<1)
415 #define ISCSI_FW_MP_REQUEST_LOCAL_COMPLETION_SHIFT 1
416 #define ISCSI_FW_MP_REQUEST_UPDATE_EXP_STAT_SN (0x1<<2)
417 #define ISCSI_FW_MP_REQUEST_UPDATE_EXP_STAT_SN_SHIFT 2
418 #define ISCSI_FW_MP_REQUEST_RESERVED2 (0x1F<<3)
419 #define ISCSI_FW_MP_REQUEST_RESERVED2_SHIFT 3
420 #elif defined(__LITTLE_ENDIAN)
422 #define ISCSI_FW_MP_REQUEST_RESERVED1 (0x1<<0)
423 #define ISCSI_FW_MP_REQUEST_RESERVED1_SHIFT 0
424 #define ISCSI_FW_MP_REQUEST_LOCAL_COMPLETION (0x1<<1)
425 #define ISCSI_FW_MP_REQUEST_LOCAL_COMPLETION_SHIFT 1
426 #define ISCSI_FW_MP_REQUEST_UPDATE_EXP_STAT_SN (0x1<<2)
427 #define ISCSI_FW_MP_REQUEST_UPDATE_EXP_STAT_SN_SHIFT 2
428 #define ISCSI_FW_MP_REQUEST_RESERVED2 (0x1F<<3)
429 #define ISCSI_FW_MP_REQUEST_RESERVED2_SHIFT 3
435 #if defined(__BIG_ENDIAN)
440 #elif defined(__LITTLE_ENDIAN)
450 * firmware response - CQE: used only by firmware
452 struct bnx2i_fw_response
{
459 #define ISCSI_FW_RESPONSE_RESERVED2 (0xFF<<0)
460 #define ISCSI_FW_RESPONSE_RESERVED2_SHIFT 0
461 #define ISCSI_FW_RESPONSE_ERR_CODE (0xFF<<8)
462 #define ISCSI_FW_RESPONSE_ERR_CODE_SHIFT 8
463 #define ISCSI_FW_RESPONSE_RESERVED3 (0xFFFF<<16)
464 #define ISCSI_FW_RESPONSE_RESERVED3_SHIFT 16
476 * iSCSI KCQ CQE parameters
478 union iscsi_kcqe_params
{
487 u32 completion_status
;
488 u32 iscsi_conn_context_id
;
489 union iscsi_kcqe_params params
;
490 #if defined(__BIG_ENDIAN)
492 #define ISCSI_KCQE_RESERVED0 (0xF<<0)
493 #define ISCSI_KCQE_RESERVED0_SHIFT 0
494 #define ISCSI_KCQE_LAYER_CODE (0x7<<4)
495 #define ISCSI_KCQE_LAYER_CODE_SHIFT 4
496 #define ISCSI_KCQE_RESERVED1 (0x1<<7)
497 #define ISCSI_KCQE_RESERVED1_SHIFT 7
500 #elif defined(__LITTLE_ENDIAN)
504 #define ISCSI_KCQE_RESERVED0 (0xF<<0)
505 #define ISCSI_KCQE_RESERVED0_SHIFT 0
506 #define ISCSI_KCQE_LAYER_CODE (0x7<<4)
507 #define ISCSI_KCQE_LAYER_CODE_SHIFT 4
508 #define ISCSI_KCQE_RESERVED1 (0x1<<7)
509 #define ISCSI_KCQE_RESERVED1_SHIFT 7
518 struct iscsi_kwqe_header
{
519 #if defined(__BIG_ENDIAN)
521 #define ISCSI_KWQE_HEADER_RESERVED0 (0xF<<0)
522 #define ISCSI_KWQE_HEADER_RESERVED0_SHIFT 0
523 #define ISCSI_KWQE_HEADER_LAYER_CODE (0x7<<4)
524 #define ISCSI_KWQE_HEADER_LAYER_CODE_SHIFT 4
525 #define ISCSI_KWQE_HEADER_RESERVED1 (0x1<<7)
526 #define ISCSI_KWQE_HEADER_RESERVED1_SHIFT 7
528 #elif defined(__LITTLE_ENDIAN)
531 #define ISCSI_KWQE_HEADER_RESERVED0 (0xF<<0)
532 #define ISCSI_KWQE_HEADER_RESERVED0_SHIFT 0
533 #define ISCSI_KWQE_HEADER_LAYER_CODE (0x7<<4)
534 #define ISCSI_KWQE_HEADER_LAYER_CODE_SHIFT 4
535 #define ISCSI_KWQE_HEADER_RESERVED1 (0x1<<7)
536 #define ISCSI_KWQE_HEADER_RESERVED1_SHIFT 7
541 * iSCSI firmware init request 1
543 struct iscsi_kwqe_init1
{
544 #if defined(__BIG_ENDIAN)
545 struct iscsi_kwqe_header hdr
;
548 #elif defined(__LITTLE_ENDIAN)
551 struct iscsi_kwqe_header hdr
;
553 u32 dummy_buffer_addr_lo
;
554 u32 dummy_buffer_addr_hi
;
555 #if defined(__BIG_ENDIAN)
556 u16 num_ccells_per_conn
;
557 u16 num_tasks_per_conn
;
558 #elif defined(__LITTLE_ENDIAN)
559 u16 num_tasks_per_conn
;
560 u16 num_ccells_per_conn
;
562 #if defined(__BIG_ENDIAN)
563 u16 sq_wqes_per_page
;
565 #elif defined(__LITTLE_ENDIAN)
567 u16 sq_wqes_per_page
;
569 #if defined(__BIG_ENDIAN)
570 u8 cq_log_wqes_per_page
;
572 #define ISCSI_KWQE_INIT1_PAGE_SIZE (0xF<<0)
573 #define ISCSI_KWQE_INIT1_PAGE_SIZE_SHIFT 0
574 #define ISCSI_KWQE_INIT1_DELAYED_ACK_ENABLE (0x1<<4)
575 #define ISCSI_KWQE_INIT1_DELAYED_ACK_ENABLE_SHIFT 4
576 #define ISCSI_KWQE_INIT1_KEEP_ALIVE_ENABLE (0x1<<5)
577 #define ISCSI_KWQE_INIT1_KEEP_ALIVE_ENABLE_SHIFT 5
578 #define ISCSI_KWQE_INIT1_RESERVED1 (0x3<<6)
579 #define ISCSI_KWQE_INIT1_RESERVED1_SHIFT 6
581 #elif defined(__LITTLE_ENDIAN)
584 #define ISCSI_KWQE_INIT1_PAGE_SIZE (0xF<<0)
585 #define ISCSI_KWQE_INIT1_PAGE_SIZE_SHIFT 0
586 #define ISCSI_KWQE_INIT1_DELAYED_ACK_ENABLE (0x1<<4)
587 #define ISCSI_KWQE_INIT1_DELAYED_ACK_ENABLE_SHIFT 4
588 #define ISCSI_KWQE_INIT1_KEEP_ALIVE_ENABLE (0x1<<5)
589 #define ISCSI_KWQE_INIT1_KEEP_ALIVE_ENABLE_SHIFT 5
590 #define ISCSI_KWQE_INIT1_RESERVED1 (0x3<<6)
591 #define ISCSI_KWQE_INIT1_RESERVED1_SHIFT 6
592 u8 cq_log_wqes_per_page
;
594 #if defined(__BIG_ENDIAN)
597 #elif defined(__LITTLE_ENDIAN)
601 #if defined(__BIG_ENDIAN)
604 #elif defined(__LITTLE_ENDIAN)
611 * iSCSI firmware init request 2
613 struct iscsi_kwqe_init2
{
614 #if defined(__BIG_ENDIAN)
615 struct iscsi_kwqe_header hdr
;
617 #elif defined(__LITTLE_ENDIAN)
619 struct iscsi_kwqe_header hdr
;
621 u32 error_bit_map
[2];
626 * Initial iSCSI connection offload request 1
628 struct iscsi_kwqe_conn_offload1
{
629 #if defined(__BIG_ENDIAN)
630 struct iscsi_kwqe_header hdr
;
632 #elif defined(__LITTLE_ENDIAN)
634 struct iscsi_kwqe_header hdr
;
636 u32 sq_page_table_addr_lo
;
637 u32 sq_page_table_addr_hi
;
638 u32 cq_page_table_addr_lo
;
639 u32 cq_page_table_addr_hi
;
644 * iSCSI Page Table Entry (PTE)
652 * Initial iSCSI connection offload request 2
654 struct iscsi_kwqe_conn_offload2
{
655 #if defined(__BIG_ENDIAN)
656 struct iscsi_kwqe_header hdr
;
658 #elif defined(__LITTLE_ENDIAN)
660 struct iscsi_kwqe_header hdr
;
662 u32 rq_page_table_addr_lo
;
663 u32 rq_page_table_addr_hi
;
664 struct iscsi_pte sq_first_pte
;
665 struct iscsi_pte cq_first_pte
;
666 u32 num_additional_wqes
;
671 * Initial iSCSI connection offload request 3
673 struct iscsi_kwqe_conn_offload3
{
674 #if defined(__BIG_ENDIAN)
675 struct iscsi_kwqe_header hdr
;
677 #elif defined(__LITTLE_ENDIAN)
679 struct iscsi_kwqe_header hdr
;
682 struct iscsi_pte qp_first_pte
[3];
687 * iSCSI connection update request
689 struct iscsi_kwqe_conn_update
{
690 #if defined(__BIG_ENDIAN)
691 struct iscsi_kwqe_header hdr
;
693 #elif defined(__LITTLE_ENDIAN)
695 struct iscsi_kwqe_header hdr
;
697 #if defined(__BIG_ENDIAN)
698 u8 session_error_recovery_level
;
699 u8 max_outstanding_r2ts
;
702 #define ISCSI_KWQE_CONN_UPDATE_HEADER_DIGEST (0x1<<0)
703 #define ISCSI_KWQE_CONN_UPDATE_HEADER_DIGEST_SHIFT 0
704 #define ISCSI_KWQE_CONN_UPDATE_DATA_DIGEST (0x1<<1)
705 #define ISCSI_KWQE_CONN_UPDATE_DATA_DIGEST_SHIFT 1
706 #define ISCSI_KWQE_CONN_UPDATE_INITIAL_R2T (0x1<<2)
707 #define ISCSI_KWQE_CONN_UPDATE_INITIAL_R2T_SHIFT 2
708 #define ISCSI_KWQE_CONN_UPDATE_IMMEDIATE_DATA (0x1<<3)
709 #define ISCSI_KWQE_CONN_UPDATE_IMMEDIATE_DATA_SHIFT 3
710 #define ISCSI_KWQE_CONN_UPDATE_RESERVED1 (0xF<<4)
711 #define ISCSI_KWQE_CONN_UPDATE_RESERVED1_SHIFT 4
712 #elif defined(__LITTLE_ENDIAN)
714 #define ISCSI_KWQE_CONN_UPDATE_HEADER_DIGEST (0x1<<0)
715 #define ISCSI_KWQE_CONN_UPDATE_HEADER_DIGEST_SHIFT 0
716 #define ISCSI_KWQE_CONN_UPDATE_DATA_DIGEST (0x1<<1)
717 #define ISCSI_KWQE_CONN_UPDATE_DATA_DIGEST_SHIFT 1
718 #define ISCSI_KWQE_CONN_UPDATE_INITIAL_R2T (0x1<<2)
719 #define ISCSI_KWQE_CONN_UPDATE_INITIAL_R2T_SHIFT 2
720 #define ISCSI_KWQE_CONN_UPDATE_IMMEDIATE_DATA (0x1<<3)
721 #define ISCSI_KWQE_CONN_UPDATE_IMMEDIATE_DATA_SHIFT 3
722 #define ISCSI_KWQE_CONN_UPDATE_RESERVED1 (0xF<<4)
723 #define ISCSI_KWQE_CONN_UPDATE_RESERVED1_SHIFT 4
725 u8 max_outstanding_r2ts
;
726 u8 session_error_recovery_level
;
729 u32 max_send_pdu_length
;
730 u32 max_recv_pdu_length
;
731 u32 first_burst_length
;
732 u32 max_burst_length
;
737 * iSCSI destroy connection request
739 struct iscsi_kwqe_conn_destroy
{
740 #if defined(__BIG_ENDIAN)
741 struct iscsi_kwqe_header hdr
;
743 #elif defined(__LITTLE_ENDIAN)
745 struct iscsi_kwqe_header hdr
;
755 struct iscsi_kwqe_init1 init1
;
756 struct iscsi_kwqe_init2 init2
;
757 struct iscsi_kwqe_conn_offload1 conn_offload1
;
758 struct iscsi_kwqe_conn_offload2 conn_offload2
;
759 struct iscsi_kwqe_conn_update conn_update
;
760 struct iscsi_kwqe_conn_destroy conn_destroy
;
766 struct bnx2i_login_request
{
767 #if defined(__BIG_ENDIAN)
770 #define ISCSI_LOGIN_REQUEST_NEXT_STAGE (0x3<<0)
771 #define ISCSI_LOGIN_REQUEST_NEXT_STAGE_SHIFT 0
772 #define ISCSI_LOGIN_REQUEST_CURRENT_STAGE (0x3<<2)
773 #define ISCSI_LOGIN_REQUEST_CURRENT_STAGE_SHIFT 2
774 #define ISCSI_LOGIN_REQUEST_RESERVED0 (0x3<<4)
775 #define ISCSI_LOGIN_REQUEST_RESERVED0_SHIFT 4
776 #define ISCSI_LOGIN_REQUEST_CONT (0x1<<6)
777 #define ISCSI_LOGIN_REQUEST_CONT_SHIFT 6
778 #define ISCSI_LOGIN_REQUEST_TRANSIT (0x1<<7)
779 #define ISCSI_LOGIN_REQUEST_TRANSIT_SHIFT 7
782 #elif defined(__LITTLE_ENDIAN)
786 #define ISCSI_LOGIN_REQUEST_NEXT_STAGE (0x3<<0)
787 #define ISCSI_LOGIN_REQUEST_NEXT_STAGE_SHIFT 0
788 #define ISCSI_LOGIN_REQUEST_CURRENT_STAGE (0x3<<2)
789 #define ISCSI_LOGIN_REQUEST_CURRENT_STAGE_SHIFT 2
790 #define ISCSI_LOGIN_REQUEST_RESERVED0 (0x3<<4)
791 #define ISCSI_LOGIN_REQUEST_RESERVED0_SHIFT 4
792 #define ISCSI_LOGIN_REQUEST_CONT (0x1<<6)
793 #define ISCSI_LOGIN_REQUEST_CONT_SHIFT 6
794 #define ISCSI_LOGIN_REQUEST_TRANSIT (0x1<<7)
795 #define ISCSI_LOGIN_REQUEST_TRANSIT_SHIFT 7
800 #if defined(__BIG_ENDIAN)
803 #elif defined(__LITTLE_ENDIAN)
807 #if defined(__BIG_ENDIAN)
810 #define ISCSI_LOGIN_REQUEST_INDEX (0x3FFF<<0)
811 #define ISCSI_LOGIN_REQUEST_INDEX_SHIFT 0
812 #define ISCSI_LOGIN_REQUEST_TYPE (0x3<<14)
813 #define ISCSI_LOGIN_REQUEST_TYPE_SHIFT 14
814 #elif defined(__LITTLE_ENDIAN)
816 #define ISCSI_LOGIN_REQUEST_INDEX (0x3FFF<<0)
817 #define ISCSI_LOGIN_REQUEST_INDEX_SHIFT 0
818 #define ISCSI_LOGIN_REQUEST_TYPE (0x3<<14)
819 #define ISCSI_LOGIN_REQUEST_TYPE_SHIFT 14
822 #if defined(__BIG_ENDIAN)
825 #elif defined(__LITTLE_ENDIAN)
832 u32 resp_bd_list_addr_lo
;
833 u32 resp_bd_list_addr_hi
;
835 #define ISCSI_LOGIN_REQUEST_RESP_BUFFER_LENGTH (0xFFFFFF<<0)
836 #define ISCSI_LOGIN_REQUEST_RESP_BUFFER_LENGTH_SHIFT 0
837 #define ISCSI_LOGIN_REQUEST_NUM_RESP_BDS (0xFF<<24)
838 #define ISCSI_LOGIN_REQUEST_NUM_RESP_BDS_SHIFT 24
839 #if defined(__BIG_ENDIAN)
843 #define ISCSI_LOGIN_REQUEST_RESERVED5 (0x3<<0)
844 #define ISCSI_LOGIN_REQUEST_RESERVED5_SHIFT 0
845 #define ISCSI_LOGIN_REQUEST_UPDATE_EXP_STAT_SN (0x1<<2)
846 #define ISCSI_LOGIN_REQUEST_UPDATE_EXP_STAT_SN_SHIFT 2
847 #define ISCSI_LOGIN_REQUEST_RESERVED6 (0x1F<<3)
848 #define ISCSI_LOGIN_REQUEST_RESERVED6_SHIFT 3
849 #elif defined(__LITTLE_ENDIAN)
851 #define ISCSI_LOGIN_REQUEST_RESERVED5 (0x3<<0)
852 #define ISCSI_LOGIN_REQUEST_RESERVED5_SHIFT 0
853 #define ISCSI_LOGIN_REQUEST_UPDATE_EXP_STAT_SN (0x1<<2)
854 #define ISCSI_LOGIN_REQUEST_UPDATE_EXP_STAT_SN_SHIFT 2
855 #define ISCSI_LOGIN_REQUEST_RESERVED6 (0x1F<<3)
856 #define ISCSI_LOGIN_REQUEST_RESERVED6_SHIFT 3
862 #if defined(__BIG_ENDIAN)
867 #elif defined(__LITTLE_ENDIAN)
879 struct bnx2i_login_response
{
880 #if defined(__BIG_ENDIAN)
883 #define ISCSI_LOGIN_RESPONSE_NEXT_STAGE (0x3<<0)
884 #define ISCSI_LOGIN_RESPONSE_NEXT_STAGE_SHIFT 0
885 #define ISCSI_LOGIN_RESPONSE_CURRENT_STAGE (0x3<<2)
886 #define ISCSI_LOGIN_RESPONSE_CURRENT_STAGE_SHIFT 2
887 #define ISCSI_LOGIN_RESPONSE_RESERVED0 (0x3<<4)
888 #define ISCSI_LOGIN_RESPONSE_RESERVED0_SHIFT 4
889 #define ISCSI_LOGIN_RESPONSE_CONT (0x1<<6)
890 #define ISCSI_LOGIN_RESPONSE_CONT_SHIFT 6
891 #define ISCSI_LOGIN_RESPONSE_TRANSIT (0x1<<7)
892 #define ISCSI_LOGIN_RESPONSE_TRANSIT_SHIFT 7
895 #elif defined(__LITTLE_ENDIAN)
899 #define ISCSI_LOGIN_RESPONSE_NEXT_STAGE (0x3<<0)
900 #define ISCSI_LOGIN_RESPONSE_NEXT_STAGE_SHIFT 0
901 #define ISCSI_LOGIN_RESPONSE_CURRENT_STAGE (0x3<<2)
902 #define ISCSI_LOGIN_RESPONSE_CURRENT_STAGE_SHIFT 2
903 #define ISCSI_LOGIN_RESPONSE_RESERVED0 (0x3<<4)
904 #define ISCSI_LOGIN_RESPONSE_RESERVED0_SHIFT 4
905 #define ISCSI_LOGIN_RESPONSE_CONT (0x1<<6)
906 #define ISCSI_LOGIN_RESPONSE_CONT_SHIFT 6
907 #define ISCSI_LOGIN_RESPONSE_TRANSIT (0x1<<7)
908 #define ISCSI_LOGIN_RESPONSE_TRANSIT_SHIFT 7
915 #if defined(__BIG_ENDIAN)
919 #elif defined(__LITTLE_ENDIAN)
926 #if defined(__BIG_ENDIAN)
929 #elif defined(__LITTLE_ENDIAN)
933 #if defined(__BIG_ENDIAN)
937 #elif defined(__LITTLE_ENDIAN)
943 #if defined(__BIG_ENDIAN)
946 #define ISCSI_LOGIN_RESPONSE_INDEX (0x3FFF<<0)
947 #define ISCSI_LOGIN_RESPONSE_INDEX_SHIFT 0
948 #define ISCSI_LOGIN_RESPONSE_TYPE (0x3<<14)
949 #define ISCSI_LOGIN_RESPONSE_TYPE_SHIFT 14
950 #elif defined(__LITTLE_ENDIAN)
952 #define ISCSI_LOGIN_RESPONSE_INDEX (0x3FFF<<0)
953 #define ISCSI_LOGIN_RESPONSE_INDEX_SHIFT 0
954 #define ISCSI_LOGIN_RESPONSE_TYPE (0x3<<14)
955 #define ISCSI_LOGIN_RESPONSE_TYPE_SHIFT 14
963 * iSCSI Logout SQ WQE
965 struct bnx2i_logout_request
{
966 #if defined(__BIG_ENDIAN)
969 #define ISCSI_LOGOUT_REQUEST_REASON (0x7F<<0)
970 #define ISCSI_LOGOUT_REQUEST_REASON_SHIFT 0
971 #define ISCSI_LOGOUT_REQUEST_ALWAYS_ONE (0x1<<7)
972 #define ISCSI_LOGOUT_REQUEST_ALWAYS_ONE_SHIFT 7
974 #elif defined(__LITTLE_ENDIAN)
977 #define ISCSI_LOGOUT_REQUEST_REASON (0x7F<<0)
978 #define ISCSI_LOGOUT_REQUEST_REASON_SHIFT 0
979 #define ISCSI_LOGOUT_REQUEST_ALWAYS_ONE (0x1<<7)
980 #define ISCSI_LOGOUT_REQUEST_ALWAYS_ONE_SHIFT 7
985 #if defined(__BIG_ENDIAN)
988 #define ISCSI_LOGOUT_REQUEST_INDEX (0x3FFF<<0)
989 #define ISCSI_LOGOUT_REQUEST_INDEX_SHIFT 0
990 #define ISCSI_LOGOUT_REQUEST_TYPE (0x3<<14)
991 #define ISCSI_LOGOUT_REQUEST_TYPE_SHIFT 14
992 #elif defined(__LITTLE_ENDIAN)
994 #define ISCSI_LOGOUT_REQUEST_INDEX (0x3FFF<<0)
995 #define ISCSI_LOGOUT_REQUEST_INDEX_SHIFT 0
996 #define ISCSI_LOGOUT_REQUEST_TYPE (0x3<<14)
997 #define ISCSI_LOGOUT_REQUEST_TYPE_SHIFT 14
1000 #if defined(__BIG_ENDIAN)
1003 #elif defined(__LITTLE_ENDIAN)
1010 u32 bd_list_addr_lo
;
1011 u32 bd_list_addr_hi
;
1012 #if defined(__BIG_ENDIAN)
1017 #elif defined(__LITTLE_ENDIAN)
1029 struct bnx2i_logout_response
{
1030 #if defined(__BIG_ENDIAN)
1035 #elif defined(__LITTLE_ENDIAN)
1045 #if defined(__BIG_ENDIAN)
1049 #elif defined(__LITTLE_ENDIAN)
1055 #if defined(__BIG_ENDIAN)
1058 #elif defined(__LITTLE_ENDIAN)
1063 #if defined(__BIG_ENDIAN)
1066 #define ISCSI_LOGOUT_RESPONSE_INDEX (0x3FFF<<0)
1067 #define ISCSI_LOGOUT_RESPONSE_INDEX_SHIFT 0
1068 #define ISCSI_LOGOUT_RESPONSE_TYPE (0x3<<14)
1069 #define ISCSI_LOGOUT_RESPONSE_TYPE_SHIFT 14
1070 #elif defined(__LITTLE_ENDIAN)
1072 #define ISCSI_LOGOUT_RESPONSE_INDEX (0x3FFF<<0)
1073 #define ISCSI_LOGOUT_RESPONSE_INDEX_SHIFT 0
1074 #define ISCSI_LOGOUT_RESPONSE_TYPE (0x3<<14)
1075 #define ISCSI_LOGOUT_RESPONSE_TYPE_SHIFT 14
1085 struct bnx2i_nop_in_msg
{
1086 #if defined(__BIG_ENDIAN)
1090 #elif defined(__LITTLE_ENDIAN)
1100 #if defined(__BIG_ENDIAN)
1104 #elif defined(__LITTLE_ENDIAN)
1112 #if defined(__BIG_ENDIAN)
1115 #define ISCSI_NOP_IN_MSG_INDEX (0x3FFF<<0)
1116 #define ISCSI_NOP_IN_MSG_INDEX_SHIFT 0
1117 #define ISCSI_NOP_IN_MSG_TYPE (0x3<<14)
1118 #define ISCSI_NOP_IN_MSG_TYPE_SHIFT 14
1119 #elif defined(__LITTLE_ENDIAN)
1121 #define ISCSI_NOP_IN_MSG_INDEX (0x3FFF<<0)
1122 #define ISCSI_NOP_IN_MSG_INDEX_SHIFT 0
1123 #define ISCSI_NOP_IN_MSG_TYPE (0x3<<14)
1124 #define ISCSI_NOP_IN_MSG_TYPE_SHIFT 14
1132 * iSCSI NOP-OUT SQ WQE
1134 struct bnx2i_nop_out_request
{
1135 #if defined(__BIG_ENDIAN)
1138 #define ISCSI_NOP_OUT_REQUEST_RESERVED1 (0x7F<<0)
1139 #define ISCSI_NOP_OUT_REQUEST_RESERVED1_SHIFT 0
1140 #define ISCSI_NOP_OUT_REQUEST_ALWAYS_ONE (0x1<<7)
1141 #define ISCSI_NOP_OUT_REQUEST_ALWAYS_ONE_SHIFT 7
1143 #elif defined(__LITTLE_ENDIAN)
1146 #define ISCSI_NOP_OUT_REQUEST_RESERVED1 (0x7F<<0)
1147 #define ISCSI_NOP_OUT_REQUEST_RESERVED1_SHIFT 0
1148 #define ISCSI_NOP_OUT_REQUEST_ALWAYS_ONE (0x1<<7)
1149 #define ISCSI_NOP_OUT_REQUEST_ALWAYS_ONE_SHIFT 7
1154 #if defined(__BIG_ENDIAN)
1157 #define ISCSI_NOP_OUT_REQUEST_INDEX (0x3FFF<<0)
1158 #define ISCSI_NOP_OUT_REQUEST_INDEX_SHIFT 0
1159 #define ISCSI_NOP_OUT_REQUEST_TYPE (0x3<<14)
1160 #define ISCSI_NOP_OUT_REQUEST_TYPE_SHIFT 14
1161 #elif defined(__LITTLE_ENDIAN)
1163 #define ISCSI_NOP_OUT_REQUEST_INDEX (0x3FFF<<0)
1164 #define ISCSI_NOP_OUT_REQUEST_INDEX_SHIFT 0
1165 #define ISCSI_NOP_OUT_REQUEST_TYPE (0x3<<14)
1166 #define ISCSI_NOP_OUT_REQUEST_TYPE_SHIFT 14
1172 u32 resp_bd_list_addr_lo
;
1173 u32 resp_bd_list_addr_hi
;
1175 #define ISCSI_NOP_OUT_REQUEST_RESP_BUFFER_LENGTH (0xFFFFFF<<0)
1176 #define ISCSI_NOP_OUT_REQUEST_RESP_BUFFER_LENGTH_SHIFT 0
1177 #define ISCSI_NOP_OUT_REQUEST_NUM_RESP_BDS (0xFF<<24)
1178 #define ISCSI_NOP_OUT_REQUEST_NUM_RESP_BDS_SHIFT 24
1179 #if defined(__BIG_ENDIAN)
1183 #define ISCSI_NOP_OUT_REQUEST_RESERVED4 (0x1<<0)
1184 #define ISCSI_NOP_OUT_REQUEST_RESERVED4_SHIFT 0
1185 #define ISCSI_NOP_OUT_REQUEST_LOCAL_COMPLETION (0x1<<1)
1186 #define ISCSI_NOP_OUT_REQUEST_LOCAL_COMPLETION_SHIFT 1
1187 #define ISCSI_NOP_OUT_REQUEST_ZERO_FILL (0x3F<<2)
1188 #define ISCSI_NOP_OUT_REQUEST_ZERO_FILL_SHIFT 2
1189 #elif defined(__LITTLE_ENDIAN)
1191 #define ISCSI_NOP_OUT_REQUEST_RESERVED4 (0x1<<0)
1192 #define ISCSI_NOP_OUT_REQUEST_RESERVED4_SHIFT 0
1193 #define ISCSI_NOP_OUT_REQUEST_LOCAL_COMPLETION (0x1<<1)
1194 #define ISCSI_NOP_OUT_REQUEST_LOCAL_COMPLETION_SHIFT 1
1195 #define ISCSI_NOP_OUT_REQUEST_ZERO_FILL (0x3F<<2)
1196 #define ISCSI_NOP_OUT_REQUEST_ZERO_FILL_SHIFT 2
1200 u32 bd_list_addr_lo
;
1201 u32 bd_list_addr_hi
;
1202 #if defined(__BIG_ENDIAN)
1207 #elif defined(__LITTLE_ENDIAN)
1218 struct bnx2i_reject_msg
{
1219 #if defined(__BIG_ENDIAN)
1224 #elif defined(__LITTLE_ENDIAN)
1234 #if defined(__BIG_ENDIAN)
1238 #elif defined(__LITTLE_ENDIAN)
1248 * bnx2i iSCSI TMF SQ WQE
1250 struct bnx2i_tmf_request
{
1251 #if defined(__BIG_ENDIAN)
1254 #define ISCSI_TMF_REQUEST_FUNCTION (0x7F<<0)
1255 #define ISCSI_TMF_REQUEST_FUNCTION_SHIFT 0
1256 #define ISCSI_TMF_REQUEST_ALWAYS_ONE (0x1<<7)
1257 #define ISCSI_TMF_REQUEST_ALWAYS_ONE_SHIFT 7
1259 #elif defined(__LITTLE_ENDIAN)
1262 #define ISCSI_TMF_REQUEST_FUNCTION (0x7F<<0)
1263 #define ISCSI_TMF_REQUEST_FUNCTION_SHIFT 0
1264 #define ISCSI_TMF_REQUEST_ALWAYS_ONE (0x1<<7)
1265 #define ISCSI_TMF_REQUEST_ALWAYS_ONE_SHIFT 7
1270 #if defined(__BIG_ENDIAN)
1273 #define ISCSI_TMF_REQUEST_INDEX (0x3FFF<<0)
1274 #define ISCSI_TMF_REQUEST_INDEX_SHIFT 0
1275 #define ISCSI_TMF_REQUEST_TYPE (0x3<<14)
1276 #define ISCSI_TMF_REQUEST_TYPE_SHIFT 14
1277 #elif defined(__LITTLE_ENDIAN)
1279 #define ISCSI_TMF_REQUEST_INDEX (0x3FFF<<0)
1280 #define ISCSI_TMF_REQUEST_INDEX_SHIFT 0
1281 #define ISCSI_TMF_REQUEST_TYPE (0x3<<14)
1282 #define ISCSI_TMF_REQUEST_TYPE_SHIFT 14
1291 u32 bd_list_addr_lo
;
1292 u32 bd_list_addr_hi
;
1293 #if defined(__BIG_ENDIAN)
1298 #elif defined(__LITTLE_ENDIAN)
1309 struct bnx2i_text_request
{
1310 #if defined(__BIG_ENDIAN)
1313 #define ISCSI_TEXT_REQUEST_RESERVED1 (0x3F<<0)
1314 #define ISCSI_TEXT_REQUEST_RESERVED1_SHIFT 0
1315 #define ISCSI_TEXT_REQUEST_CONT (0x1<<6)
1316 #define ISCSI_TEXT_REQUEST_CONT_SHIFT 6
1317 #define ISCSI_TEXT_REQUEST_FINAL (0x1<<7)
1318 #define ISCSI_TEXT_REQUEST_FINAL_SHIFT 7
1320 #elif defined(__LITTLE_ENDIAN)
1323 #define ISCSI_TEXT_REQUEST_RESERVED1 (0x3F<<0)
1324 #define ISCSI_TEXT_REQUEST_RESERVED1_SHIFT 0
1325 #define ISCSI_TEXT_REQUEST_CONT (0x1<<6)
1326 #define ISCSI_TEXT_REQUEST_CONT_SHIFT 6
1327 #define ISCSI_TEXT_REQUEST_FINAL (0x1<<7)
1328 #define ISCSI_TEXT_REQUEST_FINAL_SHIFT 7
1333 #if defined(__BIG_ENDIAN)
1336 #define ISCSI_TEXT_REQUEST_INDEX (0x3FFF<<0)
1337 #define ISCSI_TEXT_REQUEST_INDEX_SHIFT 0
1338 #define ISCSI_TEXT_REQUEST_TYPE (0x3<<14)
1339 #define ISCSI_TEXT_REQUEST_TYPE_SHIFT 14
1340 #elif defined(__LITTLE_ENDIAN)
1342 #define ISCSI_TEXT_REQUEST_INDEX (0x3FFF<<0)
1343 #define ISCSI_TEXT_REQUEST_INDEX_SHIFT 0
1344 #define ISCSI_TEXT_REQUEST_TYPE (0x3<<14)
1345 #define ISCSI_TEXT_REQUEST_TYPE_SHIFT 14
1351 u32 resp_bd_list_addr_lo
;
1352 u32 resp_bd_list_addr_hi
;
1354 #define ISCSI_TEXT_REQUEST_RESP_BUFFER_LENGTH (0xFFFFFF<<0)
1355 #define ISCSI_TEXT_REQUEST_RESP_BUFFER_LENGTH_SHIFT 0
1356 #define ISCSI_TEXT_REQUEST_NUM_RESP_BDS (0xFF<<24)
1357 #define ISCSI_TEXT_REQUEST_NUM_RESP_BDS_SHIFT 24
1359 u32 bd_list_addr_lo
;
1360 u32 bd_list_addr_hi
;
1361 #if defined(__BIG_ENDIAN)
1366 #elif defined(__LITTLE_ENDIAN)
1377 union iscsi_request
{
1378 struct bnx2i_cmd_request cmd
;
1379 struct bnx2i_tmf_request tmf
;
1380 struct bnx2i_nop_out_request nop_out
;
1381 struct bnx2i_login_request login_req
;
1382 struct bnx2i_text_request text
;
1383 struct bnx2i_logout_request logout_req
;
1384 struct bnx2i_cleanup_request cleanup
;
1391 struct bnx2i_tmf_response
{
1392 #if defined(__BIG_ENDIAN)
1397 #elif defined(__LITTLE_ENDIAN)
1407 #if defined(__BIG_ENDIAN)
1411 #elif defined(__LITTLE_ENDIAN)
1417 #if defined(__BIG_ENDIAN)
1420 #define ISCSI_TMF_RESPONSE_INDEX (0x3FFF<<0)
1421 #define ISCSI_TMF_RESPONSE_INDEX_SHIFT 0
1422 #define ISCSI_TMF_RESPONSE_TYPE (0x3<<14)
1423 #define ISCSI_TMF_RESPONSE_TYPE_SHIFT 14
1424 #elif defined(__LITTLE_ENDIAN)
1426 #define ISCSI_TMF_RESPONSE_INDEX (0x3FFF<<0)
1427 #define ISCSI_TMF_RESPONSE_INDEX_SHIFT 0
1428 #define ISCSI_TMF_RESPONSE_TYPE (0x3<<14)
1429 #define ISCSI_TMF_RESPONSE_TYPE_SHIFT 14
1438 struct bnx2i_text_response
{
1439 #if defined(__BIG_ENDIAN)
1442 #define ISCSI_TEXT_RESPONSE_RESERVED1 (0x3F<<0)
1443 #define ISCSI_TEXT_RESPONSE_RESERVED1_SHIFT 0
1444 #define ISCSI_TEXT_RESPONSE_CONT (0x1<<6)
1445 #define ISCSI_TEXT_RESPONSE_CONT_SHIFT 6
1446 #define ISCSI_TEXT_RESPONSE_FINAL (0x1<<7)
1447 #define ISCSI_TEXT_RESPONSE_FINAL_SHIFT 7
1449 #elif defined(__LITTLE_ENDIAN)
1452 #define ISCSI_TEXT_RESPONSE_RESERVED1 (0x3F<<0)
1453 #define ISCSI_TEXT_RESPONSE_RESERVED1_SHIFT 0
1454 #define ISCSI_TEXT_RESPONSE_CONT (0x1<<6)
1455 #define ISCSI_TEXT_RESPONSE_CONT_SHIFT 6
1456 #define ISCSI_TEXT_RESPONSE_FINAL (0x1<<7)
1457 #define ISCSI_TEXT_RESPONSE_FINAL_SHIFT 7
1465 #if defined(__BIG_ENDIAN)
1469 #elif defined(__LITTLE_ENDIAN)
1477 #if defined(__BIG_ENDIAN)
1480 #define ISCSI_TEXT_RESPONSE_INDEX (0x3FFF<<0)
1481 #define ISCSI_TEXT_RESPONSE_INDEX_SHIFT 0
1482 #define ISCSI_TEXT_RESPONSE_TYPE (0x3<<14)
1483 #define ISCSI_TEXT_RESPONSE_TYPE_SHIFT 14
1484 #elif defined(__LITTLE_ENDIAN)
1486 #define ISCSI_TEXT_RESPONSE_INDEX (0x3FFF<<0)
1487 #define ISCSI_TEXT_RESPONSE_INDEX_SHIFT 0
1488 #define ISCSI_TEXT_RESPONSE_TYPE (0x3<<14)
1489 #define ISCSI_TEXT_RESPONSE_TYPE_SHIFT 14
1498 union iscsi_response
{
1499 struct bnx2i_cmd_response cmd
;
1500 struct bnx2i_tmf_response tmf
;
1501 struct bnx2i_login_response login_resp
;
1502 struct bnx2i_text_response text
;
1503 struct bnx2i_logout_response logout_resp
;
1504 struct bnx2i_cleanup_response cleanup
;
1505 struct bnx2i_reject_msg reject
;
1506 struct bnx2i_async_msg async
;
1507 struct bnx2i_nop_in_msg nop_in
;
1510 #endif /* __57XX_ISCSI_HSI_LINUX_LE__ */