lh | 9ed821d | 2023-04-07 01:36:19 -0700 | [diff] [blame] | 1 | /******************************************************************************* |
| 2 | * °æÈ¨ËùÓÐ (C)2016, ÖÐÐËͨѶ¹É·ÝÓÐÏÞ¹«Ë¾¡£ |
| 3 | * |
| 4 | * ÎļþÃû³Æ: ramdump.h |
| 5 | * Îļþ±êʶ: ramdump.h |
| 6 | * ÄÚÈÝÕªÒª: ramdump¶ÔÍâÌṩͷÎļþ |
| 7 | * ʹÓ÷½·¨: #include "ramdump.h" |
| 8 | * |
| 9 | * ÐÞ¸ÄÈÕÆÚ °æ±¾ºÅ Ð޸ıê¼Ç ÐÞ¸ÄÈË ÐÞ¸ÄÄÚÈÝ |
| 10 | * ------------------------------------------------------------------------------ |
| 11 | * 2016/3/10 V1.0 Create ÕÔ¾ü¿ü ´´½¨ |
| 12 | * |
| 13 | *******************************************************************************/ |
| 14 | |
| 15 | #ifndef _RAMDUMP_H |
| 16 | #define _RAMDUMP_H |
| 17 | |
| 18 | /******************************************************************************* |
| 19 | * Í·Îļþ * |
| 20 | *******************************************************************************/ |
| 21 | |
| 22 | /******************************************************************************* |
| 23 | * Íⲿº¯ÊýÉùÃ÷ * |
| 24 | *******************************************************************************/ |
| 25 | |
| 26 | /******************************************************************************* |
| 27 | * ºê¶¨Òå * |
| 28 | *******************************************************************************/ |
xf.li | 7ccf837 | 2024-03-07 00:08:02 -0800 | [diff] [blame^] | 29 | #define RAMDUMP_CLEAR_PRIO_FLAG (0x7) |
lh | 9ed821d | 2023-04-07 01:36:19 -0700 | [diff] [blame] | 30 | |
| 31 | /******************************************************************************* |
| 32 | * Êý¾ÝÀàÐͶ¨Òå * |
| 33 | *******************************************************************************/ |
| 34 | typedef int (*ramdump_callback_t)(void); |
| 35 | |
| 36 | /* RAMDUMP_FLAG_XXX */ |
| 37 | enum |
| 38 | { |
| 39 | RAMDUMP_FLAG_NONE = 0x00, /* default */ |
| 40 | RAMDUMP_FLAG_NEED_COPY = 0x01, /* Copy destination address */ |
| 41 | RAMDUMP_FLAG_HAS_EXTERNAL = 0x02, /* External address */ |
| 42 | RAMDUMP_FLAG_HAS_CALLBACK = 0x04, /* Callback funtion */ |
xf.li | 7ccf837 | 2024-03-07 00:08:02 -0800 | [diff] [blame^] | 43 | RAMDUMP_FLAG_LEVEL_HIGH = 0x08, /* High prior level */ |
| 44 | RAMDUMP_FLAG_LEVEL_MEDIUM = 0x10, /* Medium prior level */ |
| 45 | RAMDUMP_FLAG_LEVEL_LOW = 0x20, /* Low prior level */ |
| 46 | }; |
lh | 9ed821d | 2023-04-07 01:36:19 -0700 | [diff] [blame] | 47 | |
| 48 | /******************************************************************************* |
| 49 | * È«¾Ö±äÁ¿ÉùÃ÷ * |
| 50 | *******************************************************************************/ |
| 51 | |
| 52 | /******************************************************************************* |
| 53 | * È«¾Öº¯ÊýÉùÃ÷ * |
| 54 | *******************************************************************************/ |
| 55 | #if defined (CONFIG_RAMDUMP) || defined (_USE_CLIENT_RAMDUMP) |
| 56 | extern void ramdump_ram_conf_table_add( |
| 57 | char *ram_name, |
| 58 | unsigned long ram_phy, |
| 59 | unsigned long ram_size, |
| 60 | unsigned long ram_virt, |
| 61 | unsigned long ram_flag, |
| 62 | unsigned long ram_extra); |
| 63 | #else |
| 64 | static void ramdump_ram_conf_table_add( |
| 65 | char *ram_name, |
| 66 | unsigned long ram_phy, |
| 67 | unsigned long ram_size, |
| 68 | unsigned long ram_virt, |
| 69 | unsigned long ram_flag, |
| 70 | unsigned long ram_extra) |
| 71 | { |
| 72 | ; |
| 73 | } |
| 74 | #endif |
| 75 | |
| 76 | /******************************************************************************* |
| 77 | * ÄÚÁªº¯ÊýʵÏÖ * |
| 78 | *******************************************************************************/ |
| 79 | |
| 80 | #endif //#ifndef _RAMDUMP_H |
| 81 | |