diff options
Diffstat (limited to 'fs/fscache/object.c')
-rw-r--r-- | fs/fscache/object.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/fs/fscache/object.c b/fs/fscache/object.c index f3f952cf887e..e513ac599c8e 100644 --- a/fs/fscache/object.c +++ b/fs/fscache/object.c | |||
@@ -468,6 +468,7 @@ static void fscache_lookup_object(struct fscache_object *object) | |||
468 | { | 468 | { |
469 | struct fscache_cookie *cookie = object->cookie; | 469 | struct fscache_cookie *cookie = object->cookie; |
470 | struct fscache_object *parent; | 470 | struct fscache_object *parent; |
471 | int ret; | ||
471 | 472 | ||
472 | _enter(""); | 473 | _enter(""); |
473 | 474 | ||
@@ -493,12 +494,19 @@ static void fscache_lookup_object(struct fscache_object *object) | |||
493 | 494 | ||
494 | fscache_stat(&fscache_n_object_lookups); | 495 | fscache_stat(&fscache_n_object_lookups); |
495 | fscache_stat(&fscache_n_cop_lookup_object); | 496 | fscache_stat(&fscache_n_cop_lookup_object); |
496 | object->cache->ops->lookup_object(object); | 497 | ret = object->cache->ops->lookup_object(object); |
497 | fscache_stat_d(&fscache_n_cop_lookup_object); | 498 | fscache_stat_d(&fscache_n_cop_lookup_object); |
498 | 499 | ||
499 | if (test_bit(FSCACHE_OBJECT_EV_ERROR, &object->events)) | 500 | if (test_bit(FSCACHE_OBJECT_EV_ERROR, &object->events)) |
500 | set_bit(FSCACHE_COOKIE_UNAVAILABLE, &cookie->flags); | 501 | set_bit(FSCACHE_COOKIE_UNAVAILABLE, &cookie->flags); |
501 | 502 | ||
503 | if (ret == -ETIMEDOUT) { | ||
504 | /* probably stuck behind another object, so move this one to | ||
505 | * the back of the queue */ | ||
506 | fscache_stat(&fscache_n_object_lookups_timed_out); | ||
507 | set_bit(FSCACHE_OBJECT_EV_REQUEUE, &object->events); | ||
508 | } | ||
509 | |||
502 | _leave(""); | 510 | _leave(""); |
503 | } | 511 | } |
504 | 512 | ||