[COMMON] lib: dss: Seperate definition of dbg_snapshot_log.
authorYoungwan Kim <y103.kim@samsung.com>
Tue, 8 May 2018 01:46:50 +0000 (10:46 +0900)
committerSunyoung Kang <sy0816.kang@samsung.com>
Mon, 23 Jul 2018 08:04:43 +0000 (17:04 +0900)
Change-Id: I693a926462b4dd9d95dce1fbeb3d07ec3f5252f3
Signed-off-by: Youngwan Kim <y103.kim@samsung.com>
include/dt-bindings/soc/samsung/debug-snapshot-table.h
lib/debug-snapshot-local.h
lib/debug-snapshot-log.h [new file with mode: 0644]

index 552a0cdb4330d748144c507b9c7eb01f82a0bcb4..a93502484fda90ea5ed1d157adaf1aee384b1a25 100644 (file)
  * We must use bootloader settings first.
 *************************************************************************/
 
-#define SZ_64K                         0x00010000
-#define SZ_1M                          0x00100000
+#define SZ_16                          0x00000010
+#define SZ_32                          0x00000020
+#define SZ_64                          0x00000040
+#define SZ_128                         0x00000080
+#define SZ_256                         0x00000100
+#define SZ_512                         0x00000200
+
+#define SZ_1K                          0x00000400
+#define SZ_2K                          0x00000800
+#define SZ_4K                          0x00001000
+#define SZ_8K                          0x00002000
+#define SZ_16K                         0x00004000
+#define SZ_32K                         0x00008000
+#define SZ_64K                         0x00010000
+#define SZ_128K                                0x00020000
+#define SZ_256K                                0x00040000
+#define SZ_512K                                0x00080000
+
+#define SZ_1M                          0x00100000
+#define SZ_2M                          0x00200000
+#define SZ_4M                          0x00400000
+#define SZ_8M                          0x00800000
+#define SZ_16M                         0x01000000
+#define SZ_32M                         0x02000000
+#define SZ_48M                         0x03000000
+#define SZ_64M                         0x04000000
+#define SZ_128M                                0x08000000
+#define SZ_256M                                0x10000000
+#define SZ_512M                                0x20000000
+
+#define SZ_1G                          0x40000000
+#define SZ_2G                          0x80000000
 
 #define DSS_START_ADDR                 0xF9000000
 #define DSS_HEADER_SIZE                        SZ_64K
index 7a645c2ba825e2c7123794328ce3c7b3b9b61690..4683bf72153928f14977478fc600e542a552eb66 100644 (file)
@@ -17,6 +17,7 @@
 #define DEBUG_SNAPSHOT_LOCAL_H
 #include <linux/debug-snapshot.h>
 #include <linux/debug-snapshot-helper.h>
+#include "debug-snapshot-log.h"
 
 #ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
 #include <linux/clk-provider.h>
@@ -39,52 +40,6 @@ extern void dbg_snapshot_recall_hardlockup_core(void);
 
 extern struct dbg_snapshot_helper_ops *dss_soc_ops;
 
