Skip to content

Commit

Permalink
Merge tag 'sound-5.9-rc4' of git://git.kernel.org/pub/scm/linux/kerne…
Browse files Browse the repository at this point in the history
…l/git/tiwai/sound

Pull sound fixes from Takashi Iwai:
 "A collection of small changes, nothing intrusive:

   - remaining tasklet API conversions, now all sound stuff have been
     converted

   - a few HD-audio and USB-audio quirks and minor fixes

   - FireWire Tascam and Digi00xx fixes

   - drop a kernel WARNING from PCM OSS for syzkaller"

* tag 'sound-5.9-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound: (29 commits)
  ALSA: hda/realtek - Improved routing for Thinkpad X1 7th/8th Gen
  ALSA: hda: use consistent HDAudio spelling in comments/docs
  ALSA: hda: add dev_dbg log when driver is not selected
  ALSA: hda: fix a runtime pm issue in SOF when integrated GPU is disabled
  ALSA: hda: hdmi - add Rocketlake support
  ALSA: ua101: convert tasklets to use new tasklet_setup() API
  ALSA: usb-audio: convert tasklets to use new tasklet_setup() API
  ASoC: txx9: convert tasklets to use new tasklet_setup() API
  ASoC: siu: convert tasklets to use new tasklet_setup() API
  ASoC: fsl_esai: convert tasklets to use new tasklet_setup() API
  ALSA: hdsp: convert tasklets to use new tasklet_setup() API
  ALSA: riptide: convert tasklets to use new tasklet_setup() API
  ALSA: pci/asihpi: convert tasklets to use new tasklet_setup() API
  ALSA: firewire: convert tasklets to use new tasklet_setup() API
  ALSA: core: convert tasklets to use new tasklet_setup() API
  ALSA: pcm: oss: Remove superfluous WARN_ON() for mulaw sanity check
  ALSA: hda - Fix silent audio output and corrupted input on MSI X570-A PRO
  ALSA: hda/hdmi: always check pin power status in i915 pin fixup
  ALSA: hda/realtek: Add quirk for Samsung Galaxy Book Ion NT950XCJ-X716A
  ALSA: usb-audio: Add basic capture support for Pioneer DJ DJM-250MK2
  ...
  • Loading branch information
torvalds committed Sep 4, 2020
2 parents cf85f5d + 6a6660d commit 86edf52
Show file tree
Hide file tree
Showing 29 changed files with 227 additions and 78 deletions.
2 changes: 1 addition & 1 deletion Documentation/sound/cards/audigy-mixer.rst
Original file line number Diff line number Diff line change
Expand Up @@ -332,7 +332,7 @@ WO 9901953 (A1)


