Home
last modified time | relevance | path

Searched refs:flash_addr (Results 1 – 25 of 30) sorted by relevance

12

/device/soc/hisilicon/hi3861v100/sdk_liteos/platform/system/upg/
Dupg_check_secure.c44 hi_u32 upg_hash_one_content(hi_u32 flash_addr, hi_u32 total_size, hi_u8 *hash, hi_u32 hash_size) in upg_hash_one_content() argument
62 …ret = (hi_u32)memcpy_s(block, this_size, (hi_u8 *)(HI_FLASH_BASE + flash_addr + offset), this_size… in upg_hash_one_content()
99 … ret = (hi_u32)memcpy_s(block, this_size, (hi_u8 *)(HI_FLASH_BASE + param->flash_addr[i] + offset), in upg_hash_more_content()
102 … ret = (hi_u32)memcpy_s(block, HI_BLOCK_SIZE, (hi_u8 *)(param->flash_addr[i] + offset), this_size); in upg_hash_more_content()
200 hi_void upg_crypto_set_secure_verify_param(upg_verify_param *param, hi_u32 flash_addr, in upg_crypto_set_secure_verify_param() argument
203 param->flash_addr[0] = (uintptr_t)flash_addr + head->section_offset; in upg_crypto_set_secure_verify_param()
219 param->flash_addr[1] = (uintptr_t)(para->raw_buf); in upg_crypto_set_secure_verify_param()
222 …param->flash_addr[FLASH_ADDR_NUM - 1] = flash_addr + head->section_offset + sizeof(hi_upg_section_… in upg_crypto_set_secure_verify_param()
229 …param->flash_addr[1] = flash_addr + head->section_offset + sizeof(hi_upg_section_head) + sizeof(hi… in upg_crypto_set_secure_verify_param()
236 hi_void upg_set_secure_verify_param(upg_verify_param *param, hi_u32 flash_addr, const hi_upg_common… in upg_set_secure_verify_param() argument
[all …]
Dupg_check_secure.h40 uintptr_t flash_addr[FLASH_ADDR_NUM]; member
52 hi_u32 upg_check_upg_file_code(hi_u32 flash_addr, hi_upg_head *upg_head);
54 hi_u32 upg_check_upg_file(hi_u32 flash_addr, hi_upg_head *upg_head);
55 hi_u32 upg_hash_one_content(hi_u32 flash_addr, hi_u32 total_size, hi_u8 *hash, hi_u32 hash_size);
Dupg_check_file.h39 hi_u32 upg_verify_file(hi_u32 flash_addr);
/device/soc/hisilicon/hi3861v100/sdk_liteos/boot/flashboot/upg/
Dboot_upg_check_secure.c224 hi_void boot_upg_set_secure_verify_param(upg_verify_param *param, hi_u32 flash_addr, HI_CONST hi_up… in boot_upg_set_secure_verify_param() argument
226 param->flash_addr[0] = (uintptr_t)flash_addr + upg_head->common.section_offset; in boot_upg_set_secure_verify_param()
230 param->flash_addr[1] = KERNEL_RAM_ADDR; in boot_upg_set_secure_verify_param()
233 param->flash_addr[2] = flash_addr + upg_head->common.section_offset + in boot_upg_set_secure_verify_param()
240 param->flash_addr[1] = flash_addr + upg_head->common.section_offset + in boot_upg_set_secure_verify_param()
248 hi_u32 boot_upg_secure_verify_code(hi_u32 flash_addr, HI_CONST hi_upg_head *upg_head) in boot_upg_secure_verify_code() argument
258 … ret = hi_flash_read((flash_addr + upg_head->common.section_offset + sizeof(hi_upg_section_head)), in boot_upg_secure_verify_code()
275 boot_upg_set_secure_verify_param(&param, flash_addr, upg_head); in boot_upg_secure_verify_code()
290 hi_u32 boot_upg_unsecure_verify_code(hi_u32 flash_addr, HI_CONST hi_upg_head *upg_head) in boot_upg_unsecure_verify_code() argument
298 … ret = hi_flash_read((flash_addr + upg_head->common.section_offset + sizeof(hi_upg_section_head)), in boot_upg_unsecure_verify_code()
[all …]
Dboot_upg_check_secure.h48 uintptr_t flash_addr[FLASH_ADDR_NUM]; member
61 hi_u32 boot_upg_check_secure_info(hi_u32 flash_addr, hi_upg_head *upg_head);
62 hi_u32 boot_upg_check_unsecure_info(hi_u32 flash_addr, hi_upg_head *upg_head);
Dboot_upg_check.c221 hi_u32 boot_upg_check_file(hi_u32 flash_addr) in boot_upg_check_file() argument
229 ret = hi_flash_read(flash_addr, sizeof(hi_upg_head), (hi_u8 *)upg_head); in boot_upg_check_file()
244 ret = boot_upg_check_secure_info(flash_addr, upg_head); in boot_upg_check_file()
246 ret = boot_upg_check_unsecure_info(flash_addr, upg_head); in boot_upg_check_file()
Dboot_upg_tool.c125 hi_u32 boot_upg_hash_one_content(hi_u32 flash_addr, hi_u32 total_size, hi_u8 *hash, hi_u32 hash_siz… in boot_upg_hash_one_content() argument
138 ret = hi_flash_read(flash_addr + offset, this_size, block); in boot_upg_hash_one_content()
170 ret = hi_flash_read(param->flash_addr[i] + offset, this_size, block); in boot_upg_hash_more_content()
172 … cs = (uintptr_t)block ^ HI_BLOCK_SIZE ^ (uintptr_t)(param->flash_addr[i] + offset) ^ this_size; in boot_upg_hash_more_content()
173 …ret = (hi_u32)memcpy_s(block, HI_BLOCK_SIZE, (hi_u8 *)(param->flash_addr[i] + offset), this_size, … in boot_upg_hash_more_content()
Dboot_upg_check.h27 hi_u32 boot_upg_check_file(hi_u32 flash_addr);
Dboot_upg_tool.h25 hi_u32 boot_upg_hash_one_content(hi_u32 flash_addr, hi_u32 total_size, hi_u8 *hash, hi_u32 hash_siz…
/device/soc/hisilicon/hi3861v100/sdk_liteos/boot/commonboot/
Dboot_rom.h241 hi_u32(*read)(struct spi_flash_ctrl *spif_ctrl, hi_u32 flash_addr,
243 hi_u32(*write)(struct spi_flash_ctrl *spif_ctrl, hi_u32 flash_addr,
245 hi_u32(*erase)(struct spi_flash_ctrl *spif_ctrl, hi_u32 flash_addr,
268 hi_u32 spif_dma_read(hi_spi_flash_ctrl *spif_ctrl, hi_u32 flash_addr, hi_u32 read_size, hi_void *ra…
270 hi_u32 spif_reg_erase(hi_spi_flash_ctrl *spif_ctrl, hi_u32 flash_addr, hi_u32 erase_size, hi_bool i…
271 hi_u32 spif_dma_write(hi_spi_flash_ctrl *spif_ctrl, hi_u32 flash_addr, hi_u32 write_size, hi_void *…
284 hi_u32 flash_write_prv(hi_spi_flash_ctrl *spif_ctrl, hi_u32 flash_addr, const hi_u8 *ram_addr, hi_u…
286 hi_u32 flash_erase_prv(hi_spi_flash_ctrl *spif_ctrl, hi_u32 flash_addr, hi_u32 size);
287 hi_u32 flash_read_prv(hi_spi_flash_ctrl *spif_ctrl, hi_u32 flash_addr, hi_u8 *data, hi_u32 size);
293 typedef hi_u32 (*flash_read_func)(hi_u32 flash_addr, hi_u32 flash_read_size, hi_u8 *p_flash_read_da…
[all …]
/device/soc/hisilicon/hi3861v100/sdk_liteos/boot/flashboot/drivers/flash/
Dhi_flashboot_flash.c308 hi_u32 hi_flash_erase(hi_u32 flash_addr, hi_u32 flash_erase_size) in hi_flash_erase() argument
312 ret = sfc_check_para(spif_ctrl, flash_addr, flash_erase_size, HI_FLASH_CHECK_PARAM_OPT_ERASE); in hi_flash_erase()
323 ret = flash_protect_cancel(flash_addr); in hi_flash_erase()
328 ret = flash_erase_prv(spif_ctrl, flash_addr, flash_erase_size); in hi_flash_erase()
335 flash_info_print("hi_flash_erase ret:%x addr:%x len:%x\r\n", ret, flash_addr, flash_erase_size); in hi_flash_erase()
339 hi_u32 hi_flash_write(hi_u32 flash_addr, hi_u32 flash_write_size, const hi_u8 *flash_write_data, hi… in hi_flash_write() argument
346 ret = sfc_check_para(spif_ctrl, flash_addr, flash_write_size, HI_FLASH_CHECK_PARAM_OPT_WRITE); in hi_flash_write()
357 ret = flash_protect_cancel(flash_addr); in hi_flash_write()
362 ret = flash_write_prv(spif_ctrl, flash_addr, flash_write_data, flash_write_size, do_erase); in hi_flash_write()
369 flash_info_print("hi_flash_write ret:%x addr:%x len:%x\r\n", ret, flash_addr, flash_write_size); in hi_flash_write()
[all …]
/device/soc/hisilicon/hi3861v100/sdk_liteos/boot/loaderboot/drivers/flash/
Dhi_loaderboot_flash.c254 hi_u32 hi_flash_erase(hi_u32 flash_addr, hi_u32 flash_erase_size) in hi_flash_erase() argument
258 ret = sfc_check_para(spif_ctrl, flash_addr, flash_erase_size, HI_FLASH_CHECK_PARAM_OPT_ERASE); in hi_flash_erase()
268 ret = flash_erase_prv(spif_ctrl, flash_addr, flash_erase_size); in hi_flash_erase()
276 flash_info_print("hi_flash_erase ret:%x addr:%x len:%x\r\n", ret, flash_addr, flash_erase_size); in hi_flash_erase()
280 hi_u32 hi_flash_write(hi_u32 flash_addr, hi_u32 flash_write_size, const hi_u8 *flash_write_data, hi… in hi_flash_write() argument
287 ret = sfc_check_para(spif_ctrl, flash_addr, flash_write_size, HI_FLASH_CHECK_PARAM_OPT_WRITE); in hi_flash_write()
297 ret = flash_write_prv(spif_ctrl, flash_addr, flash_write_data, flash_write_size, do_erase); in hi_flash_write()
304 flash_info_print("hi_flash_write ret:%x addr:%x len:%x\r\n", ret, flash_addr, flash_write_size); in hi_flash_write()
308 hi_u32 hi_flash_read(hi_u32 flash_addr, hi_u32 flash_read_size, hi_u8 *flash_read_data) in hi_flash_read() argument
315 ret = sfc_check_para(spif_ctrl, flash_addr, flash_read_size, HI_FLASH_CHECK_PARAM_OPT_READ); in hi_flash_read()
[all …]
/device/soc/hisilicon/hi3861v100/sdk_liteos/boot/loaderboot/include/
Dhi_loaderboot_flash.h54 hi_u32 hi_flash_erase(const hi_u32 flash_addr, hi_u32 flash_erase_size);
77 hi_u32 hi_flash_write(hi_u32 flash_addr, hi_u32 flash_write_size, const hi_u8 *flash_write_data, hi…
98 hi_u32 hi_flash_read(hi_u32 flash_addr, hi_u32 flash_read_size, hi_u8 *flash_read_data);
/device/soc/telink/b91/b91_ble_sdk/vendor/common/
Dblt_common.c89 _attribute_no_inline_ void blc_initMacAddress(int flash_addr, u8 *mac_public, u8 *mac_random_static) in blc_initMacAddress() argument
96 flash_read_page(flash_addr, 8, mac_read); in blc_initMacAddress()
112 flash_write_page(flash_addr, 6, mac_public); in blc_initMacAddress()
127 flash_write_page(flash_addr + 6, 2, (u8 *)(mac_random_static + 3)); in blc_initMacAddress()
/device/soc/hisilicon/hi3861v100/sdk_liteos/boot/loaderboot/common/nvm/
Dhi_nvm.c191 hi_u32 flash_addr = base_addr + i * block_size; in nv_init_common() local
192 if (nv_read_flash(flash_addr, block_size, data) != HI_ERR_SUCCESS) { in nv_init_common()
203 nv_ctrl->current_addr = flash_addr; in nv_init_common()
243 hi_u32 flash_addr; in nv_read_common() local
264 flash_addr = nv_ctrl->current_addr + nv_index->nv_offset; in nv_read_common()
265 ret = nv_read_flash(flash_addr, item_len, pdata); in nv_read_common()
271 ret = nv_read_flash(flash_addr + item_len, sizeof(crc), (hi_u8*)&crc); in nv_read_common()
300 hi_u32 flash_addr = nv_next_addr((HI_CONST hi_nv_ctrl *)nv_ctrl); in nv_block_write() local
306 ret = nv_write_flash(flash_addr, nv_ctrl->block_size, p_nv_file); in nv_block_write()
311 nv_ctrl->current_addr = flash_addr; in nv_block_write()
/device/soc/hisilicon/hi3861v100/sdk_liteos/boot/flashboot/common/nvm/
Dhi_nvm.c192 hi_u32 flash_addr = base_addr + i * block_size; in nv_init_common() local
193 … if (nv_read_flash(flash_addr, block_size, data) != HI_ERR_SUCCESS) { /* 读取 hi_nv_manage nv_head */ in nv_init_common()
204 nv_ctrl->current_addr = flash_addr; in nv_init_common()
245 hi_u32 flash_addr; in nv_read_common() local
266 flash_addr = nv_ctrl->current_addr + nv_index->nv_offset; in nv_read_common()
267 ret = nv_read_flash(flash_addr, item_len, pdata); in nv_read_common()
273 ret = nv_read_flash(flash_addr + item_len, sizeof(crc), (hi_u8*)&crc); in nv_read_common()
302 hi_u32 flash_addr = nv_next_addr((HI_CONST hi_nv_ctrl *)nv_ctrl); in nv_block_write() local
308 ret = nv_write_flash(flash_addr, nv_ctrl->block_size, p_nv_file); in nv_block_write()
313 nv_ctrl->current_addr = flash_addr; in nv_block_write()
/device/soc/hisilicon/hi3861v100/sdk_liteos/platform/drivers/flash/
Dflash_prv.h283 hi_u32 (*read)(struct spi_flash_ctrl* spif_ctrl, hi_u32 flash_addr, hi_u32 read_size,
285 hi_u32 (*write)(struct spi_flash_ctrl* spif_ctrl, hi_u32 flash_addr, hi_u32 write_size,
287 …hi_u32 (*erase)(struct spi_flash_ctrl* spif_ctrl, hi_u32 flash_addr, hi_u32 erase_size, hi_bool is…
304 HI_EXTERN hi_u32 spif_dma_read(hi_spi_flash_ctrl* spif_ctrl, hi_u32 flash_addr, hi_u32 read_size,
306 HI_EXTERN hi_u32 spif_reg_erase(hi_spi_flash_ctrl* spif_ctrl, hi_u32 flash_addr, hi_u32 erase_size,…
307 HI_EXTERN hi_u32 spif_dma_write(hi_spi_flash_ctrl* spif_ctrl, hi_u32 flash_addr, hi_u32 write_size,
314 HI_EXTERN hi_u32 flash_erase_prv(hi_spi_flash_ctrl* spif_ctrl, hi_u32 flash_addr, hi_u32 size, hi_b…
/device/soc/hisilicon/hi3861v100/sdk_liteos/boot/flashboot/include/
Dhi_flashboot.h530 hi_u32 hi_flash_erase(const hi_u32 flash_addr, hi_u32 flash_erase_size);
563 hi_u32 hi_flash_write(hi_u32 flash_addr, hi_u32 flash_write_size, const hi_u8 *p_flash_write_data, …
584 hi_u32 hi_flash_read(hi_u32 flash_addr, hi_u32 flash_read_size, hi_u8 *p_flash_read_data);
/device/soc/winnermicro/wm800/board/platform/drivers/internalflash/
Dwm_internal_fls.c414 unsigned int flash_addr; in flashRead() local
424 flash_addr = addr; in flashRead()
435 __readByCMD(0xEB, flash_addr, (unsigned char *)buf_tmp, max_size); in flashRead()
437 flash_addr += max_size; in flashRead()
441 __readByCMD(0xEB, flash_addr, (unsigned char *)buf_tmp, sz_remain); in flashRead()
449 flash_addr = addr & ~(INSIDE_FLS_PAGE_SIZE - 1); in flashRead()
450 __readByCMD(0xEB, flash_addr, (unsigned char *)cache, INSIDE_FLS_PAGE_SIZE); in flashRead()
454 flash_addr += INSIDE_FLS_PAGE_SIZE; in flashRead()
459 __readByCMD(0xEB, flash_addr, (unsigned char *)cache, INSIDE_FLS_PAGE_SIZE); in flashRead()
462 flash_addr += INSIDE_FLS_PAGE_SIZE; in flashRead()
[all …]
/device/soc/esp/esp32/components/spi_flash/esp32/
Dspi_flash_rom_patch.c271 …rom_spiflash_result_t esp_rom_spiflash_read_data(esp_rom_spiflash_chip_t *spi, uint32_t flash_addr, in esp_rom_spiflash_read_data() argument
280 if ((flash_addr + byte_length) > (spi->chip_size)) { in esp_rom_spiflash_read_data()
284 temp_addr = flash_addr; in esp_rom_spiflash_read_data()
529 esp_rom_spiflash_result_t esp_rom_spiflash_write_encrypted(uint32_t flash_addr, uint32_t *data, uin… in esp_rom_spiflash_write_encrypted() argument
534 if ((flash_addr & 0x1f) || (len & 0x1f)) { //check 32 byte alignment in esp_rom_spiflash_write_encrypted()
541 …if ((ret = esp_rom_spiflash_prepare_encrypted_data(flash_addr + (i << 5), data + (i << 3))) != ESP… in esp_rom_spiflash_write_encrypted()
545 …if ((ret = esp_rom_spiflash_write(flash_addr + (i << 5), data, 32)) != ESP_ROM_SPIFLASH_RESULT_OK)… in esp_rom_spiflash_write_encrypted()
/device/soc/hisilicon/hi3861v100/sdk_liteos/components/at/src/
Dat_demo_hks.c195 hi_void hks_get_key_data(hi_u32 flash_addr, struct hks_blob *blob_key_data) in hks_get_key_data() argument
198 blob_key_data->data = (hi_u8*)(FLASH_BASE_ADDR + flash_addr + KYY_PARAM_MAX_LEN + LEN_BYTE); in hks_get_key_data()
199 blob_key_data->size = *((hi_u32 *)(FLASH_BASE_ADDR + flash_addr + KYY_PARAM_MAX_LEN)); in hks_get_key_data()
202 hi_u32 hks_get_enc_param(hi_u32 flash_addr, encrypt_param *enc_param, struct hks_crypt_param *hks_e… in hks_get_enc_param() argument
206 ret = hi_flash_read(flash_addr, sizeof(encrypt_param), (hi_u8 *)enc_param); in hks_get_enc_param()
311 hi_void hks_get_conn_cipher_data(hi_u32 flash_addr, struct hks_blob *blob_cipher_data) in hks_get_conn_cipher_data() argument
313 hi_u32 cipher_data_size = *((hi_u32*)(FLASH_BASE_ADDR + flash_addr + sizeof(encrypt_param))); in hks_get_conn_cipher_data()
314 hi_u8 *cipher_data = (hi_u8*)(FLASH_BASE_ADDR + flash_addr + sizeof(encrypt_param) + LEN_BYTE); in hks_get_conn_cipher_data()
585 hi_void hks_get_cert_cipher_data(hi_u32 flash_addr, struct hks_blob *blob_cipher_data, hi_u32 ciphe… in hks_get_cert_cipher_data() argument
587 hi_u8 *cipher_data = (hi_u8*)(FLASH_BASE_ADDR + flash_addr + sizeof(encrypt_param)); in hks_get_cert_cipher_data()
/device/soc/esp/esp32/components/spi_flash/sim/
Dflash_mock.cpp103 esp_rom_spiflash_result_t esp_rom_spiflash_write_encrypted(uint32_t flash_addr, uint32_t *data, uin… in esp_rom_spiflash_write_encrypted() argument
105 return spiflash.write(flash_addr, data, len); in esp_rom_spiflash_write_encrypted()
/device/soc/esp/esp32/components/esp_rom/include/esp32/rom/
Dspi_flash.h483 esp_rom_spiflash_result_t esp_rom_spiflash_prepare_encrypted_data(uint32_t flash_addr, uint32_t *da…
513 esp_rom_spiflash_result_t esp_rom_spiflash_write_encrypted(uint32_t flash_addr, uint32_t *data, uin…
/device/soc/telink/b91/b91_ble_sdk/stack/ble/host/smp/
Dsmp_storage.h180 int blc_smp_setPeerAddrResSupportFlg(u32 flash_addr, u8 support);
/device/soc/esp/esp32/components/bootloader_support/src/
Desp_image_format.c86 static esp_err_t process_segment(int index, uint32_t flash_addr, esp_image_segment_header_t *header…
526 static esp_err_t process_segment(int index, uint32_t flash_addr, esp_image_segment_header_t *header… in process_segment() argument
531 err = bootloader_flash_read(flash_addr, header, sizeof(esp_image_segment_header_t), true); in process_segment()
533 ESP_LOGE(TAG, "bootloader_flash_read failed at 0x%08x", flash_addr); in process_segment()
542 uint32_t data_addr = flash_addr + sizeof(esp_image_segment_header_t); in process_segment()

12