summaryrefslogtreecommitdiff
path: root/sound/soc/intel
diff options
context:
space:
mode:
authorMark Brown <broonie@kernel.org>2018-01-12 12:28:40 +0000
committerMark Brown <broonie@kernel.org>2018-01-12 12:28:40 +0000
commit5b139ebe46092136fe292f433466ac0043695f6c (patch)
tree242a32a826ca1d4e32247c27632524f8a7b73571 /sound/soc/intel
parentb2cd1df66037e7c4697c7e40496bf7e4a5e16a2d (diff)
parent845ab40092601630ec9eb58398a53b9a87b6900b (diff)
downloadlwn-5b139ebe46092136fe292f433466ac0043695f6c.tar.gz
lwn-5b139ebe46092136fe292f433466ac0043695f6c.zip
Merge remote-tracking branch 'asoc/fix/intel' into asoc-linus
Diffstat (limited to 'sound/soc/intel')
-rw-r--r--sound/soc/intel/skylake/skl-nhlt.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sound/soc/intel/skylake/skl-nhlt.c b/sound/soc/intel/skylake/skl-nhlt.c
index 3eaac41090ca..26b0a5caea5a 100644
--- a/sound/soc/intel/skylake/skl-nhlt.c
+++ b/sound/soc/intel/skylake/skl-nhlt.c
@@ -43,7 +43,8 @@ struct nhlt_acpi_table *skl_nhlt_init(struct device *dev)
obj = acpi_evaluate_dsm(handle, &osc_guid, 1, 1, NULL);
if (obj && obj->type == ACPI_TYPE_BUFFER) {
nhlt_ptr = (struct nhlt_resource_desc *)obj->buffer.pointer;
- nhlt_table = (struct nhlt_acpi_table *)
+ if (nhlt_ptr->length)
+ nhlt_table = (struct nhlt_acpi_table *)
memremap(nhlt_ptr->min_addr, nhlt_ptr->length,
MEMREMAP_WB);
ACPI_FREE(obj);