Set NOMERGES flag for cache volume
Signed-off-by: Michal Mielewczyk <michal.mielewczyk@huawei.com> Signed-off-by: Rafal Stefanowski <rafal.stefanowski@huawei.com>
This commit is contained in:
committed by
Rafal Stefanowski
parent
20276bd9c1
commit
33721e7c92
@@ -1,6 +1,7 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
# Copyright(c) 2012-2022 Intel Corporation
|
||||
# Copyright(c) 2024 Huawei Technologies
|
||||
# SPDX-License-Identifier: BSD-3-Clause
|
||||
#
|
||||
|
||||
@@ -45,6 +46,11 @@ apply() {
|
||||
exp_q->limits.max_hw_sectors = core_q->limits.max_hw_sectors;
|
||||
exp_q->limits.max_segments = core_q->limits.max_segments;
|
||||
exp_q->limits.max_write_same_sectors = 0;
|
||||
}"
|
||||
|
||||
add_function "
|
||||
static inline void cas_cache_set_no_merges_flag(struct request_queue *cache_q)
|
||||
{
|
||||
if (queue_virt_boundary(cache_q))
|
||||
queue_flag_set(QUEUE_FLAG_NOMERGES, cache_q);
|
||||
}" ;;
|
||||
@@ -59,6 +65,11 @@ apply() {
|
||||
exp_q->limits.max_segments = core_q->limits.max_segments;
|
||||
exp_q->limits.max_write_same_sectors = 0;
|
||||
exp_q->limits.max_write_zeroes_sectors = 0;
|
||||
}"
|
||||
|
||||
add_function "
|
||||
static inline void cas_cache_set_no_merges_flag(struct request_queue *cache_q)
|
||||
{
|
||||
}" ;;
|
||||
"3")
|
||||
add_function "
|
||||
@@ -70,6 +81,11 @@ apply() {
|
||||
exp_q->limits.max_hw_sectors = core_q->limits.max_hw_sectors;
|
||||
exp_q->limits.max_segments = core_q->limits.max_segments;
|
||||
exp_q->limits.max_write_zeroes_sectors = 0;
|
||||
}"
|
||||
|
||||
add_function "
|
||||
static inline void cas_cache_set_no_merges_flag(struct request_queue *cache_q)
|
||||
{
|
||||
}" ;;
|
||||
"4")
|
||||
add_function "
|
||||
@@ -81,6 +97,11 @@ apply() {
|
||||
exp_q->limits.max_hw_sectors = core_q->limits.max_hw_sectors;
|
||||
exp_q->limits.max_segments = core_q->limits.max_segments;
|
||||
exp_q->limits.max_write_same_sectors = 0;
|
||||
}"
|
||||
|
||||
add_function "
|
||||
static inline void cas_cache_set_no_merges_flag(struct request_queue *cache_q)
|
||||
{
|
||||
}" ;;
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user