staging: sec_debug: store cpu number instead of useless address 95/294195/1 accepted/tizen_unified accepted/tizen_unified_dev tizen accepted/tizen/unified/20230616.172403 accepted/tizen/unified/dev/20230726.115336
authorSeung-Woo Kim <sw0312.kim@samsung.com>
Wed, 14 Jun 2023 04:04:57 +0000 (13:04 +0900)
committerSeung-Woo Kim <sw0312.kim@samsung.com>
Wed, 14 Jun 2023 05:40:33 +0000 (14:40 +0900)
The address of function stack is useless once function returns.
Instead of useless address in function stack, just store cpu number
for debug context.

Change-Id: Ie3fd1af1935adc0803ab2c9e4bf6749bb66849d8
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
drivers/staging/samsung/sec_debug.c
include/linux/sec_debug.h

index c8f4222..bedb6c8 100644 (file)
@@ -758,7 +758,7 @@ void sec_debug_irq_sched_log(unsigned int irq, void *fn, int en)
        summary_info->sched_log.irq[cpu][i].fn = (void *)fn;
        summary_info->sched_log.irq[cpu][i].en = en;
        summary_info->sched_log.irq[cpu][i].preempt_count = preempt_count();
-       summary_info->sched_log.irq[cpu][i].context = &cpu;
+       summary_info->sched_log.irq[cpu][i].p_cpu = cpu;
 }
 
 void sec_debug_irq_enterexit_log(unsigned int irq, unsigned long long start_time)
index ae4d0b7..ca05c45 100644 (file)
@@ -165,7 +165,7 @@ struct irq_log {
        void *fn;
        int en;
        int preempt_count;
-       void *context;
+       unsigned int p_cpu;
 };
 
 struct irq_exit_log {