Lines Matching +full:pages +full:- +full:count

2  * Copyright (c) 2020-2024 Nordic Semiconductor ASA
4 * SPDX-License-Identifier: Apache-2.0
22 * fixed-partition nodes.
64 TC_PRINT("Test will run on device %s\n", flash_dev->name); in flash_driver_before()
71 erase_value = fparams->erase_value; in flash_driver_before()
80 page_info.size = TEST_AREA_MAX - TEST_AREA_OFFSET; in flash_driver_before()
116 /* Erase a nb of pages aligned to the EXPECTED_SIZE */ in flash_driver_before()
119 ((EXPECTED_SIZE + page_info.size - 1) in flash_driver_before()
136 /* Erase a nb of pages aligned to the EXPECTED_SIZE */ in ZTEST()
139 ((EXPECTED_SIZE + page_info.size - 1) in ZTEST()
159 buf[buf_o - 1] = canary; in ZTEST()
172 zassert_equal(buf[buf_o - 1], canary, in ZTEST()
190 /* Erase a nb of pages aligned to the EXPECTED_SIZE */ in ZTEST()
193 ((EXPECTED_SIZE + page_info.size - 1) in ZTEST()
200 ((EXPECTED_SIZE + page_info.size - 1) in ZTEST()
208 ((EXPECTED_SIZE + page_info.size - 1) in ZTEST()
232 ((EXPECTED_SIZE + page_info.size - 1) in ZTEST()
240 ((EXPECTED_SIZE + page_info.size - 1) in ZTEST()
263 erase_value = fparams->erase_value; in ZTEST()
282 /* Cross check - confirm that expected data is pseudo-random */ in ZTEST()
285 /* Erase a nb of pages aligned to the EXPECTED_SIZE */ in ZTEST()
288 (page_info.size * ((EXPECTED_SIZE + page_info.size - 1) / page_info.size))); in ZTEST()
304 /* Cross check - confirm that expected data in ZTEST()
311 uint32_t page_counter; /* used to count how many pages was iterated */
319 cb_data->page_counter++; in flash_callback()
321 if (cb_data->page_counter >= cb_data->exit_page) { in flash_callback()
330 #if CONFIG_TEST_DRIVER_FLASH_SIZE != -1 in ZTEST()
379 "page_count = %d not equal to pages counted with cb = %d", page_count, in ZTEST()
387 "%d pages were iterated while it shall stop on page %d", in ZTEST()
431 * - src_dev or dst_dev are invalid in ZTEST()
432 * - src_offset or dst_offset are invalid in ZTEST()
433 * - src_offset + size or dst_offset + size overflow in ZTEST()
434 * - buf is NULL in ZTEST()
435 * - buf size is invalid in ZTEST()
437 test_flash_copy_inner(NULL, -1, NULL, -1, -1, NULL, 0, -EINVAL); in ZTEST()
438 test_flash_copy_inner(NULL, -1, NULL, -1, -1, NULL, sizeof(buf), -EINVAL); in ZTEST()
439 test_flash_copy_inner(NULL, -1, NULL, -1, -1, buf, sizeof(buf), -EINVAL); in ZTEST()
440 test_flash_copy_inner(NULL, -1, NULL, -1, page_info.size, buf, sizeof(buf), -EINVAL); in ZTEST()
441 test_flash_copy_inner(NULL, -1, NULL, -1, page_info.size, buf, sizeof(buf), -EINVAL); in ZTEST()
444 sizeof(buf), -ENODEV); in ZTEST()
449 /* zero-sized copy should succeed */ in ZTEST()
459 sizeof(buf), -EINVAL); in ZTEST()
463 page_info.start_offset + 32, page_info.size - 32, buf, sizeof(buf), in ZTEST()
464 -EINVAL); in ZTEST()