drm/tests: hdmi: Fix memory leaks in drm_display_mode_from_cea_vic()
[drm/drm-misc.git] / drivers / scsi / fnic / vnic_scsi.h
blobf715f7942bfe12b8f6c3ebb4669fea277af50622
1 /* SPDX-License-Identifier: GPL-2.0-only */
2 /*
3 * Copyright 2008 Cisco Systems, Inc. All rights reserved.
4 * Copyright 2007 Nuova Systems, Inc. All rights reserved.
5 */
6 #ifndef _VNIC_SCSI_H_
7 #define _VNIC_SCSI_H_
9 #define VNIC_FNIC_WQ_COPY_COUNT_MIN 1
10 #define VNIC_FNIC_WQ_COPY_COUNT_MAX 1
12 #define VNIC_FNIC_WQ_DESCS_MIN 64
13 #define VNIC_FNIC_WQ_DESCS_MAX 128
15 #define VNIC_FNIC_WQ_COPY_DESCS_MIN 64
16 #define VNIC_FNIC_WQ_COPY_DESCS_MAX 512
18 #define VNIC_FNIC_RQ_DESCS_MIN 64
19 #define VNIC_FNIC_RQ_DESCS_MAX 128
21 #define VNIC_FNIC_EDTOV_MIN 1000
22 #define VNIC_FNIC_EDTOV_MAX 255000
23 #define VNIC_FNIC_EDTOV_DEF 2000
25 #define VNIC_FNIC_RATOV_MIN 1000
26 #define VNIC_FNIC_RATOV_MAX 255000
28 #define VNIC_FNIC_MAXDATAFIELDSIZE_MIN 256
29 #define VNIC_FNIC_MAXDATAFIELDSIZE_MAX 2048
31 #define VNIC_FNIC_FLOGI_RETRIES_MIN 0
32 #define VNIC_FNIC_FLOGI_RETRIES_MAX 0xffffffff
33 #define VNIC_FNIC_FLOGI_RETRIES_DEF 0xffffffff
35 #define VNIC_FNIC_FLOGI_TIMEOUT_MIN 1000
36 #define VNIC_FNIC_FLOGI_TIMEOUT_MAX 255000
38 #define VNIC_FNIC_PLOGI_RETRIES_MIN 0
39 #define VNIC_FNIC_PLOGI_RETRIES_MAX 255
40 #define VNIC_FNIC_PLOGI_RETRIES_DEF 8
42 #define VNIC_FNIC_PLOGI_TIMEOUT_MIN 1000
43 #define VNIC_FNIC_PLOGI_TIMEOUT_MAX 255000
45 #define VNIC_FNIC_IO_THROTTLE_COUNT_MIN 1
46 #define VNIC_FNIC_IO_THROTTLE_COUNT_MAX 2048
48 #define VNIC_FNIC_LINK_DOWN_TIMEOUT_MIN 0
49 #define VNIC_FNIC_LINK_DOWN_TIMEOUT_MAX 240000
51 #define VNIC_FNIC_PORT_DOWN_TIMEOUT_MIN 0
52 #define VNIC_FNIC_PORT_DOWN_TIMEOUT_MAX 240000
54 #define VNIC_FNIC_PORT_DOWN_IO_RETRIES_MIN 0
55 #define VNIC_FNIC_PORT_DOWN_IO_RETRIES_MAX 255
57 #define VNIC_FNIC_LUNS_PER_TARGET_MIN 1
58 #define VNIC_FNIC_LUNS_PER_TARGET_MAX 4096
60 /* Device-specific region: scsi configuration */
61 struct vnic_fc_config {
62 u64 node_wwn;
63 u64 port_wwn;
64 u32 flags;
65 u32 wq_enet_desc_count;
66 u32 wq_copy_desc_count;
67 u32 rq_desc_count;
68 u32 flogi_retries;
69 u32 flogi_timeout;
70 u32 plogi_retries;
71 u32 plogi_timeout;
72 u32 io_throttle_count;
73 u32 link_down_timeout;
74 u32 port_down_timeout;
75 u32 port_down_io_retries;
76 u32 luns_per_tgt;
77 u16 maxdatafieldsize;
78 u16 ed_tov;
79 u16 ra_tov;
80 u16 intr_timer;
81 u8 intr_timer_type;
82 u8 intr_mode;
83 u8 lun_queue_depth;
84 u8 io_timeout_retry;
85 u16 wq_copy_count;
88 #define VFCF_FCP_SEQ_LVL_ERR 0x1 /* Enable FCP-2 Error Recovery */
89 #define VFCF_PERBI 0x2 /* persistent binding info available */
90 #define VFCF_FIP_CAPABLE 0x4 /* firmware can handle FIP */
92 #define VFCF_FC_INITIATOR 0x20 /* FC Initiator Mode */
93 #define VFCF_FC_TARGET 0x40 /* FC Target Mode */
94 #define VFCF_FC_NVME_INITIATOR 0x80 /* FC-NVMe Initiator Mode */
95 #define VFCF_FC_NVME_TARGET 0x100 /* FC-NVMe Target Mode */
97 #endif /* _VNIC_SCSI_H_ */