diff options
author | Xiaofei Tan <tanxiaofei@huawei.com> | 2017-12-09 01:16:44 +0800 |
---|---|---|
committer | Martin K. Petersen <martin.petersen@oracle.com> | 2017-12-14 21:25:03 -0500 |
commit | e537b62b0796042e1ab66657c4dab662d19e9f0b (patch) | |
tree | 5fbfec91a5568ff7becdb99722d38d3e76bbbf5d /drivers/scsi/hisi_sas/hisi_sas.h | |
parent | 72f7fc3050d55e9877ecc56f33b7a434fca186f5 (diff) | |
download | lwn-e537b62b0796042e1ab66657c4dab662d19e9f0b.tar.gz lwn-e537b62b0796042e1ab66657c4dab662d19e9f0b.zip |
scsi: hisi_sas: use an general way to delay PHY work
Use an general way to do delay work for a PHY. Then it will be easier to add
new delayed work for a PHY in future.
Signed-off-by: Xiaofei Tan <tanxiaofei@huawei.com>
Signed-off-by: John Garry <john.garry@huawei.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/hisi_sas/hisi_sas.h')
-rw-r--r-- | drivers/scsi/hisi_sas/hisi_sas.h | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/drivers/scsi/hisi_sas/hisi_sas.h b/drivers/scsi/hisi_sas/hisi_sas.h index 71bc8eaac99e..aa14638ab08f 100644 --- a/drivers/scsi/hisi_sas/hisi_sas.h +++ b/drivers/scsi/hisi_sas/hisi_sas.h @@ -124,12 +124,17 @@ enum hisi_sas_bit_err_type { HISI_SAS_ERR_MULTI_BIT_ECC = 0x1, }; +enum hisi_sas_phy_event { + HISI_PHYE_PHY_UP = 0U, + HISI_PHYES_NUM, +}; + struct hisi_sas_phy { + struct work_struct works[HISI_PHYES_NUM]; struct hisi_hba *hisi_hba; struct hisi_sas_port *port; struct asd_sas_phy sas_phy; struct sas_identify identify; - struct work_struct phyup_ws; u64 port_id; /* from hw */ u64 dev_sas_addr; u64 frame_rcvd_size; @@ -453,4 +458,6 @@ extern void hisi_sas_init_mem(struct hisi_hba *hisi_hba); extern void hisi_sas_rst_work_handler(struct work_struct *work); extern void hisi_sas_sync_rst_work_handler(struct work_struct *work); extern void hisi_sas_kill_tasklets(struct hisi_hba *hisi_hba); +extern bool hisi_sas_notify_phy_event(struct hisi_sas_phy *phy, + enum hisi_sas_phy_event event); #endif |