Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
494 commits
Select commit Hold shift + click to select a range
a57c3ef
vfs: fix buffered read data corruption from stale bi_iter on restart
Jul 24, 2026
516edf1
read: fix stale BCH_READ_last_fragment across retries in __bch2_read()
Jul 24, 2026
3e8923d
dkms: explain a skipped or impossible prebuilt-module fetch
Jul 24, 2026
1782589
fsck: bound trans mem in check_dirent's per-snapshot repair loops
Jul 20, 2026
8d06d92
tools: make kfree_rcu() and friends actually wait for a grace period
Jul 29, 2026
8bc0fc4
fsck: bound trans mem in check_xattr's acl-flag repair loops
Jul 21, 2026
305df77
btree: bound trans mem in insert_snapshot_whiteouts during fsck
Jul 21, 2026
40e7279
docs: stripe layout: ec_max_data_blocks and failure domains bound str…
Jul 22, 2026
997f4c3
bcachefs: use 64-bit inode numbers in VFS layer to fix 32-bit truncation
thomas7475 Jul 28, 2026
42fbfad
fusemount: zero-initialize timespec padding and deduplicate setattr()
thomas7475 Jul 28, 2026
465df9b
copy_fs: zero-initialize timespec64 padding and clean up copy_times()
thomas7475 Jul 28, 2026
8c04a4b
fusemount: fix indentation
Jul 28, 2026
56f1411
Replace 64-bit divisions with div64_u64 in several places.
thomas7475 Jul 28, 2026
7ab8a28
bindgen the block device ioctl numbers
thomas7475 Jul 28, 2026
c37b19d
btree: gc doesn't count snapshot keys in non-snapshotted btrees
Jul 25, 2026
fc9f42a
fsck: repair stale-state legacy tombstones
Jul 20, 2026
40be408
fsck: resolve damaged paths through surviving snapshot versions
Jul 20, 2026
f68a76d
fsck: print the parent directory path for inodes with a missing namin…
Jul 19, 2026
cef79a2
fsck: record str_hash duplicate repairs in the damage report
Jul 20, 2026
062df1a
snapshots: commit the collection loop per-key, make collection idempo…
Jul 21, 2026
75c7852
subvolumes: flush pending updates before set_deleted's reparent
Jul 21, 2026
4ebf120
fsck: verify the deletion chain in the subvol-root missing-subvol exe…
Jul 21, 2026
c8b8511
inode: BCH_INODE_unlinked semantics + subvolume-root ownership helpers
Jul 21, 2026
19eeb6e
fs: guard the inode reaper against subvolume roots
Jul 21, 2026
7b37099
fsck: unlinked subvolume roots carry BCH_INODE_unlinked
Jul 21, 2026
ff177e6
namei: flag the subvolume root inode unlinked at subvolume deletion
Jul 21, 2026
367e2aa
namei: subvolume deletion via rename-overwrite of the root
Jul 21, 2026
93017ae
fsck: fix unflagged interior-snapshot update in dirent parent_subvol …
Jul 21, 2026
99273b5
fsck: fix restart-count leak in bch2_check_key_has_inode repairs
Jul 21, 2026
a64cefd
fsck: dirents to tombstoned subvolumes are dirents to missing subvolumes
Jul 21, 2026
d726a03
fsck: recreate a missing root subvolume at its real snapshot
Jul 21, 2026
154a777
fsck: references to the root subvolume are never the broken side
Jul 21, 2026
405096b
fsck: don't reinitialize an existing root inode to fix its mode
Jul 21, 2026
8aeaae4
fsck: promote the check_root repair trio to FSCK_AUTOFIX
Jul 21, 2026
d44a9d0
snapshots: commit validate: subvol backrefs only on live/will_delete …
Jul 22, 2026
799b921
snapshots: check_snapshot corroborates non-live states against both w…
Jul 22, 2026
153d915
fsck: restore a wiped subvol backref from the claiming subvolume
Jul 22, 2026
4b876ff
fsck: check_snapshot_exists() uses subvol_claiming_snapshot()
Jul 22, 2026
24dced5
fsck: promote dirent_to_missing_subvol to FSCK_AUTOFIX
Jul 22, 2026
8998eba
fsck: split check_snapshot(); organize check_snapshots.c
Jul 22, 2026
b8685d6
fsck: arbitrate a deleted-but-linked snapshot node by its accounting
Jul 22, 2026
cae3f67
snapshots: bch2_snapshot_node_delete() shouldn't destroy information
Jul 22, 2026
5b919d8
fsck: undeleting a snapshot node splices it back into the tree
Jul 22, 2026
f6da727
fsck: a not-deleted snapshot must not point at a deleted node
Jul 22, 2026
6838e4e
fsck: relinking an undeleted snapshot requires another check_snapshot…
Jul 22, 2026
6b943df
fsck: BCH_INODE_unlinked on a directory requires an unlinked subvolume
Jul 22, 2026
11f446c
fsck: check_snapshot_to_subvol() reads the subvolume raw
Jul 22, 2026
c0204c7
snapshots: to_text distinguishes not-upgraded and invalid state fields
Jul 23, 2026
28b891f
recovery: RUN_RECOVERY_PASS_skip_if_complete; fixes check_key_has_sna…
Jul 23, 2026
e64df91
recovery: cleanup error report
Jul 23, 2026
b082e8f
fsck: check_snapshot_to_subvol: check the snapshot<->subvolume bicond…
Jul 23, 2026
568a540
fsck: reconstruct a missing subvolume on corroborating witnesses
Jul 23, 2026
a27a99a
fsck: inode_unlinked_but_has_dirent is now autofix
Jul 24, 2026
d101ef4
accounting: split bch2_disk_accounting_mod()
Jul 25, 2026
953ff02
accounting: improve inlining
Jul 25, 2026
ac92bb0
accounting: snapshot accounting is mem for repair
Jul 24, 2026
bc05457
alloc: uninline trigger_pointer slowpaths
Jul 25, 2026
2f9ecea
snapshots: read snapshot accounting from the accounting btree
Jul 24, 2026
704e64a
accounting: assert bch2_accounting_mem_read() is only used on in-mem …
Jul 24, 2026
57d2851
snapshots: runtime deletion refusal is not an error
Jul 24, 2026
0e9c45a
snapshots: check_no_data schedules the passes that can actually repair
Jul 24, 2026
2b3d856
fsck: check_no_data schedules repair with run_explicit, not require
Jul 25, 2026
19dc6c7
fsck: drop the undelete arm's same-pass require of check_snapshots
Jul 25, 2026
2a08085
snapshots: recover the splice point for wiped tombstones
Jul 25, 2026
91d020f
fsck: snapshot node undelete fixes
Jul 25, 2026
fe149f2
debug: expose the full fsck damaged-paths list in debugfs
Jul 25, 2026
8ba0384
fsck: record inode damage in __bch2_fsck_err(), as bch_sb_error_id
Jul 25, 2026
604d29e
fsck: audit fsck_err() sites for inode-scoped damage recording
Jul 25, 2026
72429be
fsck: fix null deref in reconstruct_inode() on an extent-less inum
Jul 26, 2026
a19d648
inode: don't strand content when snapshot-version content deletion fails
Jul 26, 2026
cdd74b7
fsck: make bch2_reattach_inode() resumable under partial commits
Jul 27, 2026
f6125cc
fsck: snapshot_subvol_flag_wrong is a live-nodes-only check
Jul 27, 2026
1a88714
sb errors: v2 entries with the time of first occurrence
Jul 28, 2026
8221539
sb errors: merge coexisting legacy and v2 sections on read
Jul 28, 2026
cb0afc4
percpu shim: 256M dynamic arenas, reserved not allocated
Jul 28, 2026
c8317ba
percpu shim: install the chunk before publishing the slot
Jul 29, 2026
dfe357b
fsck: bring back childless snapshot node undelete
Jul 28, 2026
61378d4
btree: document that write_buffer_flush_sync() drops locks
Jul 29, 2026
52a05b2
read: fix the never-firing BLK_STS_INVAL bio dump
Jul 28, 2026
0236b5f
codegen: don't blocklist source trees under /usr paths
Jul 28, 2026
4dd1376
format: reject --version together with --source
Jul 28, 2026
9831683
nix: make the doc target actually build the document
Jul 29, 2026
4d99781
snapshot: stop deleting accounting keys on snapshot delete
Jul 29, 2026
d1cb718
damage: new btree - a persistent record of damaged inodes
Jul 23, 2026
9bea69f
damage: record data read errors
Jul 28, 2026
d1275c1
damage: record data lost to device force removal
Jul 28, 2026
25b8225
fsck: extent_ptrs_all_invalid errors are inode-scoped
Jul 28, 2026
890711c
fsck: dup_extents_to_reflink records damage against both inodes
Jul 28, 2026
e1aecb7
fsck: remove dead inum in check_snapshot_keys
Jul 28, 2026
8175ab9
namei: bch2_inum_is_descendant()
Jul 24, 2026
5c6458e
vfs: BCHFS_IOC_READDIR_FLAGS
Jul 27, 2026
b6c5a6f
vfs: BCHFS_IOC_GET_DAMAGE and BCH_READDIR_damaged
Jul 27, 2026
91c70ad
vfs: BCHFS_IOC_READDIR_FLAGS recursive damaged mode
Jul 24, 2026
dd54cae
vfs: BCHFS_IOC_CLEAR_DAMAGE
Jul 28, 2026
a4887e0
damage: new subcommand - show recorded filesystem damage
Jul 24, 2026
ec9dc62
fs: generate a typed ioctl inventory from bcachefs_ioctl.h
Jul 28, 2026
68f50e0
tools: use the generated ioctl inventory everywhere
Jul 28, 2026
664c4fe
tools: thread BorrowedFd through the ioctl paths
Jul 28, 2026
7bee7d8
tools: IoctlBuf for flexible-array ioctl arguments
Jul 28, 2026
b52f1ce
sb: validated views for superblocks in raw buffers
Jul 28, 2026
e9331db
tools: convert superblock IO to the validated sb views
Jul 28, 2026
bf2c534
kvdb: use the bkey and superblock helpers
Jul 28, 2026
a0a9f80
damage: drop the remaining removable unsafe
Jul 28, 2026
0fb897b
tools: convert to existing safe helpers
Jul 28, 2026
ca78084
format: DevOpts owns its fd; handle methods for format's sb calls
Jul 28, 2026
b31d1c8
opts: safe lookup/parse/set API in fs/opts.rs
Jul 28, 2026
c2b3fc4
tools: offline set-fs-option and set-state actually write the superblock
Jul 28, 2026
225beb1
sb: count block statuses individually
Jul 28, 2026
e1aba3d
ioctl: revert bch_ioctl_snapshot_node memory layout change
Jul 28, 2026
8975000
read: only count blk statuses for block layer failures
Jul 28, 2026
079f119
snapshot: say which deletion refused, and what the node looks like
Jul 28, 2026
65308ac
snapshots: deletion_v1 processes inodes last
Jul 19, 2026
b9ab5a4
snapshot: dump the keys a refused deletion left behind
Jul 29, 2026
838814d
snapshot: print what each node holds before deleting it
Jul 29, 2026
150e029
snapshots: kill skip_unrelated_snapshot_tree()
Jul 29, 2026
ec5e821
snapshot: check content accounting before deleting inode keys
Jul 29, 2026
9462caf
snapshot: read accounting from memory, drop the write buffer flushes
Jul 29, 2026
9833659
fsck: fix -ENOMEM in check_dirents
Jul 29, 2026
42542d5
btree: bch2_bkey_get_i_typed(), and a subvolume variant
Jul 29, 2026
4b6f715
fsck: skip already-correct backpointers in bch2_fsck_update_backpointers
Jul 26, 2026
5bf9add
fsck: print the subvolume key when its root inode is missing
Jul 29, 2026
7f280d3
subvolume: fix bch2_subvolume_reparent() claiming every legacy key
Jul 29, 2026
4675f78
btree: document the pad-on-read, extend-on-write rule
Jul 29, 2026
8496a13
snapshot: bch2_snapshot_lookup_key()
Jul 29, 2026
2a4ff9f
fsck: print the nodes an edge repair is between
Jul 29, 2026
4c5eaac
fsck: print the inode on the checks that only named it
Jul 29, 2026
a0740a4
btree: bkey_has_field()
Jul 29, 2026
533574c
fsck: print the inode on wrong-nlink and wrong-i_sectors
Jul 29, 2026
8840075
doc: snapshots and snapshot deletion
Jul 29, 2026
09630ea
doc: safety mechanisms
Jul 29, 2026
6a2bc6e
fsck: say what's actually checked, not what it's a witness to
Jul 29, 2026
b990b7b
snapshots: fall back to the v1 scan when accounting says v2 missed keys
Jul 29, 2026
0ef0ec3
kill_btree_node: --error, and a csum error type
Jul 29, 2026
d8c3107
snapshots: don't splice past a deleted node that still owns data
Jul 30, 2026
3acc57e
snapshots: check_snapshot() settles the state field against data first
Jul 30, 2026
f68227a
fsck: autofix inode_bi_subvol_missing
Jul 30, 2026
7ad31f5
snapshots: check_subvols repairs the subvolume's snapshot edge
Jul 30, 2026
a4d6c31
snapshots: check_subvols settles the snapshot edge before repairing it
Jul 31, 2026
e934df8
fetch-module: fetch the compressed module
Jul 31, 2026
d7323cc
packaging: declare the tools fetch-module.sh shells out to
Jul 31, 2026
9fa50fd
snapshots: drop the stranded-key scan from the refusal diagnostic
Jul 31, 2026
a24b3a4
bcachefs: lift the snapshot deletion refusals into their own function
Aug 1, 2026
2770df2
bcachefs: check the whole delete list before deleting any of it
Aug 1, 2026
9355b10
bcachefs: a snapshot deletion refusal isn't a mount failure
Aug 1, 2026
6799159
bcachefs: undelete can relink to a no_keys neighbour
Aug 1, 2026
ae893b4
bcachefs-tools: kvdb --rw stops at going read-write
Aug 1, 2026
a852c54
errcode: zstd errors belong to the decompress error class
Aug 1, 2026
3046e87
compress: count decompression failures, per compression type
Aug 1, 2026
5db62e6
fsck: SNAPSHOT_STATE_no_keys must not have keys
Aug 1, 2026
dc27915
fsck: a key in a deleted snapshot must settle the state first
Aug 1, 2026
39f1a3b
fsck: check_snapshot checks snapshot state first
Aug 2, 2026
c749ccc
recovery: option to skip superblock-scheduled passes
Aug 2, 2026
bd54b6b
kvdb: don't run the superblock's scheduled repair passes
Aug 2, 2026
7eccdc0
errors: KEY_TYPE_error reasons for decompression failures
Aug 2, 2026
22dc71a
write: document the opts/csum_type/crc layering
Aug 2, 2026
8943f05
write: don't touch the bio until the decompressed data is ready
Aug 2, 2026
edbf8a2
alloc: helper for retiring open buckets that came up short
Aug 2, 2026
2da9892
write: fresh buckets for an extent that won't decompress
Aug 2, 2026
14bbfea
upgrade: new snapshot accounting requires check_allocations
Aug 2, 2026
9dbf413
fsck: a snapshot holding only metadata isn't empty
Aug 2, 2026
7f6d022
fsck: an unstartable filesystem is an operational error
Aug 2, 2026
7c06e35
fsck: a missing snapshot node is a fact, not an error
Aug 2, 2026
731d582
fsck: recreate a child snapshot node that was destroyed
Aug 2, 2026
6a73af4
ec: can_form_ec_stripe() must model what the allocator actually refuses
matthiasgoergens Jul 31, 2026
9281bea
ec: refuse an oversized target group before folding it to disk_label 0
matthiasgoergens Aug 2, 2026
af19a59
extents: bch2_bkey_replicas() should honour KEY_TYPE_reservation
matthiasgoergens Jul 30, 2026
3086a2c
extents: one walk of a key's pointers, all the answers
Aug 2, 2026
a440f30
extents: reservations have a durability too
Aug 2, 2026
7f4ec53
write: sum_sector_overwrites walks each key once
Aug 2, 2026
2b368e0
extents: one durability helper, not six
Aug 2, 2026
df3e3bb
fs/Makefile: only rewrite -Zno-jump-tables when rustc accepts the sta…
matthiasgoergens Jul 30, 2026
42fb7d4
build: allow the lifetime lints the vendored uuid trips
Aug 2, 2026
cfb9b66
fusemount: don't start the http server from a pthread_atfork handler
matthiasgoergens Aug 1, 2026
201e646
fusemount: shut the filesystem down when the mount fails
matthiasgoergens Aug 1, 2026
3c4881f
fusemount: apply the same cleanup to the foreground path
matthiasgoergens Aug 1, 2026
7c2e34b
fusemount: don't leave the filesystem dirty when try_clone() fails
matthiasgoergens Aug 2, 2026
ca96918
fusemount: report what the child actually failed at
matthiasgoergens Aug 2, 2026
94af7a4
journal: report the real wait in the "Journal stuck?" message
matthiasgoergens Jul 31, 2026
f4114e8
journal: size the stuck-warning timeout over every device it waits on
matthiasgoergens Aug 2, 2026
837eb15
bcachefs.h: remove unused bch_dev.flush_seq
matthiasgoergens Aug 2, 2026
fd54e8e
doc: .claude/ is working notes, not repository documentation
Aug 2, 2026
3be9383
btree: reading a node is not repairing it
Aug 3, 2026
96132cb
errors: bset_bad_csum is autofix
Aug 3, 2026
48586ef
fsck: check redundant-interior snapshot nodes in the collapse-target …
Jul 19, 2026
a5eba33
fsck: propagate a descendant's dirent to unreachable ancestor inodes
Jul 27, 2026
3a8fe7c
extents: bch2_bkey_durability_safe() takes a const fs again
Aug 3, 2026
804aacd
fsck: create_lostfound() must filter dirents the same way its lookup …
Aug 3, 2026
8da6b04
fsck: check that lost+found will be visible to whoever asked for it
Aug 3, 2026
44ab47f
fsck: restore lost+found when it was deleted in this snapshot
Aug 3, 2026
64b43af
fsck: take the link on lost+found's parent directory
Aug 3, 2026
204eefc
fsck: dirent_not_visible_in_parent_subvol is autofix
Aug 3, 2026
5ffbc8b
v1.39.0
Aug 1, 2026
75496ad
fix(merge): fix userspace compile errors
jullanggit Aug 4, 2026
95e1613
scrub: cancel per-device jobs in parallel on interrupt
zorbathut Aug 4, 2026
e29c376
bch_bindgen: export the block ioctl numbers as C constants
Aug 5, 2026
fd96e66
Changelog: fix ZorbaTHut's name
Aug 5, 2026
2184451
move: don't audit unwalked buckets when the walk is aborted
zorbathut Aug 4, 2026
52532f0
move: return an error when a move is cancelled
Aug 5, 2026
2d376fe
build: make the build scripts dependencies of the binary
Aug 5, 2026
4beb4a8
fsck: don't walk back to an ancestor version of a subvolume root
Aug 5, 2026
c068045
fsck: remove the right dirent when a subvolume root has two
Aug 5, 2026
074f2a5
fsck: give lost+found an inode in the snapshot the reattach dirent la…
Aug 5, 2026
7605edd
fsck: a reattached subvolume root doesn't bump lost+found's nlink
Aug 5, 2026
fcbfdfa
sb: FSCK_AUTOFIX for inode_bi_subvol_wrong
Aug 5, 2026
86299b5
fsck: don't dereference an error from bch2_inode_get_dirent()
Aug 5, 2026
67f4579
fsck: don't leak a tolerated ENOENT out of check_snapshot_tree()
Aug 5, 2026
74af1f0
fsck: repair the subvolume to match the dirent we just rewrote
Aug 5, 2026
be29198
fsck: reconstruct a snapshotted subvolume that lost its key
Aug 5, 2026
83ecd25
package-ci: capture what's actually deployed
Aug 5, 2026
325b991
package-ci: don't report a queued build that wasn't
Aug 5, 2026
eabd613
package-ci: make releases visible on the status page
Aug 5, 2026
49facc9
package-ci: narrow a claim in the post-receive comment
Aug 5, 2026
641fd72
vfs: give the by-inum hash its own entry type
Aug 6, 2026
de23170
vfs: hold an inum hash entry across tmpfile creation
Aug 6, 2026
2c3f334
snapshots: a childless root undeletes in place
Aug 6, 2026
57c3d4d
bcachefs: shrink: don't count free buckets in shrink tail as free
jullanggit Jul 16, 2026
4dcc51c
shrink: make copygc shrink-aware for wait and free buckets amount
jullanggit Aug 6, 2026
376f228
(I think) remove obvious reconicle-ec-shrink blockers
jullanggit Jul 19, 2026
0bd1c41
flush outstanding ec
jullanggit Aug 4, 2026
4477edd
add logging for the stalling tail head
jullanggit Aug 4, 2026
9f2d5a5
add more logging
jullanggit Aug 4, 2026
0a3a1f5
attempt ec fix
jullanggit Aug 4, 2026
812384a
more logging
jullanggit Aug 4, 2026
1bc7b6d
some kind of fix
jullanggit Aug 4, 2026
aaa6043
more logging
jullanggit Aug 4, 2026
fc42c25
attempt fix
jullanggit Aug 4, 2026
344dd2a
fix?
jullanggit Aug 4, 2026
8819bb9
fix + logging
jullanggit Aug 4, 2026
5c6102e
mostly fix
jullanggit Aug 4, 2026
a9ea26a
logging
jullanggit Aug 4, 2026
42d8bc0
fix + logging
jullanggit Aug 4, 2026
d832417
diagnostics
jullanggit Aug 4, 2026
05c69d9
inconsistency fixes
jullanggit Aug 4, 2026
2cea0c4
logging
jullanggit Aug 4, 2026
3fe44df
run alloc check pass on next mount after shrink; required as ec-accou…
jullanggit Aug 4, 2026
7cbc6b1
TODO(squash): remove logs
jullanggit Aug 4, 2026
7da1b0c
reformulate comment
jullanggit Aug 4, 2026
0ae9623
remove debugging
jullanggit Aug 4, 2026
69f3315
ec: fix memory leak through stack-allocated alloc_request
jullanggit Aug 5, 2026
69207c2
shrink: ec: revert extent-level move
jullanggit Aug 6, 2026
0b668a5
add and use stripe_dev_and_region_matches helper
jullanggit Aug 6, 2026
8c7bdfc
use PTR_BUCKET_NR helper where applicable
jullanggit Aug 6, 2026
f251ba4
stripe_update_extent(): simplify a condition and add newline to error…
jullanggit Aug 6, 2026
f8d713b
shrink: schedule accounting recovery pass before entering reconcile loop
jullanggit Aug 6, 2026
0b96f97
rework comments
jullanggit Aug 6, 2026
a665ab3
merge
jullanggit Aug 7, 2026
71853ae
fix(ec): commit needs-reconcile zeroing on empty stripe
jullanggit Aug 7, 2026
44d544c
bch2_trigger_extent: guard in-place reconcile_phys update optimizatio…
jullanggit Aug 7, 2026
e0003ca
add bcachefs device resize cancel
jullanggit Jun 24, 2026
5ba9f57
flake.lock: Update
github-actions[bot] Aug 7, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,9 +63,12 @@ software development. When approaching a new problem:
rather than planning and implementing entire features in one pass.

Research and analysis notes are a first-class output, not just
scaffolding for implementation. They should be dated and checked into the
repository under `.claude/` so that future developers (human and AI) can
see what's been analyzed and what was decided.
scaffolding for implementation. They go in `.claude/`, dated, so that
later work can see what's been analyzed and what was decided.

`.claude/` is deliberately untracked — these are working notes, not
documentation for general consumption. Anything that belongs in the
repository proper goes in `doc/`, written for that audience.

### Calibrate to the risk

Expand Down
Loading