Home
last modified time | relevance | path

Searched +full:x +full:- +full:offset (Results 1 – 25 of 542) sorted by relevance

12345678910>>...22

/Zephyr-latest/samples/drivers/soc_flash_nrf/src/
Dmain.c6 * SPDX-License-Identifier: Apache-2.0
79 uint32_t i, offset; in main() local
91 printf("\nTest 1: Internal storage erase page at 0x%x\n", TEST_PARTITION_OFFSET); in main()
98 offset = TEST_PARTITION_OFFSET + (i << 2); in main()
99 printf(" Attempted to write %x at 0x%x\n", buf_array_1[i], in main()
100 offset); in main()
101 if (flash_write(flash_dev, offset, &buf_array_1[i], in main()
106 printf(" Attempted to read 0x%x\n", offset); in main()
107 if (flash_read(flash_dev, offset, &buf_word, in main()
112 printf(" Data read: %x\n", buf_word); in main()
[all …]
/Zephyr-latest/drivers/flash/
Dflash_sam.c5 * SPDX-License-Identifier: Apache-2.0
55 static bool sam_flash_validate_offset_len(off_t offset, size_t len) in sam_flash_validate_offset_len() argument
57 if (offset < 0) { in sam_flash_validate_offset_len()
61 if ((offset + len) < len) { in sam_flash_validate_offset_len()
70 return (value & (alignment - 1)) == 0; in sam_flash_aligned()
73 static bool sam_flash_offset_is_on_write_page_boundary(off_t offset) in sam_flash_offset_is_on_write_page_boundary() argument
75 return sam_flash_aligned(offset, SAM_FLASH_WRITE_PAGE_SIZE); in sam_flash_offset_is_on_write_page_boundary()
80 Efc *regs = config->regs; in sam_flash_mask_ready_interrupt()
82 regs->EEFC_FMR &= ~EEFC_FMR_FRDY; in sam_flash_mask_ready_interrupt()
87 Efc *regs = config->regs; in sam_flash_unmask_ready_interrupt()
[all …]
Dflash_ifx_cat1.c5 * SPDX-License-Identifier: Apache-2.0
41 struct ifx_cat1_flash_data *data = dev->data; in flash_ifx_sem_take()
43 k_sem_take(&data->sem, K_FOREVER); in flash_ifx_sem_take()
48 struct ifx_cat1_flash_data *data = dev->data; in flash_ifx_sem_give()
50 k_sem_give(&data->sem); in flash_ifx_sem_give()
53 static int ifx_cat1_flash_read(const struct device *dev, off_t offset, void *data, size_t data_len) in ifx_cat1_flash_read() argument
55 struct ifx_cat1_flash_data *dev_data = dev->data; in ifx_cat1_flash_read()
56 const struct ifx_cat1_flash_config *dev_config = dev->config; in ifx_cat1_flash_read()
57 uint32_t read_offset = dev_config->base_addr + offset; in ifx_cat1_flash_read()
63 rslt = cyhal_flash_read(&dev_data->flash_obj, read_offset, (uint8_t *)data, data_len); in ifx_cat1_flash_read()
[all …]
Dflash_sam0.c4 * SPDX-License-Identifier: Apache-2.0
22 BUILD_ASSERT((FLASH_WRITE_BLK_SZ % sizeof(uint32_t)) == 0, "unsupported write-block-size");
84 struct flash_sam0_data *ctx = dev->data; in flash_sam0_sem_take()
86 k_sem_take(&ctx->sem, K_FOREVER); in flash_sam0_sem_take()
93 struct flash_sam0_data *ctx = dev->data; in flash_sam0_sem_give()
95 k_sem_give(&ctx->sem); in flash_sam0_sem_give()
99 static int flash_sam0_valid_range(off_t offset, size_t len) in flash_sam0_valid_range() argument
101 if (offset < 0) { in flash_sam0_valid_range()
102 LOG_WRN("0x%lx: before start of flash", (long)offset); in flash_sam0_valid_range()
103 return -EINVAL; in flash_sam0_valid_range()
[all …]
Dsoc_flash_nios2_qspi.c4 * SPDX-License-Identifier: Apache-2.0
9 * Nios-II QSPI Controller HAL driver.
59 #define USEC_TO_MSEC(x) (x / 1000) argument
74 static int flash_nios2_qspi_erase(const struct device *dev, off_t offset, in flash_nios2_qspi_erase() argument
77 struct flash_nios2_qspi_config *flash_cfg = dev->data; in flash_nios2_qspi_erase()
78 alt_qspi_controller2_dev *qspi_dev = &flash_cfg->qspi_dev; in flash_nios2_qspi_erase()
80 uint32_t erase_offset = offset; /* address of next byte to erase */ in flash_nios2_qspi_erase()
85 k_sem_take(&flash_cfg->sem_lock, K_FOREVER); in flash_nios2_qspi_erase()
92 * check if offset is word aligned and in flash_nios2_qspi_erase()
95 if (((offset + len) > qspi_dev->data_end) || in flash_nios2_qspi_erase()
[all …]
/Zephyr-latest/subsys/bluetooth/mesh/
Dlarge_comp_data_srv.c4 * SPDX-License-Identifier: Apache-2.0
34 (BT_MESH_TX_SDU_MAX - BT_MESH_MODEL_OP_LEN(DUMMY_2_BYTE_OP) - \
50 size_t offset, total_size; in handle_large_comp_data_get() local
53 LOG_DBG("net_idx 0x%04x app_idx 0x%04x src 0x%04x len %u: %s", in handle_large_comp_data_get()
54 ctx->net_idx, ctx->app_idx, ctx->addr, buf->len, in handle_large_comp_data_get()
55 bt_hex(buf->data, buf->len)); in handle_large_comp_data_get()
58 offset = net_buf_simple_pull_le16(buf); in handle_large_comp_data_get()
60 LOG_DBG("page %u offset %u", page, offset); in handle_large_comp_data_get()
64 net_buf_simple_add_le16(&rsp, offset); in handle_large_comp_data_get()
77 if (offset > temp_buf.len) { in handle_large_comp_data_get()
[all …]
Dlarge_comp_data_cli.c6 * SPDX-License-Identifier: Apache-2.0
43 uint16_t offset; in data_status() local
46 LOG_DBG("net_idx 0x%04x app_idx 0x%04x src 0x%04x len %u: %s", in data_status()
47 ctx->net_idx, ctx->app_idx, ctx->addr, buf->len, in data_status()
48 bt_hex(buf->data, buf->len)); in data_status()
51 offset = net_buf_simple_pull_le16(buf); in data_status()
54 if (bt_mesh_msg_ack_ctx_match(&cli->ack_ctx, op, ctx->addr, (void **)&rsp)) { in data_status()
55 rsp->page = page; in data_status()
56 rsp->offset = offset; in data_status()
57 rsp->total_size = total_size; in data_status()
[all …]
/Zephyr-latest/arch/arm/core/
Delf.c5 * SPDX-License-Identifier: Apache-2.0
43 #define OPCODE2ARMMEM(x) ((uint32_t)(x)) argument
44 #define OPCODE2THM16MEM(x) ((uint16_t)(x)) argument
45 #define MEM2ARMOPCODE(x) OPCODE2ARMMEM(x) argument
46 #define MEM2THM16OPCODE(x) OPCODE2THM16MEM(x) argument
50 #define PREL31_LOWER_BOUNDARY ((int32_t)-0x40000000)
102 uint32_t sym_base_addr, const char *sym_name, int32_t *offset) in prel31_decode() argument
106 *offset = sign_extend(*(int32_t *)loc, SHIFT_PREL31_SIGN); in prel31_decode()
107 *offset += sym_base_addr - loc; in prel31_decode()
108 if (*offset >= PREL31_UPPER_BOUNDARY || *offset < PREL31_LOWER_BOUNDARY) { in prel31_decode()
[all …]
/Zephyr-latest/soc/intel/intel_adsp/ace/include/ace30/
Dadsp_shim.h4 * SPDX-License-Identifier: Apache-2.0
20 uint32_t dfspsreq; /* Offset: 0x00 */
22 uint32_t dfspsrsp; /* Offset: 0x10 */
24 uint32_t svcfg; /* Offset: 0x18 */
25 uint32_t dfltrc; /* Offset: 0x1c */
37 uint32_t dfpmccap; /* Offset: 0x00 */
38 uint32_t dfhrosccf; /* Offset: 0x04 */
39 uint32_t dfxosccf; /* Offset: 0x08 */
40 uint32_t dflrosccf; /* Offset: 0x0c */
41 uint32_t dfsiorosccf; /* Offset: 0x10 */
[all …]
/Zephyr-latest/drivers/pinctrl/
Dpinctrl_xlnx_zynq.c4 * SPDX-License-Identifier: Apache-2.0
40 return -ENODEV; in pinctrl_configure_pins()
43 /* Guard the read-modify-write operations */ in pinctrl_configure_pins()
47 __ASSERT_NO_MSG(pins[i].offset <= MIO_PIN_53_OFFSET || in pinctrl_configure_pins()
48 pins[i].offset == SD0_WP_CD_SEL_OFFSET || in pinctrl_configure_pins()
49 pins[i].offset == SD1_WP_CD_SEL_OFFSET); in pinctrl_configure_pins()
51 addr = base + pins[i].offset; in pinctrl_configure_pins()
55 LOG_ERR("failed to read SLCR addr 0x%04x (err %d)", addr, err); in pinctrl_configure_pins()
59 LOG_DBG("0x%04x: mask 0x%08x, val 0x%08x", addr, pins[i].mask, pins[i].val); in pinctrl_configure_pins()
60 LOG_DBG("0x%04x r: 0x%08x", addr, val); in pinctrl_configure_pins()
[all …]
/Zephyr-latest/tests/drivers/i2c/i2c_target_api/src/
Dmain.c5 * SPDX-License-Identifier: Apache-2.0
31 * We need 5x(buffer size) + 1 to print a comma-separated list of each
42 sprintf(dst + 5 * i, "0x%02x,", src[i]); in to_display_format()
52 TC_PRINT("Testing full read: Master: %s, address: 0x%x\n", in run_full_read()
53 i2c->name, addr); in run_full_read()
69 return -EIO; in run_full_read()
76 uint8_t addr_width, const uint8_t *comp_buffer, unsigned int offset) in run_partial_read() argument
81 TC_PRINT("Testing partial read. Master: %s, address: 0x%x, off=%d\n", in run_partial_read()
82 i2c->name, addr, offset); in run_partial_read()
86 start_addr[0] = (uint8_t) (offset & 0xFF); in run_partial_read()
[all …]
/Zephyr-latest/subsys/bluetooth/services/ots/
Dots_oacp.c4 * SPDX-License-Identifier: Apache-2.0
41 if (!ots->cur_obj) { in oacp_l2cap_closed()
45 ots->cur_obj->state.type = BT_GATT_OTS_OBJECT_IDLE_STATE; in oacp_l2cap_closed()
46 l2cap_ctx->rx_done = NULL; in oacp_l2cap_closed()
47 l2cap_ctx->tx_done = NULL; in oacp_l2cap_closed()
60 .size = proc->create_params.size, in oacp_create_proc_validate()
61 .type = proc->create_params.type, in oacp_create_proc_validate()
65 LOG_DBG("Validating Create procedure with size: 0x%08X and " in oacp_create_proc_validate()
68 if (!BT_OTS_OACP_GET_FEAT_CREATE(ots->features.oacp)) { in oacp_create_proc_validate()
79 if (strlen(obj->metadata.name) > 0) { in oacp_create_proc_validate()
[all …]
/Zephyr-latest/subsys/bluetooth/audio/
Dmcs.c6 * Copyright (c) 2019 - 2021 Nordic Semiconductor ASA
8 * SPDX-License-Identifier: Apache-2.0
98 uint16_t len, uint16_t offset) in read_player_name() argument
102 LOG_DBG("Player name read: %s (offset %u)", name, offset); in read_player_name()
107 if (offset == 0) { in read_player_name()
108 atomic_clear_bit(client->flags, FLAG_PLAYER_NAME_CHANGED); in read_player_name()
109 } else if (atomic_test_bit(client->flags, FLAG_PLAYER_NAME_CHANGED)) { in read_player_name()
114 return bt_gatt_attr_read(conn, attr, buf, len, offset, name, in read_player_name()
121 LOG_DBG("value 0x%04x", value); in player_name_cfg_changed()
127 uint16_t len, uint16_t offset) in read_icon_id() argument
[all …]
/Zephyr-latest/soc/intel/intel_adsp/cavs/include/cavs25/
Dadsp_shim.h4 * SPDX-License-Identifier: Apache-2.0
36 uint32_t spsreq; /* Offset: 0x00A0 */
37 uint32_t ldoctl; /* Offset: 0x00A4 */
39 uint32_t lpsalhss0; /* Offset: 0x00B0 */
40 uint32_t lpsalhss1; /* Offset: 0x00B4 */
41 uint32_t lpsalhss2; /* Offset: 0x00B8 */
42 uint32_t lpsalhss3; /* Offset: 0x00BC */
44 uint32_t l2mecs; /* Offset: 0x00D0 */
47 uint32_t ltrc; /* Offset: 0x00E0 */
49 uint32_t dbgo; /* Offset: 0x00F0 */
[all …]
/Zephyr-latest/scripts/logging/dictionary/dictionary_parser/
Dlog_parser_v1.py5 # SPDX-License-Identifier: Apache-2.0
8 Dictionary-based Logging Parser Version 1
100 ret = "<string@0x{0:x}>".format(arg)
128 # '%%' -> literal percentage sign
136 or fmt in (' ', '#', '-', '+', '.', 'h'):
144 elif fmt in ('c', 'd', 'i', 'o', 'u', 'x', 'X'):
145 unsigned = fmt in ('c', 'o', 'u', 'x', 'X')
147 if fmt_str[idx - 1] == 'l':
148 if fmt_str[idx - 2] == 'l':
169 if fmt_str[idx - 1] == 'L':
[all …]
Dlog_parser_v3.py5 # SPDX-License-Identifier: Apache-2.0
9 # pylint: disable=duplicate-code
12 Dictionary-based Logging Parser Version 3
105 ret = f'<string@0x{arg:x}>'
133 # '%%' -> literal percentage sign
141 or fmt in (' ', '#', '-', '+', '.', 'h'):
149 elif fmt in ('c', 'd', 'i', 'o', 'u', 'x', 'X'):
150 unsigned = fmt in ('c', 'o', 'u', 'x', 'X')
152 if fmt_str[idx - 1] == 'l':
153 if fmt_str[idx - 2] == 'l':
[all …]
/Zephyr-latest/drivers/pcie/host/
Dshell.c4 * SPDX-License-Identifier: Apache-2.0
32 { PCI_CAP_ID_PCIX, "PCI-X" },
34 { PCI_CAP_ID_VNDR, "Vendor-Specific" },
37 { PCI_CAP_ID_SHPC, "PCI Standard Hot-Plug Controller" },
39 { PCI_CAP_ID_AGP3, "AGP 8x" },
42 { PCI_CAP_ID_MSIX, "MSI-X" },
58 { PCIE_EXT_CAP_ID_MFVC, "Multi-Function VC Capability" },
61 { PCIE_EXT_CAP_ID_VNDR, "Vendor-Specific Extended Capability" },
62 { PCIE_EXT_CAP_ID_CAC, "Config Access Correlation - obsolete" },
64 { PCIE_EXT_CAP_ID_ARI, "Alternate Routing-ID Interpretation" },
[all …]
/Zephyr-latest/subsys/fb/
DREADME_fonts.txt9 -i DroidSansMono.ttf \
10 -x 10 -y 16 -s 14 --center-x \
11 -o cfbv_1016
13 -i DroidSansMono.ttf \
14 -x 15 -y 24 -s 22 --center-x --y-offset -2 \
15 -o cfbv_1524
17 -i DroidSansMono.ttf \
18 -x 20 -y 32 -s 30 --center-x --y-offset -3 \
19 -o cfbv_2032
/Zephyr-latest/subsys/fs/zms/
Dzms_priv.h3 * SPDX-License-Identifier: Apache-2.0
19 * low 4 bytes represent the offset in a sector
24 #define SECTOR_NUM(x) FIELD_GET(ADDR_SECT_MASK, x) argument
25 #define SECTOR_OFFSET(x) FIELD_GET(ADDR_OFFS_MASK, x) argument
37 #define ZMS_GET_VERSION(x) FIELD_GET(ZMS_VERSION_MASK, x) argument
41 #define ZMS_GET_MAGIC_NUMBER(x) FIELD_GET(ZMS_MAGIC_NUMBER_MASK, x) argument
44 #define ZMS_INVALID_SECTOR_NUM -1
55 uint32_t offset; /* data offset within sector */ member
/Zephyr-latest/scripts/build/
Dfile2hex.py5 # SPDX-License-Identifier: Apache-2.0
28 parser.add_argument("-f", "--file", required=True, help="Input file")
29 parser.add_argument("-o", "--offset", type=lambda x: int(x, 0), default=0,
30 help="Byte offset in the input file")
31 parser.add_argument("-l", "--length", type=lambda x: int(x, 0), default=-1,
34 parser.add_argument("-g", "--gzip", action="store_true",
36 parser.add_argument("-t", "--gzip-mtime", type=int, default=0,
46 return ", ".join("0x" + str(x) for x in list_or_iterator)
50 hexdata = codecs.encode(chunk, 'hex').decode("utf-8")
61 fg.seek(args.offset)
[all …]
Dgen_isr_tables_parser_carrays.py7 # SPDX-License-Identifier: Apache-2.0
14 /* AUTO-GENERATED by gen_isr_tables.py, do not edit! */
35 - intlist_data: The binnary data from intlist section
36 - config: The configuration object
37 - log: The logging object, has to have error and debug methods
50 uint32_t num_vectors; <- typically CONFIG_NUM_IRQS
51 struct _isr_list isrs[]; <- Usually of smaller size than num_vectors
64 /** Parameter for non-direct IRQs */
78 intlist["offset"] = header_raw[1]
92 self.__log.debug("--------------------------")
[all …]
/Zephyr-latest/soc/sifive/sifive_freedom/fu500/
Dprci.h4 * SPDX-License-Identifier: Apache-2.0
14 #define PRCI_REG(offset) Z_REG32(PRCI_BASE_ADDR, offset) argument
27 #define PLL_R(x) (((x) & 0x3f) << 0) argument
28 #define PLL_F(x) (((x) & 0x1ff) << 6) argument
29 #define PLL_Q(x) (((x) & 0x7) << 15) argument
30 #define PLL_RANGE(x) (((x) & 0x7) << 18) argument
31 #define PLL_BYPASS(x) (((x) & 0x1) << 24) argument
32 #define PLL_FSE(x) (((x) & 0x1) << 25) argument
33 #define PLL_LOCK(x) (((x) & 0x1) << 31) argument
40 #define CORECLKSEL_CORECLKSEL(x) (((x) & 0x1) << 0) argument
/Zephyr-latest/tests/drivers/smbus/smbus_emul/src/
Demul.c4 * SPDX-License-Identifier: Apache-2.0
38 uint8_t offset; member
51 sys_slist_prepend(&peripherals, &peripheral->node); in emul_register_smbus_peripheral()
59 if (peripheral->addr == addr) { in emul_get_smbus_peripheral()
72 if (peripheral->smbalert && !peripheral->smbalert_handled) { in peripheral_handle_smbalert()
82 LOG_DBG("Return own address: 0x%02x", found->addr); in peripheral_handle_smbalert()
84 io_area[PCH_SMBUS_HD0] = found->addr; in peripheral_handle_smbalert()
85 found->smbalert_handled = true; in peripheral_handle_smbalert()
95 if (peripheral->host_notify) { in peripheral_handle_host_notify()
97 io_area[PCH_SMBUS_NDA] = peripheral->addr << 1; in peripheral_handle_host_notify()
[all …]
/Zephyr-latest/scripts/west_commands/tests/
Dtest_bossac.py3 # Copyright (c) 2020-2021 Gerson Fernando Budke <nandojve@gmail.com>
5 # SPDX-License-Identifier: Apache-2.0
18 pytest.skip("skipping Linux-only bossac tests", allow_module_level=True)
20 TEST_BOSSAC_PORT = 'test-bossac-serial'
27 ['stty', '-F', TEST_BOSSAC_PORT, 'raw', 'ispeed', '115200',
28 'ospeed', '115200', 'cs8', '-cstopb', 'ignpar', 'eol', '255',
30 ['bossac', '-p', TEST_BOSSAC_PORT, '-R', '-w', '-v',
31 '-b', RC_KERNEL_BIN],
35 ['stty', '-F', TEST_BOSSAC_PORT, 'raw', 'ispeed', TEST_BOSSAC_SPEED,
36 'ospeed', TEST_BOSSAC_SPEED, 'cs8', '-cstopb', 'ignpar', 'eol', '255',
[all …]
/Zephyr-latest/samples/arch/mpu/mpu_test/src/
Dmain.c5 * SPDX-License-Identifier: Apache-2.0
57 uint32_t offset; in cmd_write_mcux() local
60 offset = FLASH_MEM + 0x20000; in cmd_write_mcux()
64 PR_SHELL(sh, "write address: 0x%x\n", offset); in cmd_write_mcux()
66 if (flash_write(flash_dev, offset, value, in cmd_write_mcux()
82 uint32_t offset = FLASH_MEM + 0x4000; in cmd_write_stm32() local
85 PR_SHELL(sh, "write address: 0x%x\n", offset); in cmd_write_stm32()
87 if (flash_write(flash_dev, offset, &value, sizeof(value)) != 0) { in cmd_write_stm32()
103 PR_SHELL(sh, "write address: 0x%x\n", FLASH_MEM + 0x4000); in cmd_write()
134 PR_SHELL(sh, "The value is: 0x%x\n", *mem); in cmd_mtest()

12345678910>>...22