Home
last modified time | relevance | path

Searched refs:BUF_SIZE (Results 1 – 25 of 26) sorted by relevance

12

/Zephyr-latest/samples/drivers/memc/src/
Dmain.c54 #define BUF_SIZE 1024 macro
56 uint8_t memc_write_buffer[BUF_SIZE];
57 uint8_t memc_read_buffer[BUF_SIZE];
65 for (i = 0; i < BUF_SIZE; i++) { in main()
71 for (i = 0, j = 0; j < (MEMC_SIZE / BUF_SIZE); i += BUF_SIZE, j++) { in main()
72 memcpy(memc + i, memc_write_buffer, BUF_SIZE); in main()
79 for (i = 0, j = 0; j < (MEMC_SIZE / BUF_SIZE); i += BUF_SIZE, j++) { in main()
80 memcpy(memc_read_buffer, memc + i, BUF_SIZE); in main()
82 if (memcmp(memc_read_buffer, memc_write_buffer, BUF_SIZE)) { in main()
84 i, i + (BUF_SIZE - 1)); in main()
[all …]
/Zephyr-latest/tests/drivers/spi/spi_loopback/src/
Dspi_rtio.c41 #define BUF_SIZE 17 macro
45 static const char tx_data[BUF_SIZE] = "0123456789abcdef\0";
46 static __aligned(32) char buffer_tx[BUF_SIZE] __used __attribute__((__section__(".nocache")));
47 static __aligned(32) char buffer_rx[BUF_SIZE] __used __attribute__((__section__(".nocache")));
54 static uint8_t buffer_rx[BUF_SIZE] = {};
64 static uint8_t buffer_print_tx[BUF_SIZE * 5 + 1];
65 static uint8_t buffer_print_rx[BUF_SIZE * 5 + 1];
90 buffer_tx, buffer_rx, BUF_SIZE, NULL); in spi_complete_multiple()
108 if (memcmp(buffer_tx, buffer_rx, BUF_SIZE)) { in spi_complete_multiple()
109 to_display_format(buffer_tx, BUF_SIZE, buffer_print_tx); in spi_complete_multiple()
[all …]
Dspi.c59 #define BUF_SIZE 18 macro
72 static const char tx_data[BUF_SIZE] = "0123456789abcdef-\0";
73 static __aligned(32) char buffer_tx[BUF_SIZE] __used __NOCACHE;
74 static __aligned(32) char buffer_rx[BUF_SIZE] __used __NOCACHE;
86 static uint8_t buffer_print_tx[BUF_SIZE * 5 + 1];
87 static uint8_t buffer_print_rx[BUF_SIZE * 5 + 1];
111 tx_bufs[0].len = BUF_SIZE; in spi_complete_multiple()
124 rx_bufs[0].len = BUF_SIZE; in spi_complete_multiple()
140 if (memcmp(buffer_tx, buffer_rx, BUF_SIZE)) { in spi_complete_multiple()
141 to_display_format(buffer_tx, BUF_SIZE, buffer_print_tx); in spi_complete_multiple()
[all …]
/Zephyr-latest/tests/drivers/memc/ram/src/
Dmain.c13 #define BUF_SIZE 64U macro
14 #define BUF_DEF(label) static uint32_t buf_##label[BUF_SIZE] \
61 test_ram_rw(buf_sdram1, BUF_SIZE); in ZTEST()
79 test_ram_rw(buf_sdram2, BUF_SIZE); in ZTEST()
88 test_ram_rw(buf_sram1, BUF_SIZE); in ZTEST()
97 test_ram_rw(buf_sram2, BUF_SIZE); in ZTEST()
106 test_ram_rw(buf_psram, BUF_SIZE); in ZTEST()
/Zephyr-latest/samples/net/sockets/tcp/src/
Dmain.c67 #ifndef BUF_SIZE in udp()
68 #define BUF_SIZE 4096 in udp() macro
70 char *buf = malloc(BUF_SIZE); in udp()
77 ssize_t len = recv(fd, buf, BUF_SIZE, 0); in udp()
/Zephyr-latest/tests/kernel/mem_protect/syscalls/src/
Dmain.c14 #define BUF_SIZE 32 macro
35 char kernel_string[BUF_SIZE];
36 char kernel_buf[BUF_SIZE];
37 ZTEST_BMEM char user_string[BUF_SIZE];
82 src_copy = k_usermode_string_alloc_copy((char *)src, BUF_SIZE); in z_vrfy_string_alloc_copy()
105 int ret = k_usermode_string_copy(kernel_buf, (char *)src, BUF_SIZE); in z_vrfy_string_copy()
120 memcpy(dest, kernel_string, BUF_SIZE); in z_impl_to_copy()
126 return k_usermode_to_copy((char *)dest, user_string, BUF_SIZE); in z_vrfy_to_copy()
210 ret = string_nlen(kernel_string, BUF_SIZE, &err); in ZTEST_USER()
221 ret = string_nlen(user_string, BUF_SIZE, &err); in ZTEST_USER()
[all …]
/Zephyr-latest/tests/boards/intel_adsp/ssp/src/
Dmain.c54 #define BUF_SIZE 48 macro
55 #define XFER_SIZE BUF_SIZE * 4
66 static int32_t sine_buf[BUF_SIZE] = {
81 static __aligned(32) int32_t rx_data[XFERS][BUF_SIZE] = { { 0 } };
133 i, BUF_SIZE, dma_block_cfgs[i].source_address, in config_output_dma()
174 i, BUF_SIZE, dma_block_cfgs_rx[i].source_address, in config_input_dma()
187 int32_t buffer[2 * BUF_SIZE]; in check_transmission()
196 for (i = 0; i < BUF_SIZE; i++) { in check_transmission()
198 buffer[BUF_SIZE + i] = rx_data[1][i]; in check_transmission()
206 for (i = 0; i < BUF_SIZE; i += 8) { in check_transmission()
[all …]
/Zephyr-latest/tests/kernel/mem_protect/protection/src/
Dtargets.h13 #define BUF_SIZE 16 macro
14 extern uint8_t data_buf[BUF_SIZE];
Dmain.c66 memcpy(dst, src, BUF_SIZE); in execute_from_buffer()
135 memcpy(dst, src, BUF_SIZE); in ZTEST()
172 uint8_t stack_buf[BUF_SIZE] __aligned(sizeof(int)); in ZTEST()
187 uint8_t *heap_buf = k_malloc(BUF_SIZE); in ZTEST()
Dtargets.c14 uint8_t data_buf[BUF_SIZE] __aligned(sizeof(int));
/Zephyr-latest/tests/subsys/sd/mmc/src/
Dmain.c15 #define BUF_SIZE (SECTOR_SIZE * SECTOR_COUNT) macro
18 static uint8_t buf[BUF_SIZE] __aligned(CONFIG_SDHC_BUFFER_ALIGNMENT);
19 static uint8_t check_buf[BUF_SIZE] __aligned(CONFIG_SDHC_BUFFER_ALIGNMENT);
131 memset(buf, 0, BUF_SIZE); in ZTEST()
132 memset(check_buf, 0, BUF_SIZE); in ZTEST()
138 zassert_mem_equal(buf, check_buf, BUF_SIZE, "Read of erased area was not zero"); in ZTEST()
148 memset(buf, 0, BUF_SIZE); in ZTEST()
151 zassert_mem_equal(buf, check_buf, BUF_SIZE, "Read of written area was not correct"); in ZTEST()
/Zephyr-latest/tests/subsys/sd/sdmmc/src/
Dmain.c16 #define BUF_SIZE SECTOR_SIZE * SECTOR_COUNT macro
19 static uint8_t buf[BUF_SIZE] __aligned(CONFIG_SDHC_BUFFER_ALIGNMENT);
20 static uint8_t check_buf[BUF_SIZE] __aligned(CONFIG_SDHC_BUFFER_ALIGNMENT);
138 memset(buf, 0, BUF_SIZE); in ZTEST()
139 memset(check_buf, 0, BUF_SIZE); in ZTEST()
145 zassert_mem_equal(buf, check_buf, BUF_SIZE, in ZTEST()
156 memset(buf, 0, BUF_SIZE); in ZTEST()
159 zassert_mem_equal(buf, check_buf, BUF_SIZE, in ZTEST()
/Zephyr-latest/samples/drivers/mspi/mspi_async/src/
Dmain.c18 #define BUF_SIZE 1024 macro
25 uint8_t memc_write_buffer[BUF_SIZE];
26 uint8_t memc_read_buffer[BUF_SIZE];
145 for (i = 0; i < BUF_SIZE; i++) { in main()
194 for (j = 0; j < BUF_SIZE; j++) { in main()
200 if (j == BUF_SIZE) { in main()
/Zephyr-latest/tests/kernel/mem_protect/mem_map/src/
Dmain.c29 #define BUF_SIZE (CONFIG_MMU_PAGE_SIZE + 907) macro
32 #define TEST_PAGE_SZ ROUND_UP(BUF_OFFSET + BUF_SIZE, CONFIG_MMU_PAGE_SIZE)
75 BUF_SIZE, BASE_FLAGS | K_MEM_PERM_RW); in ZTEST()
79 BUF_SIZE, BASE_FLAGS); in ZTEST()
82 for (int i = 0; i < BUF_SIZE; i++) { in ZTEST()
90 BUF_SIZE, CONFIG_MMU_PAGE_SIZE); in ZTEST()
98 for (int i = 0; i < BUF_SIZE; i++) { in ZTEST()
111 for (int i = 0; i < BUF_SIZE; i++) { in ZTEST()
256 BUF_SIZE, BASE_FLAGS); in ZTEST()
269 k_mem_unmap_phys_bare(mapped, BUF_SIZE); in ZTEST()
[all …]
/Zephyr-latest/tests/drivers/disk/disk_performance/src/
Dmain.c37 #define BUF_SIZE (SECTOR_SIZE * SEQ_BLOCK_COUNT) macro
50 static uint8_t test_buf[BUF_SIZE] __aligned(32);
51 static uint8_t backup_buf[BUF_SIZE] __aligned(32);
135 ((BUF_SIZE) * (NSEC_PER_SEC / time_ns)) / 1024); in ZTEST()
198 ((BUF_SIZE) * (NSEC_PER_SEC / time_ns)) / 1024); in ZTEST()
268 sys_rand_get(test_buf, BUF_SIZE); in ZTEST()
/Zephyr-latest/tests/drivers/console_switching/src/
Dmain.c13 #define BUF_SIZE 32 macro
44 char buf[BUF_SIZE] = {0}; in ZTEST()
78 char buf[BUF_SIZE] = {0}; in ZTEST()
85 snprintf(buf, BUF_SIZE, "%s", console_getline()); in ZTEST()
/Zephyr-latest/tests/boards/mec15xxevb_assy6853/qspi/src/
Dmain.c34 #define BUF_SIZE 11 macro
205 memcpy(&safbuf[4], buffer_tx, BUF_SIZE); in test_spi_single_write()
208 txb[0].len = 4 + BUF_SIZE; in test_spi_single_write()
257 memset(safbuf2, 0, BUF_SIZE); in ZTEST_USER()
259 rxb.len = BUF_SIZE; in ZTEST_USER()
272 zassert_true(memcmp(buffer_tx, safbuf2, BUF_SIZE) == 0, in ZTEST_USER()
329 memset(safbuf2, 0, BUF_SIZE); in ZTEST_USER()
331 rxb.len = BUF_SIZE; in ZTEST_USER()
344 zassert_true(memcmp(buffer_tx, safbuf2, BUF_SIZE) == 0, in ZTEST_USER()
637 rxb.len = BUF_SIZE; in ZTEST_USER()
[all …]
/Zephyr-latest/drivers/w1/
Dw1_shell.c14 #define BUF_SIZE CONFIG_W1_SHELL_BUFFER_SIZE macro
15 static uint8_t msg_buf[BUF_SIZE];
138 if (read_len > BUF_SIZE) { in cmd_w1_read_block()
139 shell_error(sh, "num_bytes limited to: %u", BUF_SIZE); in cmd_w1_read_block()
261 if ((argc - pos) > BUF_SIZE) { in cmd_w1_write_block()
401 cmd_w1_write_block, 3, BUF_SIZE),
/Zephyr-latest/tests/drivers/uart/uart_mix_fifo_poll/src/
Dmain.c43 #define BUF_SIZE 16 macro
46 static uint8_t txbuf[3][BUF_SIZE];
172 len = uart_fifo_read(uart_dev, buf, BUF_SIZE); in rx_isr()
228 uart_poll_out(uart_dev, data->buf[i % BUF_SIZE]); in bulk_poll_out()
266 size_t len = (idx < BUF_SIZE / 2) ? 5 : 1; /* Try various lengths */ in int_async_thread_func()
290 uart_poll_out(uart_dev, data->buf[data->cnt % BUF_SIZE]); in poll_out_timer_handler()
/Zephyr-latest/tests/crypto/tinycrypt/src/
Decc_dsa.c78 #define BUF_SIZE 256 macro
98 uint8_t msg[BUF_SIZE]; in sign_vectors()
114 msglen = hex2bin(msg_vec[i], strlen(msg_vec[i]), msg, BUF_SIZE); in sign_vectors()
358 uint8_t msg[BUF_SIZE]; in vrfy_vectors()
371 msglen = hex2bin(msg_vec[i], strlen(msg_vec[i]), msg, BUF_SIZE); in vrfy_vectors()
/Zephyr-latest/tests/boards/mec172xevb_assy6906/qspi/src/
Dmain.c37 #define BUF_SIZE 11 macro
310 memcpy(&safbuf[4], buffer_tx, BUF_SIZE); in test_spi_single_write()
313 spi_bufs[0].len = 4U + BUF_SIZE; in test_spi_single_write()
378 spi_bufs[cnt].len = BUF_SIZE; in ZTEST_USER()
395 zassert_true(memcmp(buffer_tx, safbuf2, BUF_SIZE) == 0, in ZTEST_USER()
440 spi_bufs[cnt].len = BUF_SIZE; in ZTEST_USER()
461 zassert_true(memcmp(buffer_tx, safbuf2, BUF_SIZE) == 0, in ZTEST_USER()
/Zephyr-latest/soc/intel/intel_adsp/tools/
Dcavstool_client.py19 BUF_SIZE = 4096 variable
101 receive_log = str(self.sock.recv(BUF_SIZE), "utf-8").replace('\x00','')
Dremote-fw-service.py26 BUF_SIZE = 4096 variable
65 data = self.request.recv(min(BUF_SIZE, fsize - len(total)))
/Zephyr-latest/subsys/net/ip/
Dtcp.c290 #define BUF_SIZE 25 /* 6 * 4 + 1 */ in tcp_flags() macro
291 static char buf[BUF_SIZE]; in tcp_flags()
298 len += snprintk(buf + len, BUF_SIZE - len, "SYN,"); in tcp_flags()
301 len += snprintk(buf + len, BUF_SIZE - len, "FIN,"); in tcp_flags()
304 len += snprintk(buf + len, BUF_SIZE - len, "ACK,"); in tcp_flags()
307 len += snprintk(buf + len, BUF_SIZE - len, "PSH,"); in tcp_flags()
310 len += snprintk(buf + len, BUF_SIZE - len, "RST,"); in tcp_flags()
313 len += snprintk(buf + len, BUF_SIZE - len, "URG,"); in tcp_flags()
320 #undef BUF_SIZE in tcp_flags()
336 #define BUF_SIZE 80 in tcp_th() macro
[all …]
/Zephyr-latest/doc/hardware/cache/
Dguide.rst84 uint8_t buffer[BUF_SIZE] Z_GENERIC_SECTION("SRAM4");
116 uint8_t buffer[BUF_SIZE] __nocache;
183 uint8_t buffer[BUF_SIZE] __aligned(CONFIG_DCACHE_LINE_SIZE);

12