diff mbox

[1/2] libceph: For nofail == false, if __map_request failed,it should unregister.

Message ID 201307161545461466089@gmail.com (mailing list archive)
State New, archived
Headers show

Commit Message

majianpeng July 16, 2013, 7:45 a.m. UTC
For nofail == false  request, if __map_request failed, the caller do
cleanup work,like release the relative pages.It doesn't make any sense
to retry this request.So only give up it.

Signed-off-by: Jianpeng Ma <majianpeng@gmail.com>

---
 net/ceph/osd_client.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

-- 
1.8.1.2

Comments

Sage Weil July 17, 2013, 12:43 a.m. UTC | #1
Applied, thanks!

On Tue, 16 Jul 2013, majianpeng wrote:

> For nofail == false  request, if __map_request failed, the caller do
> cleanup work,like release the relative pages.It doesn't make any sense
> to retry this request.So only give up it.
> 
> Signed-off-by: Jianpeng Ma <majianpeng@gmail.com>
> ---
>  net/ceph/osd_client.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/net/ceph/osd_client.c b/net/ceph/osd_client.c
> index dd47889..7d40a61 100644
> --- a/net/ceph/osd_client.c
> +++ b/net/ceph/osd_client.c
> @@ -2129,7 +2129,8 @@ int ceph_osdc_start_request(struct ceph_osd_client *osdc,
>  			dout("osdc_start_request failed map, "
>  				" will retry %lld\n", req->r_tid);
>  			rc = 0;
> -		}
> +		} else
> +			__unregister_request(osdc, req);
>  		goto out_unlock;
>  	}
>  	if (req->r_osd == NULL) {
> -- 
> 1.8.1.2
> 
--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/net/ceph/osd_client.c b/net/ceph/osd_client.c
index dd47889..7d40a61 100644
--- a/net/ceph/osd_client.c
+++ b/net/ceph/osd_client.c
@@ -2129,7 +2129,8 @@  int ceph_osdc_start_request(struct ceph_osd_client *osdc,
 			dout("osdc_start_request failed map, "
 				" will retry %lld\n", req->r_tid);
 			rc = 0;
-		}
+		} else
+			__unregister_request(osdc, req);
 		goto out_unlock;
 	}
 	if (req->r_osd == NULL) {