mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 11:41:38 -04:00
cfq: improve fsync performance for small files
Fsync performance for small files achieved by cfq on high-end disks is lower than what deadline can achieve, due to idling introduced between the sync write happening in process context and the journal commit. Moreover, when competing with a sequential reader, a process writing small files and fsync-ing them is starved. This patch fixes the two problems by: - marking journal commits as WRITE_SYNC, so that they get the REQ_NOIDLE flag set, - force all queues that have REQ_NOIDLE requests to be put in the noidle tree. Having the queue associated to the fsync-ing process and the one associated to journal commits in the noidle tree allows: - switching between them without idling, - fairness vs. competing idling queues, since they will be serviced only after the noidle tree expires its slice. Acked-by: Vivek Goyal <[email protected]> Reviewed-by: Jeff Moyer <[email protected]> Tested-by: Jeff Moyer <[email protected]> Signed-off-by: Corrado Zoccolo <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
This commit is contained in:
parent
6d0aed7a38
commit
749ef9f842
3 changed files with 6 additions and 16 deletions
|
|
@ -318,7 +318,7 @@ void journal_commit_transaction(journal_t *journal)
|
|||
int first_tag = 0;
|
||||
int tag_flag;
|
||||
int i;
|
||||
int write_op = WRITE;
|
||||
int write_op = WRITE_SYNC;
|
||||
|
||||
/*
|
||||
* First job: lock down the current transaction and wait for
|
||||
|
|
|
|||
Loading…
Reference in a new issue