From e954cacd5aef654f9d25e77f18f32f0ec01757fe Mon Sep 17 00:00:00 2001 From: Tao Huang Date: Fri, 16 Jun 2023 11:08:07 +0800 Subject: [PATCH] ASoC: codecs: aw883xx: Fix build error for kernel 6.1 Disable AW_CALI_STORE_EXAMPLE for following build error: sound/soc/codecs/aw883xx/aw_calib.c: In function 'aw_cali_write_cali_re_to_file': sound/soc/codecs/aw883xx/aw_calib.c:65:9: error: unknown type name 'mm_segment_t' sound/soc/codecs/aw883xx/aw_calib.c:78:14: error: implicit declaration of function 'get_fs'; did you mean 'sget_fc'? [-Werror=implicit-function-declaration] sound/soc/codecs/aw883xx/aw_calib.c:79:9: error: implicit declaration of function 'set_fs'; did you mean 'sget_fc'? [-Werror=implicit-function-declaration] sound/soc/codecs/aw883xx/aw_calib.c:79:16: error: 'KERNEL_DS' undeclared (first use in this function); did you mean 'KERNFS_NS'? sound/soc/codecs/aw883xx/aw_calib.c:79:16: note: each undeclared identifier is reported only once for each function it appears in sound/soc/codecs/aw883xx/aw_calib.c: In function 'aw_cali_get_cali_re_from_file': sound/soc/codecs/aw883xx/aw883xx.c: In function 'aw883xx_i2c_remove': sound/soc/codecs/aw883xx/aw883xx.c:2506:17: error: implicit declaration of function 'devm_gpio_free'; did you mean 'devm_gpiod_get'? [-Werror=implicit-function-declaration] Signed-off-by: Tao Huang Change-Id: Ic92cc7e7d97e24778cfb6977be5e59df56fe58d8 --- sound/soc/codecs/aw883xx/aw883xx.c | 5 ----- sound/soc/codecs/aw883xx/aw_calib.h | 1 - 2 files changed, 6 deletions(-) diff --git a/sound/soc/codecs/aw883xx/aw883xx.c b/sound/soc/codecs/aw883xx/aw883xx.c index c19016b84479..5de9a62d7a58 100644 --- a/sound/soc/codecs/aw883xx/aw883xx.c +++ b/sound/soc/codecs/aw883xx/aw883xx.c @@ -2502,11 +2502,6 @@ static void aw883xx_i2c_remove(struct i2c_client *i2c) gpio_to_irq(aw883xx->irq_gpio), aw883xx); - if (gpio_is_valid(aw883xx->irq_gpio)) - devm_gpio_free(&i2c->dev, aw883xx->irq_gpio); - if (gpio_is_valid(aw883xx->reset_gpio)) - devm_gpio_free(&i2c->dev, aw883xx->reset_gpio); - sysfs_remove_group(&aw883xx->dev->kobj, &aw883xx_attribute_group); diff --git a/sound/soc/codecs/aw883xx/aw_calib.h b/sound/soc/codecs/aw883xx/aw_calib.h index d9adee208af6..ca8370415f50 100644 --- a/sound/soc/codecs/aw883xx/aw_calib.h +++ b/sound/soc/codecs/aw883xx/aw_calib.h @@ -5,7 +5,6 @@ /*#define AW_CALI_STORE_EXAMPLE*/ -#define AW_CALI_STORE_EXAMPLE #define AW_ERRO_CALI_RE_VALUE (0) #define AW_ERRO_CALI_F0_VALUE (2600)