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
defd9e39
Commit
defd9e39
authored
Dec 16, 2023
by
Kent Overstreet
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bcachefs: darray_for_each() now declares loop iter
Signed-off-by:
Kent Overstreet
<
kent.overstreet@linux.dev
>
parent
559e6c23
Changes
13
Show whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
15 additions
and
43 deletions
+15
-43
fs/bcachefs/btree_write_buffer.c
fs/bcachefs/btree_write_buffer.c
+0
-2
fs/bcachefs/darray.h
fs/bcachefs/darray.h
+5
-2
fs/bcachefs/fs-io-buffered.c
fs/bcachefs/fs-io-buffered.c
+2
-5
fs/bcachefs/fs.c
fs/bcachefs/fs.c
+1
-1
fs/bcachefs/fsck.c
fs/bcachefs/fsck.c
+4
-18
fs/bcachefs/io_write.c
fs/bcachefs/io_write.c
+0
-1
fs/bcachefs/move.c
fs/bcachefs/move.c
+1
-3
fs/bcachefs/movinggc.c
fs/bcachefs/movinggc.c
+0
-1
fs/bcachefs/recovery.c
fs/bcachefs/recovery.c
+0
-1
fs/bcachefs/snapshot.c
fs/bcachefs/snapshot.c
+1
-2
fs/bcachefs/snapshot.h
fs/bcachefs/snapshot.h
+0
-4
fs/bcachefs/super.c
fs/bcachefs/super.c
+1
-1
fs/bcachefs/util.c
fs/bcachefs/util.c
+0
-2
No files found.
fs/bcachefs/btree_write_buffer.c
View file @
defd9e39
...
@@ -246,7 +246,6 @@ static int bch2_btree_write_buffer_flush_locked(struct btree_trans *trans)
...
@@ -246,7 +246,6 @@ static int bch2_btree_write_buffer_flush_locked(struct btree_trans *trans)
struct
bch_fs
*
c
=
trans
->
c
;
struct
bch_fs
*
c
=
trans
->
c
;
struct
journal
*
j
=
&
c
->
journal
;
struct
journal
*
j
=
&
c
->
journal
;
struct
btree_write_buffer
*
wb
=
&
c
->
btree_write_buffer
;
struct
btree_write_buffer
*
wb
=
&
c
->
btree_write_buffer
;
struct
wb_key_ref
*
i
;
struct
btree_iter
iter
=
{
NULL
};
struct
btree_iter
iter
=
{
NULL
};
size_t
skipped
=
0
,
fast
=
0
,
slowpath
=
0
;
size_t
skipped
=
0
,
fast
=
0
,
slowpath
=
0
;
bool
write_locked
=
false
;
bool
write_locked
=
false
;
...
@@ -355,7 +354,6 @@ static int bch2_btree_write_buffer_flush_locked(struct btree_trans *trans)
...
@@ -355,7 +354,6 @@ static int bch2_btree_write_buffer_flush_locked(struct btree_trans *trans)
*/
*/
trace_and_count
(
c
,
write_buffer_flush_slowpath
,
trans
,
slowpath
,
wb
->
flushing
.
keys
.
nr
);
trace_and_count
(
c
,
write_buffer_flush_slowpath
,
trans
,
slowpath
,
wb
->
flushing
.
keys
.
nr
);
struct
btree_write_buffered_key
*
i
;
darray_for_each
(
wb
->
flushing
.
keys
,
i
)
{
darray_for_each
(
wb
->
flushing
.
keys
,
i
)
{
if
(
!
i
->
journal_seq
)
if
(
!
i
->
journal_seq
)
continue
;
continue
;
...
...
fs/bcachefs/darray.h
View file @
defd9e39
...
@@ -81,11 +81,14 @@ static inline int __darray_make_room(darray_char *d, size_t t_size, size_t more,
...
@@ -81,11 +81,14 @@ static inline int __darray_make_room(darray_char *d, size_t t_size, size_t more,
#define darray_remove_item(_d, _pos) \
#define darray_remove_item(_d, _pos) \
array_remove_item((_d)->data, (_d)->nr, (_pos) - (_d)->data)
array_remove_item((_d)->data, (_d)->nr, (_pos) - (_d)->data)
#define __darray_for_each(_d, _i) \
for ((_i) = (_d).data; _i < (_d).data + (_d).nr; _i++)
#define darray_for_each(_d, _i) \
#define darray_for_each(_d, _i) \
for (_i = (_d).data; _i < (_d).data + (_d).nr; _i++)
for (
typeof(&(_d).data[0])
_i = (_d).data; _i < (_d).data + (_d).nr; _i++)
#define darray_for_each_reverse(_d, _i) \
#define darray_for_each_reverse(_d, _i) \
for (_i = (_d).data + (_d).nr - 1; _i >= (_d).data; --_i)
for (
typeof(&(_d).data[0])
_i = (_d).data + (_d).nr - 1; _i >= (_d).data; --_i)
#define darray_init(_d) \
#define darray_init(_d) \
do { \
do { \
...
...
fs/bcachefs/fs-io-buffered.c
View file @
defd9e39
...
@@ -52,14 +52,11 @@ struct readpages_iter {
...
@@ -52,14 +52,11 @@ struct readpages_iter {
static
int
readpages_iter_init
(
struct
readpages_iter
*
iter
,
static
int
readpages_iter_init
(
struct
readpages_iter
*
iter
,
struct
readahead_control
*
ractl
)
struct
readahead_control
*
ractl
)
{
{
struct
folio
**
fi
;
int
ret
;
memset
(
iter
,
0
,
sizeof
(
*
iter
));
memset
(
iter
,
0
,
sizeof
(
*
iter
));
iter
->
mapping
=
ractl
->
mapping
;
iter
->
mapping
=
ractl
->
mapping
;
ret
=
bch2_filemap_get_contig_folios_d
(
iter
->
mapping
,
int
ret
=
bch2_filemap_get_contig_folios_d
(
iter
->
mapping
,
ractl
->
_index
<<
PAGE_SHIFT
,
ractl
->
_index
<<
PAGE_SHIFT
,
(
ractl
->
_index
+
ractl
->
_nr_pages
)
<<
PAGE_SHIFT
,
(
ractl
->
_index
+
ractl
->
_nr_pages
)
<<
PAGE_SHIFT
,
0
,
mapping_gfp_mask
(
iter
->
mapping
),
0
,
mapping_gfp_mask
(
iter
->
mapping
),
...
@@ -826,7 +823,7 @@ static int __bch2_buffered_write(struct bch_inode_info *inode,
...
@@ -826,7 +823,7 @@ static int __bch2_buffered_write(struct bch_inode_info *inode,
struct
bch_fs
*
c
=
inode
->
v
.
i_sb
->
s_fs_info
;
struct
bch_fs
*
c
=
inode
->
v
.
i_sb
->
s_fs_info
;
struct
bch2_folio_reservation
res
;
struct
bch2_folio_reservation
res
;
folios
fs
;
folios
fs
;
struct
folio
*
*
fi
,
*
f
;
struct
folio
*
f
;
unsigned
copied
=
0
,
f_offset
,
f_copied
;
unsigned
copied
=
0
,
f_offset
,
f_copied
;
u64
end
=
pos
+
len
,
f_pos
,
f_len
;
u64
end
=
pos
+
len
,
f_pos
,
f_len
;
loff_t
last_folio_pos
=
inode
->
v
.
i_size
;
loff_t
last_folio_pos
=
inode
->
v
.
i_size
;
...
...
fs/bcachefs/fs.c
View file @
defd9e39
...
@@ -1498,7 +1498,7 @@ static void bch2_evict_inode(struct inode *vinode)
...
@@ -1498,7 +1498,7 @@ static void bch2_evict_inode(struct inode *vinode)
void
bch2_evict_subvolume_inodes
(
struct
bch_fs
*
c
,
snapshot_id_list
*
s
)
void
bch2_evict_subvolume_inodes
(
struct
bch_fs
*
c
,
snapshot_id_list
*
s
)
{
{
struct
bch_inode_info
*
inode
,
**
i
;
struct
bch_inode_info
*
inode
;
DARRAY
(
struct
bch_inode_info
*
)
grabbed
;
DARRAY
(
struct
bch_inode_info
*
)
grabbed
;
bool
clean_pass
=
false
,
this_pass_clean
;
bool
clean_pass
=
false
,
this_pass_clean
;
...
...
fs/bcachefs/fsck.c
View file @
defd9e39
...
@@ -398,7 +398,7 @@ static int snapshots_seen_add_inorder(struct bch_fs *c, struct snapshots_seen *s
...
@@ -398,7 +398,7 @@ static int snapshots_seen_add_inorder(struct bch_fs *c, struct snapshots_seen *s
};
};
int
ret
=
0
;
int
ret
=
0
;
darray_for_each
(
s
->
ids
,
i
)
{
__
darray_for_each
(
s
->
ids
,
i
)
{
if
(
i
->
id
==
id
)
if
(
i
->
id
==
id
)
return
0
;
return
0
;
if
(
i
->
id
>
id
)
if
(
i
->
id
>
id
)
...
@@ -415,7 +415,7 @@ static int snapshots_seen_add_inorder(struct bch_fs *c, struct snapshots_seen *s
...
@@ -415,7 +415,7 @@ static int snapshots_seen_add_inorder(struct bch_fs *c, struct snapshots_seen *s
static
int
snapshots_seen_update
(
struct
bch_fs
*
c
,
struct
snapshots_seen
*
s
,
static
int
snapshots_seen_update
(
struct
bch_fs
*
c
,
struct
snapshots_seen
*
s
,
enum
btree_id
btree_id
,
struct
bpos
pos
)
enum
btree_id
btree_id
,
struct
bpos
pos
)
{
{
struct
snapshots_seen_entry
*
i
,
n
=
{
struct
snapshots_seen_entry
n
=
{
.
id
=
pos
.
snapshot
,
.
id
=
pos
.
snapshot
,
.
equiv
=
bch2_snapshot_equiv
(
c
,
pos
.
snapshot
),
.
equiv
=
bch2_snapshot_equiv
(
c
,
pos
.
snapshot
),
};
};
...
@@ -616,7 +616,7 @@ lookup_inode_for_snapshot(struct bch_fs *c, struct inode_walker *w,
...
@@ -616,7 +616,7 @@ lookup_inode_for_snapshot(struct bch_fs *c, struct inode_walker *w,
snapshot
=
bch2_snapshot_equiv
(
c
,
snapshot
);
snapshot
=
bch2_snapshot_equiv
(
c
,
snapshot
);
darray_for_each
(
w
->
inodes
,
i
)
__
darray_for_each
(
w
->
inodes
,
i
)
if
(
bch2_snapshot_is_ancestor
(
c
,
snapshot
,
i
->
snapshot
))
if
(
bch2_snapshot_is_ancestor
(
c
,
snapshot
,
i
->
snapshot
))
goto
found
;
goto
found
;
...
@@ -658,11 +658,8 @@ static struct inode_walker_entry *walk_inode(struct btree_trans *trans,
...
@@ -658,11 +658,8 @@ static struct inode_walker_entry *walk_inode(struct btree_trans *trans,
if
(
ret
)
if
(
ret
)
return
ERR_PTR
(
ret
);
return
ERR_PTR
(
ret
);
}
else
if
(
bkey_cmp
(
w
->
last_pos
,
pos
))
{
}
else
if
(
bkey_cmp
(
w
->
last_pos
,
pos
))
{
struct
inode_walker_entry
*
i
;
darray_for_each
(
w
->
inodes
,
i
)
darray_for_each
(
w
->
inodes
,
i
)
i
->
seen_this_pos
=
false
;
i
->
seen_this_pos
=
false
;
}
}
w
->
last_pos
=
pos
;
w
->
last_pos
=
pos
;
...
@@ -1032,7 +1029,6 @@ static bool dirent_points_to_inode(struct bkey_s_c_dirent d,
...
@@ -1032,7 +1029,6 @@ static bool dirent_points_to_inode(struct bkey_s_c_dirent d,
static
int
check_i_sectors
(
struct
btree_trans
*
trans
,
struct
inode_walker
*
w
)
static
int
check_i_sectors
(
struct
btree_trans
*
trans
,
struct
inode_walker
*
w
)
{
{
struct
bch_fs
*
c
=
trans
->
c
;
struct
bch_fs
*
c
=
trans
->
c
;
struct
inode_walker_entry
*
i
;
u32
restart_count
=
trans
->
restart_count
;
u32
restart_count
=
trans
->
restart_count
;
int
ret
=
0
;
int
ret
=
0
;
s64
count2
;
s64
count2
;
...
@@ -1081,11 +1077,8 @@ struct extent_ends {
...
@@ -1081,11 +1077,8 @@ struct extent_ends {
static
void
extent_ends_reset
(
struct
extent_ends
*
extent_ends
)
static
void
extent_ends_reset
(
struct
extent_ends
*
extent_ends
)
{
{
struct
extent_end
*
i
;
darray_for_each
(
extent_ends
->
e
,
i
)
darray_for_each
(
extent_ends
->
e
,
i
)
snapshots_seen_exit
(
&
i
->
seen
);
snapshots_seen_exit
(
&
i
->
seen
);
extent_ends
->
e
.
nr
=
0
;
extent_ends
->
e
.
nr
=
0
;
}
}
...
@@ -1117,7 +1110,7 @@ static int extent_ends_at(struct bch_fs *c,
...
@@ -1117,7 +1110,7 @@ static int extent_ends_at(struct bch_fs *c,
if
(
!
n
.
seen
.
ids
.
data
)
if
(
!
n
.
seen
.
ids
.
data
)
return
-
BCH_ERR_ENOMEM_fsck_extent_ends_at
;
return
-
BCH_ERR_ENOMEM_fsck_extent_ends_at
;
darray_for_each
(
extent_ends
->
e
,
i
)
{
__
darray_for_each
(
extent_ends
->
e
,
i
)
{
if
(
i
->
snapshot
==
k
.
k
->
p
.
snapshot
)
{
if
(
i
->
snapshot
==
k
.
k
->
p
.
snapshot
)
{
snapshots_seen_exit
(
&
i
->
seen
);
snapshots_seen_exit
(
&
i
->
seen
);
*
i
=
n
;
*
i
=
n
;
...
@@ -1256,7 +1249,6 @@ static int check_overlapping_extents(struct btree_trans *trans,
...
@@ -1256,7 +1249,6 @@ static int check_overlapping_extents(struct btree_trans *trans,
bool
*
fixed
)
bool
*
fixed
)
{
{
struct
bch_fs
*
c
=
trans
->
c
;
struct
bch_fs
*
c
=
trans
->
c
;
struct
extent_end
*
i
;
int
ret
=
0
;
int
ret
=
0
;
/* transaction restart, running again */
/* transaction restart, running again */
...
@@ -1495,7 +1487,6 @@ int bch2_check_indirect_extents(struct bch_fs *c)
...
@@ -1495,7 +1487,6 @@ int bch2_check_indirect_extents(struct bch_fs *c)
static
int
check_subdir_count
(
struct
btree_trans
*
trans
,
struct
inode_walker
*
w
)
static
int
check_subdir_count
(
struct
btree_trans
*
trans
,
struct
inode_walker
*
w
)
{
{
struct
bch_fs
*
c
=
trans
->
c
;
struct
bch_fs
*
c
=
trans
->
c
;
struct
inode_walker_entry
*
i
;
u32
restart_count
=
trans
->
restart_count
;
u32
restart_count
=
trans
->
restart_count
;
int
ret
=
0
;
int
ret
=
0
;
s64
count2
;
s64
count2
;
...
@@ -1992,13 +1983,10 @@ typedef DARRAY(struct pathbuf_entry) pathbuf;
...
@@ -1992,13 +1983,10 @@ typedef DARRAY(struct pathbuf_entry) pathbuf;
static
bool
path_is_dup
(
pathbuf
*
p
,
u64
inum
,
u32
snapshot
)
static
bool
path_is_dup
(
pathbuf
*
p
,
u64
inum
,
u32
snapshot
)
{
{
struct
pathbuf_entry
*
i
;
darray_for_each
(
*
p
,
i
)
darray_for_each
(
*
p
,
i
)
if
(
i
->
inum
==
inum
&&
if
(
i
->
inum
==
inum
&&
i
->
snapshot
==
snapshot
)
i
->
snapshot
==
snapshot
)
return
true
;
return
true
;
return
false
;
return
false
;
}
}
...
@@ -2092,8 +2080,6 @@ static int check_path(struct btree_trans *trans,
...
@@ -2092,8 +2080,6 @@ static int check_path(struct btree_trans *trans,
}
}
if
(
path_is_dup
(
p
,
inode
->
bi_inum
,
snapshot
))
{
if
(
path_is_dup
(
p
,
inode
->
bi_inum
,
snapshot
))
{
struct
pathbuf_entry
*
i
;
/* XXX print path */
/* XXX print path */
bch_err
(
c
,
"directory structure loop"
);
bch_err
(
c
,
"directory structure loop"
);
...
...
fs/bcachefs/io_write.c
View file @
defd9e39
...
@@ -1230,7 +1230,6 @@ static void bch2_nocow_write(struct bch_write_op *op)
...
@@ -1230,7 +1230,6 @@ static void bch2_nocow_write(struct bch_write_op *op)
struct
bkey_ptrs_c
ptrs
;
struct
bkey_ptrs_c
ptrs
;
const
struct
bch_extent_ptr
*
ptr
;
const
struct
bch_extent_ptr
*
ptr
;
DARRAY_PREALLOCATED
(
struct
bucket_to_lock
,
3
)
buckets
;
DARRAY_PREALLOCATED
(
struct
bucket_to_lock
,
3
)
buckets
;
struct
bucket_to_lock
*
i
;
u32
snapshot
;
u32
snapshot
;
struct
bucket_to_lock
*
stale_at
;
struct
bucket_to_lock
*
stale_at
;
int
ret
;
int
ret
;
...
...
fs/bcachefs/move.c
View file @
defd9e39
...
@@ -400,12 +400,10 @@ struct bch_io_opts *bch2_move_get_io_opts(struct btree_trans *trans,
...
@@ -400,12 +400,10 @@ struct bch_io_opts *bch2_move_get_io_opts(struct btree_trans *trans,
if
(
ret
)
if
(
ret
)
return
ERR_PTR
(
ret
);
return
ERR_PTR
(
ret
);
if
(
extent_k
.
k
->
p
.
snapshot
)
{
if
(
extent_k
.
k
->
p
.
snapshot
)
struct
snapshot_io_opts_entry
*
i
;
darray_for_each
(
io_opts
->
d
,
i
)
darray_for_each
(
io_opts
->
d
,
i
)
if
(
bch2_snapshot_is_ancestor
(
c
,
extent_k
.
k
->
p
.
snapshot
,
i
->
snapshot
))
if
(
bch2_snapshot_is_ancestor
(
c
,
extent_k
.
k
->
p
.
snapshot
,
i
->
snapshot
))
return
&
i
->
io_opts
;
return
&
i
->
io_opts
;
}
return
&
io_opts
->
fs_io_opts
;
return
&
io_opts
->
fs_io_opts
;
}
}
...
...
fs/bcachefs/movinggc.c
View file @
defd9e39
...
@@ -209,7 +209,6 @@ static int bch2_copygc(struct moving_context *ctxt,
...
@@ -209,7 +209,6 @@ static int bch2_copygc(struct moving_context *ctxt,
};
};
move_buckets
buckets
=
{
0
};
move_buckets
buckets
=
{
0
};
struct
move_bucket_in_flight
*
f
;
struct
move_bucket_in_flight
*
f
;
struct
move_bucket
*
i
;
u64
moved
=
atomic64_read
(
&
ctxt
->
stats
->
sectors_moved
);
u64
moved
=
atomic64_read
(
&
ctxt
->
stats
->
sectors_moved
);
int
ret
=
0
;
int
ret
=
0
;
...
...
fs/bcachefs/recovery.c
View file @
defd9e39
...
@@ -146,7 +146,6 @@ static int bch2_journal_replay(struct bch_fs *c)
...
@@ -146,7 +146,6 @@ static int bch2_journal_replay(struct bch_fs *c)
{
{
struct
journal_keys
*
keys
=
&
c
->
journal_keys
;
struct
journal_keys
*
keys
=
&
c
->
journal_keys
;
DARRAY
(
struct
journal_key
*
)
keys_sorted
=
{
0
};
DARRAY
(
struct
journal_key
*
)
keys_sorted
=
{
0
};
struct
journal_key
**
kp
;
struct
journal
*
j
=
&
c
->
journal
;
struct
journal
*
j
=
&
c
->
journal
;
u64
start_seq
=
c
->
journal_replay_seq_start
;
u64
start_seq
=
c
->
journal_replay_seq_start
;
u64
end_seq
=
c
->
journal_replay_seq_start
;
u64
end_seq
=
c
->
journal_replay_seq_start
;
...
...
fs/bcachefs/snapshot.c
View file @
defd9e39
...
@@ -1311,7 +1311,6 @@ static int bch2_fix_child_of_deleted_snapshot(struct btree_trans *trans,
...
@@ -1311,7 +1311,6 @@ static int bch2_fix_child_of_deleted_snapshot(struct btree_trans *trans,
struct
bch_fs
*
c
=
trans
->
c
;
struct
bch_fs
*
c
=
trans
->
c
;
u32
nr_deleted_ancestors
=
0
;
u32
nr_deleted_ancestors
=
0
;
struct
bkey_i_snapshot
*
s
;
struct
bkey_i_snapshot
*
s
;
u32
*
i
;
int
ret
;
int
ret
;
if
(
k
.
k
->
type
!=
KEY_TYPE_snapshot
)
if
(
k
.
k
->
type
!=
KEY_TYPE_snapshot
)
...
@@ -1369,7 +1368,7 @@ int bch2_delete_dead_snapshots(struct bch_fs *c)
...
@@ -1369,7 +1368,7 @@ int bch2_delete_dead_snapshots(struct bch_fs *c)
struct
bkey_s_c_snapshot
snap
;
struct
bkey_s_c_snapshot
snap
;
snapshot_id_list
deleted
=
{
0
};
snapshot_id_list
deleted
=
{
0
};
snapshot_id_list
deleted_interior
=
{
0
};
snapshot_id_list
deleted_interior
=
{
0
};
u32
*
i
,
id
;
u32
id
;
int
ret
=
0
;
int
ret
=
0
;
if
(
!
test_and_clear_bit
(
BCH_FS_need_delete_dead_snapshots
,
&
c
->
flags
))
if
(
!
test_and_clear_bit
(
BCH_FS_need_delete_dead_snapshots
,
&
c
->
flags
))
...
...
fs/bcachefs/snapshot.h
View file @
defd9e39
...
@@ -202,8 +202,6 @@ static inline bool bch2_snapshot_has_children(struct bch_fs *c, u32 id)
...
@@ -202,8 +202,6 @@ static inline bool bch2_snapshot_has_children(struct bch_fs *c, u32 id)
static
inline
bool
snapshot_list_has_id
(
snapshot_id_list
*
s
,
u32
id
)
static
inline
bool
snapshot_list_has_id
(
snapshot_id_list
*
s
,
u32
id
)
{
{
u32
*
i
;
darray_for_each
(
*
s
,
i
)
darray_for_each
(
*
s
,
i
)
if
(
*
i
==
id
)
if
(
*
i
==
id
)
return
true
;
return
true
;
...
@@ -212,8 +210,6 @@ static inline bool snapshot_list_has_id(snapshot_id_list *s, u32 id)
...
@@ -212,8 +210,6 @@ static inline bool snapshot_list_has_id(snapshot_id_list *s, u32 id)
static
inline
bool
snapshot_list_has_ancestor
(
struct
bch_fs
*
c
,
snapshot_id_list
*
s
,
u32
id
)
static
inline
bool
snapshot_list_has_ancestor
(
struct
bch_fs
*
c
,
snapshot_id_list
*
s
,
u32
id
)
{
{
u32
*
i
;
darray_for_each
(
*
s
,
i
)
darray_for_each
(
*
s
,
i
)
if
(
bch2_snapshot_is_ancestor
(
c
,
id
,
*
i
))
if
(
bch2_snapshot_is_ancestor
(
c
,
id
,
*
i
))
return
true
;
return
true
;
...
...
fs/bcachefs/super.c
View file @
defd9e39
...
@@ -1937,7 +1937,7 @@ struct bch_fs *bch2_fs_open(char * const *devices, unsigned nr_devices,
...
@@ -1937,7 +1937,7 @@ struct bch_fs *bch2_fs_open(char * const *devices, unsigned nr_devices,
{
{
DARRAY
(
struct
bch_sb_handle
)
sbs
=
{
0
};
DARRAY
(
struct
bch_sb_handle
)
sbs
=
{
0
};
struct
bch_fs
*
c
=
NULL
;
struct
bch_fs
*
c
=
NULL
;
struct
bch_sb_handle
*
sb
,
*
best
=
NULL
;
struct
bch_sb_handle
*
best
=
NULL
;
struct
printbuf
errbuf
=
PRINTBUF
;
struct
printbuf
errbuf
=
PRINTBUF
;
int
ret
=
0
;
int
ret
=
0
;
...
...
fs/bcachefs/util.c
View file @
defd9e39
...
@@ -297,8 +297,6 @@ int bch2_save_backtrace(bch_stacktrace *stack, struct task_struct *task)
...
@@ -297,8 +297,6 @@ int bch2_save_backtrace(bch_stacktrace *stack, struct task_struct *task)
void
bch2_prt_backtrace
(
struct
printbuf
*
out
,
bch_stacktrace
*
stack
)
void
bch2_prt_backtrace
(
struct
printbuf
*
out
,
bch_stacktrace
*
stack
)
{
{
unsigned
long
*
i
;
darray_for_each
(
*
stack
,
i
)
{
darray_for_each
(
*
stack
,
i
)
{
prt_printf
(
out
,
"[<0>] %pB"
,
(
void
*
)
*
i
);
prt_printf
(
out
,
"[<0>] %pB"
,
(
void
*
)
*
i
);
prt_newline
(
out
);
prt_newline
(
out
);
...
...
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