summaryrefslogtreecommitdiff
path: root/linux/blkdev.c
AgeCommit message (Collapse)Author
2024-01-16Move c_src dirs back to toplevelKent Overstreet
We just wanted c sourcefiles out of the top level, not c source directories. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
2024-01-16move Rust sources to top level, C sources into c_srcThomas Bertschinger
This moves the Rust sources out of rust_src/ and into the top level. Running the bcachefs executable out of the development tree is now: $ ./target/release/bcachefs command or $ cargo run --profile release -- command instead of "./bcachefs command". Building and installing is still: $ make && make install Signed-off-by: Thomas Bertschinger <tahbertschinger@gmail.com> Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
2024-01-10kill bd_buffered_fdKent Overstreet
this gets us back down to a single fd for opening block devices, which means we can use O_EXCL. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
2024-01-10kill bd_sync_fdKent Overstreet
not needed with pwritev2(.., RWF_SYNC), and perhaps we can get down to one fd and then use O_EXCL for block devices. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
2023-09-29Handle -EAGAIN from io_submit()Kent Overstreet
If io_submit() returns -EAGAIN, that just means the io context is full and we need to wait for completions - no need to die. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
2023-09-23Update bcachefs sources to f9c612bbf82d bcachefs: Fixes for building in ↵Kent Overstreet
userspace Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
2023-07-15Update bcachefs sources to e14d7c7195 bcachefs: Compression levelsKent Overstreet
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
2023-03-08linux shim: Fix dropped O_DIRECT flagKent Overstreet
A recent libbcachefs update accidentally committed a change that dropped the O_DIRECT flag - we definitely didn't want to do that. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
2023-02-27Update bcachefs sources to ca97ee3577 bcachefs: ↵Kent Overstreet
bch2_btree_iter_peek_and_restart_outlined() Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
2023-02-09Update bcachefs sources to ea93c26e98 fixup! bcachefs: We can handle missing ↵Kent Overstreet
btree roots for all alloc btrees Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
2022-11-19linux/blkdev.c: Fall back to buffered IO when O_DIRECT failsKent Overstreet
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
2022-08-11Update bcachefs sources to 90a9c61e2b bcachefs: Switch ↵Kent Overstreet
bch2_btree_delete_range() to bch2_trans_run()
2022-06-22Fix bdev_logical_block_size()Kent Overstreet
We were returning sectors instead of bytes. Signed-off-by: Kent Overstreet <kent.overstreet@gmail.com>
2022-06-18cmd_dump: Use buffered IO for reading device metadataKent Overstreet
We're reading device metadat in mostly sequential order - buffered IO will be faster than O_DIRECT. Signed-off-by: Kent Overstreet <kent.overstreet@gmail.com>
2021-11-03Update bcachefs sources to 5fd0c70102 bcachefs: Fix __remove_dirent()Kent Overstreet
2021-10-16Fix 32 bit io regressionBrett Holman
In commit ba1dbafc1fce I reverted 9942fc82d43b, which was a workaround for an upstream 32bit libaio bug. Oops. Signed-off-by: Brett Holman <bholman.devel@gmail.com>
2021-10-10Fall back to synchronous io when kernel doesn't support aio.Brett Holman
Signed-off-by: Brett Holman <bholman.devel@gmail.com>
2021-10-09Correctly print out error from io_setup()Kent Overstreet
Signed-off-by: Kent Overstreet <kent.overstreet@gmail.com>
2021-09-22Make aio code use struct io_iocb_common to support 32 bit architecturesBrett Holman
Signed-off-by: Brett Holman <bholman.devel@gmail.com>
2021-04-30Update bcachefs sources to a5c0e1bb30 bcachefs: Clean up ↵Kent Overstreet
bch2_btree_and_journal_walk()
2019-12-04Put valgrind support behind CONFIG_VALGRINDKent Overstreet
2019-11-07Make userspace blkdev cleanup code more robust.Justin Husted
The existing cleanup code would silently cancel disk IO requests, if somehow the calling code did not wait for completion. This code now tracks requests and will bug if any are lost. Signed-off-by: Justin Husted <sigstop@gmail.com>
2019-11-07Fix refcount bug in blkdev and timer kthreads.Justin Husted
The shutdown code in d79d57e and b20e160 had a race condition during shutdown, due to not owning a reference on the associated task_struct while the associated threads shut themselves down. Patch over this by taking an appropriate reference. Signed-off-by: Justin Husted <sigstop@gmail.com>
2019-11-03Stop blkdev completion thread at process exit time, to make valgrindJustin Husted
happy. Signed-off-by: Justin Husted <sigstop@gmail.com>
2019-10-18Add valgrind handling: data read from io_submit was not being markedJustin Husted
properly. Manually mark it. This might be better done by improving the valgrind wrapper for io_submit.
2017-12-21Update bcachefs sources to 14ce2a2031 bcachefs: fixes for building in userspaceKent Overstreet
2017-08-23handle REQ_OP_FLUSHKent Overstreet
2017-08-23fix incorrect errno usageKent Overstreet
2017-05-05Update bcachefs sources to 3610542890 bcachefs: Convert to skcipher ↵Kent Overstreet
interface for chacha20
2017-05-05fix sync writes - don't use O_EXCLKent Overstreet
2017-04-23Use aioKent Overstreet
2017-04-14cmd_list improvements; use %mKent Overstreet
2017-03-09cmd_migrateKent Overstreet
2017-02-02linux shim: return an error on failure to openKent Overstreet
2017-01-20bcache in userspace; userspace fsckKent Overstreet