Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b5454432 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull sound fixes from Takashi Iwai:
 "There are a few fixes in ALSA core for bugs that have been spotted by
  fuzzer.  Also a temporary workaround for PowerPC (and possibly other)
  builds with incompatible ioctls was applied to compress API.

  Other than that, a few trivial fixes and quirks for FireWire BeBoB,
  USB-audio and HD-audio are found, too"

* tag 'sound-4.5-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound:
  ALSA: hda - disable dynamic clock gating on Broxton before reset
  ALSA: hda - Add new GPU codec ID 0x10de0083 to snd-hda
  ALSA: dummy: Disable switching timer backend via sysfs
  ALSA: timer: fix SND_PCM_TIMER Kconfig text
  ALSA: Add missing dependency on CONFIG_SND_TIMER
  ALSA: bebob: Use a signed return type for get_formation_index
  ALSA: usb-audio: Fix TEAC UD-501/UD-503/NT-503 usb delay
  ALSA: compress: Disable GET_CODEC_CAPS ioctl for some architectures
  ALSA: seq: Degrade the error message for too many opens
  ALSA: seq: Fix incorrect sanity check at snd_seq_oss_synth_cleanup()
parents b943d0b9 6639484d
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -97,11 +97,11 @@ config SND_PCM_TIMER
	bool "PCM timer interface" if EXPERT
	default y
	help
	  If you disable this option, pcm timer will be inavailable, so
	  those stubs used pcm timer (e.g. dmix, dsnoop & co) may work
	  If you disable this option, pcm timer will be unavailable, so
	  those stubs that use pcm timer (e.g. dmix, dsnoop & co) may work
	  incorrectlly.

	  For some embedded device, we may disable it to reduce memory
	  For some embedded devices, we may disable it to reduce memory
	  footprint, about 20KB on x86_64 platform.

config SND_SEQUENCER_OSS
+11 −0
Original line number Diff line number Diff line
@@ -46,6 +46,13 @@
#include <sound/compress_offload.h>
#include <sound/compress_driver.h>

/* struct snd_compr_codec_caps overflows the ioctl bit size for some
 * architectures, so we need to disable the relevant ioctls.
 */
#if _IOC_SIZEBITS < 14
#define COMPR_CODEC_CAPS_OVERFLOW
#endif

/* TODO:
 * - add substream support for multiple devices in case of
 *	SND_DYNAMIC_MINORS is not used
@@ -440,6 +447,7 @@ snd_compr_get_caps(struct snd_compr_stream *stream, unsigned long arg)
	return retval;
}

#ifndef COMPR_CODEC_CAPS_OVERFLOW
static int
snd_compr_get_codec_caps(struct snd_compr_stream *stream, unsigned long arg)
{
@@ -463,6 +471,7 @@ snd_compr_get_codec_caps(struct snd_compr_stream *stream, unsigned long arg)
	kfree(caps);
	return retval;
}
#endif /* !COMPR_CODEC_CAPS_OVERFLOW */

/* revisit this with snd_pcm_preallocate_xxx */
static int snd_compr_allocate_buffer(struct snd_compr_stream *stream,
@@ -801,9 +810,11 @@ static long snd_compr_ioctl(struct file *f, unsigned int cmd, unsigned long arg)
	case _IOC_NR(SNDRV_COMPRESS_GET_CAPS):
		retval = snd_compr_get_caps(stream, arg);
		break;
#ifndef COMPR_CODEC_CAPS_OVERFLOW
	case _IOC_NR(SNDRV_COMPRESS_GET_CODEC_CAPS):
		retval = snd_compr_get_codec_caps(stream, arg);
		break;
#endif
	case _IOC_NR(SNDRV_COMPRESS_SET_PARAMS):
		retval = snd_compr_set_params(stream, arg);
		break;
+1 −1
Original line number Diff line number Diff line
@@ -202,7 +202,7 @@ snd_seq_oss_open(struct file *file, int level)

	dp->index = i;
	if (i >= SNDRV_SEQ_OSS_MAX_CLIENTS) {
		pr_err("ALSA: seq_oss: too many applications\n");
		pr_debug("ALSA: seq_oss: too many applications\n");
		rc = -ENOMEM;
		goto _error;
	}
+1 −1
Original line number Diff line number Diff line
@@ -308,7 +308,7 @@ snd_seq_oss_synth_cleanup(struct seq_oss_devinfo *dp)
	struct seq_oss_synth *rec;
	struct seq_oss_synthinfo *info;

	if (snd_BUG_ON(dp->max_synthdev >= SNDRV_SEQ_OSS_MAX_SYNTH_DEVS))
	if (snd_BUG_ON(dp->max_synthdev > SNDRV_SEQ_OSS_MAX_SYNTH_DEVS))
		return;
	for (i = 0; i < dp->max_synthdev; i++) {
		info = &dp->synths[i];
+1 −1
Original line number Diff line number Diff line
@@ -87,7 +87,7 @@ MODULE_PARM_DESC(pcm_substreams, "PCM substreams # (1-128) for dummy driver.");
module_param(fake_buffer, bool, 0444);
MODULE_PARM_DESC(fake_buffer, "Fake buffer allocations.");
#ifdef CONFIG_HIGH_RES_TIMERS
module_param(hrtimer, bool, 0644);
module_param(hrtimer, bool, 0444);
MODULE_PARM_DESC(hrtimer, "Use hrtimer as the timer source.");
#endif

Loading