-/*  Size domain */
-#define DSS_KEEP_HEADER_SZ             (SZ_256 * 3)
-#define DSS_HEADER_SZ                  SZ_4K
-#define DSS_MMU_REG_SZ                 SZ_4K
-#define DSS_CORE_REG_SZ                        SZ_4K
-#define DSS_DBGC_LOG_SZ                        SZ_4K
-#define DSS_HEADER_TOTAL_SZ            (DSS_HEADER_SZ + DSS_MMU_REG_SZ + DSS_CORE_REG_SZ + DSS_DBGC_LOG_SZ)
-#define DSS_SPARE_SZ                   (DSS_HEADER_SIZE - DSS_HEADER_TOTAL_SZ)
-
-/*  Length domain */
-#define DSS_LOG_STRING_LENGTH          SZ_128
-#define DSS_MMU_REG_OFFSET             SZ_512
-#define DSS_CORE_REG_OFFSET            SZ_512
-#define DSS_LOG_MAX_NUM                        SZ_1K
-#define DSS_API_MAX_NUM                        SZ_2K
-#define DSS_EX_MAX_NUM                 SZ_8
-#define DSS_IN_MAX_NUM                 SZ_8
-#define DSS_CALLSTACK_MAX_NUM          4
-#define DSS_ITERATION                  5
-#define DSS_NR_CPUS                    NR_CPUS
-#define DSS_ITEM_MAX_NUM               10
-
-/* Sign domain */
-#define DSS_SIGN_RESET                 0x0
-#define DSS_SIGN_RESERVED              0x1
-#define DSS_SIGN_SCRATCH               0xD
-#define DSS_SIGN_ALIVE                 0xFACE
-#define DSS_SIGN_DEAD                  0xDEAD
-#define DSS_SIGN_PANIC                 0xBABA
-#define DSS_SIGN_SAFE_FAULT            0xFAFA
-#define DSS_SIGN_NORMAL_REBOOT         0xCAFE
-#define DSS_SIGN_FORCE_REBOOT          0xDAFE
-#define DSS_SIGN_LOCKUP                        0xDEADBEEF
-
-/*  Specific Address Information */
-#define DSS_FIXED_VIRT_BASE            (VMALLOC_START + 0xF6000000)
-#define DSS_OFFSET_SCRATCH             (0x100)
-#define DSS_OFFSET_LAST_LOGBUF         (0x200)
-#define DSS_OFFSET_EMERGENCY_REASON    (0x300)
-#define DSS_OFFSET_CORE_POWER_STAT     (0x400)
-#define DSS_OFFSET_PANIC_STAT          (0x500)
-#define DSS_OFFSET_CORE_LAST_PC                (0x600)
-
-/* S5P_VA_SS_BASE + 0xC00 -- 0xFFF is reserved */
-#define DSS_OFFSET_PANIC_STRING                (0xC00)
-#define DSS_OFFSET_SPARE_BASE          (DSS_HEADER_TOTAL_SZ)
 
 /* SoC Specific define, This will be removed */
 #define DSS_REG_MCT_ADDR       (0)
@@ -143,280 +98,6 @@ struct dbg_snapshot_desc {
        int no_wdt_dev;
 };
 
