aw869xx: Fix build issue on V(CR)

- mask unused pm_ops to fix warning error
- add function do_gettimeofday which was removed in kernel 5.4

Change-Id: I33aae44467bc306fc2eed827e518d12c6ad0bad9
Signed-off-by: huangys <huangys@motorola.com>
Reviewed-on: https://gerrit.mot.com/1719561
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
This commit is contained in:
huangys 2020-08-11 23:11:23 +08:00 • committed by Yuesheng Huang
commit 3206acefcc

View file

@ -34,8 +34,8 @@
#include <sound/control.h>
#include <sound/soc.h>
#include <linux/aw869xx_reg.h>
#include <linux/aw869xx.h>
#include "aw869xx_reg.h"
#include "aw869xx.h"
/******************************************************
*
@ -76,6 +76,15 @@ static aw_snd_soc_codec_t *aw_get_codec(struct snd_soc_dai *dai)
#endif
}
static void do_gettimeofday(struct timeval *tv)
{
struct timespec64 now;
ktime_get_real_ts64(&now);
tv->tv_sec = now.tv_sec;
tv->tv_usec = now.tv_nsec/1000;
}
/******************************************************
*
* variable
@ -4351,7 +4360,7 @@ static int __maybe_unused aw869xx_resume(struct device *dev)
return ret;
}
static SIMPLE_DEV_PM_OPS(aw869xx_pm_ops, aw869xx_suspend, aw869xx_resume);
// static SIMPLE_DEV_PM_OPS(aw869xx_pm_ops, aw869xx_suspend, aw869xx_resume);
static const struct i2c_device_id aw869xx_i2c_id[] = {
{AW869XX_I2C_NAME, 0},