diff options
author | Seokmann Ju <seokmann.ju@qlogic.com> | 2007-09-20 17:07:43 -0400 |
---|---|---|
committer | James Bottomley <jejb@mulgrave.localdomain> | 2007-10-12 14:50:14 -0400 |
commit | 4d0ea24769c81581b8fd25fd7deff281b1b97dee (patch) | |
tree | 13b37f29f2d8063db4639940177800fd848980a0 /drivers/scsi/qla2xxx/qla_mbx.c | |
parent | c45bcc8e771fa152ed540b8cb2ac8022280173bd (diff) |
[SCSI] qla2xxx: Retrieve max-NPIV support capabilities from FW.
Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/scsi/qla2xxx/qla_mbx.c')
-rw-r--r-- | drivers/scsi/qla2xxx/qla_mbx.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/drivers/scsi/qla2xxx/qla_mbx.c b/drivers/scsi/qla2xxx/qla_mbx.c index e4f4b1fc2b29..ec48871ad55c 100644 --- a/drivers/scsi/qla2xxx/qla_mbx.c +++ b/drivers/scsi/qla2xxx/qla_mbx.c | |||
@@ -1919,7 +1919,8 @@ qla2x00_get_id_list(scsi_qla_host_t *ha, void *id_list, dma_addr_t id_list_dma, | |||
1919 | */ | 1919 | */ |
1920 | int | 1920 | int |
1921 | qla2x00_get_resource_cnts(scsi_qla_host_t *ha, uint16_t *cur_xchg_cnt, | 1921 | qla2x00_get_resource_cnts(scsi_qla_host_t *ha, uint16_t *cur_xchg_cnt, |
1922 | uint16_t *orig_xchg_cnt, uint16_t *cur_iocb_cnt, uint16_t *orig_iocb_cnt) | 1922 | uint16_t *orig_xchg_cnt, uint16_t *cur_iocb_cnt, |
1923 | uint16_t *orig_iocb_cnt, uint16_t *max_npiv_vports) | ||
1923 | { | 1924 | { |
1924 | int rval; | 1925 | int rval; |
1925 | mbx_cmd_t mc; | 1926 | mbx_cmd_t mc; |
@@ -1929,7 +1930,7 @@ qla2x00_get_resource_cnts(scsi_qla_host_t *ha, uint16_t *cur_xchg_cnt, | |||
1929 | 1930 | ||
1930 | mcp->mb[0] = MBC_GET_RESOURCE_COUNTS; | 1931 | mcp->mb[0] = MBC_GET_RESOURCE_COUNTS; |
1931 | mcp->out_mb = MBX_0; | 1932 | mcp->out_mb = MBX_0; |
1932 | mcp->in_mb = MBX_10|MBX_7|MBX_6|MBX_3|MBX_2|MBX_1|MBX_0; | 1933 | mcp->in_mb = MBX_11|MBX_10|MBX_7|MBX_6|MBX_3|MBX_2|MBX_1|MBX_0; |
1933 | mcp->tov = 30; | 1934 | mcp->tov = 30; |
1934 | mcp->flags = 0; | 1935 | mcp->flags = 0; |
1935 | rval = qla2x00_mailbox_command(ha, mcp); | 1936 | rval = qla2x00_mailbox_command(ha, mcp); |
@@ -1940,9 +1941,9 @@ qla2x00_get_resource_cnts(scsi_qla_host_t *ha, uint16_t *cur_xchg_cnt, | |||
1940 | ha->host_no, mcp->mb[0])); | 1941 | ha->host_no, mcp->mb[0])); |
1941 | } else { | 1942 | } else { |
1942 | DEBUG11(printk("%s(%ld): done. mb1=%x mb2=%x mb3=%x mb6=%x " | 1943 | DEBUG11(printk("%s(%ld): done. mb1=%x mb2=%x mb3=%x mb6=%x " |
1943 | "mb7=%x mb10=%x.\n", __func__, ha->host_no, | 1944 | "mb7=%x mb10=%x mb11=%x.\n", __func__, ha->host_no, |
1944 | mcp->mb[1], mcp->mb[2], mcp->mb[3], mcp->mb[6], mcp->mb[7], | 1945 | mcp->mb[1], mcp->mb[2], mcp->mb[3], mcp->mb[6], mcp->mb[7], |
1945 | mcp->mb[10])); | 1946 | mcp->mb[10], mcp->mb[11])); |
1946 | 1947 | ||
1947 | if (cur_xchg_cnt) | 1948 | if (cur_xchg_cnt) |
1948 | *cur_xchg_cnt = mcp->mb[3]; | 1949 | *cur_xchg_cnt = mcp->mb[3]; |
@@ -1952,6 +1953,8 @@ qla2x00_get_resource_cnts(scsi_qla_host_t *ha, uint16_t *cur_xchg_cnt, | |||
1952 | *cur_iocb_cnt = mcp->mb[7]; | 1953 | *cur_iocb_cnt = mcp->mb[7]; |
1953 | if (orig_iocb_cnt) | 1954 | if (orig_iocb_cnt) |
1954 | *orig_iocb_cnt = mcp->mb[10]; | 1955 | *orig_iocb_cnt = mcp->mb[10]; |
1956 | if (max_npiv_vports) | ||
1957 | *max_npiv_vports = mcp->mb[11]; | ||
1955 | } | 1958 | } |
1956 | 1959 | ||
1957 | return (rval); | 1960 | return (rval); |