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

Commit 81a6cff6 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6:
  ASoC: tpa6130a2: Get rid of compile warning from tpa6130a2_power
  ALSA: hda - MacBookAir3,1(3,2) alsa support
  ASoC: fix the building issue of missing codec field in 'struct snd_soc_card'
  ALSA: usb-audio - Support for Power/Status LED on Creative USB X-Fi S51
  ALSA: asihpi - Unsafe memory management when allocating control cache
  ASoC: Update WARN uses in wm_hubs
  ASoC: Include cx20442 to SND_SOC_ALL_CODECS
  ASoC: Fix SND_SOC_ALL_CODECS typo for jz4740
  ASoC: Remove volatility from WM8900 POWER1 register
  ALSA: lx6464es - make 1 bit signed bitfield unsigned
  ALSA: cs46xx memory management fixes for cs46xx_dsp_spos_create()
  ALSA: usb - driver neglects kmalloc return value check and may deref NULL
  ASoC: tpa6130a2: Fix unbalanced regulator disables
  ASoC: tlv320dac33: Mode1 FIFO auto configuration fix
  ASoC: tlv320dac33: Limit the US_TO_SAMPLES macro
  ASoC: tlv320dac33: Error handling for broken chip
  ASoC: Check return value of struct_strtoul() in pmdown_time_set()
parents d88c0922 69dbdd81
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -625,6 +625,8 @@ static short create_adapter_obj(struct hpi_adapter_obj *pao,
			control_cache_size, (struct hpi_control_cache_info *)
			&phw->control_cache[0]
			);
		if (!phw->p_cache)
			pao->has_control_cache = 0;
	} else
		pao->has_control_cache = 0;

+2 −0
Original line number Diff line number Diff line
@@ -644,6 +644,8 @@ static u16 create_adapter_obj(struct hpi_adapter_obj *pao,
				interface->control_cache.size_in_bytes,
				(struct hpi_control_cache_info *)
				p_control_cache_virtual);
			if (!phw->p_cache)
				err = HPI_ERROR_MEMORY_ALLOC;
		}
		if (!err) {
			err = hpios_locked_mem_get_phys_addr(&phw->
+9 −3
Original line number Diff line number Diff line
@@ -571,14 +571,20 @@ struct hpi_control_cache *hpi_alloc_control_cache(const u32
{
	struct hpi_control_cache *p_cache =
		kmalloc(sizeof(*p_cache), GFP_KERNEL);
	if (!p_cache)
		return NULL;
	p_cache->p_info =
		kmalloc(sizeof(*p_cache->p_info) * number_of_controls,
			GFP_KERNEL);
	if (!p_cache->p_info) {
		kfree(p_cache);
		return NULL;
	}
	p_cache->cache_size_in_bytes = size_in_bytes;
	p_cache->control_count = number_of_controls;
	p_cache->p_cache =
		(struct hpi_control_cache_single *)pDSP_control_buffer;
	p_cache->init = 0;
	p_cache->p_info =
		kmalloc(sizeof(*p_cache->p_info) * p_cache->control_count,
		GFP_KERNEL);
	return p_cache;
}

+11 −22
Original line number Diff line number Diff line
@@ -229,35 +229,21 @@ struct dsp_spos_instance *cs46xx_dsp_spos_create (struct snd_cs46xx * chip)
		return NULL;

	/* better to use vmalloc for this big table */
	ins->symbol_table.nsymbols = 0;
	ins->symbol_table.symbols = vmalloc(sizeof(struct dsp_symbol_entry) *
					    DSP_MAX_SYMBOLS);
	ins->symbol_table.highest_frag_index = 0;

	if (ins->symbol_table.symbols == NULL) {
	ins->code.data = kmalloc(DSP_CODE_BYTE_SIZE, GFP_KERNEL);
	ins->modules = kmalloc(sizeof(struct dsp_module_desc) * DSP_MAX_MODULES, GFP_KERNEL);
	if (!ins->symbol_table.symbols || !ins->code.data || !ins->modules) {
		cs46xx_dsp_spos_destroy(chip);
		goto error;
	}

	ins->symbol_table.nsymbols = 0;
	ins->symbol_table.highest_frag_index = 0;
	ins->code.offset = 0;
	ins->code.size = 0;
	ins->code.data = kmalloc(DSP_CODE_BYTE_SIZE, GFP_KERNEL);

	if (ins->code.data == NULL) {
		cs46xx_dsp_spos_destroy(chip);
		goto error;
	}

	ins->nscb = 0;
	ins->ntask = 0;

	ins->nmodules = 0;
	ins->modules = kmalloc(sizeof(struct dsp_module_desc) * DSP_MAX_MODULES, GFP_KERNEL);

	if (ins->modules == NULL) {
		cs46xx_dsp_spos_destroy(chip);
		goto error;
	}

	/* default SPDIF input sample rate
	   to 48000 khz */
@@ -281,6 +267,9 @@ struct dsp_spos_instance *cs46xx_dsp_spos_create (struct snd_cs46xx * chip)
	return ins;

error:
	kfree(ins->modules);
	kfree(ins->code.data);
	vfree(ins->symbol_table.symbols);
	kfree(ins);
	return NULL;
}
+1 −0
Original line number Diff line number Diff line
@@ -1166,6 +1166,7 @@ static const char *cs420x_models[CS420X_MODELS] = {

static struct snd_pci_quirk cs420x_cfg_tbl[] = {
	SND_PCI_QUIRK(0x10de, 0x0ac0, "MacBookPro 5,3", CS420X_MBP53),
	SND_PCI_QUIRK(0x10de, 0x0d94, "MacBookAir 3,1(2)", CS420X_MBP55),
	SND_PCI_QUIRK(0x10de, 0xcb79, "MacBookPro 5,5", CS420X_MBP55),
	SND_PCI_QUIRK(0x10de, 0xcb89, "MacBookPro 7,1", CS420X_MBP55),
	SND_PCI_QUIRK(0x8086, 0x7270, "IMac 27 Inch", CS420X_IMAC27),
Loading