Commit 01f15f37 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull sound fixes from Takashi Iwai:
 "Only a few regression fixes and trivial device quirks"

* tag 'sound-5.14-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound:
  ALSA: hda/via: Apply runtime PM workaround for ASUS B23E
  ALSA: hda: Fix hang during shutdown due to link reset
  ALSA: hda/realtek: Enable 4-speaker output for Dell XPS 15 9510 laptop
  ALSA: oxfw: fix functioal regression for silence in Apogee Duet FireWire
  ALSA: hda - fix the 'Capture Switch' value change notifications
parents a83955bd 4bf61ad5
Loading
Loading
Loading
Loading
+8 −1
Original line number Diff line number Diff line
@@ -153,7 +153,7 @@ static int init_stream(struct snd_oxfw *oxfw, struct amdtp_stream *stream)
	struct cmp_connection *conn;
	enum cmp_direction c_dir;
	enum amdtp_stream_direction s_dir;
	unsigned int flags = CIP_UNAWARE_SYT;
	unsigned int flags = 0;
	int err;

	if (!(oxfw->quirks & SND_OXFW_QUIRK_BLOCKING_TRANSMISSION))
@@ -161,6 +161,13 @@ static int init_stream(struct snd_oxfw *oxfw, struct amdtp_stream *stream)
	else
		flags |= CIP_BLOCKING;

	// OXFW 970/971 has no function to generate playback timing according to the sequence
	// of value in syt field, thus the packet should include NO_INFO value in the field.
	// However, some models just ignore data blocks in packet with NO_INFO for audio data
	// processing.
	if (!(oxfw->quirks & SND_OXFW_QUIRK_IGNORE_NO_INFO_PACKET))
		flags |= CIP_UNAWARE_SYT;

	if (stream == &oxfw->tx_stream) {
		conn = &oxfw->out_conn;
		c_dir = CMP_OUTPUT;
+4 −2
Original line number Diff line number Diff line
@@ -159,8 +159,10 @@ static int detect_quirks(struct snd_oxfw *oxfw, const struct ieee1394_device_id
		return snd_oxfw_scs1x_add(oxfw);
	}

	if (entry->vendor_id == OUI_APOGEE && entry->model_id == MODEL_DUET_FW)
		oxfw->quirks |= SND_OXFW_QUIRK_BLOCKING_TRANSMISSION;
	if (entry->vendor_id == OUI_APOGEE && entry->model_id == MODEL_DUET_FW) {
		oxfw->quirks |= SND_OXFW_QUIRK_BLOCKING_TRANSMISSION |
				SND_OXFW_QUIRK_IGNORE_NO_INFO_PACKET;
	}

	/*
	 * TASCAM FireOne has physical control and requires a pair of additional
+5 −0
Original line number Diff line number Diff line
@@ -42,6 +42,11 @@ enum snd_oxfw_quirk {
	SND_OXFW_QUIRK_BLOCKING_TRANSMISSION = 0x04,
	// Stanton SCS1.d and SCS1.m support unique transaction.
	SND_OXFW_QUIRK_SCS_TRANSACTION = 0x08,
	// Apogee Duet FireWire ignores data blocks in packet with NO_INFO for audio data
	// processing, while output level meter moves. Any value in syt field of packet takes
	// the device to process audio data even if the value is invalid in a point of
	// IEC 61883-1/6.
	SND_OXFW_QUIRK_IGNORE_NO_INFO_PACKET = 0x10,
};

/* This is an arbitrary number for convinience. */
+7 −3
Original line number Diff line number Diff line
@@ -3460,7 +3460,7 @@ static int cap_put_caller(struct snd_kcontrol *kcontrol,
	struct hda_gen_spec *spec = codec->spec;
	const struct hda_input_mux *imux;
	struct nid_path *path;
	int i, adc_idx, err = 0;
	int i, adc_idx, ret, err = 0;

	imux = &spec->input_mux;
	adc_idx = kcontrol->id.index;
@@ -3470,10 +3470,14 @@ static int cap_put_caller(struct snd_kcontrol *kcontrol,
		if (!path || !path->ctls[type])
			continue;
		kcontrol->private_value = path->ctls[type];
		err = func(kcontrol, ucontrol);
		if (err < 0)
		ret = func(kcontrol, ucontrol);
		if (ret < 0) {
			err = ret;
			break;
		}
		if (ret > 0)
			err = 1;
	}
	mutex_unlock(&codec->control_mutex);
	if (err >= 0 && spec->cap_sync_hook)
		spec->cap_sync_hook(codec, kcontrol, ucontrol);
+9 −3
Original line number Diff line number Diff line
@@ -883,9 +883,10 @@ static unsigned int azx_get_pos_skl(struct azx *chip, struct azx_dev *azx_dev)
	return azx_get_pos_posbuf(chip, azx_dev);
}

static void azx_shutdown_chip(struct azx *chip)
static void __azx_shutdown_chip(struct azx *chip, bool skip_link_reset)
{
	azx_stop_chip(chip);
	if (!skip_link_reset)
		azx_enter_link_reset(chip);
	azx_clear_irq_pending(chip);
	display_power(chip, false);
@@ -895,6 +896,11 @@ static void azx_shutdown_chip(struct azx *chip)
static DEFINE_MUTEX(card_list_lock);
static LIST_HEAD(card_list);

static void azx_shutdown_chip(struct azx *chip)
{
	__azx_shutdown_chip(chip, false);
}

static void azx_add_card_list(struct azx *chip)
{
	struct hda_intel *hda = container_of(chip, struct hda_intel, chip);
@@ -2385,7 +2391,7 @@ static void azx_shutdown(struct pci_dev *pci)
		return;
	chip = card->private_data;
	if (chip && chip->running)
		azx_shutdown_chip(chip);
		__azx_shutdown_chip(chip, true);
}

/* PCI IDs */
Loading