Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Btrfs: Clear the device->running_pending flag before bailing on congestion

Btrfs maintains a queue of async bio submissions so the checksumming
threads don't have to wait on get_request_wait. In order to avoid
extra wakeups, this code has a running_pending flag that is used
to tell new submissions they don't need to wake the thread.

When the threads notice congestion on a single device, they
may decide to requeue the job and move on to other devices. This
makes sure the running_pending flag is cleared before the
job is requeued.

It should help avoid IO stalls by making sure the task is woken up
when new submissions come in.

Signed-off-by: Chris Mason <chris.mason@oracle.com>

+1
+1
fs/btrfs/volumes.c
··· 220 220 tail->bi_next = old_head; 221 221 else 222 222 device->pending_bio_tail = tail; 223 + device->running_pending = 0; 223 224 224 225 spin_unlock(&device->io_lock); 225 226 btrfs_requeue_work(&device->work);