-struct dbg_snapshot_log {
-       struct __task_log {
-               unsigned long long time;
-               unsigned long sp;
-#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
-               struct task_struct *task;
-#else
-               void *task;
-#endif
-               char task_comm[TASK_COMM_LEN];
-       } task[DSS_NR_CPUS][DSS_LOG_MAX_NUM];
-
-       struct __work_log {
-               unsigned long long time;
-               unsigned long sp;
-#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
-               struct worker *worker;
-               work_func_t fn;
-#else
-               void *worker;
-               void *fn;
-#endif
-               char task_comm[TASK_COMM_LEN];
-               int en;
-       } work[DSS_NR_CPUS][DSS_LOG_MAX_NUM];
-
-       struct __cpuidle_log {
-               unsigned long long time;
-               unsigned long sp;
-               char *modes;
-               unsigned state;
-#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
-               u32 num_online_cpus;
-#else
-               unsigned int num_online_cpus;
-#endif
-               int delta;
-               int en;
-       } cpuidle[DSS_NR_CPUS][DSS_LOG_MAX_NUM];
-
-       struct __suspend_log {
-               unsigned long long time;
-               unsigned long sp;
-               void *fn;
-#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
-               struct device *dev;
-#else
-               void *dev;
-#endif
-               int en;
-               int core;
-       } suspend[DSS_LOG_MAX_NUM * 4];
-
-       struct __irq_log {
-               unsigned long long time;
-               unsigned long sp;
-               int irq;
-               void *fn;
-#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
-               struct irqaction *action;
-#else
-               void *action;
-#endif
-               int en;
-       } irq[DSS_NR_CPUS][DSS_LOG_MAX_NUM * 2];
-
-#ifdef CONFIG_DEBUG_SNAPSHOT_IRQ_EXIT
-       struct __irq_exit_log {
-               unsigned long long time;
-               unsigned long sp;
-               unsigned long long end_time;
-               unsigned long long latency;
-               int irq;
-       } irq_exit[DSS_NR_CPUS][DSS_LOG_MAX_NUM];
-#endif
-#ifdef CONFIG_DEBUG_SNAPSHOT_SPINLOCK
-       struct __spinlock_log {
-               unsigned long long time;
-               unsigned long sp;
-               unsigned long long jiffies;
-#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
-               raw_spinlock_t *lock;
-#ifdef CONFIG_DEBUG_SPINLOCK
-               u16 next;
-               u16 owner;
-#endif
-#else
-               void *lock;
-#ifdef CONFIG_DEBUG_SPINLOCK
-               unsigned short next;
-               unsigned short owner;
-#endif
-#endif
-               int en;
-               void *caller[DSS_CALLSTACK_MAX_NUM];
-       } spinlock[DSS_NR_CPUS][DSS_LOG_MAX_NUM];
-#endif
-#ifdef CONFIG_DEBUG_SNAPSHOT_IRQ_DISABLED
-       struct __irqs_disabled_log {
-               unsigned long long time;
-               unsigned long index;
-#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
-               struct task_struct *task;
-#else
-               void *task;
-#endif
-               char *task_comm;
-               void *caller[DSS_CALLSTACK_MAX_NUM];
-       } irqs_disabled[DSS_NR_CPUS][SZ_32];
-#endif
-#ifdef CONFIG_DEBUG_SNAPSHOT_CLK
-       struct __clk_log {
-               unsigned long long time;
-#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
-               struct clk_hw *clk;
-#else
-               void *clk;
-#endif
-               const char* f_name;
-               int mode;
-               unsigned long arg;
-       } clk[DSS_LOG_MAX_NUM];
-#endif
-#ifdef CONFIG_DEBUG_SNAPSHOT_PMU
-       struct __pmu_log {
-               unsigned long long time;
-               unsigned int id;
-               const char *f_name;
-               int mode;
-       } pmu[DSS_LOG_MAX_NUM];
-#endif
-#ifdef CONFIG_DEBUG_SNAPSHOT_FREQ
-       struct __freq_log {
-               unsigned long long time;
-               int cpu;
-               char *freq_name;
-               unsigned long old_freq;
-               unsigned long target_freq;
-               int en;
-       } freq[DSS_LOG_MAX_NUM];
-#endif
-#ifdef CONFIG_DEBUG_SNAPSHOT_DM
-       struct __dm_log {
-               unsigned long long time;
-               int cpu;
-               int dm_num;
-               unsigned long min_freq;
-               unsigned long max_freq;
-#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
-               s32 wait_dmt;
-               s32 do_dmt;
-#else
-               int wait_dmt;
-               int do_dmt;
-#endif
-       } dm[DSS_LOG_MAX_NUM];
-#endif
-#ifdef CONFIG_DEBUG_SNAPSHOT_REG
-       struct __reg_log {
-               unsigned long long time;
-               int read;
-               size_t val;
-               size_t reg;
-               int en;
-               void *caller[DSS_CALLSTACK_MAX_NUM];
-       } reg[DSS_NR_CPUS][DSS_LOG_MAX_NUM];
-#endif
-#ifdef CONFIG_DEBUG_SNAPSHOT_HRTIMER
-       struct __hrtimer_log {
-               unsigned long long time;
-               unsigned long long now;
-#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
-               struct hrtimer *timer;
-#else
-               void *timer;
-#endif
-               void *fn;
-               int en;
-       } hrtimers[DSS_NR_CPUS][DSS_LOG_MAX_NUM];
-#endif
-#ifdef CONFIG_DEBUG_SNAPSHOT_REGULATOR
-       struct __regulator_log {
-               unsigned long long time;
-               unsigned long long acpm_time;
-               int cpu;
-               char name[SZ_16];
-               unsigned int reg;
-               unsigned int voltage;
-               unsigned int raw_volt;
-               int en;
-       } regulator[DSS_LOG_MAX_NUM];
-#endif
-#ifdef CONFIG_DEBUG_SNAPSHOT_THERMAL
-       struct __thermal_log {
-               unsigned long long time;
-               int cpu;
-#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
-               struct exynos_tmu_platform_data *data;
-#else
-               void *data;
-#endif
-               unsigned int temp;
-               char *cooling_device;
-               unsigned int cooling_state;
-       } thermal[DSS_LOG_MAX_NUM];
-#endif
-#ifdef CONFIG_DEBUG_SNAPSHOT_ACPM
-       struct __acpm_log {
-               unsigned long long time;
-               unsigned long long acpm_time;
-               char log[9];
-               unsigned int data;
-       } acpm[DSS_LOG_MAX_NUM];
-#endif
-#ifdef CONFIG_DEBUG_SNAPSHOT_I2C
-       struct __i2c_log {
-               unsigned long long time;
-               int cpu;
-#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
-               struct i2c_adapter *adap;
-               struct i2c_msg *msgs;
-#else
-               void *adp;
-               void *msgs;
-#endif
-               int num;
-               int en;
-       } i2c[DSS_LOG_MAX_NUM];
-#endif
-#ifdef CONFIG_DEBUG_SNAPSHOT_SPI
-       struct __spi_log {
-               unsigned long long time;
-               int cpu;
-#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
-               struct spi_controller *ctlr;
-               struct spi_message *cur_msg;
-#else
-               void *ctlr;
-               void *cur_msg;
-#endif
-               int en;
-       } spi[DSS_LOG_MAX_NUM];
-#endif
-
-#ifndef CONFIG_DEBUG_SNAPSHOT_MINIMIZED_MODE
-       struct __clockevent_log {
-               unsigned long long time;
-               unsigned long long mct_cycle;
-#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
-               int64_t delta_ns;
-               ktime_t next_event;
-#else
-               long long delta_ns;
-               long long next_event;
-#endif
-               void *caller[DSS_CALLSTACK_MAX_NUM];
-       } clockevent[DSS_NR_CPUS][DSS_LOG_MAX_NUM];
-
-       struct __printkl_log {
-               unsigned long long time;
-               int cpu;
-               size_t msg;
-               size_t val;
-               void *caller[DSS_CALLSTACK_MAX_NUM];
-       } printkl[DSS_API_MAX_NUM];
-
-       struct __printk_log {
-               unsigned long long time;
-               int cpu;
-               char log[DSS_LOG_STRING_LENGTH];
-               void *caller[DSS_CALLSTACK_MAX_NUM];
-       } printk[DSS_API_MAX_NUM];
-#endif
-};
 
 extern struct dbg_snapshot_base dss_base;
 extern struct dbg_snapshot_log *dss_log;
