Merge branch 'for-linus' into for-next
This commit is contained in:
commit
0280e07bbd
@ -81,7 +81,7 @@ struct snd_compr_stream;
|
||||
#define SND_SOC_DAIFMT_CBP_CFP (1 << 12) /* codec clk provider & frame provider */
|
||||
#define SND_SOC_DAIFMT_CBC_CFP (2 << 12) /* codec clk consumer & frame provider */
|
||||
#define SND_SOC_DAIFMT_CBP_CFC (3 << 12) /* codec clk provider & frame consumer */
|
||||
#define SND_SOC_DAIFMT_CBC_CFC (4 << 12) /* codec clk consumer & frame follower */
|
||||
#define SND_SOC_DAIFMT_CBC_CFC (4 << 12) /* codec clk consumer & frame consumer */
|
||||
|
||||
/* previous definitions kept for backwards-compatibility, do not use in new contributions */
|
||||
#define SND_SOC_DAIFMT_CBM_CFM SND_SOC_DAIFMT_CBP_CFP
|
||||
|
@ -17,6 +17,9 @@ MODULE_LICENSE("GPL");
|
||||
#define MAX_LED (((SNDRV_CTL_ELEM_ACCESS_MIC_LED - SNDRV_CTL_ELEM_ACCESS_SPK_LED) \
|
||||
>> SNDRV_CTL_ELEM_ACCESS_LED_SHIFT) + 1)
|
||||
|
||||
#define to_led_card_dev(_dev) \
|
||||
container_of(_dev, struct snd_ctl_led_card, dev)
|
||||
|
||||
enum snd_ctl_led_mode {
|
||||
MODE_FOLLOW_MUTE = 0,
|
||||
MODE_FOLLOW_ROUTE,
|
||||
@ -371,6 +374,21 @@ static void snd_ctl_led_disconnect(struct snd_card *card)
|
||||
snd_ctl_led_refresh();
|
||||
}
|
||||
|
||||
static void snd_ctl_led_card_release(struct device *dev)
|
||||
{
|
||||
struct snd_ctl_led_card *led_card = to_led_card_dev(dev);
|
||||
|
||||
kfree(led_card);
|
||||
}
|
||||
|
||||
static void snd_ctl_led_release(struct device *dev)
|
||||
{
|
||||
}
|
||||
|
||||
static void snd_ctl_led_dev_release(struct device *dev)
|
||||
{
|
||||
}
|
||||
|
||||
/*
|
||||
* sysfs
|
||||
*/
|
||||
@ -667,6 +685,7 @@ static void snd_ctl_led_sysfs_add(struct snd_card *card)
|
||||
led_card->number = card->number;
|
||||
led_card->led = led;
|
||||
device_initialize(&led_card->dev);
|
||||
led_card->dev.release = snd_ctl_led_card_release;
|
||||
if (dev_set_name(&led_card->dev, "card%d", card->number) < 0)
|
||||
goto cerr;
|
||||
led_card->dev.parent = &led->dev;
|
||||
@ -685,7 +704,6 @@ static void snd_ctl_led_sysfs_add(struct snd_card *card)
|
||||
put_device(&led_card->dev);
|
||||
cerr2:
|
||||
printk(KERN_ERR "snd_ctl_led: unable to add card%d", card->number);
|
||||
kfree(led_card);
|
||||
}
|
||||
}
|
||||
|
||||
@ -704,8 +722,7 @@ static void snd_ctl_led_sysfs_remove(struct snd_card *card)
|
||||
snprintf(link_name, sizeof(link_name), "led-%s", led->name);
|
||||
sysfs_remove_link(&card->ctl_dev.kobj, link_name);
|
||||
sysfs_remove_link(&led_card->dev.kobj, "card");
|
||||
device_del(&led_card->dev);
|
||||
kfree(led_card);
|
||||
device_unregister(&led_card->dev);
|
||||
led->cards[card->number] = NULL;
|
||||
}
|
||||
}
|
||||
@ -727,6 +744,7 @@ static int __init snd_ctl_led_init(void)
|
||||
|
||||
device_initialize(&snd_ctl_led_dev);
|
||||
snd_ctl_led_dev.class = sound_class;
|
||||
snd_ctl_led_dev.release = snd_ctl_led_dev_release;
|
||||
dev_set_name(&snd_ctl_led_dev, "ctl-led");
|
||||
if (device_add(&snd_ctl_led_dev)) {
|
||||
put_device(&snd_ctl_led_dev);
|
||||
@ -737,15 +755,16 @@ static int __init snd_ctl_led_init(void)
|
||||
INIT_LIST_HEAD(&led->controls);
|
||||
device_initialize(&led->dev);
|
||||
led->dev.parent = &snd_ctl_led_dev;
|
||||
led->dev.release = snd_ctl_led_release;
|
||||
led->dev.groups = snd_ctl_led_dev_attr_groups;
|
||||
dev_set_name(&led->dev, led->name);
|
||||
if (device_add(&led->dev)) {
|
||||
put_device(&led->dev);
|
||||
for (; group > 0; group--) {
|
||||
led = &snd_ctl_leds[group - 1];
|
||||
device_del(&led->dev);
|
||||
device_unregister(&led->dev);
|
||||
}
|
||||
device_del(&snd_ctl_led_dev);
|
||||
device_unregister(&snd_ctl_led_dev);
|
||||
return -ENOMEM;
|
||||
}
|
||||
}
|
||||
@ -771,9 +790,9 @@ static void __exit snd_ctl_led_exit(void)
|
||||
}
|
||||
for (group = 0; group < MAX_LED; group++) {
|
||||
led = &snd_ctl_leds[group];
|
||||
device_del(&led->dev);
|
||||
device_unregister(&led->dev);
|
||||
}
|
||||
device_del(&snd_ctl_led_dev);
|
||||
device_unregister(&snd_ctl_led_dev);
|
||||
snd_ctl_led_clean(NULL);
|
||||
}
|
||||
|
||||
|
@ -520,9 +520,10 @@ static void snd_timer_notify1(struct snd_timer_instance *ti, int event)
|
||||
return;
|
||||
if (timer->hw.flags & SNDRV_TIMER_HW_SLAVE)
|
||||
return;
|
||||
event += 10; /* convert to SNDRV_TIMER_EVENT_MXXX */
|
||||
list_for_each_entry(ts, &ti->slave_active_head, active_list)
|
||||
if (ts->ccallback)
|
||||
ts->ccallback(ts, event + 100, &tstamp, resolution);
|
||||
ts->ccallback(ts, event, &tstamp, resolution);
|
||||
}
|
||||
|
||||
/* start/continue a master timer */
|
||||
|
@ -1032,7 +1032,7 @@ static void generate_pkt_descs(struct amdtp_stream *s, const __be32 *ctx_header,
|
||||
static inline void cancel_stream(struct amdtp_stream *s)
|
||||
{
|
||||
s->packet_index = -1;
|
||||
if (current_work() == &s->period_work)
|
||||
if (in_interrupt())
|
||||
amdtp_stream_pcm_abort(s);
|
||||
WRITE_ONCE(s->pcm_buffer_pointer, SNDRV_PCM_POS_XRUN);
|
||||
}
|
||||
|
@ -331,6 +331,10 @@ static const struct config_entry config_table[] = {
|
||||
.flags = FLAG_SOF | FLAG_SOF_ONLY_IF_DMIC_OR_SOUNDWIRE,
|
||||
.device = 0x51c8,
|
||||
},
|
||||
{
|
||||
.flags = FLAG_SOF | FLAG_SOF_ONLY_IF_DMIC_OR_SOUNDWIRE,
|
||||
.device = 0x51cc,
|
||||
},
|
||||
#endif
|
||||
|
||||
};
|
||||
|
@ -2917,6 +2917,7 @@ static int hda_codec_runtime_resume(struct device *dev)
|
||||
#ifdef CONFIG_PM_SLEEP
|
||||
static int hda_codec_pm_prepare(struct device *dev)
|
||||
{
|
||||
dev->power.power_state = PMSG_SUSPEND;
|
||||
return pm_runtime_suspended(dev);
|
||||
}
|
||||
|
||||
@ -2924,6 +2925,10 @@ static void hda_codec_pm_complete(struct device *dev)
|
||||
{
|
||||
struct hda_codec *codec = dev_to_hda_codec(dev);
|
||||
|
||||
/* If no other pm-functions are called between prepare() and complete() */
|
||||
if (dev->power.power_state.event == PM_EVENT_SUSPEND)
|
||||
dev->power.power_state = PMSG_RESUME;
|
||||
|
||||
if (pm_runtime_suspended(dev) && (codec->jackpoll_interval ||
|
||||
hda_codec_need_resume(codec) || codec->forced_resume))
|
||||
pm_request_resume(dev);
|
||||
|
@ -3520,6 +3520,7 @@ static int cap_sw_put(struct snd_kcontrol *kcontrol,
|
||||
static const struct snd_kcontrol_new cap_sw_temp = {
|
||||
.iface = SNDRV_CTL_ELEM_IFACE_MIXER,
|
||||
.name = "Capture Switch",
|
||||
.access = SNDRV_CTL_ELEM_ACCESS_READWRITE,
|
||||
.info = cap_sw_info,
|
||||
.get = cap_sw_get,
|
||||
.put = cap_sw_put,
|
||||
|
@ -2485,6 +2485,9 @@ static const struct pci_device_id azx_ids[] = {
|
||||
/* Alderlake-P */
|
||||
{ PCI_DEVICE(0x8086, 0x51c8),
|
||||
.driver_data = AZX_DRIVER_SKL | AZX_DCAPS_INTEL_SKYLAKE},
|
||||
/* Alderlake-M */
|
||||
{ PCI_DEVICE(0x8086, 0x51cc),
|
||||
.driver_data = AZX_DRIVER_SKL | AZX_DCAPS_INTEL_SKYLAKE},
|
||||
/* Elkhart Lake */
|
||||
{ PCI_DEVICE(0x8086, 0x4b55),
|
||||
.driver_data = AZX_DRIVER_SKL | AZX_DCAPS_INTEL_SKYLAKE},
|
||||
|
@ -2206,10 +2206,9 @@ static void cs8409_cs42l42_fixups(struct hda_codec *codec,
|
||||
break;
|
||||
case HDA_FIXUP_ACT_PROBE:
|
||||
|
||||
/* Set initial volume on Bullseye to -26 dB */
|
||||
if (codec->fixup_id == CS8409_BULLSEYE)
|
||||
snd_hda_codec_amp_init_stereo(codec, CS8409_CS42L42_DMIC_ADC_PIN_NID,
|
||||
HDA_INPUT, 0, 0xff, 0x19);
|
||||
/* Set initial DMIC volume to -26 dB */
|
||||
snd_hda_codec_amp_init_stereo(codec, CS8409_CS42L42_DMIC_ADC_PIN_NID,
|
||||
HDA_INPUT, 0, 0xff, 0x19);
|
||||
snd_hda_gen_add_kctl(&spec->gen,
|
||||
NULL, &cs8409_cs42l42_hp_volume_mixer);
|
||||
snd_hda_gen_add_kctl(&spec->gen,
|
||||
|
@ -2603,6 +2603,28 @@ static const struct hda_model_fixup alc882_fixup_models[] = {
|
||||
{}
|
||||
};
|
||||
|
||||
static const struct snd_hda_pin_quirk alc882_pin_fixup_tbl[] = {
|
||||
SND_HDA_PIN_QUIRK(0x10ec1220, 0x1043, "ASUS", ALC1220_FIXUP_CLEVO_P950,
|
||||
{0x14, 0x01014010},
|
||||
{0x15, 0x01011012},
|
||||
{0x16, 0x01016011},
|
||||
{0x18, 0x01a19040},
|
||||
{0x19, 0x02a19050},
|
||||
{0x1a, 0x0181304f},
|
||||
{0x1b, 0x0221401f},
|
||||
{0x1e, 0x01456130}),
|
||||
SND_HDA_PIN_QUIRK(0x10ec1220, 0x1462, "MS-7C35", ALC1220_FIXUP_CLEVO_P950,
|
||||
{0x14, 0x01015010},
|
||||
{0x15, 0x01011012},
|
||||
{0x16, 0x01011011},
|
||||
{0x18, 0x01a11040},
|
||||
{0x19, 0x02a19050},
|
||||
{0x1a, 0x0181104f},
|
||||
{0x1b, 0x0221401f},
|
||||
{0x1e, 0x01451130}),
|
||||
{}
|
||||
};
|
||||
|
||||
/*
|
||||
* BIOS auto configuration
|
||||
*/
|
||||
@ -2644,6 +2666,7 @@ static int patch_alc882(struct hda_codec *codec)
|
||||
|
||||
snd_hda_pick_fixup(codec, alc882_fixup_models, alc882_fixup_tbl,
|
||||
alc882_fixups);
|
||||
snd_hda_pick_pin_fixup(codec, alc882_pin_fixup_tbl, alc882_fixups, true);
|
||||
snd_hda_apply_fixup(codec, HDA_FIXUP_ACT_PRE_PROBE);
|
||||
|
||||
alc_auto_parse_customize_define(codec);
|
||||
@ -6543,6 +6566,9 @@ enum {
|
||||
ALC295_FIXUP_ASUS_DACS,
|
||||
ALC295_FIXUP_HP_OMEN,
|
||||
ALC285_FIXUP_HP_SPECTRE_X360,
|
||||
ALC287_FIXUP_IDEAPAD_BASS_SPK_AMP,
|
||||
ALC623_FIXUP_LENOVO_THINKSTATION_P340,
|
||||
ALC255_FIXUP_ACER_HEADPHONE_AND_MIC,
|
||||
};
|
||||
|
||||
static const struct hda_fixup alc269_fixups[] = {
|
||||
@ -8109,6 +8135,27 @@ static const struct hda_fixup alc269_fixups[] = {
|
||||
.chained = true,
|
||||
.chain_id = ALC285_FIXUP_SPEAKER2_TO_DAC1,
|
||||
},
|
||||
[ALC287_FIXUP_IDEAPAD_BASS_SPK_AMP] = {
|
||||
.type = HDA_FIXUP_FUNC,
|
||||
.v.func = alc285_fixup_ideapad_s740_coef,
|
||||
.chained = true,
|
||||
.chain_id = ALC285_FIXUP_THINKPAD_HEADSET_JACK,
|
||||
},
|
||||
[ALC623_FIXUP_LENOVO_THINKSTATION_P340] = {
|
||||
.type = HDA_FIXUP_FUNC,
|
||||
.v.func = alc_fixup_no_shutup,
|
||||
.chained = true,
|
||||
.chain_id = ALC283_FIXUP_HEADSET_MIC,
|
||||
},
|
||||
[ALC255_FIXUP_ACER_HEADPHONE_AND_MIC] = {
|
||||
.type = HDA_FIXUP_PINS,
|
||||
.v.pins = (const struct hda_pintbl[]) {
|
||||
{ 0x21, 0x03211030 }, /* Change the Headphone location to Left */
|
||||
{ }
|
||||
},
|
||||
.chained = true,
|
||||
.chain_id = ALC255_FIXUP_XIAOMI_HEADSET_MIC
|
||||
},
|
||||
};
|
||||
|
||||
static const struct snd_pci_quirk alc269_fixup_tbl[] = {
|
||||
@ -8145,6 +8192,7 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = {
|
||||
SND_PCI_QUIRK(0x1025, 0x132a, "Acer TravelMate B114-21", ALC233_FIXUP_ACER_HEADSET_MIC),
|
||||
SND_PCI_QUIRK(0x1025, 0x1330, "Acer TravelMate X514-51T", ALC255_FIXUP_ACER_HEADSET_MIC),
|
||||
SND_PCI_QUIRK(0x1025, 0x1430, "Acer TravelMate B311R-31", ALC256_FIXUP_ACER_MIC_NO_PRESENCE),
|
||||
SND_PCI_QUIRK(0x1025, 0x1466, "Acer Aspire A515-56", ALC255_FIXUP_ACER_HEADPHONE_AND_MIC),
|
||||
SND_PCI_QUIRK(0x1028, 0x0470, "Dell M101z", ALC269_FIXUP_DELL_M101Z),
|
||||
SND_PCI_QUIRK(0x1028, 0x054b, "Dell XPS one 2710", ALC275_FIXUP_DELL_XPS),
|
||||
SND_PCI_QUIRK(0x1028, 0x05bd, "Dell Latitude E6440", ALC292_FIXUP_DELL_E7X),
|
||||
@ -8266,12 +8314,15 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = {
|
||||
SND_PCI_QUIRK(0x103c, 0x82bf, "HP G3 mini", ALC221_FIXUP_HP_MIC_NO_PRESENCE),
|
||||
SND_PCI_QUIRK(0x103c, 0x82c0, "HP G3 mini premium", ALC221_FIXUP_HP_MIC_NO_PRESENCE),
|
||||
SND_PCI_QUIRK(0x103c, 0x83b9, "HP Spectre x360", ALC269_FIXUP_HP_MUTE_LED_MIC3),
|
||||
SND_PCI_QUIRK(0x103c, 0x841c, "HP Pavilion 15-CK0xx", ALC269_FIXUP_HP_MUTE_LED_MIC3),
|
||||
SND_PCI_QUIRK(0x103c, 0x8497, "HP Envy x360", ALC269_FIXUP_HP_MUTE_LED_MIC3),
|
||||
SND_PCI_QUIRK(0x103c, 0x84da, "HP OMEN dc0019-ur", ALC295_FIXUP_HP_OMEN),
|
||||
SND_PCI_QUIRK(0x103c, 0x84e7, "HP Pavilion 15", ALC269_FIXUP_HP_MUTE_LED_MIC3),
|
||||
SND_PCI_QUIRK(0x103c, 0x8519, "HP Spectre x360 15-df0xxx", ALC285_FIXUP_HP_SPECTRE_X360),
|
||||
SND_PCI_QUIRK(0x103c, 0x869d, "HP", ALC236_FIXUP_HP_MUTE_LED),
|
||||
SND_PCI_QUIRK(0x103c, 0x86c7, "HP Envy AiO 32", ALC274_FIXUP_HP_ENVY_GPIO),
|
||||
SND_PCI_QUIRK(0x103c, 0x8716, "HP Elite Dragonfly G2 Notebook PC", ALC285_FIXUP_HP_GPIO_AMP_INIT),
|
||||
SND_PCI_QUIRK(0x103c, 0x8720, "HP EliteBook x360 1040 G8 Notebook PC", ALC285_FIXUP_HP_GPIO_AMP_INIT),
|
||||
SND_PCI_QUIRK(0x103c, 0x8724, "HP EliteBook 850 G7", ALC285_FIXUP_HP_GPIO_LED),
|
||||
SND_PCI_QUIRK(0x103c, 0x8729, "HP", ALC285_FIXUP_HP_GPIO_LED),
|
||||
SND_PCI_QUIRK(0x103c, 0x8730, "HP ProBook 445 G7", ALC236_FIXUP_HP_MUTE_LED_MICMUTE_VREF),
|
||||
@ -8290,7 +8341,13 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = {
|
||||
SND_PCI_QUIRK(0x103c, 0x87f5, "HP", ALC287_FIXUP_HP_GPIO_LED),
|
||||
SND_PCI_QUIRK(0x103c, 0x87f7, "HP Spectre x360 14", ALC245_FIXUP_HP_X360_AMP),
|
||||
SND_PCI_QUIRK(0x103c, 0x8846, "HP EliteBook 850 G8 Notebook PC", ALC285_FIXUP_HP_GPIO_LED),
|
||||
SND_PCI_QUIRK(0x103c, 0x884b, "HP EliteBook 840 Aero G8 Notebook PC", ALC285_FIXUP_HP_GPIO_LED),
|
||||
SND_PCI_QUIRK(0x103c, 0x884c, "HP EliteBook 840 G8 Notebook PC", ALC285_FIXUP_HP_GPIO_LED),
|
||||
SND_PCI_QUIRK(0x103c, 0x886d, "HP ZBook Fury 17.3 Inch G8 Mobile Workstation PC", ALC285_FIXUP_HP_GPIO_AMP_INIT),
|
||||
SND_PCI_QUIRK(0x103c, 0x8870, "HP ZBook Fury 15.6 Inch G8 Mobile Workstation PC", ALC285_FIXUP_HP_GPIO_AMP_INIT),
|
||||
SND_PCI_QUIRK(0x103c, 0x8873, "HP ZBook Studio 15.6 Inch G8 Mobile Workstation PC", ALC285_FIXUP_HP_GPIO_AMP_INIT),
|
||||
SND_PCI_QUIRK(0x103c, 0x888d, "HP ZBook Power 15.6 inch G8 Mobile Workstation PC", ALC236_FIXUP_HP_GPIO_LED),
|
||||
SND_PCI_QUIRK(0x103c, 0x8896, "HP EliteBook 855 G8 Notebook PC", ALC285_FIXUP_HP_MUTE_LED),
|
||||
SND_PCI_QUIRK(0x103c, 0x8898, "HP EliteBook 845 G8 Notebook PC", ALC285_FIXUP_HP_LIMIT_INT_MIC_BOOST),
|
||||
SND_PCI_QUIRK(0x1043, 0x103e, "ASUS X540SA", ALC256_FIXUP_ASUS_MIC),
|
||||
SND_PCI_QUIRK(0x1043, 0x103f, "ASUS TX300", ALC282_FIXUP_ASUS_TX300),
|
||||
@ -8427,7 +8484,7 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = {
|
||||
SND_PCI_QUIRK(0x1558, 0xc019, "Clevo NH77D[BE]Q", ALC293_FIXUP_SYSTEM76_MIC_NO_PRESENCE),
|
||||
SND_PCI_QUIRK(0x1558, 0xc022, "Clevo NH77[DC][QW]", ALC293_FIXUP_SYSTEM76_MIC_NO_PRESENCE),
|
||||
SND_PCI_QUIRK(0x17aa, 0x1036, "Lenovo P520", ALC233_FIXUP_LENOVO_MULTI_CODECS),
|
||||
SND_PCI_QUIRK(0x17aa, 0x1048, "ThinkCentre Station", ALC283_FIXUP_HEADSET_MIC),
|
||||
SND_PCI_QUIRK(0x17aa, 0x1048, "ThinkCentre Station", ALC623_FIXUP_LENOVO_THINKSTATION_P340),
|
||||
SND_PCI_QUIRK(0x17aa, 0x20f2, "Thinkpad SL410/510", ALC269_FIXUP_SKU_IGNORE),
|
||||
SND_PCI_QUIRK(0x17aa, 0x215e, "Thinkpad L512", ALC269_FIXUP_SKU_IGNORE),
|
||||
SND_PCI_QUIRK(0x17aa, 0x21b8, "Thinkpad Edge 14", ALC269_FIXUP_SKU_IGNORE),
|
||||
@ -8477,6 +8534,7 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = {
|
||||
SND_PCI_QUIRK(0x17aa, 0x3178, "ThinkCentre Station", ALC283_FIXUP_HEADSET_MIC),
|
||||
SND_PCI_QUIRK(0x17aa, 0x3818, "Lenovo C940", ALC298_FIXUP_LENOVO_SPK_VOLUME),
|
||||
SND_PCI_QUIRK(0x17aa, 0x3827, "Ideapad S740", ALC285_FIXUP_IDEAPAD_S740_COEF),
|
||||
SND_PCI_QUIRK(0x17aa, 0x3843, "Yoga 9i", ALC287_FIXUP_IDEAPAD_BASS_SPK_AMP),
|
||||
SND_PCI_QUIRK(0x17aa, 0x3902, "Lenovo E50-80", ALC269_FIXUP_DMIC_THINKPAD_ACPI),
|
||||
SND_PCI_QUIRK(0x17aa, 0x3977, "IdeaPad S210", ALC283_FIXUP_INT_MIC),
|
||||
SND_PCI_QUIRK(0x17aa, 0x3978, "Lenovo B50-70", ALC269_FIXUP_DMIC_THINKPAD_ACPI),
|
||||
@ -8692,6 +8750,9 @@ static const struct hda_model_fixup alc269_fixup_models[] = {
|
||||
{.id = ALC245_FIXUP_HP_X360_AMP, .name = "alc245-hp-x360-amp"},
|
||||
{.id = ALC295_FIXUP_HP_OMEN, .name = "alc295-hp-omen"},
|
||||
{.id = ALC285_FIXUP_HP_SPECTRE_X360, .name = "alc285-hp-spectre-x360"},
|
||||
{.id = ALC287_FIXUP_IDEAPAD_BASS_SPK_AMP, .name = "alc287-ideapad-bass-spk-amp"},
|
||||
{.id = ALC623_FIXUP_LENOVO_THINKSTATION_P340, .name = "alc623-lenovo-thinkstation-p340"},
|
||||
{.id = ALC255_FIXUP_ACER_HEADPHONE_AND_MIC, .name = "alc255-acer-headphone-and-mic"},
|
||||
{}
|
||||
};
|
||||
#define ALC225_STANDARD_PINS \
|
||||
|
@ -235,10 +235,6 @@ static int acp3x_dma_open(struct snd_soc_component *component,
|
||||
return ret;
|
||||
}
|
||||
|
||||
if (!adata->play_stream && !adata->capture_stream &&
|
||||
!adata->i2ssp_play_stream && !adata->i2ssp_capture_stream)
|
||||
rv_writel(1, adata->acp3x_base + mmACP_EXTERNAL_INTR_ENB);
|
||||
|
||||
i2s_data->acp3x_base = adata->acp3x_base;
|
||||
runtime->private_data = i2s_data;
|
||||
return ret;
|
||||
@ -365,12 +361,6 @@ static int acp3x_dma_close(struct snd_soc_component *component,
|
||||
}
|
||||
}
|
||||
|
||||
/* Disable ACP irq, when the current stream is being closed and
|
||||
* another stream is also not active.
|
||||
*/
|
||||
if (!adata->play_stream && !adata->capture_stream &&
|
||||
!adata->i2ssp_play_stream && !adata->i2ssp_capture_stream)
|
||||
rv_writel(0, adata->acp3x_base + mmACP_EXTERNAL_INTR_ENB);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -77,6 +77,7 @@
|
||||
#define ACP_POWER_OFF_IN_PROGRESS 0x03
|
||||
|
||||
#define ACP3x_ITER_IRER_SAMP_LEN_MASK 0x38
|
||||
#define ACP_EXT_INTR_STAT_CLEAR_MASK 0xFFFFFFFF
|
||||
|
||||
struct acp3x_platform_info {
|
||||
u16 play_i2s_instance;
|
||||
|
@ -76,6 +76,19 @@ static int acp3x_reset(void __iomem *acp3x_base)
|
||||
return -ETIMEDOUT;
|
||||
}
|
||||
|
||||
static void acp3x_enable_interrupts(void __iomem *acp_base)
|
||||
{
|
||||
rv_writel(0x01, acp_base + mmACP_EXTERNAL_INTR_ENB);
|
||||
}
|
||||
|
||||
static void acp3x_disable_interrupts(void __iomem *acp_base)
|
||||
{
|
||||
rv_writel(ACP_EXT_INTR_STAT_CLEAR_MASK, acp_base +
|
||||
mmACP_EXTERNAL_INTR_STAT);
|
||||
rv_writel(0x00, acp_base + mmACP_EXTERNAL_INTR_CNTL);
|
||||
rv_writel(0x00, acp_base + mmACP_EXTERNAL_INTR_ENB);
|
||||
}
|
||||
|
||||
static int acp3x_init(struct acp3x_dev_data *adata)
|
||||
{
|
||||
void __iomem *acp3x_base = adata->acp3x_base;
|
||||
@ -93,6 +106,7 @@ static int acp3x_init(struct acp3x_dev_data *adata)
|
||||
pr_err("ACP3x reset failed\n");
|
||||
return ret;
|
||||
}
|
||||
acp3x_enable_interrupts(acp3x_base);
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -100,6 +114,7 @@ static int acp3x_deinit(void __iomem *acp3x_base)
|
||||
{
|
||||
int ret;
|
||||
|
||||
acp3x_disable_interrupts(acp3x_base);
|
||||
/* Reset */
|
||||
ret = acp3x_reset(acp3x_base);
|
||||
if (ret) {
|
||||
|
@ -307,7 +307,7 @@ static struct snd_soc_dai_driver ak5558_dai = {
|
||||
};
|
||||
|
||||
static struct snd_soc_dai_driver ak5552_dai = {
|
||||
.name = "ak5558-aif",
|
||||
.name = "ak5552-aif",
|
||||
.capture = {
|
||||
.stream_name = "Capture",
|
||||
.channels_min = 1,
|
||||
|
@ -261,6 +261,9 @@ static const struct regmap_config cs35l32_regmap = {
|
||||
.readable_reg = cs35l32_readable_register,
|
||||
.precious_reg = cs35l32_precious_register,
|
||||
.cache_type = REGCACHE_RBTREE,
|
||||
|
||||
.use_single_read = true,
|
||||
.use_single_write = true,
|
||||
};
|
||||
|
||||
static int cs35l32_handle_of_data(struct i2c_client *i2c_client,
|
||||
|
@ -1201,6 +1201,7 @@ static int cs35l33_i2c_probe(struct i2c_client *i2c_client,
|
||||
dev_err(&i2c_client->dev,
|
||||
"CS35L33 Device ID (%X). Expected ID %X\n",
|
||||
devid, CS35L33_CHIP_ID);
|
||||
ret = -EINVAL;
|
||||
goto err_enable;
|
||||
}
|
||||
|
||||
|
@ -800,6 +800,9 @@ static struct regmap_config cs35l34_regmap = {
|
||||
.readable_reg = cs35l34_readable_register,
|
||||
.precious_reg = cs35l34_precious_register,
|
||||
.cache_type = REGCACHE_RBTREE,
|
||||
|
||||
.use_single_read = true,
|
||||
.use_single_write = true,
|
||||
};
|
||||
|
||||
static int cs35l34_handle_of_data(struct i2c_client *i2c_client,
|
||||
|
@ -399,6 +399,9 @@ static const struct regmap_config cs42l42_regmap = {
|
||||
.reg_defaults = cs42l42_reg_defaults,
|
||||
.num_reg_defaults = ARRAY_SIZE(cs42l42_reg_defaults),
|
||||
.cache_type = REGCACHE_RBTREE,
|
||||
|
||||
.use_single_read = true,
|
||||
.use_single_write = true,
|
||||
};
|
||||
|
||||
static DECLARE_TLV_DB_SCALE(adc_tlv, -9600, 100, false);
|
||||
|
@ -1175,7 +1175,7 @@ static int cs42l56_i2c_probe(struct i2c_client *i2c_client,
|
||||
struct cs42l56_platform_data *pdata =
|
||||
dev_get_platdata(&i2c_client->dev);
|
||||
int ret, i;
|
||||
unsigned int devid = 0;
|
||||
unsigned int devid;
|
||||
unsigned int alpha_rev, metal_rev;
|
||||
unsigned int reg;
|
||||
|
||||
@ -1245,6 +1245,11 @@ static int cs42l56_i2c_probe(struct i2c_client *i2c_client,
|
||||
}
|
||||
|
||||
ret = regmap_read(cs42l56->regmap, CS42L56_CHIP_ID_1, ®);
|
||||
if (ret) {
|
||||
dev_err(&i2c_client->dev, "Failed to read chip ID: %d\n", ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
devid = reg & CS42L56_CHIP_ID_MASK;
|
||||
if (devid != CS42L56_DEVID) {
|
||||
dev_err(&i2c_client->dev,
|
||||
|
@ -1268,6 +1268,9 @@ static const struct regmap_config cs42l73_regmap = {
|
||||
.volatile_reg = cs42l73_volatile_register,
|
||||
.readable_reg = cs42l73_readable_register,
|
||||
.cache_type = REGCACHE_RBTREE,
|
||||
|
||||
.use_single_read = true,
|
||||
.use_single_write = true,
|
||||
};
|
||||
|
||||
static int cs42l73_i2c_probe(struct i2c_client *i2c_client,
|
||||
|
@ -912,6 +912,9 @@ static struct regmap_config cs53l30_regmap = {
|
||||
.writeable_reg = cs53l30_writeable_register,
|
||||
.readable_reg = cs53l30_readable_register,
|
||||
.cache_type = REGCACHE_RBTREE,
|
||||
|
||||
.use_single_read = true,
|
||||
.use_single_write = true,
|
||||
};
|
||||
|
||||
static int cs53l30_i2c_probe(struct i2c_client *client,
|
||||
|
@ -2181,10 +2181,7 @@ static int da7219_register_dai_clks(struct snd_soc_component *component)
|
||||
ret);
|
||||
goto err;
|
||||
}
|
||||
|
||||
da7219->dai_clks[i] = devm_clk_hw_get_clk(dev, dai_clk_hw, NULL);
|
||||
if (IS_ERR(da7219->dai_clks[i]))
|
||||
return PTR_ERR(da7219->dai_clks[i]);
|
||||
da7219->dai_clks[i] = dai_clk_hw->clk;
|
||||
|
||||
/* For DT setup onecell data, otherwise create lookup */
|
||||
if (np) {
|
||||
|
@ -3579,6 +3579,7 @@ static const struct of_device_id rx_macro_dt_match[] = {
|
||||
{ .compatible = "qcom,sm8250-lpass-rx-macro" },
|
||||
{ }
|
||||
};
|
||||
MODULE_DEVICE_TABLE(of, rx_macro_dt_match);
|
||||
|
||||
static struct platform_driver rx_macro_driver = {
|
||||
.driver = {
|
||||
|
@ -1846,6 +1846,7 @@ static const struct of_device_id tx_macro_dt_match[] = {
|
||||
{ .compatible = "qcom,sm8250-lpass-tx-macro" },
|
||||
{ }
|
||||
};
|
||||
MODULE_DEVICE_TABLE(of, tx_macro_dt_match);
|
||||
static struct platform_driver tx_macro_driver = {
|
||||
.driver = {
|
||||
.name = "tx_macro",
|
||||
|
@ -41,6 +41,7 @@ struct max98088_priv {
|
||||
enum max98088_type devtype;
|
||||
struct max98088_pdata *pdata;
|
||||
struct clk *mclk;
|
||||
unsigned char mclk_prescaler;
|
||||
unsigned int sysclk;
|
||||
struct max98088_cdata dai[2];
|
||||
int eq_textcnt;
|
||||
@ -998,13 +999,16 @@ static int max98088_dai1_hw_params(struct snd_pcm_substream *substream,
|
||||
/* Configure NI when operating as master */
|
||||
if (snd_soc_component_read(component, M98088_REG_14_DAI1_FORMAT)
|
||||
& M98088_DAI_MAS) {
|
||||
unsigned long pclk;
|
||||
|
||||
if (max98088->sysclk == 0) {
|
||||
dev_err(component->dev, "Invalid system clock frequency\n");
|
||||
return -EINVAL;
|
||||
}
|
||||
ni = 65536ULL * (rate < 50000 ? 96ULL : 48ULL)
|
||||
* (unsigned long long int)rate;
|
||||
do_div(ni, (unsigned long long int)max98088->sysclk);
|
||||
pclk = DIV_ROUND_CLOSEST(max98088->sysclk, max98088->mclk_prescaler);
|
||||
ni = DIV_ROUND_CLOSEST_ULL(ni, pclk);
|
||||
snd_soc_component_write(component, M98088_REG_12_DAI1_CLKCFG_HI,
|
||||
(ni >> 8) & 0x7F);
|
||||
snd_soc_component_write(component, M98088_REG_13_DAI1_CLKCFG_LO,
|
||||
@ -1065,13 +1069,16 @@ static int max98088_dai2_hw_params(struct snd_pcm_substream *substream,
|
||||
/* Configure NI when operating as master */
|
||||
if (snd_soc_component_read(component, M98088_REG_1C_DAI2_FORMAT)
|
||||
& M98088_DAI_MAS) {
|
||||
unsigned long pclk;
|
||||
|
||||
if (max98088->sysclk == 0) {
|
||||
dev_err(component->dev, "Invalid system clock frequency\n");
|
||||
return -EINVAL;
|
||||
}
|
||||
ni = 65536ULL * (rate < 50000 ? 96ULL : 48ULL)
|
||||
* (unsigned long long int)rate;
|
||||
do_div(ni, (unsigned long long int)max98088->sysclk);
|
||||
pclk = DIV_ROUND_CLOSEST(max98088->sysclk, max98088->mclk_prescaler);
|
||||
ni = DIV_ROUND_CLOSEST_ULL(ni, pclk);
|
||||
snd_soc_component_write(component, M98088_REG_1A_DAI2_CLKCFG_HI,
|
||||
(ni >> 8) & 0x7F);
|
||||
snd_soc_component_write(component, M98088_REG_1B_DAI2_CLKCFG_LO,
|
||||
@ -1113,8 +1120,10 @@ static int max98088_dai_set_sysclk(struct snd_soc_dai *dai,
|
||||
*/
|
||||
if ((freq >= 10000000) && (freq < 20000000)) {
|
||||
snd_soc_component_write(component, M98088_REG_10_SYS_CLK, 0x10);
|
||||
max98088->mclk_prescaler = 1;
|
||||
} else if ((freq >= 20000000) && (freq < 30000000)) {
|
||||
snd_soc_component_write(component, M98088_REG_10_SYS_CLK, 0x20);
|
||||
max98088->mclk_prescaler = 2;
|
||||
} else {
|
||||
dev_err(component->dev, "Invalid master clock frequency\n");
|
||||
return -EINVAL;
|
||||
|
@ -683,13 +683,13 @@ static int rt711_sdca_set_fu1e_capture_ctl(struct rt711_sdca_priv *rt711)
|
||||
ch_r = (rt711->fu1e_dapm_mute || rt711->fu1e_mixer_r_mute) ? 0x01 : 0x00;
|
||||
|
||||
err = regmap_write(rt711->regmap,
|
||||
SDW_SDCA_CTL(FUNC_NUM_JACK_CODEC, RT711_SDCA_ENT_USER_FU1E,
|
||||
SDW_SDCA_CTL(FUNC_NUM_MIC_ARRAY, RT711_SDCA_ENT_USER_FU1E,
|
||||
RT711_SDCA_CTL_FU_MUTE, CH_L), ch_l);
|
||||
if (err < 0)
|
||||
return err;
|
||||
|
||||
err = regmap_write(rt711->regmap,
|
||||
SDW_SDCA_CTL(FUNC_NUM_JACK_CODEC, RT711_SDCA_ENT_USER_FU1E,
|
||||
SDW_SDCA_CTL(FUNC_NUM_MIC_ARRAY, RT711_SDCA_ENT_USER_FU1E,
|
||||
RT711_SDCA_CTL_FU_MUTE, CH_R), ch_r);
|
||||
if (err < 0)
|
||||
return err;
|
||||
|
@ -408,6 +408,7 @@ static const struct of_device_id sti_sas_dev_match[] = {
|
||||
},
|
||||
{},
|
||||
};
|
||||
MODULE_DEVICE_TABLE(of, sti_sas_dev_match);
|
||||
|
||||
static int sti_sas_driver_probe(struct platform_device *pdev)
|
||||
{
|
||||
|
@ -119,6 +119,7 @@ config SND_SOC_FSL_RPMSG
|
||||
tristate "NXP Audio Base On RPMSG support"
|
||||
depends on COMMON_CLK
|
||||
depends on RPMSG
|
||||
depends on SND_IMX_SOC || SND_IMX_SOC = n
|
||||
select SND_SOC_IMX_RPMSG if SND_IMX_SOC != n
|
||||
help
|
||||
Say Y if you want to add rpmsg audio support for the Freescale CPUs.
|
||||
|
@ -209,7 +209,7 @@ static void graph_parse_mclk_fs(struct device_node *top,
|
||||
static int graph_parse_node(struct asoc_simple_priv *priv,
|
||||
struct device_node *ep,
|
||||
struct link_info *li,
|
||||
int is_cpu)
|
||||
int *cpu)
|
||||
{
|
||||
struct device *dev = simple_priv_to_dev(priv);
|
||||
struct device_node *top = dev->of_node;
|
||||
@ -217,9 +217,9 @@ static int graph_parse_node(struct asoc_simple_priv *priv,
|
||||
struct simple_dai_props *dai_props = simple_priv_to_props(priv, li->link);
|
||||
struct snd_soc_dai_link_component *dlc;
|
||||
struct asoc_simple_dai *dai;
|
||||
int ret, single = 0;
|
||||
int ret;
|
||||
|
||||
if (is_cpu) {
|
||||
if (cpu) {
|
||||
dlc = asoc_link_to_cpu(dai_link, 0);
|
||||
dai = simple_props_to_dai_cpu(dai_props, 0);
|
||||
} else {
|
||||
@ -229,7 +229,7 @@ static int graph_parse_node(struct asoc_simple_priv *priv,
|
||||
|
||||
graph_parse_mclk_fs(top, ep, dai_props);
|
||||
|
||||
ret = asoc_simple_parse_dai(ep, dlc, &single);
|
||||
ret = asoc_simple_parse_dai(ep, dlc, cpu);
|
||||
if (ret < 0)
|
||||
return ret;
|
||||
|
||||
@ -241,9 +241,6 @@ static int graph_parse_node(struct asoc_simple_priv *priv,
|
||||
if (ret < 0)
|
||||
return ret;
|
||||
|
||||
if (is_cpu)
|
||||
asoc_simple_canonicalize_cpu(dlc, single);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -276,33 +273,29 @@ static int graph_dai_link_of_dpcm(struct asoc_simple_priv *priv,
|
||||
struct link_info *li)
|
||||
{
|
||||
struct device *dev = simple_priv_to_dev(priv);
|
||||
struct snd_soc_card *card = simple_priv_to_card(priv);
|
||||
struct snd_soc_dai_link *dai_link = simple_priv_to_link(priv, li->link);
|
||||
struct simple_dai_props *dai_props = simple_priv_to_props(priv, li->link);
|
||||
struct device_node *top = dev->of_node;
|
||||
struct device_node *ep = li->cpu ? cpu_ep : codec_ep;
|
||||
struct device_node *port;
|
||||
struct device_node *ports;
|
||||
struct snd_soc_dai_link_component *cpus = asoc_link_to_cpu(dai_link, 0);
|
||||
struct snd_soc_dai_link_component *codecs = asoc_link_to_codec(dai_link, 0);
|
||||
char dai_name[64];
|
||||
int ret;
|
||||
|
||||
port = of_get_parent(ep);
|
||||
ports = of_get_parent(port);
|
||||
|
||||
dev_dbg(dev, "link_of DPCM (%pOF)\n", ep);
|
||||
|
||||
if (li->cpu) {
|
||||
struct snd_soc_card *card = simple_priv_to_card(priv);
|
||||
struct snd_soc_dai_link_component *cpus = asoc_link_to_cpu(dai_link, 0);
|
||||
int is_single_links = 0;
|
||||
|
||||
/* Codec is dummy */
|
||||
|
||||
/* FE settings */
|
||||
dai_link->dynamic = 1;
|
||||
dai_link->dpcm_merged_format = 1;
|
||||
|
||||
ret = graph_parse_node(priv, cpu_ep, li, 1);
|
||||
ret = graph_parse_node(priv, cpu_ep, li, &is_single_links);
|
||||
if (ret)
|
||||
goto out_put_node;
|
||||
return ret;
|
||||
|
||||
snprintf(dai_name, sizeof(dai_name),
|
||||
"fe.%pOFP.%s", cpus->of_node, cpus->dai_name);
|
||||
@ -318,8 +311,13 @@ static int graph_dai_link_of_dpcm(struct asoc_simple_priv *priv,
|
||||
*/
|
||||
if (card->component_chaining && !soc_component_is_pcm(cpus))
|
||||
dai_link->no_pcm = 1;
|
||||
|
||||
asoc_simple_canonicalize_cpu(cpus, is_single_links);
|
||||
} else {
|
||||
struct snd_soc_codec_conf *cconf;
|
||||
struct snd_soc_codec_conf *cconf = simple_props_to_codec_conf(dai_props, 0);
|
||||
struct snd_soc_dai_link_component *codecs = asoc_link_to_codec(dai_link, 0);
|
||||
struct device_node *port;
|
||||
struct device_node *ports;
|
||||
|
||||
/* CPU is dummy */
|
||||
|
||||
@ -327,22 +325,25 @@ static int graph_dai_link_of_dpcm(struct asoc_simple_priv *priv,
|
||||
dai_link->no_pcm = 1;
|
||||
dai_link->be_hw_params_fixup = asoc_simple_be_hw_params_fixup;
|
||||
|
||||
cconf = simple_props_to_codec_conf(dai_props, 0);
|
||||
|
||||
ret = graph_parse_node(priv, codec_ep, li, 0);
|
||||
ret = graph_parse_node(priv, codec_ep, li, NULL);
|
||||
if (ret < 0)
|
||||
goto out_put_node;
|
||||
return ret;
|
||||
|
||||
snprintf(dai_name, sizeof(dai_name),
|
||||
"be.%pOFP.%s", codecs->of_node, codecs->dai_name);
|
||||
|
||||
/* check "prefix" from top node */
|
||||
port = of_get_parent(ep);
|
||||
ports = of_get_parent(port);
|
||||
snd_soc_of_parse_node_prefix(top, cconf, codecs->of_node,
|
||||
"prefix");
|
||||
if (of_node_name_eq(ports, "ports"))
|
||||
snd_soc_of_parse_node_prefix(ports, cconf, codecs->of_node, "prefix");
|
||||
snd_soc_of_parse_node_prefix(port, cconf, codecs->of_node,
|
||||
"prefix");
|
||||
|
||||
of_node_put(ports);
|
||||
of_node_put(port);
|
||||
}
|
||||
|
||||
graph_parse_convert(dev, ep, &dai_props->adata);
|
||||
@ -351,11 +352,8 @@ static int graph_dai_link_of_dpcm(struct asoc_simple_priv *priv,
|
||||
|
||||
ret = graph_link_init(priv, cpu_ep, codec_ep, li, dai_name);
|
||||
|
||||
out_put_node:
|
||||
li->link++;
|
||||
|
||||
of_node_put(ports);
|
||||
of_node_put(port);
|
||||
return ret;
|
||||
}
|
||||
|
||||
@ -369,20 +367,23 @@ static int graph_dai_link_of(struct asoc_simple_priv *priv,
|
||||
struct snd_soc_dai_link_component *cpus = asoc_link_to_cpu(dai_link, 0);
|
||||
struct snd_soc_dai_link_component *codecs = asoc_link_to_codec(dai_link, 0);
|
||||
char dai_name[64];
|
||||
int ret;
|
||||
int ret, is_single_links = 0;
|
||||
|
||||
dev_dbg(dev, "link_of (%pOF)\n", cpu_ep);
|
||||
|
||||
ret = graph_parse_node(priv, cpu_ep, li, 1);
|
||||
ret = graph_parse_node(priv, cpu_ep, li, &is_single_links);
|
||||
if (ret < 0)
|
||||
return ret;
|
||||
|
||||
ret = graph_parse_node(priv, codec_ep, li, 0);
|
||||
ret = graph_parse_node(priv, codec_ep, li, NULL);
|
||||
if (ret < 0)
|
||||
return ret;
|
||||
|
||||
snprintf(dai_name, sizeof(dai_name),
|
||||
"%s-%s", cpus->dai_name, codecs->dai_name);
|
||||
|
||||
asoc_simple_canonicalize_cpu(cpus, is_single_links);
|
||||
|
||||
ret = graph_link_init(priv, cpu_ep, codec_ep, li, dai_name);
|
||||
if (ret < 0)
|
||||
return ret;
|
||||
|
@ -93,12 +93,11 @@ static void simple_parse_convert(struct device *dev,
|
||||
}
|
||||
|
||||
static void simple_parse_mclk_fs(struct device_node *top,
|
||||
struct device_node *cpu,
|
||||
struct device_node *codec,
|
||||
struct device_node *np,
|
||||
struct simple_dai_props *props,
|
||||
char *prefix)
|
||||
{
|
||||
struct device_node *node = of_get_parent(cpu);
|
||||
struct device_node *node = of_get_parent(np);
|
||||
char prop[128];
|
||||
|
||||
snprintf(prop, sizeof(prop), "%smclk-fs", PREFIX);
|
||||
@ -106,12 +105,71 @@ static void simple_parse_mclk_fs(struct device_node *top,
|
||||
|
||||
snprintf(prop, sizeof(prop), "%smclk-fs", prefix);
|
||||
of_property_read_u32(node, prop, &props->mclk_fs);
|
||||
of_property_read_u32(cpu, prop, &props->mclk_fs);
|
||||
of_property_read_u32(codec, prop, &props->mclk_fs);
|
||||
of_property_read_u32(np, prop, &props->mclk_fs);
|
||||
|
||||
of_node_put(node);
|
||||
}
|
||||
|
||||
static int simple_parse_node(struct asoc_simple_priv *priv,
|
||||
struct device_node *np,
|
||||
struct link_info *li,
|
||||
char *prefix,
|
||||
int *cpu)
|
||||
{
|
||||
struct device *dev = simple_priv_to_dev(priv);
|
||||
struct device_node *top = dev->of_node;
|
||||
struct snd_soc_dai_link *dai_link = simple_priv_to_link(priv, li->link);
|
||||
struct simple_dai_props *dai_props = simple_priv_to_props(priv, li->link);
|
||||
struct snd_soc_dai_link_component *dlc;
|
||||
struct asoc_simple_dai *dai;
|
||||
int ret;
|
||||
|
||||
if (cpu) {
|
||||
dlc = asoc_link_to_cpu(dai_link, 0);
|
||||
dai = simple_props_to_dai_cpu(dai_props, 0);
|
||||
} else {
|
||||
dlc = asoc_link_to_codec(dai_link, 0);
|
||||
dai = simple_props_to_dai_codec(dai_props, 0);
|
||||
}
|
||||
|
||||
simple_parse_mclk_fs(top, np, dai_props, prefix);
|
||||
|
||||
ret = asoc_simple_parse_dai(np, dlc, cpu);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
ret = asoc_simple_parse_clk(dev, np, dai, dlc);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
ret = asoc_simple_parse_tdm(np, dai);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int simple_link_init(struct asoc_simple_priv *priv,
|
||||
struct device_node *node,
|
||||
struct device_node *codec,
|
||||
struct link_info *li,
|
||||
char *prefix, char *name)
|
||||
{
|
||||
struct device *dev = simple_priv_to_dev(priv);
|
||||
struct snd_soc_dai_link *dai_link = simple_priv_to_link(priv, li->link);
|
||||
int ret;
|
||||
|
||||
ret = asoc_simple_parse_daifmt(dev, node, codec,
|
||||
prefix, &dai_link->dai_fmt);
|
||||
if (ret < 0)
|
||||
return 0;
|
||||
|
||||
dai_link->init = asoc_simple_dai_init;
|
||||
dai_link->ops = &simple_ops;
|
||||
|
||||
return asoc_simple_set_dailink_name(dev, dai_link, name);
|
||||
}
|
||||
|
||||
static int simple_dai_link_of_dpcm(struct asoc_simple_priv *priv,
|
||||
struct device_node *np,
|
||||
struct device_node *codec,
|
||||
@ -121,24 +179,21 @@ static int simple_dai_link_of_dpcm(struct asoc_simple_priv *priv,
|
||||
struct device *dev = simple_priv_to_dev(priv);
|
||||
struct snd_soc_dai_link *dai_link = simple_priv_to_link(priv, li->link);
|
||||
struct simple_dai_props *dai_props = simple_priv_to_props(priv, li->link);
|
||||
struct asoc_simple_dai *dai;
|
||||
struct snd_soc_dai_link_component *cpus = asoc_link_to_cpu(dai_link, 0);
|
||||
struct snd_soc_dai_link_component *codecs = asoc_link_to_codec(dai_link, 0);
|
||||
struct snd_soc_dai_link_component *platforms = asoc_link_to_platform(dai_link, 0);
|
||||
struct device_node *top = dev->of_node;
|
||||
struct device_node *node = of_get_parent(np);
|
||||
char *prefix = "";
|
||||
char dai_name[64];
|
||||
int ret;
|
||||
|
||||
dev_dbg(dev, "link_of DPCM (%pOF)\n", np);
|
||||
|
||||
li->link++;
|
||||
|
||||
/* For single DAI link & old style of DT node */
|
||||
if (is_top)
|
||||
prefix = PREFIX;
|
||||
|
||||
if (li->cpu) {
|
||||
struct snd_soc_dai_link_component *cpus = asoc_link_to_cpu(dai_link, 0);
|
||||
struct snd_soc_dai_link_component *platforms = asoc_link_to_platform(dai_link, 0);
|
||||
int is_single_links = 0;
|
||||
|
||||
/* Codec is dummy */
|
||||
@ -147,25 +202,16 @@ static int simple_dai_link_of_dpcm(struct asoc_simple_priv *priv,
|
||||
dai_link->dynamic = 1;
|
||||
dai_link->dpcm_merged_format = 1;
|
||||
|
||||
dai = simple_props_to_dai_cpu(dai_props, 0);
|
||||
|
||||
ret = asoc_simple_parse_dai(np, cpus, &is_single_links);
|
||||
if (ret)
|
||||
goto out_put_node;
|
||||
|
||||
ret = asoc_simple_parse_clk(dev, np, dai, cpus);
|
||||
ret = simple_parse_node(priv, np, li, prefix, &is_single_links);
|
||||
if (ret < 0)
|
||||
goto out_put_node;
|
||||
|
||||
ret = asoc_simple_set_dailink_name(dev, dai_link,
|
||||
"fe.%s",
|
||||
cpus->dai_name);
|
||||
if (ret < 0)
|
||||
goto out_put_node;
|
||||
snprintf(dai_name, sizeof(dai_name), "fe.%s", cpus->dai_name);
|
||||
|
||||
asoc_simple_canonicalize_cpu(cpus, is_single_links);
|
||||
asoc_simple_canonicalize_platform(platforms, cpus);
|
||||
} else {
|
||||
struct snd_soc_dai_link_component *codecs = asoc_link_to_codec(dai_link, 0);
|
||||
struct snd_soc_codec_conf *cconf;
|
||||
|
||||
/* CPU is dummy */
|
||||
@ -174,22 +220,13 @@ static int simple_dai_link_of_dpcm(struct asoc_simple_priv *priv,
|
||||
dai_link->no_pcm = 1;
|
||||
dai_link->be_hw_params_fixup = asoc_simple_be_hw_params_fixup;
|
||||
|
||||
dai = simple_props_to_dai_codec(dai_props, 0);
|
||||
cconf = simple_props_to_codec_conf(dai_props, 0);
|
||||
|
||||
ret = asoc_simple_parse_dai(np, codecs, NULL);
|
||||
ret = simple_parse_node(priv, np, li, prefix, NULL);
|
||||
if (ret < 0)
|
||||
goto out_put_node;
|
||||
|
||||
ret = asoc_simple_parse_clk(dev, np, dai, codecs);
|
||||
if (ret < 0)
|
||||
goto out_put_node;
|
||||
|
||||
ret = asoc_simple_set_dailink_name(dev, dai_link,
|
||||
"be.%s",
|
||||
codecs->dai_name);
|
||||
if (ret < 0)
|
||||
goto out_put_node;
|
||||
snprintf(dai_name, sizeof(dai_name), "be.%s", codecs->dai_name);
|
||||
|
||||
/* check "prefix" from top node */
|
||||
snd_soc_of_parse_node_prefix(top, cconf, codecs->of_node,
|
||||
@ -201,23 +238,14 @@ static int simple_dai_link_of_dpcm(struct asoc_simple_priv *priv,
|
||||
}
|
||||
|
||||
simple_parse_convert(dev, np, &dai_props->adata);
|
||||
simple_parse_mclk_fs(top, np, codec, dai_props, prefix);
|
||||
|
||||
ret = asoc_simple_parse_tdm(np, dai);
|
||||
if (ret)
|
||||
goto out_put_node;
|
||||
|
||||
ret = asoc_simple_parse_daifmt(dev, node, codec,
|
||||
prefix, &dai_link->dai_fmt);
|
||||
if (ret < 0)
|
||||
goto out_put_node;
|
||||
|
||||
snd_soc_dai_link_set_capabilities(dai_link);
|
||||
|
||||
dai_link->ops = &simple_ops;
|
||||
dai_link->init = asoc_simple_dai_init;
|
||||
ret = simple_link_init(priv, node, codec, li, prefix, dai_name);
|
||||
|
||||
out_put_node:
|
||||
li->link++;
|
||||
|
||||
of_node_put(node);
|
||||
return ret;
|
||||
}
|
||||
@ -230,23 +258,19 @@ static int simple_dai_link_of(struct asoc_simple_priv *priv,
|
||||
{
|
||||
struct device *dev = simple_priv_to_dev(priv);
|
||||
struct snd_soc_dai_link *dai_link = simple_priv_to_link(priv, li->link);
|
||||
struct simple_dai_props *dai_props = simple_priv_to_props(priv, li->link);
|
||||
struct asoc_simple_dai *cpu_dai = simple_props_to_dai_cpu(dai_props, 0);
|
||||
struct asoc_simple_dai *codec_dai = simple_props_to_dai_codec(dai_props, 0);
|
||||
struct snd_soc_dai_link_component *cpus = asoc_link_to_cpu(dai_link, 0);
|
||||
struct snd_soc_dai_link_component *codecs = asoc_link_to_codec(dai_link, 0);
|
||||
struct snd_soc_dai_link_component *platforms = asoc_link_to_platform(dai_link, 0);
|
||||
struct device_node *top = dev->of_node;
|
||||
struct device_node *cpu = NULL;
|
||||
struct device_node *node = NULL;
|
||||
struct device_node *plat = NULL;
|
||||
char dai_name[64];
|
||||
char prop[128];
|
||||
char *prefix = "";
|
||||
int ret, single_cpu = 0;
|
||||
|
||||
cpu = np;
|
||||
node = of_get_parent(np);
|
||||
li->link++;
|
||||
|
||||
dev_dbg(dev, "link_of (%pOF)\n", node);
|
||||
|
||||
@ -257,18 +281,11 @@ static int simple_dai_link_of(struct asoc_simple_priv *priv,
|
||||
snprintf(prop, sizeof(prop), "%splat", prefix);
|
||||
plat = of_get_child_by_name(node, prop);
|
||||
|
||||
ret = asoc_simple_parse_daifmt(dev, node, codec,
|
||||
prefix, &dai_link->dai_fmt);
|
||||
ret = simple_parse_node(priv, cpu, li, prefix, &single_cpu);
|
||||
if (ret < 0)
|
||||
goto dai_link_of_err;
|
||||
|
||||
simple_parse_mclk_fs(top, cpu, codec, dai_props, prefix);
|
||||
|
||||
ret = asoc_simple_parse_dai(cpu, cpus, &single_cpu);
|
||||
if (ret < 0)
|
||||
goto dai_link_of_err;
|
||||
|
||||
ret = asoc_simple_parse_dai(codec, codecs, NULL);
|
||||
ret = simple_parse_node(priv, codec, li, prefix, NULL);
|
||||
if (ret < 0)
|
||||
goto dai_link_of_err;
|
||||
|
||||
@ -276,39 +293,20 @@ static int simple_dai_link_of(struct asoc_simple_priv *priv,
|
||||
if (ret < 0)
|
||||
goto dai_link_of_err;
|
||||
|
||||
ret = asoc_simple_parse_tdm(cpu, cpu_dai);
|
||||
if (ret < 0)
|
||||
goto dai_link_of_err;
|
||||
|
||||
ret = asoc_simple_parse_tdm(codec, codec_dai);
|
||||
if (ret < 0)
|
||||
goto dai_link_of_err;
|
||||
|
||||
ret = asoc_simple_parse_clk(dev, cpu, cpu_dai, cpus);
|
||||
if (ret < 0)
|
||||
goto dai_link_of_err;
|
||||
|
||||
ret = asoc_simple_parse_clk(dev, codec, codec_dai, codecs);
|
||||
if (ret < 0)
|
||||
goto dai_link_of_err;
|
||||
|
||||
ret = asoc_simple_set_dailink_name(dev, dai_link,
|
||||
"%s-%s",
|
||||
cpus->dai_name,
|
||||
codecs->dai_name);
|
||||
if (ret < 0)
|
||||
goto dai_link_of_err;
|
||||
|
||||
dai_link->ops = &simple_ops;
|
||||
dai_link->init = asoc_simple_dai_init;
|
||||
snprintf(dai_name, sizeof(dai_name),
|
||||
"%s-%s", cpus->dai_name, codecs->dai_name);
|
||||
|
||||
asoc_simple_canonicalize_cpu(cpus, single_cpu);
|
||||
asoc_simple_canonicalize_platform(platforms, cpus);
|
||||
|
||||
ret = simple_link_init(priv, node, codec, li, prefix, dai_name);
|
||||
|
||||
dai_link_of_err:
|
||||
of_node_put(plat);
|
||||
of_node_put(node);
|
||||
|
||||
li->link++;
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
@ -574,6 +574,17 @@ static const struct dmi_system_id byt_rt5640_quirk_table[] = {
|
||||
BYT_RT5640_SSP0_AIF1 |
|
||||
BYT_RT5640_MCLK_EN),
|
||||
},
|
||||
{ /* Glavey TM800A550L */
|
||||
.matches = {
|
||||
DMI_MATCH(DMI_BOARD_VENDOR, "AMI Corporation"),
|
||||
DMI_MATCH(DMI_BOARD_NAME, "Aptio CRB"),
|
||||
/* Above strings are too generic, also match on BIOS version */
|
||||
DMI_MATCH(DMI_BIOS_VERSION, "ZY-8-BI-PX4S70VTR400-X423B-005-D"),
|
||||
},
|
||||
.driver_data = (void *)(BYTCR_INPUT_DEFAULTS |
|
||||
BYT_RT5640_SSP0_AIF1 |
|
||||
BYT_RT5640_MCLK_EN),
|
||||
},
|
||||
{
|
||||
.matches = {
|
||||
DMI_EXACT_MATCH(DMI_SYS_VENDOR, "Hewlett-Packard"),
|
||||
@ -652,6 +663,20 @@ static const struct dmi_system_id byt_rt5640_quirk_table[] = {
|
||||
BYT_RT5640_MONO_SPEAKER |
|
||||
BYT_RT5640_MCLK_EN),
|
||||
},
|
||||
{ /* Lenovo Miix 3-830 */
|
||||
.matches = {
|
||||
DMI_EXACT_MATCH(DMI_SYS_VENDOR, "LENOVO"),
|
||||
DMI_EXACT_MATCH(DMI_PRODUCT_VERSION, "Lenovo MIIX 3-830"),
|
||||
},
|
||||
.driver_data = (void *)(BYT_RT5640_IN1_MAP |
|
||||
BYT_RT5640_JD_SRC_JD2_IN4N |
|
||||
BYT_RT5640_OVCD_TH_2000UA |
|
||||
BYT_RT5640_OVCD_SF_0P75 |
|
||||
BYT_RT5640_MONO_SPEAKER |
|
||||
BYT_RT5640_DIFF_MIC |
|
||||
BYT_RT5640_SSP0_AIF1 |
|
||||
BYT_RT5640_MCLK_EN),
|
||||
},
|
||||
{ /* Linx Linx7 tablet */
|
||||
.matches = {
|
||||
DMI_EXACT_MATCH(DMI_SYS_VENDOR, "LINX"),
|
||||
|
@ -835,18 +835,8 @@ int asoc_qcom_lpass_cpu_platform_probe(struct platform_device *pdev)
|
||||
if (dai_id == LPASS_DP_RX)
|
||||
continue;
|
||||
|
||||
drvdata->mi2s_osr_clk[dai_id] = devm_clk_get(dev,
|
||||
drvdata->mi2s_osr_clk[dai_id] = devm_clk_get_optional(dev,
|
||||
variant->dai_osr_clk_names[i]);
|
||||
if (IS_ERR(drvdata->mi2s_osr_clk[dai_id])) {
|
||||
dev_warn(dev,
|
||||
"%s() error getting optional %s: %ld\n",
|
||||
__func__,
|
||||
variant->dai_osr_clk_names[i],
|
||||
PTR_ERR(drvdata->mi2s_osr_clk[dai_id]));
|
||||
|
||||
drvdata->mi2s_osr_clk[dai_id] = NULL;
|
||||
}
|
||||
|
||||
drvdata->mi2s_bit_clk[dai_id] = devm_clk_get(dev,
|
||||
variant->dai_bit_clk_names[i]);
|
||||
if (IS_ERR(drvdata->mi2s_bit_clk[dai_id])) {
|
||||
|
@ -421,11 +421,16 @@ static int ssp_dai_hw_params(struct snd_pcm_substream *substream,
|
||||
struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
|
||||
struct snd_soc_component *component = snd_soc_rtdcom_lookup(rtd, SOF_AUDIO_PCM_DRV_NAME);
|
||||
struct snd_sof_dev *sdev = snd_soc_component_get_drvdata(component);
|
||||
struct sof_ipc_fw_version *v = &sdev->fw_ready.version;
|
||||
struct sof_ipc_dai_config *config;
|
||||
struct snd_sof_dai *sof_dai;
|
||||
struct sof_ipc_reply reply;
|
||||
int ret;
|
||||
|
||||
/* DAI_CONFIG IPC during hw_params is not supported in older firmware */
|
||||
if (v->abi_version < SOF_ABI_VER(3, 18, 0))
|
||||
return 0;
|
||||
|
||||
list_for_each_entry(sof_dai, &sdev->dai_list, list) {
|
||||
if (!sof_dai->cpu_dai_name || !sof_dai->dai_config)
|
||||
continue;
|
||||
|
@ -484,10 +484,7 @@ static int stm32_sai_add_mclk_provider(struct stm32_sai_sub_data *sai)
|
||||
dev_err(dev, "mclk register returned %d\n", ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
sai->sai_mclk = devm_clk_hw_get_clk(dev, hw, NULL);
|
||||
if (IS_ERR(sai->sai_mclk))
|
||||
return PTR_ERR(sai->sai_mclk);
|
||||
sai->sai_mclk = hw->clk;
|
||||
|
||||
/* register mclk provider */
|
||||
return devm_of_clk_add_hw_provider(dev, of_clk_hw_simple_get, hw);
|
||||
|
@ -436,7 +436,7 @@ static bool check_valid_altsetting_v2v3(struct snd_usb_audio *chip, int iface,
|
||||
if (snd_BUG_ON(altsetting >= 64 - 8))
|
||||
return false;
|
||||
|
||||
err = snd_usb_ctl_msg(dev, usb_sndctrlpipe(dev, 0), UAC2_CS_CUR,
|
||||
err = snd_usb_ctl_msg(dev, usb_rcvctrlpipe(dev, 0), UAC2_CS_CUR,
|
||||
USB_TYPE_CLASS | USB_RECIP_INTERFACE | USB_DIR_IN,
|
||||
UAC2_AS_VAL_ALT_SETTINGS << 8,
|
||||
iface, &raw_data, sizeof(raw_data));
|
||||
|
@ -699,6 +699,10 @@ static int line6_init_cap_control(struct usb_line6 *line6)
|
||||
line6->buffer_message = kmalloc(LINE6_MIDI_MESSAGE_MAXLEN, GFP_KERNEL);
|
||||
if (!line6->buffer_message)
|
||||
return -ENOMEM;
|
||||
|
||||
ret = line6_init_midi(line6);
|
||||
if (ret < 0)
|
||||
return ret;
|
||||
} else {
|
||||
ret = line6_hwdep_init(line6);
|
||||
if (ret < 0)
|
||||
|
@ -376,11 +376,6 @@ static int pod_init(struct usb_line6 *line6,
|
||||
if (err < 0)
|
||||
return err;
|
||||
|
||||
/* initialize MIDI subsystem: */
|
||||
err = line6_init_midi(line6);
|
||||
if (err < 0)
|
||||
return err;
|
||||
|
||||
/* initialize PCM subsystem: */
|
||||
err = line6_init_pcm(line6, &pod_pcm_properties);
|
||||
if (err < 0)
|
||||
|
@ -159,7 +159,6 @@ static int variax_init(struct usb_line6 *line6,
|
||||
const struct usb_device_id *id)
|
||||
{
|
||||
struct usb_line6_variax *variax = line6_to_variax(line6);
|
||||
int err;
|
||||
|
||||
line6->process_message = line6_variax_process_message;
|
||||
line6->disconnect = line6_variax_disconnect;
|
||||
@ -172,11 +171,6 @@ static int variax_init(struct usb_line6 *line6,
|
||||
if (variax->buffer_activate == NULL)
|
||||
return -ENOMEM;
|
||||
|
||||
/* initialize MIDI subsystem: */
|
||||
err = line6_init_midi(&variax->line6);
|
||||
if (err < 0)
|
||||
return err;
|
||||
|
||||
/* initiate startup procedure: */
|
||||
schedule_delayed_work(&line6->startup_work,
|
||||
msecs_to_jiffies(VARIAX_STARTUP_DELAY1));
|
||||
|
@ -3060,7 +3060,7 @@ int snd_usb_mixer_apply_create_quirk(struct usb_mixer_interface *mixer)
|
||||
case USB_ID(0x1235, 0x8203): /* Focusrite Scarlett 6i6 2nd Gen */
|
||||
case USB_ID(0x1235, 0x8204): /* Focusrite Scarlett 18i8 2nd Gen */
|
||||
case USB_ID(0x1235, 0x8201): /* Focusrite Scarlett 18i20 2nd Gen */
|
||||
err = snd_scarlett_gen2_controls_create(mixer);
|
||||
err = snd_scarlett_gen2_init(mixer);
|
||||
break;
|
||||
|
||||
case USB_ID(0x041e, 0x323b): /* Creative Sound Blaster E1 */
|
||||
|
@ -635,7 +635,7 @@ static int scarlett2_usb(
|
||||
/* send a second message to get the response */
|
||||
|
||||
err = snd_usb_ctl_msg(mixer->chip->dev,
|
||||
usb_sndctrlpipe(mixer->chip->dev, 0),
|
||||
usb_rcvctrlpipe(mixer->chip->dev, 0),
|
||||
SCARLETT2_USB_VENDOR_SPECIFIC_CMD_RESP,
|
||||
USB_RECIP_INTERFACE | USB_TYPE_CLASS | USB_DIR_IN,
|
||||
0,
|
||||
@ -1997,38 +1997,11 @@ static int scarlett2_mixer_status_create(struct usb_mixer_interface *mixer)
|
||||
return usb_submit_urb(mixer->urb, GFP_KERNEL);
|
||||
}
|
||||
|
||||
/* Entry point */
|
||||
int snd_scarlett_gen2_controls_create(struct usb_mixer_interface *mixer)
|
||||
static int snd_scarlett_gen2_controls_create(struct usb_mixer_interface *mixer,
|
||||
const struct scarlett2_device_info *info)
|
||||
{
|
||||
const struct scarlett2_device_info *info;
|
||||
int err;
|
||||
|
||||
/* only use UAC_VERSION_2 */
|
||||
if (!mixer->protocol)
|
||||
return 0;
|
||||
|
||||
switch (mixer->chip->usb_id) {
|
||||
case USB_ID(0x1235, 0x8203):
|
||||
info = &s6i6_gen2_info;
|
||||
break;
|
||||
case USB_ID(0x1235, 0x8204):
|
||||
info = &s18i8_gen2_info;
|
||||
break;
|
||||
case USB_ID(0x1235, 0x8201):
|
||||
info = &s18i20_gen2_info;
|
||||
break;
|
||||
default: /* device not (yet) supported */
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
if (!(mixer->chip->setup & SCARLETT2_ENABLE)) {
|
||||
usb_audio_err(mixer->chip,
|
||||
"Focusrite Scarlett Gen 2 Mixer Driver disabled; "
|
||||
"use options snd_usb_audio device_setup=1 "
|
||||
"to enable and report any issues to g@b4.vu");
|
||||
return 0;
|
||||
}
|
||||
|
||||
/* Initialise private data, routing, sequence number */
|
||||
err = scarlett2_init_private(mixer, info);
|
||||
if (err < 0)
|
||||
@ -2073,3 +2046,51 @@ int snd_scarlett_gen2_controls_create(struct usb_mixer_interface *mixer)
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
int snd_scarlett_gen2_init(struct usb_mixer_interface *mixer)
|
||||
{
|
||||
struct snd_usb_audio *chip = mixer->chip;
|
||||
const struct scarlett2_device_info *info;
|
||||
int err;
|
||||
|
||||
/* only use UAC_VERSION_2 */
|
||||
if (!mixer->protocol)
|
||||
return 0;
|
||||
|
||||
switch (chip->usb_id) {
|
||||
case USB_ID(0x1235, 0x8203):
|
||||
info = &s6i6_gen2_info;
|
||||
break;
|
||||
case USB_ID(0x1235, 0x8204):
|
||||
info = &s18i8_gen2_info;
|
||||
break;
|
||||
case USB_ID(0x1235, 0x8201):
|
||||
info = &s18i20_gen2_info;
|
||||
break;
|
||||
default: /* device not (yet) supported */
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
if (!(chip->setup & SCARLETT2_ENABLE)) {
|
||||
usb_audio_info(chip,
|
||||
"Focusrite Scarlett Gen 2 Mixer Driver disabled; "
|
||||
"use options snd_usb_audio vid=0x%04x pid=0x%04x "
|
||||
"device_setup=1 to enable and report any issues "
|
||||
"to g@b4.vu",
|
||||
USB_ID_VENDOR(chip->usb_id),
|
||||
USB_ID_PRODUCT(chip->usb_id));
|
||||
return 0;
|
||||
}
|
||||
|
||||
usb_audio_info(chip,
|
||||
"Focusrite Scarlett Gen 2 Mixer Driver enabled pid=0x%04x",
|
||||
USB_ID_PRODUCT(chip->usb_id));
|
||||
|
||||
err = snd_scarlett_gen2_controls_create(mixer, info);
|
||||
if (err < 0)
|
||||
usb_audio_err(mixer->chip,
|
||||
"Error initialising Scarlett Mixer Driver: %d",
|
||||
err);
|
||||
|
||||
return err;
|
||||
}
|
||||
|
@ -2,6 +2,6 @@
|
||||
#ifndef __USB_MIXER_SCARLETT_GEN2_H
|
||||
#define __USB_MIXER_SCARLETT_GEN2_H
|
||||
|
||||
int snd_scarlett_gen2_controls_create(struct usb_mixer_interface *mixer);
|
||||
int snd_scarlett_gen2_init(struct usb_mixer_interface *mixer);
|
||||
|
||||
#endif /* __USB_MIXER_SCARLETT_GEN2_H */
|
||||
|
Loading…
Reference in New Issue
Block a user