summaryrefslogtreecommitdiffstats
path: root/sound/soc/intel/common/sst-acpi.h
AgeCommit message (Collapse)AuthorFilesLines
2017-10-21ASoC: move ACPI common code out of Intel/sst treePierre-Louis Bossart1-82/+0
ACPI support is not specific to the Intel/SST driver. Move the enumeration and matching code which is not hardware-dependent to sound/soc and rename relevant sst_acpi_ structures and functions with snd_soc_acpi_ prefix soc-acpi.h is protected by a #ifndef __LINUX_SND_SOC_ACPI_H for consistency with all other SoC .h files: grep -L __LINUX include/sound/soc* | wc -l 0 grep __LINUX include/sound/soc* | wc -l 14 Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Acked-by: Liam Girdwood <liam.r.girdwood@linux.intel.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2017-05-24ASoC: Improve machine driver selection based on quirk dataNaveen M1-0/+20
Use quirk function to select the correct machine driver by checking all codecs instead of only one based on quirk data. Signed-off-by: Naveen M <naveen.m@intel.com> Signed-off-by: Harsha Priya <harshapriya.n@intel.com> Acked-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2017-05-24ASoC: Intel: Create a helper to search for matching machineNaveen M1-0/+3
Create a helper function to search for a matching machine based on HID. No functional change Signed-off-by: Naveen M <naveen.m@intel.com> Signed-off-by: Harsha Priya <harshapriya.n@intel.com> Acked-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2016-11-13ASoC: Intel: common: add ACPI package extraction utilityPierre-Louis Bossart1-1/+16
Add a new common routine to extract a package exposed by a device indexed with the HID value. The functionality is implemented without assumptions on the package type or structure to allow for reuse. The caller is responsible for defining the name and allocating structures to store the results, ACPICA will complain in case of type mismatches or buffer size issues. Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2016-10-11treewide: remove redundant #include <linux/kconfig.h>Masahiro Yamada1-1/+0
Kernel source files need not include <linux/kconfig.h> explicitly because the top Makefile forces to include it with: -include $(srctree)/include/linux/kconfig.h This commit removes explicit includes except the following: * arch/s390/include/asm/facilities_src.h * tools/testing/radix-tree/linux/kernel.h These two are used for host programs. Link: http://lkml.kernel.org/r/1473656164-11929-1-git-send-email-yamada.masahiro@socionext.com Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2016-07-08ASoC: Intel: Atom: Add quirk for Surface 3Vinod Koul1-1/+1
Surface 3 is CHT based device which shows up with RT5645 codec. But the BIOS reports ACPI ID as 5640! To solve this, add a DMI overide for cht-5640 machine. Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=98001 Signed-off-by: Sachin Mokashi <sachinx.mokashi@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2016-05-30ASoC: intel: make function stub staticRandy Dunlap1-1/+1
This function stub should have been 'static' in the original patch so that multiple uses of the header file (in different drivers) will not cause multiple function definitions. sound/soc/intel/boards/built-in.o: In function `sst_acpi_find_name_from_hid': (.text+0x560): multiple definition of `sst_acpi_find_name_from_hid' sound/soc/intel/atom/built-in.o:(.text+0x10610): first defined here ../scripts/Makefile.build:369: recipe for target 'sound/soc/intel/built-in.o' failed Fixes: f17131a93f43: add function stub when ACPI is not enabled Signed-off-by: Randy Dunlap <rdunlap@infradead.org> Signed-off-by: Mark Brown <broonie@kernel.org>
2016-03-30ASoC: intel: add function stub when ACPI is not enabledRandy Dunlap1-0/+9
Add function stub for "sst_acpi_find_name_from_hid()" when CONFIG_ACPI is not enabled so that the driver will build successfully. This fixes the following build errors: (loadable module) ERROR: "sst_acpi_find_name_from_hid" [sound/soc/intel/boards/snd-soc-sst-bytcr-rt5640.ko] undefined! (or built-in) bytcr_rt5640.c:(.text+0x26fc52): undefined reference to `sst_acpi_find_name_from_hid' Reported-by: Borislav Petkov <bp@alien8.de> Signed-off-by: Randy Dunlap <rdunlap@infradead.org> Signed-off-by: Mark Brown <broonie@kernel.org>
2016-03-05ASoC: Intel: common: add translation from HID to codec-namePierre-Louis Bossart1-0/+3
BIOS vendors sometimes declare multiple devices in the DSDT table that all refer to the same HID. This is not very smart but not illegal as long as only one device reports present with the _STA method. The ACPI subsystem tracks each device with an extension, e.g. 10EC5640:00 and 10EC5640:01 In the ASoC machine driver, the DAI codec name needs to refer to the ACPI device that reported present, e.g. "i2c-10EC5640:01". The extension will vary depending on how the BIOS is written and which ACPI device is activated. This patch adds a translation function that provides the codec name from the ACPI HID to avoid any hard-coded values in the machine driver. Suggested-by: Mika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2015-11-16ASoC: Intel: Atom: move atom driver to common acpi matchVinod Koul1-0/+5
This patch moves the atom driver to use the common acpi match functions. Since atom driver has few more information in machine table, these are appended to table and set to NULL for common driver Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2015-11-16ASoC: Intel: Move apci find machine routinesVinod Koul1-0/+28
This code to find the machine is common for all drivers so move it to a separate file and header for use in other drivers Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org>