Re: [RFC PATCH 1/3] topology: use inclusive language for bclk

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 03 Sep 2020 22:10:22 +0200,
Pierre-Louis Bossart wrote:
> 
> use bclk_provider for structure fields, 'codec_provider' and
> 'codec_follower' for options and modify #defines to use CP and CF
> suffixes.
> 
> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@xxxxxxxxxxxxxxx>
> ---
>  include/sound/uapi/asoc.h | 11 +++++++----
>  include/topology.h        |  2 +-
>  src/topology/pcm.c        | 37 +++++++++++++++++++++++++++----------
>  3 files changed, 35 insertions(+), 15 deletions(-)
> 
> diff --git a/include/sound/uapi/asoc.h b/include/sound/uapi/asoc.h
> index 4efb4ec4..8558992f 100644
> --- a/include/sound/uapi/asoc.h
> +++ b/include/sound/uapi/asoc.h
> @@ -169,10 +169,13 @@
>  #define SND_SOC_TPLG_LNK_FLGBIT_VOICE_WAKEUP            (1 << 3)
>  
>  /* DAI topology BCLK parameter
> - * For the backwards capability, by default codec is bclk master
> + * For the backwards capability, by default codec is bclk provider
>   */
> -#define SND_SOC_TPLG_BCLK_CM         0 /* codec is bclk master */
> -#define SND_SOC_TPLG_BCLK_CS         1 /* codec is bclk slave */
> +#define SND_SOC_TPLG_BCLK_CP         0 /* codec is bclk provider */
> +#define SND_SOC_TPLG_BCLK_CF         1 /* codec is bclk follower */
> +/* keep previous definitions for compatibility */
> +#define SND_SOC_TPLG_BCLK_CM         SND_SOC_TPLG_BCLK_CP
> +#define SND_SOC_TPLG_BCLK_CS         SND_SOC_TPLG_BCLK_CF

Those change are indeed backward compatible, but ...

>  
>  /* DAI topology FSYNC parameter
>   * For the backwards capability, by default codec is fsync master
> @@ -335,7 +338,7 @@ struct snd_soc_tplg_hw_config {
>  	__u8 clock_gated;	/* SND_SOC_TPLG_DAI_CLK_GATE_ value */
>  	__u8 invert_bclk;	/* 1 for inverted BCLK, 0 for normal */
>  	__u8 invert_fsync;	/* 1 for inverted frame clock, 0 for normal */
> -	__u8 bclk_master;	/* SND_SOC_TPLG_BCLK_ value */
> +	__u8 bclk_provider;	/* SND_SOC_TPLG_BCLK_ value */
>  	__u8 fsync_master;	/* SND_SOC_TPLG_FSYNC_ value */
>  	__u8 mclk_direction;    /* SND_SOC_TPLG_MCLK_ value */
>  	__le16 reserved;	/* for 32bit alignment */

Is it 100% compatible?  Note that the uapi/* header is a copy from the
kernel header, and it means that we'll change the same for the kernel,
too.

The similar argument applied to the patch 2, too.


thanks,

Takashi



[Index of Archives]     [ALSA User]     [Linux Audio Users]     [Pulse Audio]     [Kernel Archive]     [Asterisk PBX]     [Photo Sharing]     [Linux Sound]     [Video 4 Linux]     [Gimp]     [Yosemite News]

  Powered by Linux