linux-brain/sound/hda
Mark Pearson 537653a069 ALSA: hda: ignore invalid NHLT table
[ Upstream commit a14a6219996ee6f6e858d83b11affc7907633687 ]

On some Lenovo systems if the microphone is disabled in the BIOS
only the NHLT table header is created, with no data. This means
the endpoints field is not correctly set to zero - leading to an
unintialised variable and hence invalid descriptors are parsed
leading to page faults.

The Lenovo firmware team is addressing this, but adding a check
preventing invalid tables being parsed is worthwhile.

Tested on a Lenovo T14.

Tested-by: Philipp Leskovitz <philipp.leskovitz@secunet.com>
Reported-by: Philipp Leskovitz <philipp.leskovitz@secunet.com>
Signed-off-by: Mark Pearson <markpearson@lenovo.com>
Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/20210302141003.7342-1-markpearson@lenovo.com
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2021-03-30 14:35:20 +02:00
..
ext ALSA: hda: prevent undefined shift in snd_hdac_ext_bus_get_link() 2020-11-18 19:20:18 +01:00
Kconfig Merge branch 'topic/hda-bus-ops-cleanup' into for-next 2019-08-08 22:35:44 +02:00
Makefile ALSA: hda: move parts of NHLT code to new module 2019-07-31 15:45:59 +02:00
array.c treewide: Add SPDX license identifier for missed files 2019-05-21 10:50:45 +02:00
hda_bus_type.c treewide: Add SPDX license identifier for more missed files 2019-05-21 10:50:45 +02:00
hdac_bus.c ALSA: hda: Fix potential race in unsol event handler 2020-10-01 13:18:00 +02:00
hdac_component.c Linux 5.1-rc5 2019-04-15 15:51:49 +10:00
hdac_controller.c Revert "ALSA: hda: Flush interrupts on disabling" 2019-10-28 11:47:59 +01:00
hdac_device.c ALSA: hda: fix a runtime pm issue in SOF when integrated GPU is disabled 2020-09-17 13:47:49 +02:00
hdac_i915.c ALSA: hda: Fix 1-minute detection delay when i915 module is not available 2019-07-27 08:31:46 +02:00
hdac_regmap.c ALSA: hda: enable regmap internal locking 2020-10-01 13:17:24 +02:00
hdac_stream.c ALSA: hda: Fix regression by strip mask fix 2019-12-21 11:05:23 +01:00
hdac_sysfs.c ALSA: hda: Simplify snd_hdac_refresh_widgets() 2019-07-05 12:01:06 +02:00
hdmi_chmap.c ALSA: hda: Use scnprintf() for printing texts for sysfs/procfs 2020-02-28 17:22:12 +01:00
intel-nhlt.c ALSA: hda: ignore invalid NHLT table 2021-03-30 14:35:20 +02:00
local.h ALSA: hda: Unexport a few more stuff 2019-08-14 20:00:56 +02:00
trace.c ALSA: hda - Re-add tracepoints to HD-audio core driver 2015-03-23 13:17:58 +01:00
trace.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00