Home
last modified time | relevance | path

Searched refs:chunk (Results 1 – 25 of 41) sorted by relevance

12

/Zephyr-latest/tests/bluetooth/mesh/blob_io_flash/src/
Dmain.c53 struct bt_mesh_blob_chunk chunk = { 0 }; in ZTEST() local
94 chunk.data = chunk_data; in ZTEST()
121 chunk.size = chunk_size(&block, chunk_idx); in ZTEST()
122 chunk.offset = CHUNK_SIZE * chunk_idx; in ZTEST()
124 err = blob_flash_stream.io.rd(&blob_flash_stream.io, &xfer, &block, &chunk); in ZTEST()
126 err, block.offset + chunk.offset, chunk.size); in ZTEST()
128 zassert_mem_equal(&chunk_data, &test_data[tests_data_offset], chunk.size, in ZTEST()
132 remaining -= chunk.size; in ZTEST()
133 tests_data_offset += chunk.size; in ZTEST()
142 chunk.offset++; in ZTEST()
[all …]
/Zephyr-latest/scripts/build/
Dfile2hex.py49 def make_hex(chunk): argument
50 hexdata = codecs.encode(chunk, 'hex').decode("utf-8")
68 for chunk in iter(lambda: content.read(8), b''):
69 make_hex(chunk)
74 for chunk in iter(lambda: fp.read(8), b''):
75 make_hex(chunk)
78 for chunk in iter(lambda: fp.read(min(8, remainder)), b''):
79 make_hex(chunk)
80 remainder = remainder - len(chunk)
Duf2conv.py133 chunk = file_content[ptr:ptr + 256]
140 while len(chunk) < 256:
141 chunk += b"\x00"
142 block = hd + chunk + datapadding + struct.pack(b"<I", UF2_MAGIC_END)
/Zephyr-latest/subsys/bluetooth/mesh/
Dblob_io_flash.c98 const struct bt_mesh_blob_chunk *chunk) in rd_chunk() argument
103 flash->offset + block->offset + chunk->offset, in rd_chunk()
104 chunk->data, chunk->size); in rd_chunk()
110 const struct bt_mesh_blob_chunk *chunk) in wr_chunk() argument
116 flash->offset + block->offset + chunk->offset, in wr_chunk()
117 chunk->data, chunk->size); in wr_chunk()
121 off_t area_offset = flash->offset + block->offset + chunk->offset; in wr_chunk()
128 memcpy(&buf[i], chunk->data, chunk->size); in wr_chunk()
129 i += chunk->size; in wr_chunk()
Dblob_srv.c128 static void buf_chunk_index_add(struct net_buf_simple *buf, uint16_t chunk) in buf_chunk_index_add() argument
131 if (chunk < 0x80) { in buf_chunk_index_add()
132 net_buf_simple_add_u8(buf, chunk); in buf_chunk_index_add()
133 } else if (chunk < 0x8000) { in buf_chunk_index_add()
134 net_buf_simple_add_u8(buf, 0xc0 | chunk >> 6); in buf_chunk_index_add()
135 net_buf_simple_add_u8(buf, 0x80 | (chunk & BIT_MASK(6))); in buf_chunk_index_add()
137 net_buf_simple_add_u8(buf, 0xe0 | chunk >> 12); in buf_chunk_index_add()
138 net_buf_simple_add_u8(buf, 0x80 | ((chunk >> 6) & BIT_MASK(6))); in buf_chunk_index_add()
139 net_buf_simple_add_u8(buf, 0x80 | (chunk & BIT_MASK(6))); in buf_chunk_index_add()
726 struct bt_mesh_blob_chunk chunk; in handle_chunk() local
[all …]
Ddelayable_msg.c168 struct delayable_msg_chunk *chunk; in push_msg_from_delayable_msgs() local
184 chunk = CONTAINER_OF(node, struct delayable_msg_chunk, node); in push_msg_from_delayable_msgs()
185 memcpy(net_buf_simple_add(&buf, tmp), chunk->data, tmp); in push_msg_from_delayable_msgs()
265 struct delayable_msg_chunk *chunk = in bt_mesh_delayable_msg_manage() local
268 memcpy(chunk->data, net_buf_simple_pull_mem(buf, tmp), tmp); in bt_mesh_delayable_msg_manage()
/Zephyr-latest/tests/subsys/storage/flash_map/src/
Dmain.c188 int chunk = MIN(sizeof(buf), fa->fa_size - i); in ZTEST() local
190 rc = flash_read(flash_dev, fa->fa_off + i, buf, chunk); in ZTEST()
192 for (int ii = 0; ii < chunk; ++ii, ++i) { in ZTEST()
211 int chunk = MIN(sizeof(buf), fa->fa_size - i); in ZTEST() local
213 rc = flash_read(flash_dev, fa->fa_off + i, buf, chunk); in ZTEST()
215 for (int ii = 0; ii < chunk; ++ii, ++i) { in ZTEST()
/Zephyr-latest/doc/kernel/memory_management/
Dheap.rst64 chunks. The first chunk of every allocation or unused block is
65 prefixed by a chunk header that stores the length of the chunk, the
66 length of the next lower ("left") chunk in physical memory, a bit
67 indicating whether the chunk is in use, and chunk-indexed link
68 pointers to the previous and next chunk in a "free list" to which
156 A thread can dynamically allocate a chunk of heap memory by calling
157 :c:func:`k_malloc`. The address of the allocated chunk is
159 chunk of heap memory cannot be found ``NULL`` is returned.
161 When the thread is finished with a chunk of heap memory it can release
162 the chunk back to the system heap by calling :c:func:`k_free`.
[all …]
/Zephyr-latest/include/zephyr/bluetooth/mesh/
Dblob.h228 const struct bt_mesh_blob_chunk *chunk);
253 const struct bt_mesh_blob_chunk *chunk);
/Zephyr-latest/drivers/spi/
Dspi_ambiq_spid.c188 uint32_t chunk, num_written, num_read, used_space = 0; in spi_ambiq_xfer() local
194 chunk = (ctx->tx_len > AMBIQ_SPID_TX_BUFSIZE_MAX) in spi_ambiq_xfer()
205 (uint8_t *)ctx->tx_buf, chunk, in spi_ambiq_xfer()
212 while (chunk) { in spi_ambiq_xfer()
213 uint32_t size = (chunk > AMBIQ_SPID_DUMMY_LENGTH) in spi_ambiq_xfer()
215 : chunk; in spi_ambiq_xfer()
221 chunk -= dummy_written; in spi_ambiq_xfer()
/Zephyr-latest/subsys/bluetooth/mesh/shell/
Dblob.c38 const struct bt_mesh_blob_chunk *chunk) in blob_chunk_wr() argument
42 for (i = 0; i < chunk->size; ++i) { in blob_chunk_wr()
43 blob_rx_sum += chunk->data[i]; in blob_chunk_wr()
44 if (chunk->data[i] != in blob_chunk_wr()
45 blob_data[(i + chunk->offset) % sizeof(blob_data)]) { in blob_chunk_wr()
56 const struct bt_mesh_blob_chunk *chunk) in blob_chunk_rd() argument
58 for (int i = 0; i < chunk->size; ++i) { in blob_chunk_rd()
59 chunk->data[i] = in blob_chunk_rd()
60 blob_data[(i + chunk->offset) % sizeof(blob_data)]; in blob_chunk_rd()
/Zephyr-latest/tests/drivers/flash_simulator/flash_sim_impl/src/
Dmain.c93 size_t chunk = MIN(size - i, sizeof(buf)); in test_check_erase() local
100 buf, chunk); in test_check_erase()
114 --chunk; in test_check_erase()
115 } while (chunk); in test_check_erase()
485 size_t chunk = MIN(size, FLASH_SIMULATOR_PROG_UNIT); in ZTEST() local
489 buf, chunk); in ZTEST()
496 --chunk; in ZTEST()
497 } while (chunk); in ZTEST()
/Zephyr-latest/subsys/mgmt/mcumgr/grp/fs_mgmt/
DKconfig45 size/offset within CBOR frame with file chunk.
51 size/offset within CBOR frame with file chunk.
61 CBOR frame containing chunk of downloaded file.
69 bool "Setting custom size of download file chunk"
71 By default file chunk, that will be read off storage and fit into
75 allowed for such chunk.
81 int "Maximum chunk size for file downloads"
85 Sets the MAXIMUM size of chunk which will be rounded down to
/Zephyr-latest/drivers/flash/
Dflash_util.c58 size_t chunk = MIN(sizeof(filler), size - stored); in z_impl_flash_fill() local
60 rc = api->write(dev, offset + stored, filler, chunk); in z_impl_flash_fill()
66 stored += chunk; in z_impl_flash_fill()
/Zephyr-latest/doc/connectivity/bluetooth/api/mesh/
Dblob_flash.rst27 The BLOB Flash Writer copies chunk data into a buffer to accommodate chunks that are unaligned with
29 the chunk is unaligned.
/Zephyr-latest/lib/heap/
DKconfig39 smallest chunk level (the one that might not fit the
75 Heaps using reduced-size chunk headers can accommodate so called
78 Heaps using full-size chunk headers can have a total size up to
90 On 64-bit systems the "big" chunk header size conveniently provides
91 the needed alignment on returned memory allocations. Small chunk
/Zephyr-latest/subsys/usb/device/
Dusb_device.c245 uint32_t chunk = usb_dev.data_buf_residue; in usb_data_to_host() local
249 usb_dev.data_buf_residue, &chunk); in usb_data_to_host()
250 usb_dev.data_buf += chunk; in usb_data_to_host()
251 usb_dev.data_buf_residue -= chunk; in usb_data_to_host()
258 if (!usb_dev.data_buf_residue && chunk && in usb_data_to_host()
285 uint32_t chunk = 0U; in usb_handle_control_transfer() local
355 usb_dev.data_buf, 0, &chunk) < 0) { in usb_handle_control_transfer()
364 usb_dev.data_buf_residue, &chunk) < 0) { in usb_handle_control_transfer()
371 usb_dev.data_buf += chunk; in usb_handle_control_transfer()
372 usb_dev.data_buf_residue -= chunk; in usb_handle_control_transfer()
/Zephyr-latest/drivers/wifi/esp_at/
Desp.c1172 const char *chunk, size_t chunk_len) in esp_conn_cmd_append() argument
1176 const char *chunk_end = chunk + chunk_len; in esp_conn_cmd_append()
1178 for (; chunk < chunk_end; chunk++) { in esp_conn_cmd_append()
1183 *str = *chunk; in esp_conn_cmd_append()
1192 #define esp_conn_cmd_append_literal(data, off, chunk) \ argument
1193 esp_conn_cmd_append(data, off, chunk, sizeof(chunk) - 1)
1196 const char *chunk, size_t chunk_len) in esp_conn_cmd_escape_and_append() argument
1200 const char *chunk_end = chunk + chunk_len; in esp_conn_cmd_escape_and_append()
1202 for (; chunk < chunk_end; chunk++) { in esp_conn_cmd_escape_and_append()
1203 switch (*chunk) { in esp_conn_cmd_escape_and_append()
[all …]
/Zephyr-latest/subsys/shell/modules/
Ddevmem_service.c37 static char chunk[2]; variable
213 chunk[chunk_element] = *recv; in bypass_cb()
218 byte = (uint8_t)strtoul(chunk, NULL, 16); in bypass_cb()
/Zephyr-latest/subsys/net/lib/tls_credentials/
Dtls_credentials_shell.c155 static int cred_buf_write(char *chunk) in cred_buf_write() argument
158 size_t chunk_len = strlen(chunk); in cred_buf_write()
168 memcpy(writehead, chunk, chunk_len); in cred_buf_write()
328 static int shell_write_cred_buf(const struct shell *sh, char *chunk) in shell_write_cred_buf() argument
330 int res = cred_buf_write(chunk); in shell_write_cred_buf()
/Zephyr-latest/scripts/west_commands/runners/
Dcanopen_program.py289 chunk = infile.read(self.download_buffer_size // 2)
290 if not chunk:
292 outfile.write(chunk)
293 progress.next(n=len(chunk))
/Zephyr-latest/doc/services/debugging/
Dcs_trace_defmt.rst18 end of chunk is reached. Callback contains stream ID and the data.
/Zephyr-latest/tests/boards/espressif/cache_coex/
DREADME.rst10 a common cache. It does so by allocating a big PSRAM memory chunk and repeatedly filling that region
/Zephyr-latest/scripts/west_commands/
Dsdk.py316 for chunk in resp.iter_content(chunk_size=8192):
317 file.write(chunk)
318 count = count + len(chunk)
/Zephyr-latest/tests/lib/heap/src/
Dmain.c128 size_t chunk = ROUND_DOWN(addr - 1, 8); in testalloc() local
129 size_t hdr = addr - chunk; in testalloc()

12