perf: avoid div zero if up_perf_init() hasn't init
Signed-off-by: ligd <liguiding1@xiaomi.com>
This commit is contained in:
parent
2cfea55f95
commit
af3600436e
@ -32,7 +32,7 @@
|
||||
* Private Data
|
||||
****************************************************************************/
|
||||
|
||||
static unsigned long g_cpu_freq;
|
||||
static unsigned long g_cpu_freq = ULONG_MAX;
|
||||
|
||||
/****************************************************************************
|
||||
* Public Functions
|
||||
|
@ -34,7 +34,7 @@
|
||||
* Private Data
|
||||
****************************************************************************/
|
||||
|
||||
static unsigned long g_cpu_freq;
|
||||
static unsigned long g_cpu_freq = ULONG_MAX;
|
||||
|
||||
/****************************************************************************
|
||||
* Public Functions
|
||||
|
@ -32,7 +32,7 @@
|
||||
* Private Data
|
||||
****************************************************************************/
|
||||
|
||||
static unsigned long g_cpu_freq;
|
||||
static unsigned long g_cpu_freq = ULONG_MAX;
|
||||
|
||||
/****************************************************************************
|
||||
* Public Functions
|
||||
|
@ -34,7 +34,7 @@
|
||||
* Private Data
|
||||
****************************************************************************/
|
||||
|
||||
static unsigned long g_cpu_freq;
|
||||
static unsigned long g_cpu_freq = ULONG_MAX;
|
||||
|
||||
/****************************************************************************
|
||||
* Public Functions
|
||||
|
@ -32,7 +32,7 @@
|
||||
* Private Data
|
||||
****************************************************************************/
|
||||
|
||||
static unsigned long g_cpu_freq;
|
||||
static unsigned long g_cpu_freq = ULONG_MAX;
|
||||
|
||||
/****************************************************************************
|
||||
* Public Functions
|
||||
|
Loading…
Reference in New Issue
Block a user