From b4e3f36918e8022b7f6cb2100c3bd7e316daad5f Mon Sep 17 00:00:00 2001 From: David Horstmann Date: Thu, 16 Nov 2023 19:57:25 +0000 Subject: [PATCH] Change data pattern to simpler one Just use the index modulo 256, as this has a greater stride and is simpler to use. Signed-off-by: David Horstmann --- tests/suites/test_suite_psa_crypto_memory.function | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/tests/suites/test_suite_psa_crypto_memory.function b/tests/suites/test_suite_psa_crypto_memory.function index 29cb3eca13..81c52a3f7a 100644 --- a/tests/suites/test_suite_psa_crypto_memory.function +++ b/tests/suites/test_suite_psa_crypto_memory.function @@ -15,10 +15,8 @@ * been written, in a way that will detect an error in offset. */ static void fill_buffer_pattern(uint8_t *buffer, size_t len) { - uint8_t data[] = { 0x12, 0x34, 0x56, 0x78 }; - for (size_t i = 0; i < len; i++) { - buffer[i] = data[i % sizeof(data)]; + buffer[i] = (uint8_t) (i % 256); } } /* END_HEADER */