Lines Matching refs:pctx
46 struct problem_context *pctx);
59 struct problem_context pctx; in e2fsck_pass3() local
64 clear_problem_context(&pctx); in e2fsck_pass3()
71 fix_problem(ctx, PR_3_PASS_HEADER, &pctx); in e2fsck_pass3()
76 pctx.errcode = ext2fs_allocate_inode_bitmap(fs, _("inode done bitmap"), in e2fsck_pass3()
78 if (pctx.errcode) { in e2fsck_pass3()
79 pctx.num = 2; in e2fsck_pass3()
80 fix_problem(ctx, PR_3_ALLOCATE_IBITMAP_ERROR, &pctx); in e2fsck_pass3()
106 if (check_directory(ctx, dir->ino, &pctx)) in e2fsck_pass3()
147 struct problem_context pctx; in check_root() local
149 clear_problem_context(&pctx); in check_root()
159 fix_problem(ctx, PR_3_ROOT_NOT_DIR_ABORT, &pctx); in check_root()
165 if (!fix_problem(ctx, PR_3_NO_ROOT_INODE, &pctx)) { in check_root()
166 fix_problem(ctx, PR_3_NO_ROOT_INODE_ABORT, &pctx); in check_root()
176 pctx.errcode = ext2fs_new_block(fs, 0, ctx->block_found_map, &blk); in check_root()
177 if (pctx.errcode) { in check_root()
178 pctx.str = "ext2fs_new_block"; in check_root()
179 fix_problem(ctx, PR_3_CREATE_ROOT_ERROR, &pctx); in check_root()
190 pctx.errcode = ext2fs_new_dir_block(fs, EXT2_ROOT_INO, EXT2_ROOT_INO, in check_root()
192 if (pctx.errcode) { in check_root()
193 pctx.str = "ext2fs_new_dir_block"; in check_root()
194 fix_problem(ctx, PR_3_CREATE_ROOT_ERROR, &pctx); in check_root()
199 pctx.errcode = ext2fs_write_dir_block(fs, blk, block); in check_root()
200 if (pctx.errcode) { in check_root()
201 pctx.str = "ext2fs_write_dir_block"; in check_root()
202 fix_problem(ctx, PR_3_CREATE_ROOT_ERROR, &pctx); in check_root()
222 pctx.errcode = ext2fs_write_new_inode(fs, EXT2_ROOT_INO, &inode); in check_root()
223 if (pctx.errcode) { in check_root()
224 pctx.str = "ext2fs_write_inode"; in check_root()
225 fix_problem(ctx, PR_3_CREATE_ROOT_ERROR, &pctx); in check_root()
260 struct problem_context *pctx) in check_directory() argument
281 fix_problem(ctx, PR_3_NO_DIRINFO, pctx); in check_directory()
294 pctx->ino = ino; in check_directory()
295 if (fix_problem(ctx, PR_3_UNCONNECTED_DIR, pctx)) { in check_directory()
296 if (e2fsck_reconnect_file(ctx, pctx->ino)) in check_directory()
299 fix_dotdot(ctx, pctx->ino, in check_directory()
320 …pctx->errcode = ext2fs_allocate_inode_bitmap(fs, _("inode loop detection bitmap"), &inode_loop_det… in check_directory()
321 if (pctx->errcode) { in check_directory()
322 pctx->num = 1; in check_directory()
324 PR_3_ALLOCATE_IBITMAP_ERROR, pctx); in check_directory()
337 pctx->ino = dir; in check_directory()
338 if (e2fsck_dir_info_get_dotdot(ctx, dir, &pctx->ino2) || in check_directory()
339 e2fsck_dir_info_get_parent(ctx, dir, &pctx->dir)) { in check_directory()
340 fix_problem(ctx, PR_3_NO_DIRINFO, pctx); in check_directory()
343 if (pctx->ino2 != pctx->dir) { in check_directory()
344 if (fix_problem(ctx, PR_3_BAD_DOT_DOT, pctx)) in check_directory()
345 fix_dotdot(ctx, dir, pctx->dir); in check_directory()
363 struct problem_context pctx; in e2fsck_get_lost_and_found() local
368 clear_problem_context(&pctx); in e2fsck_get_lost_and_found()
383 pctx.ino = ino; in e2fsck_get_lost_and_found()
384 if (!fix_problem(ctx, PR_3_LPF_NOTDIR, &pctx)) in e2fsck_get_lost_and_found()
388 pctx.errcode = ext2fs_unlink(fs, EXT2_ROOT_INO, name, ino, 0); in e2fsck_get_lost_and_found()
389 if (pctx.errcode) { in e2fsck_get_lost_and_found()
390 pctx.str = "ext2fs_unlink"; in e2fsck_get_lost_and_found()
391 fix_problem(ctx, PR_3_CREATE_LPF_ERROR, &pctx); in e2fsck_get_lost_and_found()
397 pctx.errcode = retval; in e2fsck_get_lost_and_found()
398 fix_problem(ctx, PR_3_ERR_FIND_LPF, &pctx); in e2fsck_get_lost_and_found()
414 pctx.errcode = retval; in e2fsck_get_lost_and_found()
415 fix_problem(ctx, PR_3_ERR_LPF_NEW_BLOCK, &pctx); in e2fsck_get_lost_and_found()
427 pctx.errcode = retval; in e2fsck_get_lost_and_found()
428 fix_problem(ctx, PR_3_ERR_LPF_NEW_INODE, &pctx); in e2fsck_get_lost_and_found()
440 pctx.errcode = retval; in e2fsck_get_lost_and_found()
441 fix_problem(ctx, PR_3_ERR_LPF_NEW_DIR_BLOCK, &pctx); in e2fsck_get_lost_and_found()
448 pctx.errcode = retval; in e2fsck_get_lost_and_found()
449 fix_problem(ctx, PR_3_ERR_LPF_WRITE_BLOCK, &pctx); in e2fsck_get_lost_and_found()
467 pctx.errcode = ext2fs_write_new_inode(fs, ino, &inode); in e2fsck_get_lost_and_found()
468 if (pctx.errcode) { in e2fsck_get_lost_and_found()
469 pctx.str = "ext2fs_write_inode"; in e2fsck_get_lost_and_found()
470 fix_problem(ctx, PR_3_CREATE_LPF_ERROR, &pctx); in e2fsck_get_lost_and_found()
476 pctx.errcode = ext2fs_link(fs, EXT2_ROOT_INO, name, ino, EXT2_FT_DIR); in e2fsck_get_lost_and_found()
477 if (pctx.errcode) { in e2fsck_get_lost_and_found()
478 pctx.str = "ext2fs_link"; in e2fsck_get_lost_and_found()
479 fix_problem(ctx, PR_3_CREATE_LPF_ERROR, &pctx); in e2fsck_get_lost_and_found()
505 struct problem_context pctx; in e2fsck_reconnect_file() local
509 clear_problem_context(&pctx); in e2fsck_reconnect_file()
510 pctx.ino = ino; in e2fsck_reconnect_file()
517 fix_problem(ctx, PR_3_NO_LPF, &pctx); in e2fsck_reconnect_file()
526 if (!fix_problem(ctx, PR_3_EXPAND_LF_DIR, &pctx)) in e2fsck_reconnect_file()
531 pctx.errcode = retval; in e2fsck_reconnect_file()
532 fix_problem(ctx, PR_3_CANT_EXPAND_LPF, &pctx); in e2fsck_reconnect_file()
539 pctx.errcode = retval; in e2fsck_reconnect_file()
540 fix_problem(ctx, PR_3_CANT_RECONNECT, &pctx); in e2fsck_reconnect_file()
608 struct problem_context pctx; in fix_dotdot_proc() local
615 clear_problem_context(&pctx); in fix_dotdot_proc()
619 pctx.errcode = retval; in fix_dotdot_proc()
620 fix_problem(fp->ctx, PR_3_ADJUST_INODE, &pctx); in fix_dotdot_proc()
624 pctx.errcode = retval; in fix_dotdot_proc()
625 fix_problem(fp->ctx, PR_3_ADJUST_INODE, &pctx); in fix_dotdot_proc()
644 struct problem_context pctx; in fix_dotdot() local
655 clear_problem_context(&pctx); in fix_dotdot()
656 pctx.ino = ino; in fix_dotdot()
660 pctx.errcode = retval; in fix_dotdot()
662 PR_3_FIX_PARENT_NOFIND, &pctx); in fix_dotdot()
667 fix_problem(ctx, PR_3_NO_DIRINFO, &pctx); in fix_dotdot()