Home
last modified time | relevance | path

Searched refs:bytes_read (Results 1 – 25 of 93) sorted by relevance

1234

/openbmc/linux/tools/power/acpi/tools/ec/
H A Dec_access.c129 int byte_off, bytes_read; in dump_ec() local
131 bytes_read = read(fd, buf, EC_SPACE_SIZE); in dump_ec()
133 if (bytes_read == -1) in dump_ec()
136 if (bytes_read != EC_SPACE_SIZE) in dump_ec()
137 fprintf(stderr, "Could only read %d bytes\n", bytes_read); in dump_ec()
140 for (byte_off = 0; byte_off < bytes_read; byte_off++) { in dump_ec()
154 bytes_read = read(fd, buf2, EC_SPACE_SIZE); in dump_ec()
156 if (bytes_read == -1) in dump_ec()
159 if (bytes_read != EC_SPACE_SIZE) in dump_ec()
160 fprintf(stderr, "Could only read %d bytes\n", bytes_read); in dump_ec()
[all …]
/openbmc/linux/drivers/net/wireless/ath/ath9k/
H A Drng.c73 int bytes_read = 0; in ath9k_rng_read() local
77 bytes_read = ath9k_rng_data_read(sc, buf, max >> 2); in ath9k_rng_read()
79 memcpy(buf + bytes_read, &word, max & 3UL); in ath9k_rng_read()
80 bytes_read += max & 3UL; in ath9k_rng_read()
83 if (!wait || !max || likely(bytes_read) || fail_stats > 110) in ath9k_rng_read()
90 if (wait && !bytes_read && max) in ath9k_rng_read()
91 bytes_read = -EIO; in ath9k_rng_read()
92 return bytes_read; in ath9k_rng_read()
/openbmc/linux/arch/x86/events/
H A Dutils.c92 int bytes_read, bytes_left, insn_offset; in get_branch_type() local
126 bytes_read = MAX_INSN_SIZE - bytes_left; in get_branch_type()
127 if (!bytes_read) in get_branch_type()
147 bytes_read = MAX_INSN_SIZE; in get_branch_type()
160 insn_init(&insn, addr, bytes_read, is64); in get_branch_type()
171 bytes_read -= insn.length; in get_branch_type()
172 if (bytes_read < 0) in get_branch_type()
175 insn_init(&insn, addr + insn_offset, bytes_read, is64); in get_branch_type()
/openbmc/linux/drivers/usb/misc/
H A Didmouse.c125 int bytes_read; in idmouse_create_image() local
130 bytes_read = sizeof(HEADER)-1; in idmouse_create_image()
159 while (bytes_read < IMGSIZE) { in idmouse_create_image()
162 dev->bulk_in_buffer + bytes_read, in idmouse_create_image()
177 bytes_read += bulk_read; in idmouse_create_image()
182 for (bytes_read = sizeof(HEADER)-1 + WIDTH-1; bytes_read < IMGSIZE; bytes_read += WIDTH) in idmouse_create_image()
183 if (dev->bulk_in_buffer[bytes_read] != 0x00) in idmouse_create_image()
187 for (bytes_read = IMGSIZE-WIDTH; bytes_read < IMGSIZE-1; bytes_read++) in idmouse_create_image()
188 if (dev->bulk_in_buffer[bytes_read] != 0xFF) in idmouse_create_image()
197 bytes_read); in idmouse_create_image()
/openbmc/linux/tools/perf/scripts/perl/
H A Drwtop.pl44 $reads{$common_pid}{bytes_read} += $ret;
46 if (!defined ($reads{$common_pid}{bytes_read})) {
47 $reads{$common_pid}{bytes_read} = 0;
136 foreach my $pid (sort { ($reads{$b}{bytes_read} || 0) <=>
137 ($reads{$a}{bytes_read} || 0) } keys %reads) {
141 my $bytes_read = $reads{$pid}{bytes_read} || 0;
144 $total_reads, $bytes_requested, $bytes_read);
H A Drw-by-pid.pl31 $reads{$common_pid}{bytes_read} += $ret;
33 if (!defined ($reads{$common_pid}{bytes_read})) {
34 $reads{$common_pid}{bytes_read} = 0;
82 foreach my $pid (sort { ($reads{$b}{bytes_read} || 0) <=>
83 ($reads{$a}{bytes_read} || 0) } keys %reads) {
87 my $bytes_read = $reads{$pid}{bytes_read} || 0;
90 $total_reads, $bytes_requested, $bytes_read);
/openbmc/linux/drivers/net/wwan/iosm/
H A Diosm_ipc_flash.c101 u32 bytes_read; in ipc_flash_link_establish() local
114 if (bytes_read != IOSM_LER_RSP_SIZE) in ipc_flash_link_establish()
130 u32 bytes_read; in ipc_flash_receive_data() local
134 IOSM_EBL_HEAD_SIZE, &bytes_read); in ipc_flash_receive_data()
147 &bytes_read); in ipc_flash_receive_data()
154 if (bytes_read != size) { in ipc_flash_receive_data()
511 u32 bytes_read; in ipc_flash_boot_ebl() local
531 &bytes_read); in ipc_flash_boot_ebl()
537 if (bytes_read != IOSM_READ_SIZE) { in ipc_flash_boot_ebl()
550 &bytes_read); in ipc_flash_boot_ebl()
[all …]
H A Diosm_ipc_coredump.c21 int ret, bytes_to_read, bytes_read = 0, i = 0; in ipc_coredump_collect() local
37 bytes_read = 0; in ipc_coredump_collect()
39 bytes_to_read, &bytes_read); in ipc_coredump_collect()
44 remaining -= bytes_read; in ipc_coredump_collect()
45 i += bytes_read; in ipc_coredump_collect()
/openbmc/linux/drivers/char/
H A Dadi.c57 size_t ver_buf_sz, bytes_read = 0; in adi_read() local
70 while (bytes_read < count) { in adi_read()
80 if (copy_to_user(buf + bytes_read, ver_buf, in adi_read()
86 bytes_read += ver_buf_sz; in adi_read()
89 ver_buf_sz = min(count - bytes_read, in adi_read()
94 (*offp) += bytes_read; in adi_read()
95 ret = bytes_read; in adi_read()
/openbmc/linux/drivers/net/ethernet/cavium/liquidio/
H A Docteon_console.c435 s32 bytes_read) in output_console_line() argument
496 bytes_read = in check_console()
499 if (bytes_read > 0) { in check_console()
500 total_read += bytes_read; in check_console()
507 } else if (bytes_read < 0) { in check_console()
509 console_num, bytes_read); in check_console()
608 bytes_read = in octeon_get_uboot_version()
613 if (bytes_read > 0) { in octeon_get_uboot_version()
614 buf[bytes_read] = '\0'; in octeon_get_uboot_version()
616 total_read += bytes_read; in octeon_get_uboot_version()
[all …]
/openbmc/qemu/net/
H A Deth.c383 size_t bytes_read; in _eth_get_rss_ex_dst_addr() local
391 assert(bytes_read == sizeof(rt_hdr)); in _eth_get_rss_ex_dst_addr()
397 assert(bytes_read == sizeof(*dst_addr)); in _eth_get_rss_ex_dst_addr()
414 size_t bytes_read, optlen; in _eth_get_rss_ex_src_addr() local
423 if (bytes_read != sizeof(opthdr)) { in _eth_get_rss_ex_src_addr()
439 bytes_read = iov_to_buf(pkt, pkt_frags, in _eth_get_rss_ex_src_addr()
443 return bytes_read == sizeof(*src_addr); in _eth_get_rss_ex_src_addr()
457 size_t bytes_read; in eth_parse_ipv6_hdr() local
469 bytes_read = iov_to_buf(pkt, pkt_frags, ip6hdr_off, in eth_parse_ipv6_hdr()
471 if (bytes_read < sizeof(info->ip6_hdr)) { in eth_parse_ipv6_hdr()
[all …]
/openbmc/linux/fs/befs/
H A Ddatastream.c133 befs_off_t bytes_read = 0; /* bytes readed */ in befs_read_lsymlink() local
139 while (bytes_read < len) { in befs_read_lsymlink()
140 bh = befs_read_datastream(sb, ds, bytes_read, NULL); in befs_read_lsymlink()
143 "starting from %llu", bytes_read); in befs_read_lsymlink()
145 return bytes_read; in befs_read_lsymlink()
148 plen = ((bytes_read + BEFS_SB(sb)->block_size) < len) ? in befs_read_lsymlink()
149 BEFS_SB(sb)->block_size : len - bytes_read; in befs_read_lsymlink()
150 memcpy(buff + bytes_read, bh->b_data, plen); in befs_read_lsymlink()
152 bytes_read += plen; in befs_read_lsymlink()
156 bytes_read); in befs_read_lsymlink()
[all …]
/openbmc/linux/tools/testing/selftests/sparc64/drivers/
H A Dadi-test.c182 int ret, bytes_read = 0; in read_adi() local
187 ret = read(fd, buf + bytes_read, buf_sz - bytes_read); in read_adi()
194 bytes_read += ret; in read_adi()
196 } while (bytes_read < buf_sz); in read_adi()
201 return bytes_read; in read_adi()
207 int ret, i, bytes_read = 0; in pread_adi() local
214 ret = pread(fd, buf + bytes_read, buf_sz - bytes_read, in pread_adi()
222 bytes_read += ret; in pread_adi()
225 } while (bytes_read < buf_sz); in pread_adi()
229 bytes_read, offset); in pread_adi()
[all …]
/openbmc/qemu/hw/net/
H A Dnet_tx_pkt.c165 size_t bytes_read; in net_tx_pkt_parse_headers() local
176 if (bytes_read < sizeof(struct eth_header)) { in net_tx_pkt_parse_headers()
191 if (bytes_read < l2_hdr->iov_len) { in net_tx_pkt_parse_headers()
209 if (bytes_read < sizeof(struct ip_header)) { in net_tx_pkt_parse_headers()
225 bytes_read = iov_to_buf(pkt->raw, pkt->raw_frags, in net_tx_pkt_parse_headers()
258 if (bytes_read < full_ip6hdr_len) { in net_tx_pkt_parse_headers()
324 size_t bytes_read; in net_tx_pkt_build_vheader() local
347 if (bytes_read < sizeof(l4hdr) || in net_tx_pkt_build_vheader()
597 size_t bytes_read = 0; in net_tx_pkt_tcp_fragment_init() local
612 bytes_read += pkt->vec[*src_idx].iov_len; in net_tx_pkt_tcp_fragment_init()
[all …]
/openbmc/u-boot/cmd/
H A Davb.c47 size_t bytes, bytes_read = 0; in do_avb_read_part() local
64 buffer, &bytes_read) == in do_avb_read_part()
66 printf("Read %zu bytes\n", bytes_read); in do_avb_read_part()
80 size_t bytes, bytes_read = 0; in do_avb_read_part_hex() local
103 &bytes_read) == AVB_IO_RESULT_OK) { in do_avb_read_part_hex()
104 printf("Requested %zu, read %zu bytes\n", bytes, bytes_read); in do_avb_read_part_hex()
106 for (int i = 0; i < bytes_read; i++) in do_avb_read_part_hex()
/openbmc/linux/drivers/platform/x86/dell/
H A Ddell_rbu.c248 int length, int bytes_read, int *list_read_count) in do_packet_read() argument
256 if (*list_read_count > bytes_read) { in do_packet_read()
258 j = newpacket->length - (*list_read_count - bytes_read); in do_packet_read()
265 if (length > (*list_read_count - bytes_read)) in do_packet_read()
270 bytes_copied = (*list_read_count - bytes_read); in do_packet_read()
284 int bytes_read = 0; in packet_read_list() local
293 bytes_read = rbu_data.packet_read_count; in packet_read_list()
297 remaining_bytes, bytes_read, &temp_count); in packet_read_list()
299 bytes_read += bytes_copied; in packet_read_list()
309 *pread_length = bytes_read - rbu_data.packet_read_count; in packet_read_list()
[all …]
/openbmc/linux/drivers/mtd/parsers/
H A Dparser_trx.c32 size_t bytes_read; in parser_trx_data_part_name() local
35 err = mtd_read(master, offset, sizeof(buf), &bytes_read, in parser_trx_data_part_name()
58 size_t bytes_read; in parser_trx_parse() local
73 err = mtd_read(mtd, 0, sizeof(trx), &bytes_read, (uint8_t *)&trx); in parser_trx_parse()
/openbmc/linux/drivers/w1/slaves/
H A Dw1_ds2413.c33 ssize_t bytes_read = -EIO; in state_read() local
59 bytes_read = 1; in state_read()
77 (bytes_read > 0) ? "succeeded" : "error", retries); in state_read()
78 return bytes_read; in state_read()
/openbmc/linux/drivers/char/hw_random/
H A Dcore.c69 int bytes_read; in add_early_randomness() local
72 bytes_read = rng_get_data(rng, rng_fillbuf, 32, 0); in add_early_randomness()
74 if (bytes_read > 0) { in add_early_randomness()
75 size_t entropy = bytes_read * 8 * rng->quality / 1024; in add_early_randomness()
76 add_hwgenerator_randomness(rng_fillbuf, bytes_read, entropy, false); in add_early_randomness()
218 int bytes_read, len; in rng_dev_read() local
237 bytes_read = rng_get_data(rng, rng_buffer, in rng_dev_read()
240 if (bytes_read < 0) { in rng_dev_read()
241 err = bytes_read; in rng_dev_read()
243 } else if (bytes_read == 0 && in rng_dev_read()
[all …]
/openbmc/linux/Documentation/usb/
H A Dgadget_printer.rst222 int bytes_read;
233 if (bytes_read < 0) {
238 } else if (bytes_read > 0) {
240 fwrite(buf, 1, bytes_read, stdout);
276 if (!bytes_read) {
280 while (bytes_read) {
295 bytes_read -= retval;
319 int bytes_read;
331 bytes_read = read(fd, buf, BUF_SIZE);
332 if (bytes_read <= 0) {
[all …]
/openbmc/linux/drivers/ps3/
H A Dps3-vuart.c382 unsigned int bytes, u64 *bytes_read) in ps3_vuart_raw_read() argument
398 priv->stats.bytes_read += *bytes_read; in ps3_vuart_raw_read()
401 *bytes_read, bytes, priv->stats.bytes_read); in ps3_vuart_raw_read()
448 priv->stats.bytes_read -= bytes_waiting; in ps3_vuart_clear_rx_bytes()
605 unsigned long bytes_read; in ps3_vuart_read() local
630 memcpy(buf, lb->head, bytes_read); in ps3_vuart_read()
631 buf += bytes_read; in ps3_vuart_read()
632 bytes -= bytes_read; in ps3_vuart_read()
636 lb->head += bytes_read; in ps3_vuart_read()
639 bytes_read); in ps3_vuart_read()
[all …]
/openbmc/u-boot/fs/jffs2/
H A Djffs2_1pass.c179 u32 bytes_read = 0; in read_nand_cached() local
187 while (bytes_read < size) { in read_nand_cached()
213 cpy_bytes = size - bytes_read; in read_nand_cached()
214 memcpy(buf + bytes_read, in read_nand_cached()
217 bytes_read += cpy_bytes; in read_nand_cached()
219 return bytes_read; in read_nand_cached()
282 u32 bytes_read = 0; in read_onenand_cached() local
286 while (bytes_read < size) { in read_onenand_cached()
313 memcpy(buf + bytes_read, in read_onenand_cached()
316 bytes_read += cpy_bytes; in read_onenand_cached()
[all …]
/openbmc/linux/tools/testing/vsock/
H A Dvsock_perf.c215 ssize_t bytes_read; in run_receiver() local
219 bytes_read = read(fds.fd, data, buf_size_bytes); in run_receiver()
223 if (!bytes_read) in run_receiver()
226 if (bytes_read < 0) { in run_receiver()
231 total_recv += bytes_read; in run_receiver()
/openbmc/linux/drivers/net/ethernet/netronome/nfp/
H A Dnfp_net_debugdump.c160 int bytes_read; in nfp_net_dump_load_dumpspec() local
175 if (bytes_read != sym_size) { in nfp_net_dump_load_dumpspec()
455 int bytes_read; in nfp_dump_csr_range() local
484 bytes_read = nfp_cpp_read(pf->cpp, cpp_id, cpp_rd_addr, in nfp_dump_csr_range()
486 err = bytes_read == reg_sz ? 0 : -EIO; in nfp_dump_csr_range()
606 int bytes_read; in nfp_dump_single_rtsym() local
643 bytes_read = nfp_rtsym_read(pf->cpp, sym, 0, dest, sym_size); in nfp_dump_single_rtsym()
644 if (bytes_read != sym_size) { in nfp_dump_single_rtsym()
645 if (bytes_read >= 0) in nfp_dump_single_rtsym()
646 bytes_read = -EIO; in nfp_dump_single_rtsym()
[all …]
/openbmc/linux/drivers/tty/serial/
H A Dsunhv.c119 unsigned long bytes_read, i; in receive_chars_read() local
120 long stat = sun4v_con_read(ra, PAGE_SIZE, &bytes_read); in receive_chars_read()
123 bytes_read = 0; in receive_chars_read()
133 bytes_read = 1; in receive_chars_read()
150 for (i = 0; i < bytes_read; i++) in receive_chars_read()
158 port->icount.rx += bytes_read; in receive_chars_read()
161 bytes_read); in receive_chars_read()

1234