• Home
  • Raw
  • Download

Lines Matching refs:r

74 	int r;  in sm_disk_count_is_more_than_one()  local
77 r = sm_disk_get_count(sm, b, &count); in sm_disk_count_is_more_than_one()
78 if (r) in sm_disk_count_is_more_than_one()
79 return r; in sm_disk_count_is_more_than_one()
87 int r; in sm_disk_set_count() local
92 r = sm_ll_insert(&smd->ll, b, count, &ev); in sm_disk_set_count()
93 if (!r) { in sm_disk_set_count()
111 r = sm_ll_lookup(&smd->old_ll, b, &old_count); in sm_disk_set_count()
112 if (r) in sm_disk_set_count()
113 return r; in sm_disk_set_count()
121 return r; in sm_disk_set_count()
126 int r; in sm_disk_inc_block() local
130 r = sm_ll_inc(&smd->ll, b, &ev); in sm_disk_inc_block()
131 if (!r && (ev == SM_ALLOC)) in sm_disk_inc_block()
138 return r; in sm_disk_inc_block()
143 int r; in sm_disk_dec_block() local
148 r = sm_ll_dec(&smd->ll, b, &ev); in sm_disk_dec_block()
149 if (!r && (ev == SM_FREE)) { in sm_disk_dec_block()
154 r = sm_ll_lookup(&smd->old_ll, b, &old_count); in sm_disk_dec_block()
155 if (r) in sm_disk_dec_block()
156 return r; in sm_disk_dec_block()
162 return r; in sm_disk_dec_block()
167 int r; in sm_disk_new_block() local
172 r = sm_ll_find_free_block(&smd->old_ll, smd->begin, smd->old_ll.nr_blocks, b); in sm_disk_new_block()
173 if (r) in sm_disk_new_block()
174 return r; in sm_disk_new_block()
177 r = sm_ll_inc(&smd->ll, *b, &ev); in sm_disk_new_block()
178 if (!r) { in sm_disk_new_block()
183 return r; in sm_disk_new_block()
188 int r; in sm_disk_commit() local
192 r = sm_disk_get_nr_free(sm, &nr_free); in sm_disk_commit()
193 if (r) in sm_disk_commit()
194 return r; in sm_disk_commit()
196 r = sm_ll_commit(&smd->ll); in sm_disk_commit()
197 if (r) in sm_disk_commit()
198 return r; in sm_disk_commit()
204 r = sm_disk_get_nr_free(sm, &nr_free); in sm_disk_commit()
205 if (r) in sm_disk_commit()
206 return r; in sm_disk_commit()
258 int r; in dm_sm_disk_create() local
269 r = sm_ll_new_disk(&smd->ll, tm); in dm_sm_disk_create()
270 if (r) in dm_sm_disk_create()
273 r = sm_ll_extend(&smd->ll, nr_blocks); in dm_sm_disk_create()
274 if (r) in dm_sm_disk_create()
277 r = sm_disk_commit(&smd->sm); in dm_sm_disk_create()
278 if (r) in dm_sm_disk_create()
285 return ERR_PTR(r); in dm_sm_disk_create()
292 int r; in dm_sm_disk_open() local
303 r = sm_ll_open_disk(&smd->ll, tm, root_le, len); in dm_sm_disk_open()
304 if (r) in dm_sm_disk_open()
307 r = sm_disk_commit(&smd->sm); in dm_sm_disk_open()
308 if (r) in dm_sm_disk_open()
315 return ERR_PTR(r); in dm_sm_disk_open()