Home
last modified time | relevance | path

Searched refs:buf_size (Results 1 – 18 of 18) sorted by relevance

/spdk/test/unit/lib/util/crc64.c/
H A Dcrc64_ut.c14 unsigned int buf_size = 4096; in test_crc64_nvme() local
15 char buf[buf_size]; in test_crc64_nvme()
23 memset(buf, 0, buf_size); in test_crc64_nvme()
24 crc = spdk_crc64_nvme(buf, buf_size, 0); in test_crc64_nvme()
28 memset(buf, 0xFF, buf_size); in test_crc64_nvme()
29 crc = spdk_crc64_nvme(buf, buf_size, 0); in test_crc64_nvme()
33 memset(buf, 0, buf_size); in test_crc64_nvme()
35 for (i = 0; i < buf_size; i++) { in test_crc64_nvme()
43 crc = spdk_crc64_nvme(buf, buf_size, 0); in test_crc64_nvme()
47 memset(buf, 0, buf_size); in test_crc64_nvme()
[all …]
/spdk/test/unit/lib/util/crc32c.c/
H A Dcrc32c_ut.c120 unsigned int buf_size = 4096; in test_crc32c_nvme() local
121 char buf[buf_size]; in test_crc32c_nvme()
129 memset(buf, 0, buf_size); in test_crc32c_nvme()
130 crc = spdk_crc32c_nvme(buf, buf_size, 0); in test_crc32c_nvme()
134 memset(buf, 0xFF, buf_size); in test_crc32c_nvme()
135 crc = spdk_crc32c_nvme(buf, buf_size, 0); in test_crc32c_nvme()
139 memset(buf, 0, buf_size); in test_crc32c_nvme()
141 for (i = 0; i < buf_size; i++) { in test_crc32c_nvme()
149 crc = spdk_crc32c_nvme(buf, buf_size, 0); in test_crc32c_nvme()
153 memset(buf, 0, buf_size); in test_crc32c_nvme()
[all …]
/spdk/lib/util/
H A Dfile.c13 size_t rc, buf_size, cur_size = 0; in spdk_posix_file_load()
16 buf_size = 128 * 1024; in spdk_posix_file_load()
18 while (buf_size <= 1024 * 1024 * 1024) { in spdk_posix_file_load()
19 newbuf = realloc(buf, buf_size); in spdk_posix_file_load()
26 rc = fread(buf + cur_size, 1, buf_size - cur_size, file); in spdk_posix_file_load()
39 buf_size *= 2; in spdk_posix_file_load()
12 size_t rc, buf_size, cur_size = 0; spdk_posix_file_load() local
/spdk/module/bdev/raid/
H A Dbdev_raid_sb.c31 uint32_t buf_size; member
149 spdk_divide_round_up(ctx->buf_size, bdev->blocklen)) { in raid_bdev_parse_superblock()
206 buf_size_prev = ctx->buf_size; in raid_bdev_read_sb_remainder()
207 ctx->buf_size = spdk_divide_round_up(spdk_min(sb->length, RAID_BDEV_SB_MAX_LENGTH), in raid_bdev_read_sb_remainder()
209 buf = spdk_dma_realloc(ctx->buf, ctx->buf_size, spdk_bdev_get_buf_align(bdev), NULL); in raid_bdev_read_sb_remainder()
217 ctx->buf_size - buf_size_prev, raid_bdev_read_sb_cb, ctx); in raid_bdev_read_sb_remainder()
235 if (spdk_bdev_is_md_interleaved(bdev_io->bdev) && ctx->buf_size > bdev->blocklen) { in raid_bdev_read_sb_cb()
239 for (i = 1; i < ctx->buf_size / bdev->blocklen; i++) { in raid_bdev_read_sb_cb()
290 ctx->buf_size = spdk_divide_round_up(sizeof(struct raid_bdev_superblock), in raid_bdev_load_base_bdev_superblock()
292 ctx->buf = spdk_dma_malloc(ctx->buf_size, spdk_bdev_get_buf_align(bdev), NULL); in raid_bdev_load_base_bdev_superblock()
[all …]
/spdk/lib/env_dpdk/
H A Dpci_event.c25 int buf_size; in spdk_pci_event_listen() local
46 opt_size = sizeof(buf_size); in spdk_pci_event_listen()
47 if (getsockopt(netlink_fd, SOL_SOCKET, SO_RCVBUF, &buf_size, &opt_size) < 0) { in spdk_pci_event_listen()
52 if (buf_size < SPDK_UEVENT_RECVBUF_SIZE) { in spdk_pci_event_listen()
/spdk/module/bdev/gpt/
H A Dgpt.c42 (gpt->buf + (gpt->buf_size - gpt->sector_size)); in gpt_get_header_buf()
58 gpt->buf_size) { in gpt_get_partitions_buf()
66 if (secondary_total_size > gpt->buf_size) { in gpt_get_partitions_buf()
71 (gpt->buf + (gpt->buf_size - secondary_total_size)); in gpt_get_partitions_buf()
H A Dvbdev_gpt.c123 gpt->buf_size = spdk_max(SPDK_GPT_BUFFER_SIZE, bdev->blocklen); in gpt_base_bdev_init()
124 gpt->buf = spdk_zmalloc(gpt->buf_size, spdk_bdev_get_buf_align(bdev), NULL, in gpt_base_bdev_init()
451 secondary_offset = gpt->total_sectors * gpt->sector_size - gpt->buf_size; in vbdev_gpt_read_secondary_table()
453 gpt_base->gpt.buf_size, gpt_read_secondary_table_complete, in vbdev_gpt_read_secondary_table()
535 gpt_base->gpt.buf_size, gpt_bdev_complete, gpt_base); in vbdev_gpt_read_gpt()
H A Dgpt.h46 uint64_t buf_size; member
/spdk/test/unit/lib/bdev/gpt/gpt.c/
H A Dgpt_ut.c77 gpt->buf_size = sizeof(a); in test_read_header()
145 gpt->buf_size = sizeof(a); in test_read_partitions()
210 gpt->buf_size = sizeof(a); in test_parse_mbr_and_primary()
276 gpt->buf_size = sizeof(a); in test_parse_secondary()
281 head = (struct spdk_gpt_header *)(gpt->buf + gpt->buf_size - gpt->sector_size); in test_parse_secondary()
/spdk/test/unit/lib/json/json_write.c/
H A Djson_write_ut.c345 test_generate_string_uint128(char *buf, int buf_size, uint64_t low, uint64_t high) in test_generate_string_uint128() argument
352 memset(buf, 0, buf_size); in test_generate_string_uint128()
359 snprintf(tmp_buf, buf_size, "%015" PRIu64 "%s", seg, buf); in test_generate_string_uint128()
361 snprintf(tmp_buf, buf_size, "%" PRIu64 "%s", seg, buf); in test_generate_string_uint128()
364 count = snprintf(buf, buf_size, "%s", tmp_buf); in test_generate_string_uint128()
371 test_generate_string_name_uint128(char *name, char *buf, int buf_size, uint64_t low, uint64_t high) in test_generate_string_name_uint128() argument
374 int count = test_generate_string_uint128(buf, buf_size, low, high); in test_generate_string_name_uint128()
376 memcpy(tmp_buf, buf, buf_size); in test_generate_string_name_uint128()
/spdk/lib/log/
H A Dlog.c118 get_timestamp_prefix(char *buf, int buf_size) in spdk_log_to_syslog_level()
134 snprintf(buf, buf_size, "[%s.%06ld] ", "unknown date", usec);
139 snprintf(buf, buf_size, "[%s.%06ld] ", date, usec); in spdk_vlog()
77 get_timestamp_prefix(char * buf,int buf_size) get_timestamp_prefix() argument
/spdk/test/app/fuzz/llvm_vfio_fuzz/
H A Dllvm_vfio_fuzz.c58 size_t buf_size; member
337 if (memcmp(io->read_buf, io->write_buf, io->buf_size)) { in read_complete()
432 for (i = 0; i < io->buf_size / sizeof(int); i++) { in io_poller()
510 g_io_thread.buf_size = spdk_nvme_ns_get_sector_size(g_io_thread.io_ns); in init_io()
512 g_io_thread.read_buf = spdk_zmalloc(g_io_thread.buf_size, 0x1000, NULL, in init_io()
515 g_io_thread.write_buf = spdk_zmalloc(g_io_thread.buf_size, 0x1000, NULL, in init_io()
/spdk/test/unit/lib/bdev/raid/raid5f.c/
H A Draid5f_ut.c217 size_t buf_size; member
690 size_t buf_size = num_blocks * blocklen; in init_io_info() local
699 if (buf_size) { in init_io_info()
700 src_buf = spdk_dma_malloc(buf_size, 4096, NULL); in init_io_info()
703 dest_buf = spdk_dma_malloc(buf_size, 4096, NULL); in init_io_info()
706 memset(src_buf, 0xff, buf_size); in init_io_info()
742 io_info->buf_size = buf_size; in init_io_info()
854 CU_ASSERT(memcmp(io_info.src_buf, io_info.dest_buf, io_info.buf_size) == 0); in test_raid5f_submit_rw_request()
/spdk/lib/blobfs/
H A Dcache_tree.h12 uint32_t buf_size; member
/spdk/test/unit/lib/bdev/raid/bdev_raid_sb.c/
H A Dbdev_raid_sb_ut.c336 .buf_size = g_bdev.blocklen, in test_raid_bdev_parse_superblock()
370 ctx.buf_size = g_bdev.blocklen * 3; in test_raid_bdev_parse_superblock()
/spdk/test/nvme/fdp/
H A Dfdp.c39 uint32_t buf_size; member
62 iov_len = req->buf_size - req->sgl_offset; in nvme_req_next_sge()
290 req->buf_size = sector_size * lba_count; in check_fdp_write()
291 req->contig = spdk_zmalloc(req->buf_size, 0x1000, NULL, SPDK_ENV_LCORE_ID_ANY, in check_fdp_write()
/spdk/test/nvme/e2edp/
H A Dnvme_dp.c42 uint32_t buf_size; member
99 *length = req->buf_size - req->sgl_offset; in nvme_req_next_sge()
129 req->buf_size = (sector_size + md_size) * req->lba_count; in dp_guard_check_extended_lba_test()
/spdk/lib/nvme/
H A Dnvme_ctrlr.c3204 size_t buf_size = (SPDK_NVME_MAX_CHANGED_NAMESPACES * sizeof(uint32_t)); in nvme_ctrlr_clear_changed_ns_log()
3210 buffer = spdk_dma_zmalloc(buf_size, 4096, NULL); in nvme_ctrlr_clear_changed_ns_log()
3226 buffer, buf_size, 0, in nvme_ctrlr_process_async_event()
3167 size_t buf_size = (SPDK_NVME_MAX_CHANGED_NAMESPACES * sizeof(uint32_t)); nvme_ctrlr_clear_changed_ns_log() local