Lines Matching refs:md_io
87 (r = atomic_cmpxchg(&device->md_io.in_use, 0, 1)) == 0 || in drbd_md_get_buffer()
93 device->md_io.current_use = intent; in drbd_md_get_buffer()
94 device->md_io.start_jif = jiffies; in drbd_md_get_buffer()
95 device->md_io.submit_jif = device->md_io.start_jif - 1; in drbd_md_get_buffer()
96 return page_address(device->md_io.page); in drbd_md_get_buffer()
101 if (atomic_dec_and_test(&device->md_io.in_use)) in drbd_md_put_buffer()
135 device->md_io.done = 0; in _drbd_md_sync_page_io()
136 device->md_io.error = -ENODEV; in _drbd_md_sync_page_io()
146 if (bio_add_page(bio, device->md_io.page, size, 0) != size) in _drbd_md_sync_page_io()
162 atomic_inc(&device->md_io.in_use); /* drbd_md_put_buffer() is in the completion handler */ in _drbd_md_sync_page_io()
163 device->md_io.submit_jif = jiffies; in _drbd_md_sync_page_io()
168 wait_until_done_or_force_detached(device, bdev, &device->md_io.done); in _drbd_md_sync_page_io()
170 err = device->md_io.error; in _drbd_md_sync_page_io()
181 D_ASSERT(device, atomic_read(&device->md_io.in_use) == 1); in drbd_md_sync_page_io()