US Patents (https://www.uspto.gov/)
----------------------------------
-----------------------------------

US 5925841
Digital Sampling Instrument employing cache memory (Jul. 20, 1999)
Expand Down
2 changes: 1 addition & 1 deletion Documentation/sound/cards/sb-live-mixer.rst
Original file line number Diff line number Diff line change
Expand Up @@ -337,7 +337,7 @@ WO 9901953 (A1)


US Patents (https://www.uspto.gov/)
----------------------------------
-----------------------------------

US 5925841
Digital Sampling Instrument employing cache memory (Jul. 20, 1999)
Expand Down
2 changes: 1 addition & 1 deletion Documentation/sound/designs/timestamping.rst
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ timestamp shows when the information is put together by the driver
before returning from the ``STATUS`` and ``STATUS_EXT`` ioctl. in most cases
this driver_timestamp will be identical to the regular system tstamp.

Examples of typestamping with HDaudio:
Examples of timestamping with HDAudio:

1. DMA timestamp, no compensation for DMA+analog delay
::
Expand Down
4 changes: 2 additions & 2 deletions sound/core/oss/mulaw.c
Original file line number Diff line number Diff line change
Expand Up @@ -329,8 +329,8 @@ int snd_pcm_plugin_build_mulaw(struct snd_pcm_substream *plug,
snd_BUG();
return -EINVAL;
}
if (snd_BUG_ON(!snd_pcm_format_linear(format->format)))
return -ENXIO;
if (!snd_pcm_format_linear(format->format))
return -EINVAL;

err = snd_pcm_plugin_build(plug, "Mu-Law<->linear conversion",
src_format, dst_format,
Expand Down
7 changes: 3 additions & 4 deletions sound/core/timer.c
Original file line number Diff line number Diff line change
Expand Up @@ -816,9 +816,9 @@ static void snd_timer_clear_callbacks(struct snd_timer *timer,
* timer tasklet
*
*/
static void snd_timer_tasklet(unsigned long arg)
static void snd_timer_tasklet(struct tasklet_struct *t)
{
struct snd_timer *timer = (struct snd_timer *) arg;
struct snd_timer *timer = from_tasklet(timer, t, task_queue);
unsigned long flags;

if (timer->card && timer->card->shutdown) {
Expand Down Expand Up @@ -967,8 +967,7 @@ int snd_timer_new(struct snd_card *card, char *id, struct snd_timer_id *tid,
INIT_LIST_HEAD(&timer->ack_list_head);
INIT_LIST_HEAD(&timer->sack_list_head);
spin_lock_init(&timer->lock);
tasklet_init(&timer->task_queue, snd_timer_tasklet,
(unsigned long)timer);
tasklet_setup(&timer->task_queue, snd_timer_tasklet);
timer->max_instances = 1000; /* default limit per timer */
if (card != NULL) {
timer->module = card->module;
Expand Down
8 changes: 4 additions & 4 deletions sound/firewire/amdtp-stream.c
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
#define IT_PKT_HEADER_SIZE_CIP 8 // For 2 CIP header.
#define IT_PKT_HEADER_SIZE_NO_CIP 0 // Nothing.

static void pcm_period_tasklet(unsigned long data);
static void pcm_period_tasklet(struct tasklet_struct *t);

/**
* amdtp_stream_init - initialize an AMDTP stream structure
Expand Down Expand Up @@ -94,7 +94,7 @@ int amdtp_stream_init(struct amdtp_stream *s, struct fw_unit *unit,
s->flags = flags;
s->context = ERR_PTR(-1);
mutex_init(&s->mutex);
tasklet_init(&s->period_tasklet, pcm_period_tasklet, (unsigned long)s);
tasklet_setup(&s->period_tasklet, pcm_period_tasklet);
s->packet_index = 0;

init_waitqueue_head(&s->callback_wait);
Expand Down Expand Up @@ -441,9 +441,9 @@ static void update_pcm_pointers(struct amdtp_stream *s,
}
}

static void pcm_period_tasklet(unsigned long data)
static void pcm_period_tasklet(struct tasklet_struct *t)
{
struct amdtp_stream *s = (void *)data;
struct amdtp_stream *s = from_tasklet(s, t, period_tasklet);
struct snd_pcm_substream *pcm = READ_ONCE(s->pcm);

if (pcm)
Expand Down
5 changes: 5 additions & 0 deletions sound/firewire/digi00x/digi00x.c
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ MODULE_LICENSE("GPL v2");
#define VENDOR_DIGIDESIGN 0x00a07e
#define MODEL_CONSOLE 0x000001
#define MODEL_RACK 0x000002
#define SPEC_VERSION 0x000001

static int name_card(struct snd_dg00x *dg00x)
{
Expand Down Expand Up @@ -175,14 +176,18 @@ static const struct ieee1394_device_id snd_dg00x_id_table[] = {
/* Both of 002/003 use the same ID. */
{
.match_flags = IEEE1394_MATCH_VENDOR_ID |
IEEE1394_MATCH_VERSION |
IEEE1394_MATCH_MODEL_ID,
.vendor_id = VENDOR_DIGIDESIGN,
.version = SPEC_VERSION,
.model_id = MODEL_CONSOLE,
},
{
.match_flags = IEEE1394_MATCH_VENDOR_ID |
IEEE1394_MATCH_VERSION |
IEEE1394_MATCH_MODEL_ID,
.vendor_id = VENDOR_DIGIDESIGN,
.version = SPEC_VERSION,
.model_id = MODEL_RACK,
},
{}
Expand Down
33 changes: 29 additions & 4 deletions sound/firewire/tascam/tascam.c
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,6 @@ static const struct snd_tscm_spec model_specs[] = {
.midi_capture_ports = 2,
.midi_playback_ports = 4,
},
// This kernel module doesn't support FE-8 because the most of features
// can be implemented in userspace without any specific support of this
// module.
};

static int identify_model(struct snd_tscm *tscm)
Expand Down Expand Up @@ -211,11 +208,39 @@ static void snd_tscm_remove(struct fw_unit *unit)
}

static const struct ieee1394_device_id snd_tscm_id_table[] = {
// Tascam, FW-1884.
{
.match_flags = IEEE1394_MATCH_VENDOR_ID |
IEEE1394_MATCH_SPECIFIER_ID |
IEEE1394_MATCH_VERSION,
.vendor_id = 0x00022e,
.specifier_id = 0x00022e,
.version = 0x800000,
},
// Tascam, FE-8 (.version = 0x800001)
// This kernel module doesn't support FE-8 because the most of features
// can be implemented in userspace without any specific support of this
// module.
//
// .version = 0x800002 is unknown.
//
// Tascam, FW-1082.
{
.match_flags = IEEE1394_MATCH_VENDOR_ID |
IEEE1394_MATCH_SPECIFIER_ID |
IEEE1394_MATCH_VERSION,
.vendor_id = 0x00022e,
.specifier_id = 0x00022e,
.version = 0x800003,
},
// Tascam, FW-1804.
{
.match_flags = IEEE1394_MATCH_VENDOR_ID |
IEEE1394_MATCH_SPECIFIER_ID,
IEEE1394_MATCH_SPECIFIER_ID |
IEEE1394_MATCH_VERSION,
.vendor_id = 0x00022e,
.specifier_id = 0x00022e,
.version = 0x800004,
},
{}
};
Expand Down
2 changes: 2 additions & 0 deletions sound/hda/hdac_device.c
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,8 @@ EXPORT_SYMBOL_GPL(snd_hdac_device_init);
void snd_hdac_device_exit(struct hdac_device *codec)
{
pm_runtime_put_noidle(&codec->dev);
/* keep balance of runtime PM child_count in parent device */
pm_runtime_set_suspended(&codec->dev);
snd_hdac_bus_remove_device(codec->bus, codec);
kfree(codec->vendor_name);
kfree(codec->chip_name);
Expand Down
10 changes: 5 additions & 5 deletions sound/hda/intel-dsp-config.c
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ static const struct config_entry config_table[] = {
#endif
/*
* Apollolake (Broxton-P)
* the legacy HDaudio driver is used except on Up Squared (SOF) and
* the legacy HDAudio driver is used except on Up Squared (SOF) and
* Chromebooks (SST)
*/
#if IS_ENABLED(CONFIG_SND_SOC_SOF_APOLLOLAKE)
Expand Down Expand Up @@ -89,7 +89,7 @@ static const struct config_entry config_table[] = {
},
#endif
/*
* Skylake and Kabylake use legacy HDaudio driver except for Google
* Skylake and Kabylake use legacy HDAudio driver except for Google
* Chromebooks (SST)
*/

Expand Down Expand Up @@ -135,7 +135,7 @@ static const struct config_entry config_table[] = {
#endif

/*
* Geminilake uses legacy HDaudio driver except for Google
* Geminilake uses legacy HDAudio driver except for Google
* Chromebooks
*/
/* Geminilake */
Expand All @@ -157,7 +157,7 @@ static const struct config_entry config_table[] = {

/*
* CoffeeLake, CannonLake, CometLake, IceLake, TigerLake use legacy
* HDaudio driver except for Google Chromebooks and when DMICs are
* HDAudio driver except for Google Chromebooks and when DMICs are
* present. Two cases are required since Coreboot does not expose NHLT
* tables.
*
Expand Down Expand Up @@ -391,7 +391,7 @@ int snd_intel_dsp_driver_probe(struct pci_dev *pci)
if (pci->class == 0x040300)
return SND_INTEL_DSP_DRIVER_LEGACY;
if (pci->class != 0x040100 && pci->class != 0x040380) {
dev_err(&pci->dev, "Unknown PCI class/subclass/prog-if information (0x%06x) found, selecting HDA legacy driver\n", pci->class);
dev_err(&pci->dev, "Unknown PCI class/subclass/prog-if information (0x%06x) found, selecting HDAudio legacy driver\n", pci->class);
return SND_INTEL_DSP_DRIVER_LEGACY;
}

Expand Down
9 changes: 4 additions & 5 deletions sound/pci/asihpi/asihpi.c
Original file line number Diff line number Diff line change
Expand Up @@ -921,10 +921,10 @@ static void snd_card_asihpi_timer_function(struct timer_list *t)
add_timer(&dpcm->timer);
}

static void snd_card_asihpi_int_task(unsigned long data)
static void snd_card_asihpi_int_task(struct tasklet_struct *t)
{
struct hpi_adapter *a = (struct hpi_adapter *)data;
struct snd_card_asihpi *asihpi;
struct snd_card_asihpi *asihpi = from_tasklet(asihpi, t, t);
struct hpi_adapter *a = asihpi->hpi;

WARN_ON(!a || !a->snd_card || !a->snd_card->private_data);
asihpi = (struct snd_card_asihpi *)a->snd_card->private_data;
Expand Down Expand Up @@ -2871,8 +2871,7 @@ static int snd_asihpi_probe(struct pci_dev *pci_dev,
if (hpi->interrupt_mode) {
asihpi->pcm_start = snd_card_asihpi_pcm_int_start;
asihpi->pcm_stop = snd_card_asihpi_pcm_int_stop;
tasklet_init(&asihpi->t, snd_card_asihpi_int_task,
(unsigned long)hpi);
tasklet_setup(&asihpi->t, snd_card_asihpi_int_task);
hpi->interrupt_callback = snd_card_asihpi_isr;
} else {
asihpi->pcm_start = snd_card_asihpi_pcm_timer_start;
Expand Down
3 changes: 2 additions & 1 deletion sound/pci/ca0106/ca0106_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -537,7 +537,8 @@ static int snd_ca0106_pcm_power_dac(struct snd_ca0106 *chip, int channel_id,
else
/* Power down */
chip->spi_dac_reg[reg] |= bit;
return snd_ca0106_spi_write(chip, chip->spi_dac_reg[reg]);
if (snd_ca0106_spi_write(chip, chip->spi_dac_reg[reg]) != 0)
return -ENXIO;
}
return 0;
}
Expand Down
7 changes: 3 additions & 4 deletions sound/pci/hda/hda_intel.c
Original file line number Diff line number Diff line change
Expand Up @@ -2127,9 +2127,10 @@ static int azx_probe(struct pci_dev *pci,
*/
if (dmic_detect) {
err = snd_intel_dsp_driver_probe(pci);
if (err != SND_INTEL_DSP_DRIVER_ANY &&
err != SND_INTEL_DSP_DRIVER_LEGACY)
if (err != SND_INTEL_DSP_DRIVER_ANY && err != SND_INTEL_DSP_DRIVER_LEGACY) {
dev_dbg(&pci->dev, "HDAudio driver not selected, aborting probe\n");
return -ENODEV;
}
} else {
dev_warn(&pci->dev, "dmic_detect option is deprecated, pass snd-intel-dspcfg.dsp_driver=1 option instead\n");
}
Expand Down Expand Up @@ -2745,8 +2746,6 @@ static const struct pci_device_id azx_ids[] = {
.driver_data = AZX_DRIVER_GENERIC | AZX_DCAPS_PRESET_ATI_HDMI },
/* Zhaoxin */
{ PCI_DEVICE(0x1d17, 0x3288), .driver_data = AZX_DRIVER_ZHAOXIN },
/* Loongson */
{ PCI_DEVICE(0x0014, 0x7a07), .driver_data = AZX_DRIVER_GENERIC },
{ 0, }
};
MODULE_DEVICE_TABLE(pci, azx_ids);
Expand Down
7 changes: 7 additions & 0 deletions sound/pci/hda/hda_tegra.c
Original file line number Diff line number Diff line change
Expand Up @@ -179,6 +179,10 @@ static int __maybe_unused hda_tegra_runtime_suspend(struct device *dev)
struct hda_tegra *hda = container_of(chip, struct hda_tegra, chip);

if (chip && chip->running) {
/* enable controller wake up event */
azx_writew(chip, WAKEEN, azx_readw(chip, WAKEEN) |
STATESTS_INT_MASK);

azx_stop_chip(chip);
azx_enter_link_reset(chip);
}
Expand All @@ -200,6 +204,9 @@ static int __maybe_unused hda_tegra_runtime_resume(struct device *dev)
if (chip && chip->running) {
hda_tegra_init(hda);
azx_init_chip(chip, 1);
/* disable controller wake up event*/
azx_writew(chip, WAKEEN, azx_readw(chip, WAKEEN) &
~STATESTS_INT_MASK);
}

return 0;
Expand Down
7 changes: 7 additions & 0 deletions sound/pci/hda/patch_hdmi.c
Original file line number Diff line number Diff line change
Expand Up @@ -2794,6 +2794,7 @@ static void i915_pin_cvt_fixup(struct hda_codec *codec,
hda_nid_t cvt_nid)
{
if (per_pin) {
haswell_verify_D0(codec, per_pin->cvt_nid, per_pin->pin_nid);
snd_hda_set_dev_select(codec, per_pin->pin_nid,
per_pin->dev_id);
intel_verify_pin_cvt_connect(codec, per_pin);
Expand Down Expand Up @@ -3734,13 +3735,18 @@ static int tegra_hdmi_build_pcms(struct hda_codec *codec)

static int patch_tegra_hdmi(struct hda_codec *codec)
{
struct hdmi_spec *spec;
int err;

err = patch_generic_hdmi(codec);
if (err)
return err;

codec->patch_ops.build_pcms = tegra_hdmi_build_pcms;
spec = codec->spec;
spec->chmap.ops.chmap_cea_alloc_validate_get_type =
nvhdmi_chmap_cea_alloc_validate_get_type;
spec->chmap.ops.chmap_validate = nvhdmi_chmap_validate;

return 0;
}
Expand Down Expand Up @@ -4263,6 +4269,7 @@ HDA_CODEC_ENTRY(0x8086280c, "Cannonlake HDMI", patch_i915_glk_hdmi),
HDA_CODEC_ENTRY(0x8086280d, "Geminilake HDMI", patch_i915_glk_hdmi),
HDA_CODEC_ENTRY(0x8086280f, "Icelake HDMI", patch_i915_icl_hdmi),
HDA_CODEC_ENTRY(0x80862812, "Tigerlake HDMI", patch_i915_tgl_hdmi),
HDA_CODEC_ENTRY(0x80862816, "Rocketlake HDMI", patch_i915_tgl_hdmi),
HDA_CODEC_ENTRY(0x8086281a, "Jasperlake HDMI", patch_i915_icl_hdmi),
HDA_CODEC_ENTRY(0x8086281b, "Elkhartlake HDMI", patch_i915_icl_hdmi),
HDA_CODEC_ENTRY(0x80862880, "CedarTrail HDMI", patch_generic_hdmi),
Expand Down
Loading

0 comments on commit 86edf52

Please sign in to comment.