xf.li | 6c8fc1e | 2023-08-12 00:11:09 -0700 | [diff] [blame^] | 1 | /** |
| 2 | * @file flags_api.h |
| 3 | * @brief flags·ÖÇø½Ó¿Ú |
| 4 | * |
| 5 | * Copyright (C) 2023 Sanechips Technology Co., Ltd. |
| 6 | * @author |
| 7 | * @ingroup |
| 8 | * |
| 9 | * This program is free software; you can redistribute it and/or modify |
| 10 | * it under the terms of the GNU General Public License version 2 as |
| 11 | * published by the Free Software Foundation. £¨±ØÑ¡£ºGPLv2 Licence£© |
| 12 | * |
| 13 | */ |
| 14 | |
| 15 | |
| 16 | #ifndef FLAGS_API_H |
| 17 | #define FLAGS_API_H |
| 18 | |
| 19 | |
| 20 | /******************************************************************************* |
| 21 | * Include header files * |
| 22 | ******************************************************************************/ |
| 23 | #include "pub_flags.h" |
| 24 | |
| 25 | |
| 26 | /******************************************************************************* |
| 27 | * Macro definitions * |
| 28 | ******************************************************************************/ |
| 29 | |
| 30 | |
| 31 | /******************************************************************************* |
| 32 | * Type definitions * |
| 33 | ******************************************************************************/ |
| 34 | |
| 35 | |
| 36 | /******************************************************************************* |
| 37 | * Global variable declarations * |
| 38 | ******************************************************************************/ |
| 39 | |
| 40 | |
| 41 | /******************************************************************************* |
| 42 | * Global function declarations * |
| 43 | ******************************************************************************/ |
| 44 | /** |
| 45 | * @brief ³õʼ»¯flags·ÖÇø |
| 46 | * @param[out] p_flags_info flags³õʼ»¯Êý¾Ý |
| 47 | * @return 0 ³õʼ»¯³É¹¦, -1 ³õʼ»¯Ê§°Ü |
| 48 | * @note |
| 49 | */ |
| 50 | int flags_init(); |
| 51 | |
| 52 | |
| 53 | /** |
| 54 | * @brief »ñÈ¡flags·ÖÇøÄÚÈÝ |
| 55 | * @param[out] p_flags_info flags·ÖÇøÄÚÈÝ |
| 56 | * @return 0 »ñÈ¡³É¹¦, -1 »ñȡʧ°Ü |
| 57 | * @note |
| 58 | */ |
| 59 | int flags_get(T_FLAGS_INFO *p_flags_info); |
| 60 | |
| 61 | |
| 62 | /** |
| 63 | * @brief ÉèÖÃflags·ÖÇøÄÚÈÝ |
| 64 | * @param[out] p_flags_info flags·ÖÇøÄÚÈÝ |
| 65 | * @return 0 ÉèÖóɹ¦, -1 ÉèÖÃʧ°Ü |
| 66 | * @note |
| 67 | */ |
| 68 | int flags_set(T_FLAGS_INFO *p_flags_info); |
| 69 | |
| 70 | |
| 71 | /** |
| 72 | * @brief »ñÈ¡flags·ÖÇøÖÐubifs״̬ |
| 73 | * @param[out] status ubifs״̬ |
| 74 | * @return 0 »ñÈ¡³É¹¦, -1 »ñȡʧ°Ü |
| 75 | * @note |
| 76 | */ |
| 77 | int flags_get_ubifs_status(T_UBIFS_STATUS *p_ubifs_status); |
| 78 | |
| 79 | |
| 80 | /** |
| 81 | * @brief ÉèÖÃflags·ÖÇøÖÐubifs״̬ |
| 82 | * @param[in] status ubifs״̬ |
| 83 | * @return 0 ÉèÖóɹ¦, -1 ÉèÖÃʧ°Ü |
| 84 | * @note |
| 85 | */ |
| 86 | int flags_set_ubifs_status(T_UBIFS_STATUS *p_ubifs_status); |
| 87 | |
| 88 | |
| 89 | /** |
| 90 | * @brief »ñÈ¡µ±Ç°ÏµÍ³ |
| 91 | * @return µ±Ç°ÔËÐÐϵͳ |
| 92 | * @note |
| 93 | */ |
| 94 | int flags_get_current_system(); |
| 95 | |
| 96 | |
| 97 | #endif // FLAGS_API_H |
| 98 | |