Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
linux
Commits
6543f562
Commit
6543f562
authored
Mar 28, 2019
by
Kent Overstreet
Committed by
Kent Overstreet
Oct 22, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bcachefs: Handle fsck errors at runtime better
Signed-off-by:
Kent Overstreet
<
kent.overstreet@linux.dev
>
parent
05b3d5ac
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
3 deletions
+13
-3
fs/bcachefs/error.c
fs/bcachefs/error.c
+13
-3
No files found.
fs/bcachefs/error.c
View file @
6543f562
...
@@ -67,10 +67,20 @@ enum fsck_err_ret bch2_fsck_err(struct bch_fs *c, unsigned flags,
...
@@ -67,10 +67,20 @@ enum fsck_err_ret bch2_fsck_err(struct bch_fs *c, unsigned flags,
bool
fix
=
false
,
print
=
true
,
suppressing
=
false
;
bool
fix
=
false
,
print
=
true
,
suppressing
=
false
;
char
_buf
[
sizeof
(
s
->
buf
)],
*
buf
=
_buf
;
char
_buf
[
sizeof
(
s
->
buf
)],
*
buf
=
_buf
;
mutex_lock
(
&
c
->
fsck_error_lock
);
if
(
test_bit
(
BCH_FS_FSCK_DONE
,
&
c
->
flags
))
{
va_start
(
args
,
fmt
);
vprintk
(
fmt
,
args
);
va_end
(
args
);
if
(
test_bit
(
BCH_FS_FSCK_DONE
,
&
c
->
flags
))
if
(
c
->
opts
.
errors
==
BCH_ON_ERROR_CONTINUE
&&
goto
print
;
flags
&
FSCK_CAN_FIX
)
return
FSCK_ERR_FIX
;
bch2_inconsistent_error
(
c
);
return
FSCK_ERR_EXIT
;
}
mutex_lock
(
&
c
->
fsck_error_lock
);
list_for_each_entry
(
s
,
&
c
->
fsck_errors
,
list
)
list_for_each_entry
(
s
,
&
c
->
fsck_errors
,
list
)
if
(
s
->
fmt
==
fmt
)
if
(
s
->
fmt
==
fmt
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment