diff --git a/fs/jbd/transaction.c b/fs/jbd/transaction.c index 429f4b2..9c84ad0 100644 --- a/fs/jbd/transaction.c +++ b/fs/jbd/transaction.c @@ -1335,10 +1335,12 @@ int journal_stop(handle_t *handle) * by 30x or more... */ if (handle->h_sync) { + long start = jiffies; do { old_handle_count = transaction->t_handle_count; - schedule_timeout_uninterruptible(1); - } while (old_handle_count != transaction->t_handle_count); + yield(); + } while (old_handle_count != transaction->t_handle_count && + (jiffies - start < HZ/50)); } current->journal_info = NULL;