Lines Matching refs:r
79 int r; in userspace_do_request() local
87 r = dm_consult_userspace(uuid, lc->luid, request_type, data, in userspace_do_request()
90 if (r != -ESRCH) in userspace_do_request()
91 return r; in userspace_do_request()
98 r = dm_consult_userspace(uuid, lc->luid, DM_ULOG_CTR, in userspace_do_request()
102 if (!r) in userspace_do_request()
106 r = dm_consult_userspace(uuid, lc->luid, DM_ULOG_RESUME, NULL, in userspace_do_request()
108 if (!r) in userspace_do_request()
111 DMERR("Error trying to resume userspace log: %d", r); in userspace_do_request()
160 int r = 0; in userspace_ctr() local
205 r = -ENOMEM; in userspace_ctr()
212 r = dm_consult_userspace(lc->uuid, lc->luid, DM_ULOG_CTR, in userspace_ctr()
216 if (r < 0) { in userspace_ctr()
217 if (r == -ESRCH) in userspace_ctr()
226 r = dm_consult_userspace(lc->uuid, lc->luid, DM_ULOG_GET_REGION_SIZE, in userspace_ctr()
229 if (r) { in userspace_ctr()
240 r = -EINVAL; in userspace_ctr()
243 r = dm_get_device(ti, devices_rdata, in userspace_ctr()
245 if (r) in userspace_ctr()
251 if (r) { in userspace_ctr()
260 return r; in userspace_ctr()
282 int r; in userspace_presuspend() local
285 r = dm_consult_userspace(lc->uuid, lc->luid, DM_ULOG_PRESUSPEND, in userspace_presuspend()
289 return r; in userspace_presuspend()
294 int r; in userspace_postsuspend() local
297 r = dm_consult_userspace(lc->uuid, lc->luid, DM_ULOG_POSTSUSPEND, in userspace_postsuspend()
301 return r; in userspace_postsuspend()
306 int r; in userspace_resume() local
310 r = dm_consult_userspace(lc->uuid, lc->luid, DM_ULOG_RESUME, in userspace_resume()
314 return r; in userspace_resume()
334 int r; in userspace_is_clean() local
341 r = userspace_do_request(lc, lc->uuid, DM_ULOG_IS_CLEAN, in userspace_is_clean()
345 return (r) ? 0 : (int)is_clean; in userspace_is_clean()
362 int r; in userspace_in_sync() local
385 r = userspace_do_request(lc, lc->uuid, DM_ULOG_IN_SYNC, in userspace_in_sync()
388 return (r) ? 0 : (int)in_sync; in userspace_in_sync()
393 int r = 0; in flush_one_by_one() local
397 r = userspace_do_request(lc, lc->uuid, fe->type, in flush_one_by_one()
401 if (r) in flush_one_by_one()
405 return r; in flush_one_by_one()
410 int r = 0; in flush_by_group() local
434 r = userspace_do_request(lc, lc->uuid, type, in flush_by_group()
438 if (r) { in flush_by_group()
441 r = flush_one_by_one(lc, flush_list); in flush_by_group()
452 return r; in flush_by_group()
474 int r = 0; in userspace_flush() local
489 r = flush_by_group(lc, &mark_list); in userspace_flush()
490 if (r) in userspace_flush()
493 r = flush_by_group(lc, &clear_list); in userspace_flush()
494 if (r) in userspace_flush()
497 r = userspace_do_request(lc, lc->uuid, DM_ULOG_FLUSH, in userspace_flush()
515 if (r) in userspace_flush()
518 return r; in userspace_flush()
593 int r; in userspace_get_resync_work() local
598 region_t r; in userspace_get_resync_work() member
605 r = userspace_do_request(lc, lc->uuid, DM_ULOG_GET_RESYNC_WORK, in userspace_get_resync_work()
609 *region = pkg.r; in userspace_get_resync_work()
610 return (r) ? r : (int)pkg.i; in userspace_get_resync_work()
622 int r; in userspace_set_region_sync() local
625 region_t r; in userspace_set_region_sync() member
629 pkg.r = region; in userspace_set_region_sync()
632 r = userspace_do_request(lc, lc->uuid, DM_ULOG_SET_REGION_SYNC, in userspace_set_region_sync()
653 int r; in userspace_get_sync_count() local
659 r = userspace_do_request(lc, lc->uuid, DM_ULOG_GET_SYNC_COUNT, in userspace_get_sync_count()
663 if (r) in userspace_get_sync_count()
680 int r = 0; in userspace_status() local
687 r = userspace_do_request(lc, lc->uuid, DM_ULOG_STATUS_INFO, in userspace_status()
691 if (r) { in userspace_status()
706 return (r) ? 0 : (int)sz; in userspace_status()
717 int r; in userspace_is_remote_recovering() local
740 r = userspace_do_request(lc, lc->uuid, DM_ULOG_IS_REMOTE_RECOVERING, in userspace_is_remote_recovering()
743 if (r) in userspace_is_remote_recovering()
774 int r = 0; in userspace_dirty_log_init() local
784 r = dm_ulog_tfr_init(); in userspace_dirty_log_init()
785 if (r) { in userspace_dirty_log_init()
788 return r; in userspace_dirty_log_init()
791 r = dm_dirty_log_type_register(&_userspace_type); in userspace_dirty_log_init()
792 if (r) { in userspace_dirty_log_init()
796 return r; in userspace_dirty_log_init()