Home
last modified time | relevance | path

Searched +full:write +full:- +full:protected (Results 1 – 25 of 67) sorted by relevance

123

/Zephyr-latest/samples/tfm_integration/psa_protected_storage/
DREADME.rst1 .. zephyr:code-sample:: psa_protected_storage
2 :name: TF-M PSA Protected Storage
4 Use the Protected Storage (PS) API to store encrypted data.
9 This sample demonstrates how the Protected Storage (PS) API can be used for storing data.
11 Protected storage provides a key/value storage interface where data is (by default) encrypted, with
12 optional authentication and rollback protection. The default crypto algorithm is ``AES-128-GCM``.
16 Using the PS API, this sample stores data to non-volatile storage. The sample shows how data can
19 TF-M includes a maximum number of PS records, set via ``PS_NUM_ASSETS`` (default 10 as of
20 TF-M 1.3.0), and a maximum record size, set via ``PS_MAX_ASSET_SIZE`` (default of 2048 as of
21 TF-M 1.3.0). These defaults may be different depending on the platform being used, the current
[all …]
/Zephyr-latest/samples/tfm_integration/psa_protected_storage/src/
Dmain.c4 * SPDX-License-Identifier: Apache-2.0
20 printk("Protected Storage sample started.\n"); in main()
21 printk("PSA Protected Storage API Version %d.%d\n", in main()
43 printk("- Size: %d\n", uid1_info.size); in main()
44 printk("- Capacity: 0x%2x\n", uid1_info.capacity); in main()
45 printk("- Flags: 0x%2x\n", uid1_info.flags); in main()
71 printk("Failed to set write once flag! (%d)\n", status); in main()
75 printk("Attempting to write '%s' to UID2\n", TEST_STRING_2); in main()
81 printk("Got expected error (PSA_ERROR_NOT_PERMITTED) when writing to protected UID\n"); in main()
/Zephyr-latest/tests/drivers/flash/stm32/src/
Dmain.c4 * SPDX-License-Identifier: Apache-2.0
36 flash_get_page_info_by_offs(dev, offset + size - 1, &end_page)) { in sector_mask_from_offset()
37 return -EINVAL; in sector_mask_from_offset()
40 *mask = ((1UL << (end_page.index + 1)) - 1) & in sector_mask_from_offset()
41 ~((1UL << start_page.index) - 1); in sector_mask_from_offset()
73 /* Check if region is not write protected. */ in flash_stm32_setup()
76 zassert_equal(rc, 0, "Cannot get write protect status"); in flash_stm32_setup()
78 TC_PRINT("Protected sectors: 0x%llx\n", wp_status.protected_mask); in flash_stm32_setup()
82 TC_PRINT("Removing write protection\n"); in flash_stm32_setup()
88 zassert_equal(rc, 0, "Cannot remove write protection"); in flash_stm32_setup()
[all …]
/Zephyr-latest/doc/hardware/peripherals/edac/
Dibecc.rst12 The In-Band Error Correction Code (IBECC) improves reliability by providing
15 not support the out-of-band ECC.
18 and used to store ECC syndrome data. IBECC converts read / write transactions
23 IBECC functionality. ECC errors are injected on the write path and cause ECC
35 * OPERATION_MODE = 0x1 sets functional mode to all requests not be protected and
58 * Correctable Error (CE) - error is detected and corrected by IBECC module.
60 * Uncorrectable Error (UE) - error is detected by IBECC module and not
63 The IBECC driver provides error type for the higher-level application to
65 syndrome is not used in the IBECC driver but provided to higher-level
75 higher-level synchronization primitives. So, you cannot share anything that is
[all …]
/Zephyr-latest/tests/arch/riscv/pmp/no-multithreading/src/
Dmain.c3 * SPDX-License-Identifier: Apache-2.0
16 TC_PRINT("Caught system error -- reason %d %d\n", reason, valid_fault); in k_sys_fatal_error_handler()
65 * @brief Verify RISC-V specific PMP stack guard regions.
66 * @details Manually write to the protected stack region to trigger fatal error.
75 zassert_unreachable("Write to stack guard did not fault"); in ZTEST()
/Zephyr-latest/drivers/sdhc/
Dsdhc_renesas_ra.h4 * SPDX-License-Identifier: Apache-2.0
39 ret = -ETIMEDOUT; in err_fsp2zep()
42 ret = -ENODEV; /* SD card not inserted (requires CD signal) */ in err_fsp2zep()
45 ret = -EACCES; /* SD card write-protected (requires WP sinal) */ in err_fsp2zep()
49 ret = -EIO; in err_fsp2zep()
Dsdhc_esp32.h4 * SPDX-License-Identifier: Apache-2.0
115 ret = -EINVAL; in err_esp2zep()
118 ret = -ETIMEDOUT; in err_esp2zep()
121 ret = -ENODEV; /* SD card not inserted (requires CD signal) */ in err_esp2zep()
124 ret = -EACCES; /* SD card write-protected (requires WP sinal) */ in err_esp2zep()
127 ret = -EIO; in err_esp2zep()
/Zephyr-latest/drivers/ethernet/
Doa_tc6.h4 * SPDX-License-Identifier: Apache-2.0
108 /** Indication of protected control transmission mode */
109 bool protected; member
155 * @brief Write to OA TC6 compliant device a single register
163 * @return 0 if write was successful, <0 otherwise.
168 * @brief Enable or disable the protected mode for control transactions
172 * @param prote enable or disable protected control transactions
230 * @brief Read, modify and write control register from OA TC6 device
/Zephyr-latest/doc/services/
Dsecure_storage.rst7 …`Platform Security Architecture (PSA) Secure Storage API <https://arm-software.github.io/psa-api/s…
15 non-volatile memory support.
19 cannot enable the subsystem because TF-M already provides an implementation of the API.
22 device-specific security features and the configuration, the subsystem
24 | Keep in mind, however, that it's preferable to use a secure processing environment like TF-M when
39 This depends on device-specific security features and the configuration.
41 * does not yet provide an implementation of the Protected Storage (PS) API as of this writing.
44 (unless a `custom implementation <#whole-api>`_ of the PS API is provided).
50 …rage requirements <https://arm-software.github.io/psa-api/storage/1.0/overview/requirements.html#i…
53 ``implicitly confidential and protected from replay``
[all …]
/Zephyr-latest/include/zephyr/drivers/flash/
Dstm32_flash_api_extensions.h4 * SPDX-License-Identifier: Apache-2.0
14 * STM32 sector write protection control.
23 * Input can be NULL if we only want to get protected sectors.
58 * STM32 option bytes write.
60 * Write the option bytes content, in takes the new value, out is
/Zephyr-latest/dts/bindings/flash_controller/
Dst,stm32-qspi-nor.yaml2 # SPDX-License-Identifier: Apache-2.0
9 mx25r6435f: qspi-nor-flash@90000000 {
10 compatible = "st,stm32-qspi-nor";
12 qspi-max-frequency = <80000000>;
13 reset-gpios = <&gpiod 3 GPIO_ACTIVE_LOW>;
14 reset-gpios-duration = <1>;
15 spi-bus-width = <4>;
19 compatible: "st,stm32-qspi-nor"
21 include: ["flash-controller.yaml", "jedec,jesd216.yaml"]
23 on-bus: qspi
[all …]
/Zephyr-latest/subsys/secure_storage/include/psa/
Dprotected_storage.h2 * SPDX-License-Identifier: Apache-2.0
7 /** @file psa/protected_storage.h The PSA Protected Storage (PS) API.
9 …e PS, see [The Protected Storage API](https://arm-software.github.io/psa-api/storage/1.0/overview/…
190 * @param uid The identifier of the entry to write.
193 * @param data_length The size in bytes of the data in `p_data` to write. `data_offset`
195 * @param p_data A buffer containing the data to write.
/Zephyr-latest/dts/bindings/mtd/
Djedec,spi-nor-common.yaml3 # SPDX-License-Identifier: Apache-2.0
5 # Common properties used by nodes describing M25P80-compatible SPI NOR
8 # This extends JESD216-defined features with additional functionality
9 # that may be specific to the vendor of a M25P80-compatible device and
17 requires-ulbpr:
23 protection register that initializes to write-protected. Use this
24 property to indicate that the BPR must be unlocked before write
27 has-dpd:
33 Power-Down mode that is entered by command 0xB9 to reduce power
37 Electronic Signature; see t-enter-dpd).
[all …]
/Zephyr-latest/samples/tfm_integration/tfm_regression_test/
DREADME.rst3 TF-M Regression Test Sample
9 Run both the Secure and Non-secure TF-M Regression tests using the Zephyr build system.
11 The build system will replace the Zephyr application with the Non-Secure TF-M test application,
12 while the Secure tests will be included in the TF-M build itself.
14 The TF-M regression tests are implemented in the tf-m-tests repo: https://git.trustedfirmware.org/T…
16 …tforms that are supported in the trusted-firmware-m repo: https://git.trustedfirmware.org/TF-M/tru…
22 Tests for both the secure and non-secure domain are enabled by default, controlled via the CONFIG_T…
27 Refer to :zephyr:code-sample:`tfm_ipc` for detailed instructions.
32 Refer to :zephyr:code-sample:`tfm_ipc` for detailed instructions.
35 .. code-block:: bash
[all …]
/Zephyr-latest/samples/boards/phytec/reel_board/mesh_badge/
DREADME.rst1 .. zephyr:code-sample:: mesh_badge
3 :relevant-api: monochrome_character_framebuffer bt_mesh bt_gatt bluetooth
23 #. Connect to the device. You'll see a single service - select it
24 #. Request to write to the characteristic by pressing on the upward pointing
31 #. Press "Send" - this will trigger pairing since this is a protected
/Zephyr-latest/doc/services/storage/nvs/
Dnvs.rst3 Non-Volatile Storage (NVS)
6 Elements, represented as id-data pairs, are stored in flash using a
7 FIFO-managed circular buffer. The flash area is divided into sectors. Elements
10 sector it is checked that identifier - data pairs exist in the sectors in use,
11 if not the id-data pair is copied.
13 The id is a 16-bit unsigned number. NVS ensures that for each used id there is
14 at least one id-data pair stored in flash at all time.
23 only calculated over the metadata and only ensures that a write has been
24 completed. The actual data of the element can be protected by a different (and optional)
25 CRC-32. Use the :kconfig:option:`CONFIG_NVS_DATA_CRC` configuration item to enable
[all …]
/Zephyr-latest/include/zephyr/drivers/
Ddisk.h5 * SPDX-License-Identifier: Apache-2.0
58 /** Deinitialize the disk. This IOCTL can be used to de-initialize the disk,
59 * enabling it to be removed from the system if the disk is hot-pluggable.
62 * `DISK_IOCTL_CTRL_INIT` IOCTL was issued in order to de-initialize it.
81 /** Disk status write protected */
110 int (*write)(struct disk_info *disk, const uint8_t *data_buf, member
/Zephyr-latest/modules/thrift/src/thrift/server/
DTFDServer.cpp4 * SPDX-License-Identifier: Apache-2.0
72 r = poll(&pollfds.front(), pollfds.size(), -1); in read_virt()
73 if (r == -1) { in read_virt()
74 if (efd == -1 || fd == -1) { in read_virt()
92 if (r == -1) { in read_virt()
114 for (int r = 0; len > 0; buf += r, len -= r) { in write_virt()
115 r = ::write(fd, buf, len); in write_virt()
116 if (r == -1) { in write_virt()
118 throw system_error(errno, system_category(), "write"); in write_virt()
132 int r = ::write(efd, &x, sizeof(x)); in interrupt()
[all …]
/Zephyr-latest/arch/x86/
Dgen_gdt.py5 # SPDX-License-Identifier: Apache-2.0
13 which is a link of the Zephyr kernel without various build-time
22 - Memory addresses of the Main and Double Fault TSS structures
24 - Memory addresses of where the GDT lives in memory, so that this
26 - whether userspace or HW stack protection are enabled in Kconfig
30 we generate flat 32-bit code and data segments. If hardware-
32 we additionally create descriptors for the main and double-
34 double-fault handling. If userspace is enabled, we also create
55 """Display debug message if --verbose"""
57 sys.stdout.write(os.path.basename(sys.argv[0]) + ": " + text + "\n")
[all …]
/Zephyr-latest/drivers/flash/
Dflash_stm32wbx.c5 * SPDX-License-Identifier: Apache-2.0
39 if (regs->ACR & FLASH_ACR_DCEN) { in flush_cache()
40 regs->ACR &= ~FLASH_ACR_DCEN; in flush_cache()
44 regs->ACR |= FLASH_ACR_DCRST; in flush_cache()
45 regs->ACR &= ~FLASH_ACR_DCRST; in flush_cache()
46 regs->ACR |= FLASH_ACR_DCEN; in flush_cache()
49 if (regs->ACR & FLASH_ACR_ICEN) { in flush_cache()
50 regs->ACR &= ~FLASH_ACR_ICEN; in flush_cache()
55 regs->ACR |= FLASH_ACR_ICRST; in flush_cache()
56 regs->ACR &= ~FLASH_ACR_ICRST; in flush_cache()
[all …]
Dflash_stm32g4x.c4 * SPDX-License-Identifier: Apache-2.0
27 * offset and len must be aligned on 8 for write,
32 bool write) in flash_stm32_valid_range() argument
46 if (write && !flash_stm32_valid_write(offset, len)) { in flash_stm32_valid_range()
54 if (regs->ACR & FLASH_ACR_DCEN) { in flush_cache()
55 regs->ACR &= ~FLASH_ACR_DCEN; in flush_cache()
59 regs->ACR |= FLASH_ACR_DCRST; in flush_cache()
60 regs->ACR &= ~FLASH_ACR_DCRST; in flush_cache()
61 regs->ACR |= FLASH_ACR_DCEN; in flush_cache()
64 if (regs->ACR & FLASH_ACR_ICEN) { in flush_cache()
[all …]
Dflash_stm32l4x.c6 * SPDX-License-Identifier: Apache-2.0
38 if (regs->ACR & FLASH_ACR_DCEN) { in flush_cache()
39 regs->ACR &= ~FLASH_ACR_DCEN; in flush_cache()
43 regs->ACR |= FLASH_ACR_DCRST; in flush_cache()
44 regs->ACR &= ~FLASH_ACR_DCRST; in flush_cache()
45 regs->ACR |= FLASH_ACR_DCEN; in flush_cache()
48 if (regs->ACR & FLASH_ACR_ICEN) { in flush_cache()
49 regs->ACR &= ~FLASH_ACR_ICEN; in flush_cache()
54 regs->ACR |= FLASH_ACR_ICRST; in flush_cache()
55 regs->ACR &= ~FLASH_ACR_ICRST; in flush_cache()
[all …]
Dsoc_flash_cc13xx_cc26xx.c4 * SPDX-License-Identifier: Apache-2.0
38 struct flash_priv *priv = dev->data; in flash_cc13xx_cc26xx_init()
40 k_sem_init(&priv->mutex, 1, 1); in flash_cc13xx_cc26xx_init()
89 * After write protecting a sector this sector can only be set back in flash_cc13xx_cc26xx_range_protected()
92 * Return early if any of sectors from requested range is protected. in flash_cc13xx_cc26xx_range_protected()
108 struct flash_priv *priv = dev->data; in flash_cc13xx_cc26xx_erase()
121 return -EINVAL; in flash_cc13xx_cc26xx_erase()
125 return -EINVAL; in flash_cc13xx_cc26xx_erase()
128 if (k_sem_take(&priv->mutex, K_FOREVER)) { in flash_cc13xx_cc26xx_erase()
129 return -EACCES; in flash_cc13xx_cc26xx_erase()
[all …]
Dsoc_flash_nios2_qspi.c4 * SPDX-License-Identifier: Apache-2.0
9 * Nios-II QSPI Controller HAL driver.
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()
85 k_sem_take(&flash_cfg->sem_lock, K_FOREVER); in flash_nios2_qspi_erase()
95 if (((offset + len) > qspi_dev->data_end) || in flash_nios2_qspi_erase()
97 (NIOS2_WRITE_BLOCK_SIZE - 1)))) { in flash_nios2_qspi_erase()
99 rc = -EINVAL; in flash_nios2_qspi_erase()
103 for (i = offset/qspi_dev->sector_size; in flash_nios2_qspi_erase()
104 i < qspi_dev->number_of_sectors; i++) { in flash_nios2_qspi_erase()
[all …]
/Zephyr-latest/include/zephyr/arch/arc/v2/
Darcv2_irq_unit.h1 /* arcv2_irq_unit.h - ARCv2 Interrupt Unit device driver */
7 * SPDX-License-Identifier: Apache-2.0
30 * All APIs provided by this file are protected with INTERRUPTS LOCKED. The
32 * it wants to write to, then write to them: THIS IS NOT AN ATOMIC OPERATION.
34 * Locking the interrupts inside of the APIs are some kind of self-protection
165 * Pulse interrupts self-clear as the interrupt handler is entered.
247 * to clear a pulse-triggered interrupt.

123