Remove "metadata_layout" parameter of the cache

This feature is replaced with LRU list shuffling.

Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
This commit is contained in:
Robert Baldyga
2022-03-07 17:20:03 +01:00
parent 9a956f59cd
commit d5b2c65a39
20 changed files with 33 additions and 277 deletions

View File

@@ -1,5 +1,5 @@
#
# Copyright(c) 2019-2021 Intel Corporation
# Copyright(c) 2019-2022 Intel Corporation
# SPDX-License-Identifier: BSD-3-Clause
#
@@ -82,10 +82,3 @@ def not_cache_line_size_randomize(request):
)
def not_promotion_policy_randomize(request):
return request.param
@pytest.fixture(
params=RandomGenerator(DefaultRanges.UINT32).exclude_range(enum_range(MetadataLayout))
)
def not_metadata_layout_randomize(request):
return request.param

View File

@@ -1,5 +1,5 @@
#
# Copyright(c) 2019-2021 Intel Corporation
# Copyright(c) 2019-2022 Intel Corporation
# SPDX-License-Identifier: BSD-3-Clause
#
@@ -73,25 +73,6 @@ def test_fuzzy_start_name(pyocf_ctx, string_randomize, cm, cls):
cache.stop()
@pytest.mark.security
@pytest.mark.parametrize("cm", CacheMode)
@pytest.mark.parametrize("cls", CacheLineSize)
def test_fuzzy_start_metadata_layout(pyocf_ctx, not_metadata_layout_randomize, cm, cls):
"""
Test whether it is impossible to start cache with invalid metadata layout value.
:param pyocf_ctx: basic pyocf context fixture
:param c_uint32_randomize: metadata layout enum value to start cache with
:param cm: cache mode value to start cache with
:param cls: cache line size value to start cache with
"""
with pytest.raises(OcfError, match="OCF_ERR_INVAL"):
try_start_cache(
metadata_layout=not_metadata_layout_randomize,
cache_mode=cm,
cache_line_size=cls
)
@pytest.mark.security
@pytest.mark.parametrize("cls", CacheLineSize)
@pytest.mark.parametrize('max_wb_queue_size', RandomGenerator(DefaultRanges.UINT32, 10))