Lines Matching refs:r

88 	int r;  in userspace_do_request()  local
96 r = dm_consult_userspace(uuid, lc->luid, request_type, data, in userspace_do_request()
99 if (r != -ESRCH) in userspace_do_request()
100 return r; in userspace_do_request()
107 r = dm_consult_userspace(uuid, lc->luid, DM_ULOG_CTR, in userspace_do_request()
111 if (!r) in userspace_do_request()
115 r = dm_consult_userspace(uuid, lc->luid, DM_ULOG_RESUME, NULL, in userspace_do_request()
117 if (!r) in userspace_do_request()
120 DMERR("Error trying to resume userspace log: %d", r); in userspace_do_request()
158 int r; in do_flush() local
163 r = userspace_do_request(lc, lc->uuid, DM_ULOG_FLUSH, NULL, 0, NULL, NULL); in do_flush()
165 if (r) in do_flush()
193 int r = 0; in userspace_ctr() local
248 r = -ENOMEM; in userspace_ctr()
256 r = -ENOMEM; in userspace_ctr()
263 r = dm_consult_userspace(lc->uuid, lc->luid, DM_ULOG_CTR, in userspace_ctr()
267 if (r < 0) { in userspace_ctr()
268 if (r == -ESRCH) in userspace_ctr()
277 r = dm_consult_userspace(lc->uuid, lc->luid, DM_ULOG_GET_REGION_SIZE, in userspace_ctr()
280 if (r) { in userspace_ctr()
291 r = -EINVAL; in userspace_ctr()
294 r = dm_get_device(ti, devices_rdata, in userspace_ctr()
296 if (r) in userspace_ctr()
305 r = -ENOMEM; in userspace_ctr()
315 if (r) { in userspace_ctr()
324 return r; in userspace_ctr()
355 int r; in userspace_presuspend() local
358 r = dm_consult_userspace(lc->uuid, lc->luid, DM_ULOG_PRESUSPEND, in userspace_presuspend()
361 return r; in userspace_presuspend()
366 int r; in userspace_postsuspend() local
375 r = dm_consult_userspace(lc->uuid, lc->luid, DM_ULOG_POSTSUSPEND, in userspace_postsuspend()
378 return r; in userspace_postsuspend()
383 int r; in userspace_resume() local
387 r = dm_consult_userspace(lc->uuid, lc->luid, DM_ULOG_RESUME, in userspace_resume()
390 return r; in userspace_resume()
410 int r; in userspace_is_clean() local
417 r = userspace_do_request(lc, lc->uuid, DM_ULOG_IS_CLEAN, in userspace_is_clean()
421 return (r) ? 0 : (int)is_clean; in userspace_is_clean()
438 int r; in userspace_in_sync() local
461 r = userspace_do_request(lc, lc->uuid, DM_ULOG_IN_SYNC, in userspace_in_sync()
464 return (r) ? 0 : (int)in_sync; in userspace_in_sync()
469 int r = 0; in flush_one_by_one() local
473 r = userspace_do_request(lc, lc->uuid, fe->type, in flush_one_by_one()
477 if (r) in flush_one_by_one()
481 return r; in flush_one_by_one()
487 int r = 0; in flush_by_group() local
512 r = userspace_do_request(lc, lc->uuid, DM_ULOG_FLUSH, in flush_by_group()
519 if (r) in flush_by_group()
522 r = userspace_do_request(lc, lc->uuid, type, in flush_by_group()
526 if (r) { in flush_by_group()
531 r = flush_one_by_one(lc, flush_list); in flush_by_group()
543 return r; in flush_by_group()
565 int r = 0; in userspace_flush() local
586 r = flush_by_group(lc, &clear_list, 0); in userspace_flush()
587 if (r) in userspace_flush()
591 r = flush_by_group(lc, &mark_list, 0); in userspace_flush()
592 if (r) in userspace_flush()
594 r = userspace_do_request(lc, lc->uuid, DM_ULOG_FLUSH, in userspace_flush()
602 r = flush_by_group(lc, &mark_list, 1); in userspace_flush()
603 if (r) in userspace_flush()
637 if (r) in userspace_flush()
640 return r; in userspace_flush()
715 int r; in userspace_get_resync_work() local
720 region_t r; in userspace_get_resync_work() member
727 r = userspace_do_request(lc, lc->uuid, DM_ULOG_GET_RESYNC_WORK, in userspace_get_resync_work()
730 *region = pkg.r; in userspace_get_resync_work()
731 return (r) ? r : (int)pkg.i; in userspace_get_resync_work()
745 region_t r; in userspace_set_region_sync() member
749 pkg.r = region; in userspace_set_region_sync()
772 int r; in userspace_get_sync_count() local
778 r = userspace_do_request(lc, lc->uuid, DM_ULOG_GET_SYNC_COUNT, in userspace_get_sync_count()
781 if (r) in userspace_get_sync_count()
798 int r = 0; in userspace_status() local
805 r = userspace_do_request(lc, lc->uuid, DM_ULOG_STATUS_INFO, in userspace_status()
808 if (r) { in userspace_status()
825 return (r) ? 0 : (int)sz; in userspace_status()
836 int r; in userspace_is_remote_recovering() local
859 r = userspace_do_request(lc, lc->uuid, DM_ULOG_IS_REMOTE_RECOVERING, in userspace_is_remote_recovering()
862 if (r) in userspace_is_remote_recovering()
893 int r = 0; in userspace_dirty_log_init() local
901 r = dm_ulog_tfr_init(); in userspace_dirty_log_init()
902 if (r) { in userspace_dirty_log_init()
905 return r; in userspace_dirty_log_init()
908 r = dm_dirty_log_type_register(&_userspace_type); in userspace_dirty_log_init()
909 if (r) { in userspace_dirty_log_init()
913 return r; in userspace_dirty_log_init()