FS-Cache: Actually requeue an object when requested

FS-Cache objects have an FSCACHE_OBJECT_EV_REQUEUE event that can theoretically
be raised to ask the state machine to requeue the object for further processing
before the work function returns to the slow-work facility.

However, fscache_object_work_execute() was clearing that bit before checking
the event mask to see whether the object has any pending events that require it
to be requeued immediately.

Instead, the bit should be cleared after the check and enqueue.

Signed-off-by: David Howells <dhowells@redhat.com>
This commit is contained in:
David Howells 2009-11-19 18:11:48 +00:00
parent 60d543ca72
commit 868411be3f
1 changed files with 1 additions and 2 deletions

View File

@ -353,13 +353,12 @@ static void fscache_object_slow_work_execute(struct slow_work *work)
_enter("{OBJ%x}", object->debug_id); _enter("{OBJ%x}", object->debug_id);
clear_bit(FSCACHE_OBJECT_EV_REQUEUE, &object->events);
start = jiffies; start = jiffies;
fscache_object_state_machine(object); fscache_object_state_machine(object);
fscache_hist(fscache_objs_histogram, start); fscache_hist(fscache_objs_histogram, start);
if (object->events & object->event_mask) if (object->events & object->event_mask)
fscache_enqueue_object(object); fscache_enqueue_object(object);
clear_bit(FSCACHE_OBJECT_EV_REQUEUE, &object->events);
} }
/* /*