Skip to content

Commit

Permalink
use O_DIRECT as preferred
Browse files Browse the repository at this point in the history
Signed-off-by: Yuchen Liang <[email protected]>
  • Loading branch information
yliang412 committed Oct 1, 2024
1 parent 2607a57 commit f48ab8b
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion libs/pageserver_api/src/models.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1005,7 +1005,11 @@ pub mod virtual_file {

impl IoMode {
pub const fn preferred() -> Self {
Self::Buffered
if cfg!(target_os = "linux") {
Self::Direct
} else {
Self::Buffered
}
}
}

Expand Down

0 comments on commit f48ab8b

Please sign in to comment.