* [PATCH v2] xen_pvscsi: reclaim the ring request when the prepairing failed
@ 2016-07-12 0:36 ` Bin Wu
0 siblings, 0 replies; 5+ messages in thread
From: Bin Wu @ 2016-07-12 0:36 UTC (permalink / raw)
To: boris.ostrovsky, david.vrabel, jgross, jejb, martin.petersen,
xen-devel, linux-scsi, linux-kernel, wu.wubin
During scsi command queueing or exception handling, if prepairing
fails, we need to reclaim the failed request. Otherwise, the garbage
request will be pushed into the ring for the backend to work.
Signed-off-by: Bin Wu <wu.wubin@huawei.com>
---
drivers/scsi/xen-scsifront.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/scsi/xen-scsifront.c b/drivers/scsi/xen-scsifront.c
index 9dc8687..8646db1 100644
--- a/drivers/scsi/xen-scsifront.c
+++ b/drivers/scsi/xen-scsifront.c
@@ -184,8 +184,6 @@ static struct vscsiif_request *scsifront_pre_req(struct vscsifrnt_info *info)
ring_req = RING_GET_REQUEST(&(info->ring), ring->req_prod_pvt);
- ring->req_prod_pvt++;
-
ring_req->rqid = (uint16_t)id;
return ring_req;
@@ -196,6 +194,8 @@ static void scsifront_do_request(struct vscsifrnt_info *info)
struct vscsiif_front_ring *ring = &(info->ring);
int notify;
+ ring->req_prod_pvt++;
+
RING_PUSH_REQUESTS_AND_CHECK_NOTIFY(ring, notify);
if (notify)
notify_remote_via_irq(info->irq);
--
2.3.2 (Apple Git-55)
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [PATCH v2] xen_pvscsi: reclaim the ring request when the prepairing failed
@ 2016-07-12 0:36 ` Bin Wu
0 siblings, 0 replies; 5+ messages in thread
From: Bin Wu @ 2016-07-12 0:36 UTC (permalink / raw)
To: boris.ostrovsky, david.vrabel, jgross, jejb, martin.petersen,
xen-devel, linux-scsi, linux-kernel, wu.wubin
During scsi command queueing or exception handling, if prepairing
fails, we need to reclaim the failed request. Otherwise, the garbage
request will be pushed into the ring for the backend to work.
Signed-off-by: Bin Wu <wu.wubin@huawei.com>
---
drivers/scsi/xen-scsifront.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/scsi/xen-scsifront.c b/drivers/scsi/xen-scsifront.c
index 9dc8687..8646db1 100644
--- a/drivers/scsi/xen-scsifront.c
+++ b/drivers/scsi/xen-scsifront.c
@@ -184,8 +184,6 @@ static struct vscsiif_request *scsifront_pre_req(struct vscsifrnt_info *info)
ring_req = RING_GET_REQUEST(&(info->ring), ring->req_prod_pvt);
- ring->req_prod_pvt++;
-
ring_req->rqid = (uint16_t)id;
return ring_req;
@@ -196,6 +194,8 @@ static void scsifront_do_request(struct vscsifrnt_info *info)
struct vscsiif_front_ring *ring = &(info->ring);
int notify;
+ ring->req_prod_pvt++;
+
RING_PUSH_REQUESTS_AND_CHECK_NOTIFY(ring, notify);
if (notify)
notify_remote_via_irq(info->irq);
--
2.3.2 (Apple Git-55)
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [PATCH v2] xen_pvscsi: reclaim the ring request when the prepairing failed
@ 2016-07-12 0:36 Bin Wu
0 siblings, 0 replies; 5+ messages in thread
From: Bin Wu @ 2016-07-12 0:36 UTC (permalink / raw)
To: boris.ostrovsky, david.vrabel, jgross, jejb, martin.petersen,
xen-devel, linux-scsi, linux-kernel, wu.wubin
During scsi command queueing or exception handling, if prepairing
fails, we need to reclaim the failed request. Otherwise, the garbage
request will be pushed into the ring for the backend to work.
Signed-off-by: Bin Wu <wu.wubin@huawei.com>
---
drivers/scsi/xen-scsifront.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/scsi/xen-scsifront.c b/drivers/scsi/xen-scsifront.c
index 9dc8687..8646db1 100644
--- a/drivers/scsi/xen-scsifront.c
+++ b/drivers/scsi/xen-scsifront.c
@@ -184,8 +184,6 @@ static struct vscsiif_request *scsifront_pre_req(struct vscsifrnt_info *info)
ring_req = RING_GET_REQUEST(&(info->ring), ring->req_prod_pvt);
- ring->req_prod_pvt++;
-
ring_req->rqid = (uint16_t)id;
return ring_req;
@@ -196,6 +194,8 @@ static void scsifront_do_request(struct vscsifrnt_info *info)
struct vscsiif_front_ring *ring = &(info->ring);
int notify;
+ ring->req_prod_pvt++;
+
RING_PUSH_REQUESTS_AND_CHECK_NOTIFY(ring, notify);
if (notify)
notify_remote_via_irq(info->irq);
--
2.3.2 (Apple Git-55)
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH v2] xen_pvscsi: reclaim the ring request when the prepairing failed
2016-07-12 0:36 ` Bin Wu
(?)
@ 2016-07-12 8:02 ` Juergen Gross
-1 siblings, 0 replies; 5+ messages in thread
From: Juergen Gross @ 2016-07-12 8:02 UTC (permalink / raw)
To: Bin Wu, boris.ostrovsky, david.vrabel, jejb, martin.petersen,
xen-devel, linux-scsi, linux-kernel
On 12/07/16 02:36, Bin Wu wrote:
> During scsi command queueing or exception handling, if prepairing
> fails, we need to reclaim the failed request. Otherwise, the garbage
> request will be pushed into the ring for the backend to work.
>
> Signed-off-by: Bin Wu <wu.wubin@huawei.com>
Reviewed-by: Juergen Gross <jgross@suse.com>
> ---
> drivers/scsi/xen-scsifront.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/scsi/xen-scsifront.c b/drivers/scsi/xen-scsifront.c
> index 9dc8687..8646db1 100644
> --- a/drivers/scsi/xen-scsifront.c
> +++ b/drivers/scsi/xen-scsifront.c
> @@ -184,8 +184,6 @@ static struct vscsiif_request *scsifront_pre_req(struct vscsifrnt_info *info)
>
> ring_req = RING_GET_REQUEST(&(info->ring), ring->req_prod_pvt);
>
> - ring->req_prod_pvt++;
> -
> ring_req->rqid = (uint16_t)id;
>
> return ring_req;
> @@ -196,6 +194,8 @@ static void scsifront_do_request(struct vscsifrnt_info *info)
> struct vscsiif_front_ring *ring = &(info->ring);
> int notify;
>
> + ring->req_prod_pvt++;
> +
> RING_PUSH_REQUESTS_AND_CHECK_NOTIFY(ring, notify);
> if (notify)
> notify_remote_via_irq(info->irq);
>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v2] xen_pvscsi: reclaim the ring request when the prepairing failed
2016-07-12 0:36 ` Bin Wu
(?)
(?)
@ 2016-07-12 8:02 ` Juergen Gross
-1 siblings, 0 replies; 5+ messages in thread
From: Juergen Gross @ 2016-07-12 8:02 UTC (permalink / raw)
To: Bin Wu, boris.ostrovsky, david.vrabel, jejb, martin.petersen,
xen-devel, linux-scsi, linux-kernel
On 12/07/16 02:36, Bin Wu wrote:
> During scsi command queueing or exception handling, if prepairing
> fails, we need to reclaim the failed request. Otherwise, the garbage
> request will be pushed into the ring for the backend to work.
>
> Signed-off-by: Bin Wu <wu.wubin@huawei.com>
Reviewed-by: Juergen Gross <jgross@suse.com>
> ---
> drivers/scsi/xen-scsifront.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/scsi/xen-scsifront.c b/drivers/scsi/xen-scsifront.c
> index 9dc8687..8646db1 100644
> --- a/drivers/scsi/xen-scsifront.c
> +++ b/drivers/scsi/xen-scsifront.c
> @@ -184,8 +184,6 @@ static struct vscsiif_request *scsifront_pre_req(struct vscsifrnt_info *info)
>
> ring_req = RING_GET_REQUEST(&(info->ring), ring->req_prod_pvt);
>
> - ring->req_prod_pvt++;
> -
> ring_req->rqid = (uint16_t)id;
>
> return ring_req;
> @@ -196,6 +194,8 @@ static void scsifront_do_request(struct vscsifrnt_info *info)
> struct vscsiif_front_ring *ring = &(info->ring);
> int notify;
>
> + ring->req_prod_pvt++;
> +
> RING_PUSH_REQUESTS_AND_CHECK_NOTIFY(ring, notify);
> if (notify)
> notify_remote_via_irq(info->irq);
>
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2016-07-12 8:02 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-07-12 0:36 [PATCH v2] xen_pvscsi: reclaim the ring request when the prepairing failed Bin Wu
2016-07-12 0:36 ` Bin Wu
2016-07-12 8:02 ` Juergen Gross
2016-07-12 8:02 ` Juergen Gross
-- strict thread matches above, loose matches on Subject: below --
2016-07-12 0:36 Bin Wu
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.