diff --git a/lib/debug-snapshot-log.h b/lib/debug-snapshot-log.h
new file mode 100644 (file)
index 0000000..1655fa0
--- /dev/null
@@ -0,0 +1,344 @@
+
+#ifndef DEBUG_SNAPSHOT_LOG_H
+#define DEBUG_SNAPSHOT_LOG_H
+
+#ifdef DSS_ANALYZER
+
+#define TASK_COMM_LEN 16
+#define NR_CPUS 8
+#undef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
+
+#else // DSS_ANALYZER
+
+#include <generated/autoconf.h>
+#include <linux/clk-provider.h>
+#include <linux/debug-snapshot.h>
+#include <linux/debug-snapshot-helper.h>
+
+#endif // DSS_ANALYZER
+
+#include <dt-bindings/soc/samsung/debug-snapshot-table.h>
+
+/*  Size domain */
+#define DSS_KEEP_HEADER_SZ             (SZ_256 * 3)
+#define DSS_HEADER_SZ                  SZ_4K
+#define DSS_MMU_REG_SZ                 SZ_4K
+#define DSS_CORE_REG_SZ                        SZ_4K
+#define DSS_DBGC_LOG_SZ                        SZ_4K
+#define DSS_HEADER_TOTAL_SZ            (DSS_HEADER_SZ + DSS_MMU_REG_SZ + DSS_CORE_REG_SZ + DSS_DBGC_LOG_SZ)
+#define DSS_SPARE_SZ                   (DSS_HEADER_SIZE - DSS_HEADER_TOTAL_SZ)
+
+/*  Length domain */
+#define DSS_LOG_STRING_LENGTH          SZ_128
+#define DSS_MMU_REG_OFFSET             SZ_512
+#define DSS_CORE_REG_OFFSET            SZ_512
+#define DSS_LOG_MAX_NUM                        SZ_1K
+#define DSS_API_MAX_NUM                        SZ_2K
+#define DSS_EX_MAX_NUM                 SZ_8
+#define DSS_IN_MAX_NUM                 SZ_8
+#define DSS_CALLSTACK_MAX_NUM          4
+#define DSS_ITERATION                  5
+#define DSS_NR_CPUS                    NR_CPUS
+#define DSS_ITEM_MAX_NUM               10
+
+/* Sign domain */
+#define DSS_SIGN_RESET                 0x0
+#define DSS_SIGN_RESERVED              0x1
+#define DSS_SIGN_SCRATCH               0xD
+#define DSS_SIGN_ALIVE                 0xFACE
+#define DSS_SIGN_DEAD                  0xDEAD
+#define DSS_SIGN_PANIC                 0xBABA
+#define DSS_SIGN_SAFE_FAULT            0xFAFA
+#define DSS_SIGN_NORMAL_REBOOT         0xCAFE
+#define DSS_SIGN_FORCE_REBOOT          0xDAFE
+#define DSS_SIGN_LOCKUP                        0xDEADBEEF
+
+/*  Specific Address Information */
+#define DSS_FIXED_VIRT_BASE            (VMALLOC_START + 0xF6000000)
+#define DSS_OFFSET_SCRATCH             (0x100)
+#define DSS_OFFSET_LAST_LOGBUF         (0x200)
+#define DSS_OFFSET_EMERGENCY_REASON    (0x300)
+#define DSS_OFFSET_CORE_POWER_STAT     (0x400)
+#define DSS_OFFSET_PANIC_STAT          (0x500)
+#define DSS_OFFSET_CORE_LAST_PC                (0x600)
+
+/* S5P_VA_SS_BASE + 0xC00 -- 0xFFF is reserved */
+#define DSS_OFFSET_PANIC_STRING                (0xC00)
+#define DSS_OFFSET_SPARE_BASE          (DSS_HEADER_TOTAL_SZ)
+
+struct dbg_snapshot_log {
+       struct __task_log {
+               unsigned long long time;
+               unsigned long sp;
+#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
+               struct task_struct *task;
+#else
+               void *task;
+#endif
+               char task_comm[TASK_COMM_LEN];
+       } task[DSS_NR_CPUS][DSS_LOG_MAX_NUM];
+
+       struct __work_log {
+               unsigned long long time;
+               unsigned long sp;
+#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
+               struct worker *worker;
+               work_func_t fn;
+#else
+               void *worker;
+               void *fn;
+#endif
+               char task_comm[TASK_COMM_LEN];
+               int en;
+       } work[DSS_NR_CPUS][DSS_LOG_MAX_NUM];
+
+       struct __cpuidle_log {
+               unsigned long long time;
+               unsigned long sp;
+               char *modes;
+               unsigned int state;
+#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
+               u32 num_online_cpus;
+#else
+               unsigned int num_online_cpus;
+#endif
+               int delta;
+               int en;
+       } cpuidle[DSS_NR_CPUS][DSS_LOG_MAX_NUM];
+
+       struct __suspend_log {
+               unsigned long long time;
+               unsigned long sp;
+               void *fn;
+#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
+               struct device *dev;
+#else
+               void *dev;
+#endif
+               int en;
+               int core;
+       } suspend[DSS_LOG_MAX_NUM * 4];
+
+       struct __irq_log {
+               unsigned long long time;
+               unsigned long sp;
+               int irq;
+               void *fn;
+#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
+               struct irqaction *action;
+#else
+               void *action;
+#endif
+               int en;
+       } irq[DSS_NR_CPUS][DSS_LOG_MAX_NUM * 2];
+
+#ifdef CONFIG_DEBUG_SNAPSHOT_IRQ_EXIT
+       struct __irq_exit_log {
+               unsigned long long time;
+               unsigned long sp;
+               unsigned long long end_time;
+               unsigned long long latency;
+               int irq;
+       } irq_exit[DSS_NR_CPUS][DSS_LOG_MAX_NUM];
+#endif
+#ifdef CONFIG_DEBUG_SNAPSHOT_SPINLOCK
+       struct __spinlock_log {
+               unsigned long long time;
+               unsigned long sp;
+               unsigned long long jiffies;
+#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
+               raw_spinlock_t *lock;
+#ifdef CONFIG_DEBUG_SPINLOCK
+               u16 next;
+               u16 owner;
+#endif
+#else
+               void *lock;
+#ifdef CONFIG_DEBUG_SPINLOCK
+               unsigned short next;
+               unsigned short owner;
+#endif
+#endif
+               int en;
+               void *caller[DSS_CALLSTACK_MAX_NUM];
+       } spinlock[DSS_NR_CPUS][DSS_LOG_MAX_NUM];
+#endif
+#ifdef CONFIG_DEBUG_SNAPSHOT_IRQ_DISABLED
+       struct __irqs_disabled_log {
+               unsigned long long time;
+               unsigned long index;
+#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
+               struct task_struct *task;
+#else
+               void *task;
+#endif
+               char *task_comm;
+               void *caller[DSS_CALLSTACK_MAX_NUM];
+       } irqs_disabled[DSS_NR_CPUS][SZ_32];
+#endif
+#ifdef CONFIG_DEBUG_SNAPSHOT_CLK
+       struct __clk_log {
+               unsigned long long time;
+#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
+               struct clk_hw *clk;
+#else
+               void *clk;
+#endif
+               const char *f_name;
+               int mode;
+               unsigned long arg;
+       } clk[DSS_LOG_MAX_NUM];
+#endif
+#ifdef CONFIG_DEBUG_SNAPSHOT_PMU
+       struct __pmu_log {
+               unsigned long long time;
+               unsigned int id;
+               const char *f_name;
+               int mode;
+       } pmu[DSS_LOG_MAX_NUM];
+#endif
+#ifdef CONFIG_DEBUG_SNAPSHOT_FREQ
+       struct __freq_log {
+               unsigned long long time;
+               int cpu;
+               char *freq_name;
+               unsigned long old_freq;
+               unsigned long target_freq;
+               int en;
+       } freq[DSS_LOG_MAX_NUM];
+#endif
+#ifdef CONFIG_DEBUG_SNAPSHOT_DM
+       struct __dm_log {
+               unsigned long long time;
+               int cpu;
+               int dm_num;
+               unsigned long min_freq;
+               unsigned long max_freq;
+#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
+               s32 wait_dmt;
+               s32 do_dmt;
+#else
+               int wait_dmt;
+               int do_dmt;
+#endif
+       } dm[DSS_LOG_MAX_NUM];
+#endif
+#ifdef CONFIG_DEBUG_SNAPSHOT_REG
+       struct __reg_log {
+               unsigned long long time;
+               int read;
+               size_t val;
+               size_t reg;
+               int en;
+               void *caller[DSS_CALLSTACK_MAX_NUM];
+       } reg[DSS_NR_CPUS][DSS_LOG_MAX_NUM];
+#endif
+#ifdef CONFIG_DEBUG_SNAPSHOT_HRTIMER
+       struct __hrtimer_log {
+               unsigned long long time;
+               unsigned long long now;
+#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
+               struct hrtimer *timer;
+#else
+               void *timer;
+#endif
+               void *fn;
+               int en;
+       } hrtimers[DSS_NR_CPUS][DSS_LOG_MAX_NUM];
+#endif
+#ifdef CONFIG_DEBUG_SNAPSHOT_REGULATOR
+       struct __regulator_log {
+               unsigned long long time;
+               unsigned long long acpm_time;
+               int cpu;
+               char name[SZ_16];
+               unsigned int reg;
+               unsigned int voltage;
+               unsigned int raw_volt;
+               int en;
+       } regulator[DSS_LOG_MAX_NUM];
+#endif
+#ifdef CONFIG_DEBUG_SNAPSHOT_THERMAL
+       struct __thermal_log {
+               unsigned long long time;
+               int cpu;
+#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
+               struct exynos_tmu_platform_data *data;
+#else
+               void *data;
+#endif
+               unsigned int temp;
+               char *cooling_device;
+               unsigned int cooling_state;
+       } thermal[DSS_LOG_MAX_NUM];
+#endif
+#ifdef CONFIG_DEBUG_SNAPSHOT_ACPM
+       struct __acpm_log {
+               unsigned long long time;
+               unsigned long long acpm_time;
+               char log[9];
+               unsigned int data;
+       } acpm[DSS_LOG_MAX_NUM];
+#endif
+#ifdef CONFIG_DEBUG_SNAPSHOT_I2C
+       struct __i2c_log {
+               unsigned long long time;
+               int cpu;
+#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
+               struct i2c_adapter *adap;
+               struct i2c_msg *msgs;
+#else
+               void *adp;
+               void *msgs;
+#endif
+               int num;
+               int en;
+       } i2c[DSS_LOG_MAX_NUM];
+#endif
+#ifdef CONFIG_DEBUG_SNAPSHOT_SPI
+       struct __spi_log {
+               unsigned long long time;
+               int cpu;
+#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
+               struct spi_controller *ctlr;
+               struct spi_message *cur_msg;
+#else
+               void *ctlr;
+               void *cur_msg;
+#endif
+               int en;
+       } spi[DSS_LOG_MAX_NUM];
+#endif
+
+#ifndef CONFIG_DEBUG_SNAPSHOT_MINIMIZED_MODE
+       struct __clockevent_log {
+               unsigned long long time;
+               unsigned long long mct_cycle;
+#ifdef CONFIG_DEBUG_SNAPSHOT_LINUX_BUILD
+               int64_t delta_ns;
+               ktime_t next_event;
+#else
+               long long delta_ns;
+               long long next_event;
+#endif
+               void *caller[DSS_CALLSTACK_MAX_NUM];
+       } clockevent[DSS_NR_CPUS][DSS_LOG_MAX_NUM];
+
+       struct __printkl_log {
+               unsigned long long time;
+               int cpu;
+               size_t msg;
+               size_t val;
+               void *caller[DSS_CALLSTACK_MAX_NUM];
+       } printkl[DSS_API_MAX_NUM];
+
+       struct __printk_log {
+               unsigned long long time;
+               int cpu;
+               char log[DSS_LOG_STRING_LENGTH];
+               void *caller[DSS_CALLSTACK_MAX_NUM];
+       } printk[DSS_API_MAX_NUM];
+#endif
+};
+
+#endif