[PATCH RESEND V2 2/3] ASoC: amd: add Machine driver for Jadeite platform

Mukunda,Vijendar vijendar.mukunda at amd.com
Mon Jul 4 18:37:00 CEST 2022


On 7/4/22 8:27 PM, Amadeusz Sławiński wrote:
> On 7/4/2022 4:08 PM, Vijendar Mukunda wrote:
>> Add Machine driver for Jadeite platform which uses ES8336 codec.
>>
>> Signed-off-by: Vijendar Mukunda <Vijendar.Mukunda at amd.com>
>>
>> Changes since v1:
>>        - as sysclk is fixed, moved code to startup() callback.
>>        - Removed unused macros (ST_PLAT_CLK & ST_ES8336_GPIO_QUIRK)
>> from code.
>> ---
>>   sound/soc/amd/acp-es8336.c | 324 +++++++++++++++++++++++++++++++++++++
>>   1 file changed, 324 insertions(+)
>>   create mode 100644 sound/soc/amd/acp-es8336.c
>>
>> diff --git a/sound/soc/amd/acp-es8336.c b/sound/soc/amd/acp-es8336.c
>> new file mode 100644
>> index 000000000000..eec3d57092fa
>> --- /dev/null
>> +++ b/sound/soc/amd/acp-es8336.c
>> @@ -0,0 +1,324 @@
>> +// SPDX-License-Identifier: GPL-2.0+
>> +/*
>> + * Machine driver for AMD Stoney platform using ES8336 Codec
>> + *
>> + * Copyright 2022 Advanced Micro Devices, Inc.
>> + */
>> +
>> +#include <sound/core.h>
>> +#include <sound/soc.h>
>> +#include <sound/pcm.h>
>> +#include <sound/pcm_params.h>
>> +#include <sound/soc-dapm.h>
>> +#include <sound/jack.h>
>> +#include <linux/gpio.h>
>> +#include <linux/device.h>
>> +#include <linux/dmi.h>
>> +#include <linux/gpio/consumer.h>
>> +#include <linux/gpio/machine.h>
>> +#include <linux/i2c.h>
>> +#include <linux/input.h>
>> +#include <linux/module.h>
>> +#include <linux/platform_device.h>
>> +#include <linux/module.h>
>> +#include <linux/acpi.h>
>> +
>> +#include "../codecs/es8316.h"
> 
> Any reason to include this header? From quick check I see that it only
> defines ES8316_* defines and those don't seem to be used anywhere in
> this driver?

Agreed. There are no references to ES8316_*.
Will drop the header inclusion.
> 
> (...)
> 
>> +
>> +static int st_es8336_remove(struct platform_device *pdev)
>> +{
>> +    return 0;
>> +}
> 
> No need to provide .remove handler when it only returns.
> 
Will remove this API and post the new patch .


More information about the Alsa-devel mailing list