Home
last modified time | relevance | path

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

12345678910>>...27

/openbmc/linux/tools/testing/selftests/resctrl/
H A Dfill_buf.c41 static void mem_flush(unsigned char *buf, size_t buf_size) in mem_flush() argument
46 buf_size = buf_size / CL_SIZE; /* mem size in cache lines */ in mem_flush()
48 for (i = 0; i < buf_size; i++) in mem_flush()
54 static int fill_one_span_read(unsigned char *buf, size_t buf_size) in fill_one_span_read() argument
56 unsigned char *end_ptr = buf + buf_size; in fill_one_span_read()
69 static void fill_one_span_write(unsigned char *buf, size_t buf_size) in fill_one_span_write() argument
71 unsigned char *end_ptr = buf + buf_size; in fill_one_span_write()
81 static int fill_cache_read(unsigned char *buf, size_t buf_size, bool once) in fill_cache_read() argument
87 ret = fill_one_span_read(buf, buf_size); in fill_cache_read()
104 static int fill_cache_write(unsigned char *buf, size_t buf_size, bool once) in fill_cache_write() argument
[all …]
/openbmc/linux/drivers/ntb/hw/intel/
H A Dntb_hw_gen3.c261 size_t buf_size; in ndev_ntb3_debugfs_read() local
268 buf_size = min(count, 0x800ul); in ndev_ntb3_debugfs_read()
270 buf = kmalloc(buf_size, GFP_KERNEL); in ndev_ntb3_debugfs_read()
276 off += scnprintf(buf + off, buf_size - off, in ndev_ntb3_debugfs_read()
279 off += scnprintf(buf + off, buf_size - off, in ndev_ntb3_debugfs_read()
283 off += scnprintf(buf + off, buf_size - off, in ndev_ntb3_debugfs_read()
285 off += scnprintf(buf + off, buf_size - off, in ndev_ntb3_debugfs_read()
289 off += scnprintf(buf + off, buf_size - off, in ndev_ntb3_debugfs_read()
292 off += scnprintf(buf + off, buf_size - off, in ndev_ntb3_debugfs_read()
294 off += scnprintf(buf + off, buf_size - off, in ndev_ntb3_debugfs_read()
[all …]
H A Dntb_hw_gen4.c225 size_t buf_size; in ndev_ntb4_debugfs_read() local
232 buf_size = min(count, 0x800ul); in ndev_ntb4_debugfs_read()
234 buf = kmalloc(buf_size, GFP_KERNEL); in ndev_ntb4_debugfs_read()
240 off += scnprintf(buf + off, buf_size - off, in ndev_ntb4_debugfs_read()
243 off += scnprintf(buf + off, buf_size - off, in ndev_ntb4_debugfs_read()
247 off += scnprintf(buf + off, buf_size - off, in ndev_ntb4_debugfs_read()
249 off += scnprintf(buf + off, buf_size - off, in ndev_ntb4_debugfs_read()
253 off += scnprintf(buf + off, buf_size - off, in ndev_ntb4_debugfs_read()
256 off += scnprintf(buf + off, buf_size - off, in ndev_ntb4_debugfs_read()
258 off += scnprintf(buf + off, buf_size - off, in ndev_ntb4_debugfs_read()
[all …]
H A Dntb_hw_gen1.c498 size_t buf_size; in ndev_ntb_debugfs_read() local
506 buf_size = min(count, 0x800ul); in ndev_ntb_debugfs_read()
508 buf = kmalloc(buf_size, GFP_KERNEL); in ndev_ntb_debugfs_read()
514 off += scnprintf(buf + off, buf_size - off, in ndev_ntb_debugfs_read()
517 off += scnprintf(buf + off, buf_size - off, in ndev_ntb_debugfs_read()
522 off += scnprintf(buf + off, buf_size - off, in ndev_ntb_debugfs_read()
524 off += scnprintf(buf + off, buf_size - off, in ndev_ntb_debugfs_read()
528 off += scnprintf(buf + off, buf_size - off, in ndev_ntb_debugfs_read()
532 off += scnprintf(buf + off, buf_size - off, in ndev_ntb_debugfs_read()
534 off += scnprintf(buf + off, buf_size - off, in ndev_ntb_debugfs_read()
[all …]
/openbmc/linux/drivers/gpu/drm/amd/amdgpu/
H A Damdgpu_eeprom.c93 u8 *eeprom_buf, u16 buf_size, bool read) in __amdgpu_eeprom_xfer() argument
110 for (r = 0; buf_size > 0; in __amdgpu_eeprom_xfer()
111 buf_size -= len, eeprom_addr += len, eeprom_buf += len) { in __amdgpu_eeprom_xfer()
138 (u32)buf_size); in __amdgpu_eeprom_xfer()
144 len = buf_size; in __amdgpu_eeprom_xfer()
182 u8 *eeprom_buf, u32 buf_size, bool read) in amdgpu_eeprom_xfer() argument
198 eeprom_buf, buf_size, read); in amdgpu_eeprom_xfer()
202 eeprom_addr, buf_size, in amdgpu_eeprom_xfer()
212 for ( ; buf_size > 0; in amdgpu_eeprom_xfer()
213 buf_size -= ps, eeprom_addr += ps, eeprom_buf += ps) { in amdgpu_eeprom_xfer()
[all …]
/openbmc/linux/tools/perf/util/
H A Dsymbol-minimal.c95 size_t buf_size; in filename__read_build_id() local
128 buf_size = ehdr.e_phentsize * ehdr.e_phnum; in filename__read_build_id()
129 buf = malloc(buf_size); in filename__read_build_id()
134 if (fread(buf, buf_size, 1, fp) != 1) in filename__read_build_id()
150 buf_size = phdr->p_filesz; in filename__read_build_id()
152 tmp = realloc(buf, buf_size); in filename__read_build_id()
158 if (fread(buf, buf_size, 1, fp) != 1) in filename__read_build_id()
161 ret = read_build_id(buf, buf_size, bid, need_swap); in filename__read_build_id()
179 buf_size = ehdr.e_phentsize * ehdr.e_phnum; in filename__read_build_id()
180 buf = malloc(buf_size); in filename__read_build_id()
[all …]
/openbmc/linux/drivers/media/platform/ti/omap3isp/
H A Dispstat.c62 u32 buf_size, enum dma_data_direction dir, in __isp_stat_buf_sync_magic() argument
69 dma_sync(stat->isp->dev, buf->dma_addr + (buf_size & PAGE_MASK), in __isp_stat_buf_sync_magic()
70 buf_size & ~PAGE_MASK, MAGIC_SIZE, dir); in __isp_stat_buf_sync_magic()
75 u32 buf_size, in isp_stat_buf_sync_magic_for_device() argument
81 __isp_stat_buf_sync_magic(stat, buf, buf_size, dir, in isp_stat_buf_sync_magic_for_device()
87 u32 buf_size, in isp_stat_buf_sync_magic_for_cpu() argument
93 __isp_stat_buf_sync_magic(stat, buf, buf_size, dir, in isp_stat_buf_sync_magic_for_cpu()
100 const u32 buf_size = IS_H3A_AF(stat) ? in isp_stat_buf_check_magic() local
101 buf->buf_size + AF_EXTRA_DATA : buf->buf_size; in isp_stat_buf_check_magic()
106 isp_stat_buf_sync_magic_for_cpu(stat, buf, buf_size, DMA_FROM_DEVICE); in isp_stat_buf_check_magic()
[all …]
H A Disph3a_aewb.c75 aewb->buf_size = conf->buf_size; in h3a_aewb_setup_regs()
115 u32 buf_size; in h3a_aewb_validate_params() local
163 buf_size = h3a_aewb_get_buf_size(user_cfg); in h3a_aewb_validate_params()
164 if (buf_size > user_cfg->buf_size) in h3a_aewb_validate_params()
165 user_cfg->buf_size = buf_size; in h3a_aewb_validate_params()
166 else if (user_cfg->buf_size > OMAP3ISP_AEWB_MAX_BUF_SIZE) in h3a_aewb_validate_params()
167 user_cfg->buf_size = OMAP3ISP_AEWB_MAX_BUF_SIZE; in h3a_aewb_validate_params()
237 cur_cfg->buf_size = h3a_aewb_get_buf_size(cur_cfg); in h3a_aewb_set_params()
330 aewb_recover_cfg->buf_size = h3a_aewb_get_buf_size(aewb_recover_cfg); in omap3isp_h3a_aewb_init()
H A Disph3a_af.c125 af->buf_size = conf->buf_size; in h3a_af_setup_regs()
159 u32 buf_size; in h3a_af_validate_params() local
216 buf_size = h3a_af_get_buf_size(user_cfg); in h3a_af_validate_params()
217 if (buf_size > user_cfg->buf_size) in h3a_af_validate_params()
219 user_cfg->buf_size = buf_size; in h3a_af_validate_params()
220 else if (user_cfg->buf_size > OMAP3ISP_AF_MAX_BUF_SIZE) in h3a_af_validate_params()
221 user_cfg->buf_size = OMAP3ISP_AF_MAX_BUF_SIZE; in h3a_af_validate_params()
301 cur_cfg->buf_size = h3a_af_get_buf_size(cur_cfg); in h3a_af_set_params()
388 af_recover_cfg->buf_size = h3a_af_get_buf_size(af_recover_cfg); in omap3isp_h3a_af_init()
H A Disphist.c137 hist->buf_size = conf->buf_size; in hist_setup_regs()
194 cfg.src_maxburst = hist->buf_size / 4; in hist_buf_dma()
204 hist->buf_size, DMA_DEV_TO_MEM, in hist_buf_dma()
255 for (i = hist->buf_size / 16; i > 0; i--) { in hist_buf_pio()
308 u32 buf_size; in hist_validate_params() local
350 buf_size = hist_get_buf_size(user_cfg); in hist_validate_params()
351 if (buf_size > user_cfg->buf_size) in hist_validate_params()
353 user_cfg->buf_size = buf_size; in hist_validate_params()
354 else if (user_cfg->buf_size > OMAP3ISP_HIST_MAX_BUF_SIZE) in hist_validate_params()
355 user_cfg->buf_size = OMAP3ISP_HIST_MAX_BUF_SIZE; in hist_validate_params()
[all …]
/openbmc/linux/fs/
H A Dkernel_read_file.c36 size_t buf_size, size_t *file_size, in kernel_read_file() argument
66 if (!file_size && offset == 0 && i_size > buf_size) { in kernel_read_file()
71 whole_file = (offset == 0 && i_size <= buf_size); in kernel_read_file()
88 while (copied < buf_size) { in kernel_read_file()
90 size_t wanted = min_t(size_t, buf_size - copied, in kernel_read_file()
128 size_t buf_size, size_t *file_size, in kernel_read_file_from_path() argument
141 ret = kernel_read_file(file, offset, buf, buf_size, file_size, id); in kernel_read_file_from_path()
148 void **buf, size_t buf_size, in kernel_read_file_from_path_initns() argument
168 ret = kernel_read_file(file, offset, buf, buf_size, file_size, id); in kernel_read_file_from_path_initns()
175 size_t buf_size, size_t *file_size, in kernel_read_file_from_fd() argument
[all …]
/openbmc/linux/net/mac80211/
H A Dagg-rx.c51 for (i = 0; i < tid_rx->buf_size; i++) in ieee80211_free_tid_rx()
184 u16 buf_size) in ieee80211_add_addbaext() argument
195 resp->data |= u8_encode_bits(buf_size >> IEEE80211_ADDBA_EXT_BUF_SIZE_SHIFT, in ieee80211_add_addbaext()
201 u16 buf_size, u16 timeout, in ieee80211_send_addba_resp() argument
241 capab |= u16_encode_bits(buf_size, IEEE80211_ADDBA_PARAM_BUF_SIZE_MASK); in ieee80211_send_addba_resp()
248 ieee80211_add_addbaext(sdata, skb, addbaext, buf_size); in ieee80211_send_addba_resp()
256 u16 buf_size, bool tx, bool auto_seq, in ___ieee80211_start_rx_ba_session() argument
309 (buf_size > max_buf_size)) { in ___ieee80211_start_rx_ba_session()
313 sta->sta.addr, tid, ba_policy, buf_size); in ___ieee80211_start_rx_ba_session()
317 if (buf_size == 0) in ___ieee80211_start_rx_ba_session()
[all …]
/openbmc/u-boot/cmd/
H A Dnvedit_efi.c99 efi_uintn_t buf_size, size; in efi_dump_vars() local
101 buf_size = 128; in efi_dump_vars()
102 var_name16 = malloc(buf_size); in efi_dump_vars()
108 if (buf_size < size) { in efi_dump_vars()
109 buf_size = size; in efi_dump_vars()
110 p = realloc(var_name16, buf_size); in efi_dump_vars()
140 efi_uintn_t buf_size, size; in efi_dump_var_all() local
144 buf_size = 128; in efi_dump_var_all()
145 var_name16 = malloc(buf_size); in efi_dump_var_all()
151 size = buf_size; in efi_dump_var_all()
[all …]
H A Dfastboot.c19 uintptr_t buf_addr, size_t buf_size) in do_fastboot_udp() argument
37 uintptr_t buf_addr, size_t buf_size) in do_fastboot_usb() argument
99 size_t buf_size = 0; in do_fastboot() local
119 buf_size = simple_strtoul(*++argv, NULL, 16); in do_fastboot()
136 fastboot_init((void *)buf_addr, buf_size); in do_fastboot()
139 return do_fastboot_udp(argc, argv, buf_addr, buf_size); in do_fastboot()
146 return do_fastboot_usb(argc, argv, buf_addr, buf_size); in do_fastboot()
/openbmc/u-boot/lib/efi_selftest/
H A Defi_selftest_block_device.c309 efi_uintn_t buf_size; in execute() local
371 buf_size = sizeof(system_info); in execute()
372 ret = root->getinfo(root, &guid_file_system_info, &buf_size, in execute()
401 buf_size = sizeof(buf) - 1; in execute()
402 ret = file->read(file, &buf_size, buf); in execute()
407 if (buf_size != 12) { in execute()
409 (unsigned int)buf_size); in execute()
440 buf_size = 7; in execute()
442 boottime->copy_mem(buf, "U-Boot", buf_size); in execute()
443 ret = file->write(file, &buf_size, buf); in execute()
[all …]
/openbmc/u-boot/drivers/power/pmic/
H A Di2c_pmic_emul.c24 u8 buf_size; member
33 if (plat->rw_idx + len > plat->buf_size) { in sandbox_i2c_pmic_read_data()
71 if (plat->rw_idx + len > plat->buf_size) { in sandbox_i2c_pmic_write_data()
114 plat->buf_size = plat->reg_count * plat->trans_len; in sandbox_i2c_pmic_ofdata_to_platdata()
116 plat->reg = calloc(1, plat->buf_size); in sandbox_i2c_pmic_ofdata_to_platdata()
119 plat->buf_size); in sandbox_i2c_pmic_ofdata_to_platdata()
124 plat->buf_size); in sandbox_i2c_pmic_ofdata_to_platdata()
133 memcpy(plat->reg, reg_defaults, plat->buf_size); in sandbox_i2c_pmic_ofdata_to_platdata()
/openbmc/linux/drivers/media/pci/ivtv/
H A Divtv-queue.c15 if (s->buf_size - buf->bytesused < copybytes) in ivtv_buf_copy_from_user()
16 copybytes = s->buf_size - buf->bytesused; in ivtv_buf_copy_from_user()
54 q->length += s->buf_size; in ivtv_enqueue()
69 q->length -= s->buf_size; in ivtv_dequeue()
83 from->length -= s->buf_size; in ivtv_queue_move_buf()
89 to->length += s->buf_size; in ivtv_queue_move_buf()
144 steal->length -= s->buf_size; in ivtv_queue_move()
148 from->length += s->buf_size; in ivtv_queue_move()
149 bytes_available += s->buf_size; in ivtv_queue_move()
192 s->name, s->buffers, s->buf_size, s->buffers * s->buf_size / 1024); in ivtv_stream_alloc()
[all …]
/openbmc/linux/net/wireless/
H A Ddebugfs.c41 char *buf, int buf_size, int offset) in ht_print_chan() argument
43 if (WARN_ON(offset > buf_size)) in ht_print_chan()
48 buf_size - offset, in ht_print_chan()
53 buf_size - offset, in ht_print_chan()
68 unsigned int offset = 0, buf_size = PAGE_SIZE, i; in ht40allow_map_read() local
73 buf = kzalloc(buf_size, GFP_KERNEL); in ht40allow_map_read()
83 buf, buf_size, offset); in ht40allow_map_read()
/openbmc/linux/drivers/media/pci/cx18/
H A Dcx18-queue.c93 u32 buf_size = s->buf_size; in _cx18_mdl_update_bufs_for_cpu() local
98 if (bytesused >= buf_size) { in _cx18_mdl_update_bufs_for_cpu()
99 buf->bytesused = buf_size; in _cx18_mdl_update_bufs_for_cpu()
100 bytesused -= buf_size; in _cx18_mdl_update_bufs_for_cpu()
294 cx18_writel(cx, s->buf_size, in cx18_load_queues()
306 partial_buf_size = s->mdl_size % s->buf_size; in cx18_load_queues()
323 u32 buf_size = s->buf_size; in _cx18_mdl_sync_for_device() local
329 buf_size, dma); in _cx18_mdl_sync_for_device()
341 s->name, s->buffers, s->buf_size, in cx18_stream_alloc()
342 s->buffers * s->buf_size / 1024, in cx18_stream_alloc()
[all …]
/openbmc/linux/drivers/infiniband/sw/rxe/
H A Drxe_queue.c14 size_t buf_size, struct rxe_mmap_info **ip_p) in do_mmap_info() argument
20 ip = rxe_create_mmap_info(rxe, buf_size, udata, buf); in do_mmap_info()
52 memset(q->buf->data, 0, q->buf_size - sizeof(struct rxe_queue_buf)); in rxe_queue_reset()
59 size_t buf_size; in rxe_queue_init() local
87 buf_size = sizeof(struct rxe_queue_buf) + num_slots * elem_size; in rxe_queue_init()
89 q->buf = vmalloc_user(buf_size); in rxe_queue_init()
96 q->buf_size = buf_size; in rxe_queue_init()
163 new_q->buf_size, &new_q->ip); in rxe_queue_resize()
/openbmc/linux/drivers/staging/most/dim2/
H A Dhal.c472 u16 dim_norm_ctrl_async_buffer_size(u16 buf_size) in dim_norm_ctrl_async_buffer_size() argument
476 if (buf_size > max_size) in dim_norm_ctrl_async_buffer_size()
479 return buf_size; in dim_norm_ctrl_async_buffer_size()
482 static inline u16 norm_isoc_buffer_size(u16 buf_size, u16 packet_length) in norm_isoc_buffer_size() argument
487 if (buf_size > max_size) in norm_isoc_buffer_size()
488 buf_size = max_size; in norm_isoc_buffer_size()
490 n = buf_size / packet_length; in norm_isoc_buffer_size()
498 static inline u16 norm_sync_buffer_size(u16 buf_size, u16 bytes_per_frame) in norm_sync_buffer_size() argument
504 if (buf_size > max_size) in norm_sync_buffer_size()
505 buf_size = max_size; in norm_sync_buffer_size()
[all …]
/openbmc/linux/tools/testing/vsock/
H A Dvsock_test.c421 size_t buf_size; in test_seqpacket_msg_bounds_client() local
427 buf_size = page_size + in test_seqpacket_msg_bounds_client()
430 buf_size = 1 + (rand() % page_size); in test_seqpacket_msg_bounds_client()
432 buf = malloc(buf_size); in test_seqpacket_msg_bounds_client()
439 memset(buf, rand() & 0xff, buf_size); in test_seqpacket_msg_bounds_client()
448 send_size = send(fd, buf, buf_size, flags); in test_seqpacket_msg_bounds_client()
455 if (send_size != buf_size) { in test_seqpacket_msg_bounds_client()
469 curr_hash += hash_djb2(buf, buf_size); in test_seqpacket_msg_bounds_client()
758 int buf_size = getpagesize() * 3; in test_seqpacket_invalid_rec_buffer_client() local
766 buf1 = malloc(buf_size); in test_seqpacket_invalid_rec_buffer_client()
[all …]
/openbmc/linux/drivers/scsi/fnic/
H A Dfnic_trace.c205 int buf_size = debug->buf_size; in fnic_get_stats_data() local
209 len = scnprintf(debug->debug_buffer + len, buf_size - len, in fnic_get_stats_data()
214 len += scnprintf(debug->debug_buffer + len, buf_size - len, in fnic_get_stats_data()
232 len += scnprintf(debug->debug_buffer + len, buf_size - len, in fnic_get_stats_data()
236 len += scnprintf(debug->debug_buffer + len, buf_size - len, in fnic_get_stats_data()
269 len += scnprintf(debug->debug_buffer + len, buf_size - len, in fnic_get_stats_data()
273 len += scnprintf(debug->debug_buffer + len, buf_size - len, in fnic_get_stats_data()
278 len += scnprintf(debug->debug_buffer + len, buf_size - len, in fnic_get_stats_data()
307 len += scnprintf(debug->debug_buffer + len, buf_size - len, in fnic_get_stats_data()
312 len += scnprintf(debug->debug_buffer + len, buf_size - len, in fnic_get_stats_data()
[all …]
/openbmc/linux/drivers/infiniband/hw/erdma/
H A Derdma_cmdq.c92 u32 buf_size; in erdma_cmdq_sq_init() local
97 buf_size = sq->depth << SQEBB_SHIFT; in erdma_cmdq_sq_init()
100 dma_alloc_coherent(&dev->pdev->dev, WARPPED_BUFSIZE(buf_size), in erdma_cmdq_sq_init()
105 sq->db_record = (u64 *)(sq->qbuf + buf_size); in erdma_cmdq_sq_init()
115 sq->qbuf_dma_addr + buf_size); in erdma_cmdq_sq_init()
124 u32 buf_size; in erdma_cmdq_cq_init() local
127 buf_size = cq->depth << CQE_SHIFT; in erdma_cmdq_cq_init()
130 dma_alloc_coherent(&dev->pdev->dev, WARPPED_BUFSIZE(buf_size), in erdma_cmdq_cq_init()
137 cq->db_record = (u64 *)(cq->qbuf + buf_size); in erdma_cmdq_cq_init()
146 cq->qbuf_dma_addr + buf_size); in erdma_cmdq_cq_init()
[all …]
/openbmc/linux/tools/testing/selftests/bpf/prog_tests/
H A Dxdp_adjust_frags.c8 int err, prog_fd, max_skb_frags, buf_size, num; in test_xdp_update_frags() local
118 buf_size = 4096 + (max_skb_frags + 1) * sysconf(_SC_PAGE_SIZE); in test_xdp_update_frags()
119 buf = malloc(buf_size); in test_xdp_update_frags()
123 memset(buf, 0, buf_size); in test_xdp_update_frags()
131 topts.data_size_in = buf_size; in test_xdp_update_frags()
132 topts.data_size_out = buf_size; in test_xdp_update_frags()

12345678910>>...27