0002-surface3-oemb.patch 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. From e09db7fd5b8a8589a26b618fb1aa8903edc337fc Mon Sep 17 00:00:00 2001
  2. From: Chih-Wei Huang <cwhuang@linux.org.tw>
  3. Date: Tue, 18 Sep 2018 11:01:37 +0800
  4. Subject: [PATCH 2/6] surface3-oemb
  5. ---
  6. drivers/platform/x86/surface3-wmi.c | 7 +++++++
  7. sound/soc/codecs/rt5645.c | 9 +++++++++
  8. sound/soc/intel/common/soc-acpi-intel-cht-match.c | 8 ++++++++
  9. 3 files changed, 24 insertions(+)
  10. diff --git a/drivers/platform/x86/surface3-wmi.c b/drivers/platform/x86/surface3-wmi.c
  11. index 130b6f52a6001..801083aa56d6d 100644
  12. --- a/drivers/platform/x86/surface3-wmi.c
  13. +++ b/drivers/platform/x86/surface3-wmi.c
  14. @@ -37,6 +37,13 @@ static const struct dmi_system_id surface3_dmi_table[] = {
  15. DMI_MATCH(DMI_PRODUCT_NAME, "Surface 3"),
  16. },
  17. },
  18. + {
  19. + .matches = {
  20. + DMI_MATCH(DMI_BIOS_VENDOR, "American Megatrends Inc."),
  21. + DMI_MATCH(DMI_SYS_VENDOR, "OEMB"),
  22. + DMI_MATCH(DMI_PRODUCT_NAME, "OEMB"),
  23. + },
  24. + },
  25. #endif
  26. { }
  27. };
  28. diff --git a/sound/soc/codecs/rt5645.c b/sound/soc/codecs/rt5645.c
  29. index c83f7f5da96b7..e6bfe684d6be8 100644
  30. --- a/sound/soc/codecs/rt5645.c
  31. +++ b/sound/soc/codecs/rt5645.c
  32. @@ -3681,6 +3681,15 @@ static const struct dmi_system_id dmi_platform_data[] = {
  33. },
  34. .driver_data = (void *)&intel_braswell_platform_data,
  35. },
  36. + {
  37. + .ident = "Microsoft Surface 3",
  38. + .matches = {
  39. + DMI_MATCH(DMI_BIOS_VENDOR, "American Megatrends Inc."),
  40. + DMI_MATCH(DMI_SYS_VENDOR, "OEMB"),
  41. + DMI_MATCH(DMI_PRODUCT_NAME, "OEMB"),
  42. + },
  43. + .driver_data = (void *)&intel_braswell_platform_data,
  44. + },
  45. {
  46. /*
  47. * Match for the GPDwin which unfortunately uses somewhat
  48. diff --git a/sound/soc/intel/common/soc-acpi-intel-cht-match.c b/sound/soc/intel/common/soc-acpi-intel-cht-match.c
  49. index d0fb43c2b9f68..0e938713cb133 100644
  50. --- a/sound/soc/intel/common/soc-acpi-intel-cht-match.c
  51. +++ b/sound/soc/intel/common/soc-acpi-intel-cht-match.c
  52. @@ -27,6 +27,14 @@ static const struct dmi_system_id cht_table[] = {
  53. DMI_MATCH(DMI_PRODUCT_NAME, "Surface 3"),
  54. },
  55. },
  56. + {
  57. + .callback = cht_surface_quirk_cb,
  58. + .matches = {
  59. + DMI_MATCH(DMI_BIOS_VENDOR, "American Megatrends Inc."),
  60. + DMI_MATCH(DMI_SYS_VENDOR, "OEMB"),
  61. + DMI_MATCH(DMI_PRODUCT_NAME, "OEMB"),
  62. + },
  63. + },
  64. { }
  65. };
  66. --
  67. 2.28.0