diff options
author | Saurav Kashyap <saurav.kashyap@qlogic.com> | 2011-08-16 11:31:45 -0700 |
---|---|---|
committer | James Bottomley <JBottomley@Parallels.com> | 2011-08-29 00:14:55 -0700 |
commit | 999916dc59dc2fb0de221ad607d58cdc88fcbbe4 (patch) | |
tree | 6c4aa867e0bfaf31ea045578b5d04778cf8858f9 /drivers/scsi/qla2xxx/qla_nx.c | |
parent | 08de2844c626511cfd1db9c36e5e7d126707f780 (diff) | |
download | blackbird-obmc-linux-999916dc59dc2fb0de221ad607d58cdc88fcbbe4.tar.gz blackbird-obmc-linux-999916dc59dc2fb0de221ad607d58cdc88fcbbe4.zip |
[SCSI] qla2xxx: Implemeted beacon on/off for ISP82XX.
[jejb: fix up checkpatch.pl errors]
Signed-off-by: Saurav Kashyap <saurav.kashyap@qlogic.com>
Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>
Diffstat (limited to 'drivers/scsi/qla2xxx/qla_nx.c')
-rw-r--r-- | drivers/scsi/qla2xxx/qla_nx.c | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/drivers/scsi/qla2xxx/qla_nx.c b/drivers/scsi/qla2xxx/qla_nx.c index 43a0a9a4556f..b03c86b7a989 100644 --- a/drivers/scsi/qla2xxx/qla_nx.c +++ b/drivers/scsi/qla2xxx/qla_nx.c @@ -4874,3 +4874,43 @@ qla82xx_md_prep(scsi_qla_host_t *vha) } } } + +int +qla82xx_beacon_on(struct scsi_qla_host *vha) +{ + + int rval; + struct qla_hw_data *ha = vha->hw; + qla82xx_idc_lock(ha); + rval = qla82xx_mbx_beacon_ctl(vha, 1); + + if (rval) { + ql_log(ql_log_warn, vha, 0xb050, + "mbx set led config failed in %s\n", __func__); + goto exit; + } + ha->beacon_blink_led = 1; +exit: + qla82xx_idc_unlock(ha); + return rval; +} + +int +qla82xx_beacon_off(struct scsi_qla_host *vha) +{ + + int rval; + struct qla_hw_data *ha = vha->hw; + qla82xx_idc_lock(ha); + rval = qla82xx_mbx_beacon_ctl(vha, 0); + + if (rval) { + ql_log(ql_log_warn, vha, 0xb051, + "mbx set led config failed in %s\n", __func__); + goto exit; + } + ha->beacon_blink_led = 0; +exit: + qla82xx_idc_unlock(ha); + return rval; +} |