Btrfs: do some plugging in the submit_bio threads

The Btrfs submit bio threads have a small number of
threads responsible for pushing down bios we've collected
for a large number of devices.

Since we do all the bios for a single device at once,
we want to make sure we unplug and send down the bios
for each device as we're done processing them.

The new plugging API removed the btrfs code to
unplug while processing bios, this adds it back with
the new API.

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

+10
+10
fs/btrfs/volumes.c
··· 155 155 unsigned long limit; 156 156 unsigned long last_waited = 0; 157 157 int force_reg = 0; 158 + struct blk_plug plug; 159 + 160 + /* 161 + * this function runs all the bios we've collected for 162 + * a particular device. We don't want to wander off to 163 + * another device without first sending all of these down. 164 + * So, setup a plug here and finish it off before we return 165 + */ 166 + blk_start_plug(&plug); 158 167 159 168 bdi = blk_get_backing_dev_info(device->bdev); 160 169 fs_info = device->dev_root->fs_info; ··· 303 294 spin_unlock(&device->io_lock); 304 295 305 296 done: 297 + blk_finish_plug(&plug); 306 298 return 0; 307 299 } 308 300