You've already forked linux-apfs
mirror of
https://github.com/linux-apfs/linux-apfs.git
synced 2026-05-01 15:00:59 -07:00
Merge tag 'asoc-v4.11' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linus
ASoC: Updates for v4.11 Another release that's mainly focused on drivers rather than core changes, highlights include: - A huge batch of updates to the Intel drivers, mainly around DisplayPort and HDMI with some additional board support too. - Channel mapping support for HDMI. - Support for AllWinner A31 and A33, Everest Semiconductor ES8328, Nuvoton NAU8540.
This commit is contained in:
@@ -24,6 +24,8 @@ Optional properties:
|
||||
this parameter to choose where the clock from.
|
||||
- By default the clock is from TK pin, if the clock from RK pin, this
|
||||
property is needed.
|
||||
- #sound-dai-cells: Should contain <0>.
|
||||
- This property makes the SSC into an automatically registered DAI.
|
||||
|
||||
Examples:
|
||||
- PDC transfer:
|
||||
|
||||
@@ -2,8 +2,7 @@ Devicetree bindings for the Axentia TSE-850 audio complex
|
||||
|
||||
Required properties:
|
||||
- compatible: "axentia,tse850-pcm5142"
|
||||
- axentia,ssc-controller: The phandle of the atmel SSC controller used as
|
||||
cpu dai.
|
||||
- axentia,cpu-dai: The phandle of the cpu dai.
|
||||
- axentia,audio-codec: The phandle of the PCM5142 codec.
|
||||
- axentia,add-gpios: gpio specifier that controls the mixer.
|
||||
- axentia,loop1-gpios: gpio specifier that controls loop relays on channel 1.
|
||||
@@ -43,6 +42,12 @@ the PCM5142 codec.
|
||||
|
||||
Example:
|
||||
|
||||
&ssc0 {
|
||||
#sound-dai-cells = <0>;
|
||||
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&i2c {
|
||||
codec: pcm5142@4c {
|
||||
compatible = "ti,pcm5142";
|
||||
@@ -77,7 +82,7 @@ Example:
|
||||
sound {
|
||||
compatible = "axentia,tse850-pcm5142";
|
||||
|
||||
axentia,ssc-controller = <&ssc0>;
|
||||
axentia,cpu-dai = <&ssc0>;
|
||||
axentia,audio-codec = <&codec>;
|
||||
|
||||
axentia,add-gpios = <&pioA 8 GPIO_ACTIVE_LOW>;
|
||||
|
||||
@@ -4,7 +4,7 @@ This device supports both I2C and SPI.
|
||||
|
||||
Required properties:
|
||||
|
||||
- compatible : "everest,es8328"
|
||||
- compatible : Should be "everest,es8328" or "everest,es8388"
|
||||
- DVDD-supply : Regulator providing digital core supply voltage 1.8 - 3.6V
|
||||
- AVDD-supply : Regulator providing analog supply voltage 3.3V
|
||||
- PVDD-supply : Regulator providing digital IO supply voltage 1.8 - 3.6V
|
||||
|
||||
@@ -4,6 +4,7 @@ Required properties:
|
||||
- compatible = "mediatek,mt2701-audio";
|
||||
- reg: register location and size
|
||||
- interrupts: Should contain AFE interrupt
|
||||
- power-domains: should define the power domain
|
||||
- clock-names: should have these clock names:
|
||||
"infra_sys_audio_clk",
|
||||
"top_audio_mux1_sel",
|
||||
@@ -58,6 +59,7 @@ Example:
|
||||
<0 0x112A0000 0 0x20000>;
|
||||
interrupts = <GIC_SPI 104 IRQ_TYPE_LEVEL_LOW>,
|
||||
<GIC_SPI 132 IRQ_TYPE_LEVEL_LOW>;
|
||||
power-domains = <&scpsys MT2701_POWER_DOMAIN_IFR_MSC>;
|
||||
clocks = <&infracfg CLK_INFRA_AUDIO>,
|
||||
<&topckgen CLK_TOP_AUD_MUX1_SEL>,
|
||||
<&topckgen CLK_TOP_AUD_MUX2_SEL>,
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
NAU85L40 audio CODEC
|
||||
|
||||
This device supports I2C only.
|
||||
|
||||
Required properties:
|
||||
|
||||
- compatible : "nuvoton,nau8540"
|
||||
|
||||
- reg : the I2C address of the device.
|
||||
|
||||
Example:
|
||||
|
||||
codec: nau8540@1c {
|
||||
compatible = "nuvoton,nau8540";
|
||||
reg = <0x1c>;
|
||||
};
|
||||
@@ -0,0 +1,36 @@
|
||||
ROCKCHIP RK3288 with HDMI and analog audio
|
||||
|
||||
Required properties:
|
||||
- compatible: "rockchip,rk3288-hdmi-analog"
|
||||
- rockchip,model: The user-visible name of this sound complex
|
||||
- rockchip,i2s-controller: The phandle of the Rockchip I2S controller that's
|
||||
connected to the CODEC
|
||||
- rockchip,audio-codec: The phandle of the analog audio codec.
|
||||
- rockchip,routing: A list of the connections between audio components.
|
||||
Each entry is a pair of strings, the first being the
|
||||
connection's sink, the second being the connection's
|
||||
source. For this driver the first string should always be
|
||||
"Analog".
|
||||
|
||||
Optionnal properties:
|
||||
- rockchip,hp-en-gpios = The phandle of the GPIO that power up/down the
|
||||
headphone (when the analog output is an headphone).
|
||||
- rockchip,hp-det-gpios = The phandle of the GPIO that detects the headphone
|
||||
(when the analog output is an headphone).
|
||||
- pinctrl-names, pinctrl-0: Please refer to pinctrl-bindings.txt
|
||||
|
||||
Example:
|
||||
|
||||
sound {
|
||||
compatible = "rockchip,rockchip-audio-es8388";
|
||||
rockchip,model = "Analog audio output";
|
||||
rockchip,i2s-controller = <&i2s>;
|
||||
rockchip,audio-codec = <&es8388>;
|
||||
rockchip,routing = "Analog", "LOUT2",
|
||||
"Analog", "ROUT2";
|
||||
rockchip,hp-en-gpios = <&gpio8 0 GPIO_ACTIVE_HIGH>;
|
||||
rockchip,hp-det-gpios = <&gpio7 7 GPIO_ACTIVE_HIGH>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&headphone>;
|
||||
};
|
||||
|
||||
@@ -7,6 +7,7 @@ Required properties:
|
||||
|
||||
- compatible: should be one of the followings
|
||||
- "allwinner,sun4i-a10-i2s"
|
||||
- "allwinner,sun6i-a31-i2s"
|
||||
- reg: physical base address of the controller and length of memory mapped
|
||||
region.
|
||||
- interrupts: should contain the I2S interrupt.
|
||||
@@ -19,6 +20,10 @@ Required properties:
|
||||
- "mod" : module clock for the I2S controller
|
||||
- #sound-dai-cells : Must be equal to 0
|
||||
|
||||
Required properties for the following compatibles:
|
||||
- "allwinner,sun6i-a31-i2s"
|
||||
- resets: phandle to the reset line for this codec
|
||||
|
||||
Example:
|
||||
|
||||
i2s0: i2s@01c22400 {
|
||||
|
||||
@@ -0,0 +1,63 @@
|
||||
Allwinner SUN8I audio codec
|
||||
------------------------------------
|
||||
|
||||
On Sun8i-A33 SoCs, the audio is separated in different parts:
|
||||
- A DAI driver. It uses the "sun4i-i2s" driver which is
|
||||
documented here:
|
||||
Documentation/devicetree/bindings/sound/sun4i-i2s.txt
|
||||
- An analog part of the codec which is handled as PRCM registers.
|
||||
See Documentation/devicetree/bindings/sound/sun8i-codec-analog.txt
|
||||
- An digital part of the codec which is documented in this current
|
||||
binding documentation.
|
||||
- And finally, an audio card which links all the above components.
|
||||
The simple-audio card will be used.
|
||||
See Documentation/devicetree/bindings/sound/simple-card.txt
|
||||
|
||||
This bindings documentation exposes Sun8i codec (digital part).
|
||||
|
||||
Required properties:
|
||||
- compatible: must be "allwinner,sun8i-a33-codec"
|
||||
- reg: must contain the registers location and length
|
||||
- interrupts: must contain the codec interrupt
|
||||
- clocks: a list of phandle + clock-specifer pairs, one for each entry
|
||||
in clock-names.
|
||||
- clock-names: should contain followings:
|
||||
- "bus": the parent APB clock for this controller
|
||||
- "mod": the parent module clock
|
||||
|
||||
Here is an example to add a sound card and the codec binding on sun8i SoCs that
|
||||
are similar to A33 using simple-card:
|
||||
|
||||
sound {
|
||||
compatible = "simple-audio-card";
|
||||
simple-audio-card,name = "sun8i-a33-audio";
|
||||
simple-audio-card,format = "i2s";
|
||||
simple-audio-card,frame-master = <&link_codec>;
|
||||
simple-audio-card,bitclock-master = <&link_codec>;
|
||||
simple-audio-card,mclk-fs = <512>;
|
||||
simple-audio-card,aux-devs = <&codec_analog>;
|
||||
simple-audio-card,routing =
|
||||
"Left DAC", "Digital Left DAC",
|
||||
"Right DAC", "Digital Right DAC";
|
||||
|
||||
simple-audio-card,cpu {
|
||||
sound-dai = <&dai>;
|
||||
};
|
||||
|
||||
link_codec: simple-audio-card,codec {
|
||||
sound-dai = <&codec>;
|
||||
};
|
||||
|
||||
soc@01c00000 {
|
||||
[...]
|
||||
|
||||
audio-codec@1c22e00 {
|
||||
#sound-dai-cells = <0>;
|
||||
compatible = "allwinner,sun8i-a33-codec";
|
||||
reg = <0x01c22e00 0x400>;
|
||||
interrupts = <GIC_SPI 29 IRQ_TYPE_LEVEL_HIGH>;
|
||||
clocks = <&ccu CLK_BUS_CODEC>, <&ccu CLK_AC_DIG>;
|
||||
clock-names = "bus", "mod";
|
||||
};
|
||||
};
|
||||
|
||||
@@ -10,6 +10,7 @@ Required properties:
|
||||
- compatible : should be one of the following:
|
||||
- "allwinner,sun4i-a10-spdif": for the Allwinner A10 SoC
|
||||
- "allwinner,sun6i-a31-spdif": for the Allwinner A31 SoC
|
||||
- "allwinner,sun8i-h3-spdif": for the Allwinner H3 SoC
|
||||
|
||||
- reg : Offset and length of the register set for the device.
|
||||
|
||||
|
||||
@@ -1,10 +1,12 @@
|
||||
ZTE ZX296702 I2S controller
|
||||
|
||||
Required properties:
|
||||
- compatible : Must be "zte,zx296702-i2s"
|
||||
- compatible : Must be one of:
|
||||
"zte,zx296718-i2s", "zte,zx296702-i2s"
|
||||
"zte,zx296702-i2s"
|
||||
- reg : Must contain I2S core's registers location and length
|
||||
- clocks : Pairs of phandle and specifier referencing the controller's clocks.
|
||||
- clock-names: "tx" for the clock to the I2S interface.
|
||||
- clock-names: "wclk" for the wclk, "pclk" for the pclk to the I2S interface.
|
||||
- dmas: Pairs of phandle and specifier for the DMA channel that is used by
|
||||
the core. The core expects two dma channels for transmit.
|
||||
- dma-names : Must be "tx" and "rx"
|
||||
@@ -16,12 +18,12 @@ please check:
|
||||
* dma/dma.txt
|
||||
|
||||
Example:
|
||||
i2s0: i2s0@0b005000 {
|
||||
i2s0: i2s@b005000 {
|
||||
#sound-dai-cells = <0>;
|
||||
compatible = "zte,zx296702-i2s";
|
||||
compatible = "zte,zx296718-i2s", "zte,zx296702-i2s";
|
||||
reg = <0x0b005000 0x1000>;
|
||||
clocks = <&lsp0clk ZX296702_I2S0_DIV>;
|
||||
clock-names = "tx";
|
||||
clocks = <&audiocrm AUDIO_I2S0_WCLK>, <&audiocrm AUDIO_I2S0_PCLK>;
|
||||
clock-names = "wclk", "pclk";
|
||||
interrupts = <GIC_SPI 22 IRQ_TYPE_LEVEL_HIGH>;
|
||||
dmas = <&dma 5>, <&dma 6>;
|
||||
dma-names = "tx", "rx";
|
||||
|
||||
@@ -106,9 +106,7 @@ static struct s3c_audio_pdata i2sv4_pdata = {
|
||||
.dma_playback = DMACH_HSI_I2SV40_TX,
|
||||
.dma_capture = DMACH_HSI_I2SV40_RX,
|
||||
.type = {
|
||||
.i2s = {
|
||||
.quirks = QUIRK_PRI_6CHAN,
|
||||
},
|
||||
.quirks = QUIRK_PRI_6CHAN,
|
||||
},
|
||||
};
|
||||
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
|
||||
#include <linux/of.h>
|
||||
|
||||
#include "../../sound/soc/atmel/atmel_ssc_dai.h"
|
||||
|
||||
/* Serialize access to ssc_list and user count */
|
||||
static DEFINE_SPINLOCK(user_lock);
|
||||
static LIST_HEAD(ssc_list);
|
||||
@@ -145,6 +147,49 @@ static inline const struct atmel_ssc_platform_data * __init
|
||||
platform_get_device_id(pdev)->driver_data;
|
||||
}
|
||||
|
||||
#ifdef CONFIG_SND_ATMEL_SOC_SSC
|
||||
static int ssc_sound_dai_probe(struct ssc_device *ssc)
|
||||
{
|
||||
struct device_node *np = ssc->pdev->dev.of_node;
|
||||
int ret;
|
||||
int id;
|
||||
|
||||
ssc->sound_dai = false;
|
||||
|
||||
if (!of_property_read_bool(np, "#sound-dai-cells"))
|
||||
return 0;
|
||||
|
||||
id = of_alias_get_id(np, "ssc");
|
||||
if (id < 0)
|
||||
return id;
|
||||
|
||||
ret = atmel_ssc_set_audio(id);
|
||||
ssc->sound_dai = !ret;
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
static void ssc_sound_dai_remove(struct ssc_device *ssc)
|
||||
{
|
||||
if (!ssc->sound_dai)
|
||||
return;
|
||||
|
||||
atmel_ssc_put_audio(of_alias_get_id(ssc->pdev->dev.of_node, "ssc"));
|
||||
}
|
||||
#else
|
||||
static inline int ssc_sound_dai_probe(struct ssc_device *ssc)
|
||||
{
|
||||
if (of_property_read_bool(ssc->pdev->dev.of_node, "#sound-dai-cells"))
|
||||
return -ENOTSUPP;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static inline void ssc_sound_dai_remove(struct ssc_device *ssc)
|
||||
{
|
||||
}
|
||||
#endif
|
||||
|
||||
static int ssc_probe(struct platform_device *pdev)
|
||||
{
|
||||
struct resource *regs;
|
||||
@@ -204,6 +249,9 @@ static int ssc_probe(struct platform_device *pdev)
|
||||
dev_info(&pdev->dev, "Atmel SSC device at 0x%p (irq %d)\n",
|
||||
ssc->regs, ssc->irq);
|
||||
|
||||
if (ssc_sound_dai_probe(ssc))
|
||||
dev_err(&pdev->dev, "failed to auto-setup ssc for audio\n");
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -211,6 +259,8 @@ static int ssc_remove(struct platform_device *pdev)
|
||||
{
|
||||
struct ssc_device *ssc = platform_get_drvdata(pdev);
|
||||
|
||||
ssc_sound_dai_remove(ssc);
|
||||
|
||||
spin_lock(&user_lock);
|
||||
list_del(&ssc->list);
|
||||
spin_unlock(&user_lock);
|
||||
|
||||
@@ -248,6 +248,7 @@ struct detailed_timing {
|
||||
# define DRM_ELD_AUD_SYNCH_DELAY_MAX 0xfa /* 500 ms */
|
||||
|
||||
#define DRM_ELD_SPEAKER 7
|
||||
# define DRM_ELD_SPEAKER_MASK 0x7f
|
||||
# define DRM_ELD_SPEAKER_RLRC (1 << 6)
|
||||
# define DRM_ELD_SPEAKER_FLRC (1 << 5)
|
||||
# define DRM_ELD_SPEAKER_RC (1 << 4)
|
||||
@@ -413,6 +414,18 @@ static inline int drm_eld_size(const uint8_t *eld)
|
||||
return DRM_ELD_HEADER_BLOCK_SIZE + eld[DRM_ELD_BASELINE_ELD_LEN] * 4;
|
||||
}
|
||||
|
||||
/**
|
||||
* drm_eld_get_spk_alloc - Get speaker allocation
|
||||
* @eld: pointer to an ELD memory structure
|
||||
*
|
||||
* The returned value is the speakers mask. User has to use %DRM_ELD_SPEAKER
|
||||
* field definitions to identify speakers.
|
||||
*/
|
||||
static inline u8 drm_eld_get_spk_alloc(const uint8_t *eld)
|
||||
{
|
||||
return eld[DRM_ELD_SPEAKER] & DRM_ELD_SPEAKER_MASK;
|
||||
}
|
||||
|
||||
/**
|
||||
* drm_eld_get_conn_type - Get device type hdmi/dp connected
|
||||
* @eld: pointer to an ELD memory structure
|
||||
|
||||
@@ -20,6 +20,7 @@ struct ssc_device {
|
||||
int user;
|
||||
int irq;
|
||||
bool clk_from_rk_pin;
|
||||
bool sound_dai;
|
||||
};
|
||||
|
||||
struct ssc_device * __must_check ssc_request(unsigned int ssc_num);
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
|
||||
extern void s3c64xx_ac97_setup_gpio(int);
|
||||
|
||||
struct samsung_i2s {
|
||||
struct samsung_i2s_type {
|
||||
/* If the Primary DAI has 5.1 Channels */
|
||||
#define QUIRK_PRI_6CHAN (1 << 0)
|
||||
/* If the I2S block has a Stereo Overlay Channel */
|
||||
@@ -47,7 +47,5 @@ struct s3c_audio_pdata {
|
||||
void *dma_capture;
|
||||
void *dma_play_sec;
|
||||
void *dma_capture_mic;
|
||||
union {
|
||||
struct samsung_i2s i2s;
|
||||
} type;
|
||||
struct samsung_i2s_type type;
|
||||
};
|
||||
|
||||
@@ -71,6 +71,7 @@ struct dma_chan *snd_dmaengine_pcm_get_chan(struct snd_pcm_substream *substream)
|
||||
* @slave_id: Slave requester id for the DMA channel.
|
||||
* @filter_data: Custom DMA channel filter data, this will usually be used when
|
||||
* requesting the DMA channel.
|
||||
* @chan_name: Custom channel name to use when requesting DMA channel.
|
||||
* @fifo_size: FIFO size of the DAI controller in bytes
|
||||
* @flags: PCM_DAI flags, only SND_DMAENGINE_PCM_DAI_FLAG_PACK for now
|
||||
*/
|
||||
@@ -80,6 +81,7 @@ struct snd_dmaengine_dai_dma_data {
|
||||
u32 maxburst;
|
||||
unsigned int slave_id;
|
||||
void *filter_data;
|
||||
const char *chan_name;
|
||||
unsigned int fifo_size;
|
||||
unsigned int flags;
|
||||
};
|
||||
@@ -105,6 +107,10 @@ void snd_dmaengine_pcm_set_config_from_dai_data(
|
||||
* playback.
|
||||
*/
|
||||
#define SND_DMAENGINE_PCM_FLAG_HALF_DUPLEX BIT(3)
|
||||
/*
|
||||
* The PCM streams have custom channel names specified.
|
||||
*/
|
||||
#define SND_DMAENGINE_PCM_FLAG_CUSTOM_CHANNEL_NAME BIT(4)
|
||||
|
||||
/**
|
||||
* struct snd_dmaengine_pcm_config - Configuration data for dmaengine based PCM
|
||||
|
||||
@@ -34,11 +34,12 @@ int asoc_simple_card_set_dailink_name(struct device *dev,
|
||||
int asoc_simple_card_parse_card_name(struct snd_soc_card *card,
|
||||
char *prefix);
|
||||
|
||||
#define asoc_simple_card_parse_clk_cpu(node, dai_link, simple_dai) \
|
||||
asoc_simple_card_parse_clk(node, dai_link->cpu_of_node, simple_dai)
|
||||
#define asoc_simple_card_parse_clk_codec(node, dai_link, simple_dai) \
|
||||
asoc_simple_card_parse_clk(node, dai_link->codec_of_node, simple_dai)
|
||||
int asoc_simple_card_parse_clk(struct device_node *node,
|
||||
#define asoc_simple_card_parse_clk_cpu(dev, node, dai_link, simple_dai) \
|
||||
asoc_simple_card_parse_clk(dev, node, dai_link->cpu_of_node, simple_dai)
|
||||
#define asoc_simple_card_parse_clk_codec(dev, node, dai_link, simple_dai) \
|
||||
asoc_simple_card_parse_clk(dev, node, dai_link->codec_of_node, simple_dai)
|
||||
int asoc_simple_card_parse_clk(struct device *dev,
|
||||
struct device_node *node,
|
||||
struct device_node *dai_of_node,
|
||||
struct asoc_simple_dai *simple_dai);
|
||||
|
||||
|
||||
@@ -256,6 +256,9 @@ struct snd_soc_dai_driver {
|
||||
int (*resume)(struct snd_soc_dai *dai);
|
||||
/* compress dai */
|
||||
int (*compress_new)(struct snd_soc_pcm_runtime *rtd, int num);
|
||||
/* Optional Callback used at pcm creation*/
|
||||
int (*pcm_new)(struct snd_soc_pcm_runtime *rtd,
|
||||
struct snd_soc_dai *dai);
|
||||
/* DAI is also used for the control bus */
|
||||
bool bus_control;
|
||||
|
||||
|
||||
+17
-35
@@ -497,6 +497,8 @@ void snd_soc_runtime_deactivate(struct snd_soc_pcm_runtime *rtd, int stream);
|
||||
int snd_soc_runtime_set_dai_fmt(struct snd_soc_pcm_runtime *rtd,
|
||||
unsigned int dai_fmt);
|
||||
|
||||
int snd_soc_set_dmi_name(struct snd_soc_card *card, const char *flavour);
|
||||
|
||||
/* Utility functions to get clock rates from various things */
|
||||
int snd_soc_calc_frame_size(int sample_size, int channels, int tdm_slots);
|
||||
int snd_soc_params_to_frame_size(struct snd_pcm_hw_params *params);
|
||||
@@ -507,9 +509,6 @@ int snd_soc_params_to_bclk(struct snd_pcm_hw_params *parms);
|
||||
int snd_soc_set_runtime_hwparams(struct snd_pcm_substream *substream,
|
||||
const struct snd_pcm_hardware *hw);
|
||||
|
||||
int snd_soc_platform_trigger(struct snd_pcm_substream *substream,
|
||||
int cmd, struct snd_soc_platform *platform);
|
||||
|
||||
int soc_dai_hw_params(struct snd_pcm_substream *substream,
|
||||
struct snd_pcm_hw_params *params,
|
||||
struct snd_soc_dai *dai);
|
||||
@@ -785,6 +784,10 @@ struct snd_soc_component_driver {
|
||||
int (*suspend)(struct snd_soc_component *);
|
||||
int (*resume)(struct snd_soc_component *);
|
||||
|
||||
/* pcm creation and destruction */
|
||||
int (*pcm_new)(struct snd_soc_pcm_runtime *);
|
||||
void (*pcm_free)(struct snd_pcm *);
|
||||
|
||||
/* DT */
|
||||
int (*of_xlate_dai_name)(struct snd_soc_component *component,
|
||||
struct of_phandle_args *args,
|
||||
@@ -859,6 +862,8 @@ struct snd_soc_component {
|
||||
void (*remove)(struct snd_soc_component *);
|
||||
int (*suspend)(struct snd_soc_component *);
|
||||
int (*resume)(struct snd_soc_component *);
|
||||
int (*pcm_new)(struct snd_soc_pcm_runtime *);
|
||||
void (*pcm_free)(struct snd_pcm *);
|
||||
|
||||
/* machine specific init */
|
||||
int (*init)(struct snd_soc_component *component);
|
||||
@@ -941,20 +946,11 @@ struct snd_soc_platform_driver {
|
||||
int (*pcm_new)(struct snd_soc_pcm_runtime *);
|
||||
void (*pcm_free)(struct snd_pcm *);
|
||||
|
||||
/*
|
||||
* For platform caused delay reporting.
|
||||
* Optional.
|
||||
*/
|
||||
snd_pcm_sframes_t (*delay)(struct snd_pcm_substream *,
|
||||
struct snd_soc_dai *);
|
||||
|
||||
/* platform stream pcm ops */
|
||||
const struct snd_pcm_ops *ops;
|
||||
|
||||
/* platform stream compress ops */
|
||||
const struct snd_compr_ops *compr_ops;
|
||||
|
||||
int (*bespoke_trigger)(struct snd_pcm_substream *, int);
|
||||
};
|
||||
|
||||
struct snd_soc_dai_link_component {
|
||||
@@ -1099,6 +1095,8 @@ struct snd_soc_card {
|
||||
const char *name;
|
||||
const char *long_name;
|
||||
const char *driver_name;
|
||||
char dmi_longname[80];
|
||||
|
||||
struct device *dev;
|
||||
struct snd_card *snd_card;
|
||||
struct module *owner;
|
||||
@@ -1647,37 +1645,21 @@ static inline struct snd_soc_platform *snd_soc_kcontrol_platform(
|
||||
int snd_soc_util_init(void);
|
||||
void snd_soc_util_exit(void);
|
||||
|
||||
#define snd_soc_of_parse_card_name(card, propname) \
|
||||
snd_soc_of_parse_card_name_from_node(card, NULL, propname)
|
||||
int snd_soc_of_parse_card_name_from_node(struct snd_soc_card *card,
|
||||
struct device_node *np,
|
||||
const char *propname);
|
||||
#define snd_soc_of_parse_audio_simple_widgets(card, propname)\
|
||||
snd_soc_of_parse_audio_simple_widgets_from_node(card, NULL, propname)
|
||||
int snd_soc_of_parse_audio_simple_widgets_from_node(struct snd_soc_card *card,
|
||||
struct device_node *np,
|
||||
const char *propname);
|
||||
|
||||
int snd_soc_of_parse_card_name(struct snd_soc_card *card,
|
||||
const char *propname);
|
||||
int snd_soc_of_parse_audio_simple_widgets(struct snd_soc_card *card,
|
||||
const char *propname);
|
||||
int snd_soc_of_parse_tdm_slot(struct device_node *np,
|
||||
unsigned int *tx_mask,
|
||||
unsigned int *rx_mask,
|
||||
unsigned int *slots,
|
||||
unsigned int *slot_width);
|
||||
#define snd_soc_of_parse_audio_prefix(card, codec_conf, of_node, propname) \
|
||||
snd_soc_of_parse_audio_prefix_from_node(card, NULL, codec_conf, \
|
||||
of_node, propname)
|
||||
void snd_soc_of_parse_audio_prefix_from_node(struct snd_soc_card *card,
|
||||
struct device_node *np,
|
||||
void snd_soc_of_parse_audio_prefix(struct snd_soc_card *card,
|
||||
struct snd_soc_codec_conf *codec_conf,
|
||||
struct device_node *of_node,
|
||||
const char *propname);
|
||||
|
||||
#define snd_soc_of_parse_audio_routing(card, propname) \
|
||||
snd_soc_of_parse_audio_routing_from_node(card, NULL, propname)
|
||||
int snd_soc_of_parse_audio_routing_from_node(struct snd_soc_card *card,
|
||||
struct device_node *np,
|
||||
const char *propname);
|
||||
|
||||
int snd_soc_of_parse_audio_routing(struct snd_soc_card *card,
|
||||
const char *propname);
|
||||
unsigned int snd_soc_of_parse_daifmt(struct device_node *np,
|
||||
const char *prefix,
|
||||
struct device_node **bitclkmaster,
|
||||
|
||||
@@ -128,14 +128,17 @@ void snd_hdac_ext_stream_decouple(struct hdac_ext_bus *ebus,
|
||||
{
|
||||
struct hdac_stream *hstream = &stream->hstream;
|
||||
struct hdac_bus *bus = &ebus->bus;
|
||||
u32 val;
|
||||
int mask = AZX_PPCTL_PROCEN(hstream->index);
|
||||
|
||||
spin_lock_irq(&bus->reg_lock);
|
||||
if (decouple)
|
||||
snd_hdac_updatel(bus->ppcap, AZX_REG_PP_PPCTL, 0,
|
||||
AZX_PPCTL_PROCEN(hstream->index));
|
||||
else
|
||||
snd_hdac_updatel(bus->ppcap, AZX_REG_PP_PPCTL,
|
||||
AZX_PPCTL_PROCEN(hstream->index), 0);
|
||||
val = readw(bus->ppcap + AZX_REG_PP_PPCTL) & mask;
|
||||
|
||||
if (decouple && !val)
|
||||
snd_hdac_updatel(bus->ppcap, AZX_REG_PP_PPCTL, mask, mask);
|
||||
else if (!decouple && val)
|
||||
snd_hdac_updatel(bus->ppcap, AZX_REG_PP_PPCTL, mask, 0);
|
||||
|
||||
stream->decoupled = decouple;
|
||||
spin_unlock_irq(&bus->reg_lock);
|
||||
}
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user