Re: [PATCH 2/6] fstests: btrfs: add functions to get and put a device for replace target

2016-06-15 Thread Anand Jain
On 06/12/2016 12:42 PM, Eryu Guan wrote: On Tue, May 17, 2016 at 10:32:06PM +0800, Anand Jain wrote: For the replace tests we need a device as a spare device, here functions _spare_dev_get() and _spare_dev_put() will get it from the SCRATCH_DEV_POOL_SAVED, which is set when

Re: [PATCH 2/6] fstests: btrfs: add functions to get and put a device for replace target

2016-06-11 Thread Eryu Guan
On Tue, May 17, 2016 at 10:32:06PM +0800, Anand Jain wrote: > For the replace tests we need a device as a spare device, > here functions _spare_dev_get() and _spare_dev_put() > will get it from the SCRATCH_DEV_POOL_SAVED, which is set > when _scratch_dev_pool_get() is called, and is based on how >

[PATCH 2/6] fstests: btrfs: add functions to get and put a device for replace target

2016-05-17 Thread Anand Jain
For the replace tests we need a device as a spare device, here functions _spare_dev_get() and _spare_dev_put() will get it from the SCRATCH_DEV_POOL_SAVED, which is set when _scratch_dev_pool_get() is called, and is based on how many has already been assigned to SCRATCH_DEV_POOL. usage: