[Feature][ZXW-179]merge P52U02 version

Only Configure: No
Affected branch: master
Affected module: unknow
Is it affected on both ZXIC and MTK: only ZXIC
Self-test: Yes
Doc Update: No

Change-Id: I4fa8f86757e71388ae88400914dae8b50cd00338
diff --git a/ap/app/include/flags_api.h b/ap/app/include/flags_api.h
index c779ef4..ac2db80 100755
--- a/ap/app/include/flags_api.h
+++ b/ap/app/include/flags_api.h
@@ -1,6 +1,6 @@
 /**
  * @file flags_api.h
- * @brief flags分区接口
+ * @brief flags·ÖÇø½Ó¿Ú
  *
  * Copyright (C) 2023 Sanechips Technology Co., Ltd.
  * @author 
@@ -8,7 +8,7 @@
  * 
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License version 2 as
- * published by the Free Software Foundation. (必选:GPLv2 Licence)
+ * published by the Free Software Foundation. £¨±ØÑ¡£ºGPLv2 Licence£©
  *
  */
 
@@ -42,59 +42,59 @@
  *                       Global function declarations                          *
  ******************************************************************************/
 /**
- * @brief  初始化flags分区
- * @param[out]  p_flags_info  flags初始化数据
- * @return  0 初始化成功, -1 初始化失败
+ * @brief  ³õʼ»¯flags·ÖÇø
+ * @param[out]  p_flags_info  flags³õʼ»¯Êý¾Ý
+ * @return  0 ³õʼ»¯³É¹¦, -1 ³õʼ»¯Ê§°Ü
  * @note
  */
 int flags_init();
 
 
 /**
- * @brief  获取flags分区内容
- * @param[out]  p_flags_info  flags分区内容
- * @return  0 获取成功, -1 获取失败
+ * @brief  »ñÈ¡flags·ÖÇøÄÚÈÝ
+ * @param[out]  p_flags_info  flags·ÖÇøÄÚÈÝ
+ * @return  0 »ñÈ¡³É¹¦, -1 »ñȡʧ°Ü
  * @note
  */
 int flags_get(T_FLAGS_INFO *p_flags_info);
 
 
 /**
- * @brief  设置flags分区内容
- * @param[out]  p_flags_info  flags分区内容
- * @return  0 设置成功, -1 设置失败
+ * @brief  ÉèÖÃflags·ÖÇøÄÚÈÝ
+ * @param[in]  p_flags_info  flags·ÖÇøÄÚÈÝ
+ * @return  0 ÉèÖóɹ¦, -1 ÉèÖÃʧ°Ü
  * @note
  */
 int flags_set(T_FLAGS_INFO *p_flags_info);
 
 
 /**
- * @brief  获取flags分区中ubifs状态
- * @param[out]  status  ubifs状态
- * @return  0 获取成功, -1 获取失败
+ * @brief  »ñÈ¡flags·ÖÇøÖÐubifs״̬
+ * @param[out]  status  ubifs״̬
+ * @return  0 »ñÈ¡³É¹¦, -1 »ñȡʧ°Ü
  * @note
  */
 int flags_get_ubifs_status(T_UBIFS_STATUS *p_ubifs_status);
 
 
 /**
- * @brief  设置flags分区中ubifs状态
- * @param[in]  status  ubifs状态
- * @return  0 设置成功, -1 设置失败
+ * @brief  ÉèÖÃflags·ÖÇøÖÐubifs״̬
+ * @param[in]  status  ubifs״̬
+ * @return  0 ÉèÖóɹ¦, -1 ÉèÖÃʧ°Ü
  * @note
  */
 int flags_set_ubifs_status(T_UBIFS_STATUS *p_ubifs_status);
 
 
 /**
- * @brief  获取当前系统
- * @return  当前运行系统
+ * @brief  »ñÈ¡µ±Ç°ÏµÍ³
+ * @return  µ±Ç°ÔËÐÐϵͳ
  * @note
  */
 int flags_get_current_system();
 
 /**
- * @brief  »ñÈ¡flags·ÖÇøÖÐnvro_flag״̬
+ * @brief  »ñÈ¡flags·ÖÇøÖÐnvro_flag״̬
  * @param[out]  
  * @return  nvro_flag
  * @note
@@ -102,13 +102,52 @@
 unsigned int flags_get_nvroflag(void);
 
 /**
- * @brief  ÉèÖÃflags·ÖÇøÖÐnvro_flag
- * @param[in]  flag nvro״̬
- * @return  0 ÉèÖóɹ¦, -1 ÉèÖÃʧ°Ü
+ * @brief  ÉèÖÃflags·ÖÇøÖÐnvro_flag
+ * @param[in]  flag nvro״̬
+ * @return  0 ÉèÖóɹ¦, -1 ÉèÖÃʧ°Ü
  * @note
  */
 int flags_set_nvroflag(unsigned int flag);
 
 
+/**
+ * @brief  »ñÈ¡flags·ÖÇøÄÚÈÝ(ÎÞCRC)
+ * @param[out]  p_flags_info  flags·ÖÇøÄÚÈÝ
+ * @return  0 »ñÈ¡³É¹¦, -1 »ñȡʧ°Ü
+ * @note  ´ËAPI½öÓÃÓÚµ÷²â£¬Õýʽ´úÂë²»¿ÉʹÓÃ
+
+ */
+int flags_get_nocrc(T_FLAGS_INFO *p_flags_info);
+
+
+/**
+ * @brief  ÉèÖÃflags·ÖÇøÄÚÈÝ(ÎÞCRC)
+ * @param[in]  p_flags_info  flags·ÖÇøÄÚÈÝ
+ * @return  0 ÉèÖóɹ¦, -1 ÉèÖÃʧ°Ü
+ * @note  ´ËAPI½öÓÃÓÚµ÷²â£¬Õýʽ´úÂë²»¿ÉʹÓÃ
+ */
+int flags_set_nocrc(T_FLAGS_INFO *p_flags_info);
+
+
+/**
+ * @brief  ³õʼ»¯CRC32Âë±í(С¶Ë)
+ * @param  ÎÞ
+ * @return ÎÞ
+ * @note
+ */
+void crc32init_le(void);
+
+
+/**
+ * @brief  ¼ÆËãCRC32УÑéÂë(С¶Ë)
+ * @param[in]  crc ³õʼֵ
+ * @param[in]  p  ÐèÒª¼ÆËãCRC32УÑéÂëµÄÊý¾ÝbufferÖ¸Õë
+ * @param[in]  len  buffer @pµÄ´óС
+ * @return  ¼ÆËãËùµÃµÄCRC32УÑéÂë
+ * @note
+ */
+unsigned int crc32_le(unsigned int crc, unsigned char const *p, size_t len);
+
+
 #endif // FLAGS_API_H