From: John Garry <john.garry@huawei.com>
To: <jejb@linux.vnet.ibm.com>, <martin.petersen@oracle.com>
Cc: <linuxarm@huawei.com>, <linux-scsi@vger.kernel.org>,
<linux-kernel@vger.kernel.org>, <bianpan2016@163.com>,
Xiang Chen <chenxiang66@hisilicon.com>,
John Garry <john.garry@huawei.com>
Subject: [PATCH 02/19] scsi: hisi_sas: avoid potential v2 hw interrupt issue
Date: Fri, 11 Aug 2017 00:09:27 +0800 [thread overview]
Message-ID: <1502381384-219889-3-git-send-email-john.garry@huawei.com> (raw)
In-Reply-To: <1502381384-219889-1-git-send-email-john.garry@huawei.com>
From: Xiang Chen <chenxiang66@hisilicon.com>
When some interrupts happen together, we need to process
every interrupt one-by-one, and should not return
immediately when one interrupt process is finished being
processed.
Signed-off-by: Xiang Chen <chenxiang66@hisilicon.com>
Signed-off-by: John Garry <john.garry@huawei.com>
---
drivers/scsi/hisi_sas/hisi_sas_v2_hw.c | 19 ++++++++++---------
1 file changed, 10 insertions(+), 9 deletions(-)
diff --git a/drivers/scsi/hisi_sas/hisi_sas_v2_hw.c b/drivers/scsi/hisi_sas/hisi_sas_v2_hw.c
index a6be33c..8c504b4 100644
--- a/drivers/scsi/hisi_sas/hisi_sas_v2_hw.c
+++ b/drivers/scsi/hisi_sas/hisi_sas_v2_hw.c
@@ -2606,6 +2606,7 @@ static irqreturn_t int_phy_updown_v2_hw(int irq_no, void *p)
struct hisi_hba *hisi_hba = p;
u32 irq_msk;
int phy_no = 0;
+ irqreturn_t res = IRQ_NONE;
irq_msk = (hisi_sas_read32(hisi_hba, HGC_INVLD_DQE_INFO)
>> HGC_INVLD_DQE_INFO_FB_CH0_OFF) & 0x1ff;
@@ -2620,15 +2621,15 @@ static irqreturn_t int_phy_updown_v2_hw(int irq_no, void *p)
case CHL_INT0_SL_PHY_ENABLE_MSK:
/* phy up */
if (phy_up_v2_hw(phy_no, hisi_hba) ==
- IRQ_NONE)
- return IRQ_NONE;
+ IRQ_HANDLED)
+ res = IRQ_HANDLED;
break;
case CHL_INT0_NOT_RDY_MSK:
/* phy down */
if (phy_down_v2_hw(phy_no, hisi_hba) ==
- IRQ_NONE)
- return IRQ_NONE;
+ IRQ_HANDLED)
+ res = IRQ_HANDLED;
break;
case (CHL_INT0_NOT_RDY_MSK |
@@ -2638,13 +2639,13 @@ static irqreturn_t int_phy_updown_v2_hw(int irq_no, void *p)
if (reg_value & BIT(phy_no)) {
/* phy up */
if (phy_up_v2_hw(phy_no, hisi_hba) ==
- IRQ_NONE)
- return IRQ_NONE;
+ IRQ_HANDLED)
+ res = IRQ_HANDLED;
} else {
/* phy down */
if (phy_down_v2_hw(phy_no, hisi_hba) ==
- IRQ_NONE)
- return IRQ_NONE;
+ IRQ_HANDLED)
+ res = IRQ_HANDLED;
}
break;
@@ -2657,7 +2658,7 @@ static irqreturn_t int_phy_updown_v2_hw(int irq_no, void *p)
phy_no++;
}
- return IRQ_HANDLED;
+ return res;
}
static void phy_bcast_v2_hw(int phy_no, struct hisi_hba *hisi_hba)
--
1.9.1
next prev parent reply other threads:[~2017-08-10 15:42 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-08-10 16:09 [PATCH 00/19] hisi_sas: misc fixes, improvements, and new features John Garry
2017-08-10 16:09 ` [PATCH 01/19] scsi: hisi_sas: fix reset and port ID refresh issues John Garry
2017-08-10 16:09 ` John Garry [this message]
2017-08-10 16:09 ` [PATCH 03/19] scsi: hisi_sas: fix v2 hw underflow residual value John Garry
2017-08-10 16:09 ` [PATCH 04/19] scsi: hisi_sas: add v2 hw DFX feature John Garry
2017-08-10 16:09 ` [PATCH 05/19] scsi: hisi_sas: use array for v2 hw ECC errors John Garry
2017-08-10 16:09 ` [PATCH 06/19] scsi: hisi_sas: remove repeated device config in v2 hw John Garry
2017-08-10 16:09 ` [PATCH 07/19] scsi: hisi_sas: add irq and tasklet cleanup " John Garry
2017-08-10 16:09 ` [PATCH 08/19] scsi: hisi_sas: service interrupt ITCT_CLR interrupt " John Garry
2017-08-10 16:09 ` [PATCH 09/19] scsi: hisi_sas: support zone management commands John Garry
2017-08-10 16:09 ` [PATCH 10/19] scsi: hisi_sas: add status and command buffer for internal abort John Garry
2017-08-10 16:09 ` [PATCH 11/19] scsi: hisi_sas: Modify v3 hw STP_LINK_TIMER setting John Garry
2017-08-10 16:09 ` [PATCH 12/19] scsi: hisi_sas: fix v3 hw channel interrupt processing John Garry
2017-08-10 16:09 ` [PATCH 13/19] scsi: hisi_sas: kill tasklet when destroying irq in v3 hw John Garry
2017-08-10 16:09 ` [PATCH 14/19] scsi: hisi_sas: update some v3 register init settings John Garry
2017-08-10 16:09 ` [PATCH 15/19] scsi: hisi_sas: add reset handler for v3 hw John Garry
2017-08-10 16:09 ` [PATCH 16/19] scsi: hisi_sas: add phy_set_linkrate_v3_hw() John Garry
2017-08-10 16:09 ` [PATCH 17/19] scsi: hisi_sas: remove phy_down_v3_hw() res variable John Garry
2017-08-10 16:09 ` [PATCH 18/19] scsi: hisi_sas: replace kfree with scsi_host_put John Garry
2017-08-10 16:09 ` [PATCH 19/19] scsi: hisi_sas: remove driver versioning John Garry
2017-08-11 0:18 ` [PATCH 00/19] hisi_sas: misc fixes, improvements, and new features Martin K. Petersen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1502381384-219889-3-git-send-email-john.garry@huawei.com \
--to=john.garry@huawei.com \
--cc=bianpan2016@163.com \
--cc=chenxiang66@hisilicon.com \
--cc=jejb@linux.vnet.ibm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=linuxarm@huawei.com \
--cc=martin.petersen@oracle.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®