Received: by 2002:ac0:aa62:0:0:0:0:0 with SMTP id w31-v6csp3264239ima; Tue, 23 Oct 2018 03:08:42 -0700 (PDT) X-Google-Smtp-Source: ACcGV619KDFxCsifQBlL1zrplPeyG/fLKSoJZhqTKAz6O9GEW4NghqdMuYhpRL5dHWfjTAlrVL5V X-Received: by 2002:a63:c251:: with SMTP id l17-v6mr18888112pgg.146.1540289321899; Tue, 23 Oct 2018 03:08:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1540289321; cv=none; d=google.com; s=arc-20160816; b=Ndg+uEVCRK8IyTHiWTJvZ+Pjmu+qyqmlJenZhxI4/FUMIz0YMeY67q8EIyfwZLCsph u4heUsR3RRwJAl6PcMJsrLl012yYkwqa1AZaU24NoPm7VQy2YdH8aGeDH0bWk4SkxhXt XOZ1+QAnQ5RXeKvMl3gsS42gPysVay6k9/FcJY1eRURwQxL13b5X0UJg1kdDnNXuvD/H ncM/dAaOFugK5EV5cNWilixu+sujEWe+IHya5WwyRA5I9hQF9Pm+jG+jg0ZwLIvE607Z S3SDm4rP3+6Jsxsy6B+UzpRRtKfJvfZEE3hCyZzWNMS6noCe8akSmRdAUUn66UrmwXDY 5baA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature; bh=1yJ8J3Yam1Q1wlDeQK3fsxuGh+b4WnI7dD8h+RpA+YI=; b=oh0nQ454ModOsO1vR4K3Iicl234ws1VP4F4ZxLA4/VmIMTCyNM9A2GUZa/m5Bw2V7L Oe0lavfrDz45XJqYd7zSXJGYNJKroQ135lCP5cGmJiOFElzXVbe/bGrPw4BEQnlo/rEf 5v8DNNvnc5/95Xo9yRcJ3m2l9ex0cdujwVsLdWvFIp8+5uavzB8Ul6QYzzLRbfO9opGa fOTEtCv1qAXi20Ma83TRrL/q9p3pMRiC5JYtnXHozglB9fGv+AQShlXVLUFoAt2mD9JU rtglbLsuiJ/e9MD2HKYD5c8uhfikITsiH0F8+v2O/T5g78yTlqTCaFHWwCJ97kbO2/LX PI4A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@astier-eu.20150623.gappssmtp.com header.s=20150623 header.b=UpWJbEze; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z189-v6si933990pfz.32.2018.10.23.03.08.26; Tue, 23 Oct 2018 03:08:41 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@astier-eu.20150623.gappssmtp.com header.s=20150623 header.b=UpWJbEze; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729036AbeJWSa3 (ORCPT + 99 others); Tue, 23 Oct 2018 14:30:29 -0400 Received: from mail-wm1-f67.google.com ([209.85.128.67]:38271 "EHLO mail-wm1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728961AbeJWSa1 (ORCPT ); Tue, 23 Oct 2018 14:30:27 -0400 Received: by mail-wm1-f67.google.com with SMTP id 193-v6so1124815wme.3 for ; Tue, 23 Oct 2018 03:07:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=astier-eu.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :in-reply-to:references; bh=1yJ8J3Yam1Q1wlDeQK3fsxuGh+b4WnI7dD8h+RpA+YI=; b=UpWJbEze0+jM+5C8+Fi9ybuFpiBJkNfHfHYzpWDsd1JZW+XssMvYQa5Os5lItXUmPD yJ2cYWuNp3NgDCFd11mNJ0lEhBLMFSzwlIgHz5KDBlEGLZ80JKaBtycBAr2fEkSGj5wV eLE/Ul7c8Ogs/mi8XoWImYH6MvzqcvoYJT6vL20SZZcBaZftSVB7AXrRDNQDR40SOGMg 7q7az35HZp+2pd6yNE2ijxMV5kMwlLhpiJ8LEtv2iC4Yh/HN9qKmIbvZmuTJOzge/nsQ qjSwt/zM0jpYks0843grIPl+3yxMgB9s3toD9JCtKwrDQOM8Gh2vwe7EK08TLW0ux7W8 T+mw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:in-reply-to:references; bh=1yJ8J3Yam1Q1wlDeQK3fsxuGh+b4WnI7dD8h+RpA+YI=; b=qTz40ofLFW82uA7IgrUGL2wZp0b+SA3U7qOIbd9gVYgtFCMyvybusk8dnQEDh94RVF JEq8rvqQnhRl83DjT5YLRXhTJiQD90dOGs/flQB6Q1PcHBI0LoA0hoU+HX91alDeLnKT isH3ZfDsoTjLD8IFn43c6KZ2bPDPPUW1BywlgHnMFGqZIQb1x8rUZiL5kistq/8MbaWD l4+MpeLUYWl/tMMKxZ4Ohs6l6s1N+JLLHVirnZMAn3GOw/BokaIAOSkqwpMYKKCXbZnl 1fa1/Pvkqfl6eSwraCO6x3ttpNBglcXnmExrCKi+ysEpOvlT+ZFfpZ9Clhx4/8tS8UCd /LAQ== X-Gm-Message-State: AGRZ1gJvizQhrPJsqcinPciAzZmw4mv5GnWfQCkas0JWneYCPi+AY/5T nrw8Lj5LVykMgGOt08yjmox93A== X-Received: by 2002:a1c:7a0a:: with SMTP id v10-v6mr2532579wmc.41.1540289263047; Tue, 23 Oct 2018 03:07:43 -0700 (PDT) Received: from jaya.substantiel.local ([92.103.140.194]) by smtp.gmail.com with ESMTPSA id i13-v6sm910930wrn.62.2018.10.23.03.07.42 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 23 Oct 2018 03:07:42 -0700 (PDT) From: Anisse Astier To: Adrian Hunter Cc: Ulf Hansson , linux-mmc@vger.kernel.org, linux-kernel@vger.kernel.org, Anisse Astier Subject: [PATCH v2 1/3] mmc: sdhci-pci: disable 1.8V with dmi quirk Date: Tue, 23 Oct 2018 12:07:27 +0200 Message-Id: <20181023100729.28864-2-anisse@astier.eu> X-Mailer: git-send-email 2.17.2 In-Reply-To: <20181023100729.28864-1-anisse@astier.eu> References: <20181023100729.28864-1-anisse@astier.eu> In-Reply-To: <20181022134026.GB18413@jaya> References: <20181022134026.GB18413@jaya> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org If the motherboard is known not to support 1.8V properly, add the necessary quirk on probe. This fixes an issue on a Gemini Lake (GLK) laptop : eMMC driver will timeout on boot (from 60seconds to 10minutes ) as the cqhci attempts CQE recovery after a failed voltage switch. In earlier kernels, the problem existed, but only delayed boot for about 10 seconds after an I/O error, allowing booting on the eMMC (almost) unnoticed. Signed-off-by: Anisse Astier --- drivers/mmc/host/sdhci-pci-core.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/drivers/mmc/host/sdhci-pci-core.c b/drivers/mmc/host/sdhci-pci-core.c index 7bfd366d970d..396413f7c854 100644 --- a/drivers/mmc/host/sdhci-pci-core.c +++ b/drivers/mmc/host/sdhci-pci-core.c @@ -29,6 +29,7 @@ #include #include #include +#include #include "cqhci.h" @@ -703,6 +704,16 @@ static int intel_execute_tuning(struct mmc_host *mmc, u32 opcode) return 0; } +static const struct dmi_system_id board_no_1_8v[] = { + { + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "Notebook"), + DMI_MATCH(DMI_PRODUCT_NAME, "N75_77GU"), + }, + }, + { } +}; + static void byt_probe_slot(struct sdhci_pci_slot *slot) { struct mmc_host_ops *ops = &slot->host->mmc_host_ops; @@ -710,6 +721,12 @@ static void byt_probe_slot(struct sdhci_pci_slot *slot) byt_read_dsm(slot); ops->execute_tuning = intel_execute_tuning; + + if (dmi_check_system(board_no_1_8v)) { + pr_debug("%s: motherboard does not support 1.8V\n", + mmc_hostname(slot->host->mmc)); + slot->host->quirks2 |= SDHCI_QUIRK2_NO_1_8_V; + } ops->start_signal_voltage_switch = intel_start_signal_voltage_switch; } -- 2.17.2