From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.7 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 39FE6C2BA19 for ; Wed, 15 Apr 2020 14:56:17 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 1E313214D8 for ; Wed, 15 Apr 2020 14:56:17 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S371137AbgDOO4O (ORCPT ); Wed, 15 Apr 2020 10:56:14 -0400 Received: from mga07.intel.com ([134.134.136.100]:57046 "EHLO mga07.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S371082AbgDOOzr (ORCPT ); Wed, 15 Apr 2020 10:55:47 -0400 IronPort-SDR: h+BuQwEpK5baNWeggaqlnSKMgZi+JTbcQjfO9KstNc9BPanuBF084AjqaMeU9ErlJ8YHfdoJyQ 8uk/n+ea5AxA== X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 15 Apr 2020 07:55:46 -0700 IronPort-SDR: YMknequTHuJ5gH68ECaixFGpOMMezScX1cOg6clpO32nbcExs4hTQ4Xg3yuSJmGIjUAvkSYi3S ouYhENvLTylA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.72,387,1580803200"; d="scan'208";a="454934621" Received: from black.fi.intel.com ([10.237.72.28]) by fmsmga006.fm.intel.com with ESMTP; 15 Apr 2020 07:55:43 -0700 Received: by black.fi.intel.com (Postfix, from userid 1003) id 58DB8C4E; Wed, 15 Apr 2020 17:55:40 +0300 (EEST) From: Andy Shevchenko To: Thomas Gleixner , Ingo Molnar , Borislav Petkov , "H. Peter Anvin" , x86@kernel.org, Mark Brown , linux-kernel@vger.kernel.org Cc: Andy Shevchenko , Cezary Rojewski , Pierre-Louis Bossart , Liam Girdwood , Jie Yang , alsa-devel@alsa-project.org Subject: [PATCH v4 6/9] x86/quirks: Add a DMI quirk for Microsoft Surface 3 Date: Wed, 15 Apr 2020 17:55:21 +0300 Message-Id: <20200415145524.31745-7-andriy.shevchenko@linux.intel.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20200415145524.31745-1-andriy.shevchenko@linux.intel.com> References: <20200415145524.31745-1-andriy.shevchenko@linux.intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Add a DMI quirk for Microsoft Surface 3 which will be utilized by few drivers. Cc: Cezary Rojewski Cc: Pierre-Louis Bossart Cc: Liam Girdwood Cc: Jie Yang Cc: Mark Brown Cc: alsa-devel@alsa-project.org Signed-off-by: Andy Shevchenko --- arch/x86/kernel/quirks.c | 10 ++++++++++ include/linux/platform_data/x86/machine.h | 5 +++++ 2 files changed, 15 insertions(+) diff --git a/arch/x86/kernel/quirks.c b/arch/x86/kernel/quirks.c index a97055599bb7..b4a3aa9c3f48 100644 --- a/arch/x86/kernel/quirks.c +++ b/arch/x86/kernel/quirks.c @@ -658,6 +658,9 @@ DECLARE_PCI_FIXUP_EARLY(PCI_VENDOR_ID_INTEL, 0x2083, quirk_intel_purley_xeon_ras bool x86_apple_machine; EXPORT_SYMBOL(x86_apple_machine); +bool x86_microsoft_surface_3_machine; +EXPORT_SYMBOL(x86_microsoft_surface_3_machine); + static const struct dmi_system_id x86_machine_table[] __initconst = { { .ident = "x86 Apple Macintosh", @@ -673,6 +676,13 @@ static const struct dmi_system_id x86_machine_table[] __initconst = { }, .driver_data = &x86_apple_machine, }, + { + .ident = "Microsoft Surface 3", + .matches = { + DMI_MATCH(DMI_PRODUCT_NAME, "Surface 3"), + }, + .driver_data = &x86_microsoft_surface_3_machine, + }, {} }; diff --git a/include/linux/platform_data/x86/machine.h b/include/linux/platform_data/x86/machine.h index b1e7a560a046..9bdf5a06b490 100644 --- a/include/linux/platform_data/x86/machine.h +++ b/include/linux/platform_data/x86/machine.h @@ -8,8 +8,13 @@ * x86_apple_machine - whether the machine is an x86 Apple Macintosh */ extern bool x86_apple_machine; +/** + * x86_microsoft_surface_3_machine - whether the machine is Microsoft Surface 3 + */ +extern bool x86_microsoft_surface_3_machine; #else #define x86_apple_machine false +#define x86_microsoft_surface_3_machine false #endif #endif /* PLATFORM_DATA_X86_MACHINE_H */ -- 2.25.1