• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2020 HiSilicon (Shanghai) Technologies CO., LIMITED.
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  *     http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 
16 #ifndef __BOOT_UPG_CHECK_H__
17 #define __BOOT_UPG_CHECK_H__
18 
19 #include <boot_upg_common.h>
20 
21 #define PRODUCT_UPG_FILE_IMAGE_ID 0x3C78961E
22 #define KERELN_VER_MAX          48
23 #define KERNEL_VER_LEN          6
24 hi_u32 boot_upg_get_common_head(hi_u32 addr, hi_upg_common_head *head);
25 hi_u32 boot_upg_get_section_head(hi_u32 addr, hi_upg_section_head *section_head);
26 hi_u32 boot_upg_check_common_head(const hi_upg_common_head *head);
27 hi_u32 boot_upg_check_file(hi_u32 flash_addr);
28 hi_void boot_get_start_addr_offset(hi_u32 addr, hi_u32 *offset);
29 hi_u32 boot_upg_check_code_ver(hi_u8 ver);
30 
31 #endif
32