mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-12-28 05:24:47 +08:00
556910e392
Introduce an rq-qos policy that assigns an I/O priority to requests based on blk-cgroup configuration settings. This policy has the following advantages over the ioprio_set() system call: - This policy is cgroup based so it has all the advantages of cgroups. - While ioprio_set() does not affect page cache writeback I/O, this rq-qos controller affects page cache writeback I/O for filesystems that support assiociating a cgroup with writeback I/O. See also Documentation/admin-guide/cgroup-v2.rst. Cc: Damien Le Moal <damien.lemoal@wdc.com> Cc: Hannes Reinecke <hare@suse.de> Cc: Christoph Hellwig <hch@lst.de> Cc: Ming Lei <ming.lei@redhat.com> Cc: Johannes Thumshirn <johannes.thumshirn@wdc.com> Cc: Himanshu Madhani <himanshu.madhani@oracle.com> Signed-off-by: Bart Van Assche <bvanassche@acm.org> Link: https://lore.kernel.org/r/20210618004456.7280-5-bvanassche@acm.org Signed-off-by: Jens Axboe <axboe@kernel.dk>
20 lines
332 B
C
20 lines
332 B
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
|
|
#ifndef _BLK_IOPRIO_H_
|
|
#define _BLK_IOPRIO_H_
|
|
|
|
#include <linux/kconfig.h>
|
|
|
|
struct request_queue;
|
|
|
|
#ifdef CONFIG_BLK_CGROUP_IOPRIO
|
|
int blk_ioprio_init(struct request_queue *q);
|
|
#else
|
|
static inline int blk_ioprio_init(struct request_queue *q)
|
|
{
|
|
return 0;
|
|
}
|
|
#endif
|
|
|
|
#endif /* _BLK_IOPRIO_H_ */
|