Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp1299158imu; Mon, 5 Nov 2018 18:05:09 -0800 (PST) X-Google-Smtp-Source: AJdET5f/2mqpN1QGv1LuZJKp4O78nKl2F0cydP3XvWi5wYkq6+ERrTEdhZIMTh6e1Z1Rtz3h7UEU X-Received: by 2002:a65:47ca:: with SMTP id f10mr4995483pgs.166.1541469909157; Mon, 05 Nov 2018 18:05:09 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1541469909; cv=none; d=google.com; s=arc-20160816; b=Uj00jeincCcx/6oQH8YGgCLvey+amkvHLXBP4lkCbiMlsVr/wfsLdxtybIq42hmn7q 7hr1+vFYPA++5eL69ytPxkgPyMoVvcjkb6h8peYmQ48CwTkbjsa9VX8bWuu1HOOJcIOC A1dKWSl6pEXD7BjymeAMSq92bPvtms9ulV92OavAtZYXreOzX1jyVkTzRUcikH86Hvem ng9/ioREviMB4KmIOtEWvFNaxei5D3iVdluPUh9sGOznV67CibeCHUt60BrmMVYhVJ4Q JEkYh142PfJTEeH70zOCVcm70zSMC6F5sAWxfnuUnwMKyL83EQcLyGoH9PVK0aUAM6Dw 6E1Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:to:from :dkim-signature; bh=19U5nnS+32OVLXwVWLlWkIemkFQKEnGuAOn8fC7twHs=; b=Bl8rFWYaYNq29e++NPEoALU3jZqg30+afqhPEYjfjpiauitp4bcDNlzIDnpwm5v5vY KwSRjPrGNOArjwfLPy7OnF2jpTkdcGkJwbf4xxb3d7aAHgsqkenYTMG7uEVimrv+KC5f L1TH0wMSeWLdawkw6SPIqGr3Md51d+dt8J2o3UEsfLZEryFav5njPT0Ss6oIZbT2GLzF S514TUdQvyEU9YAP8ggv/5QLQNY4AtPgsH3NyB2yT76sZazEiutJiWYvZrYuhW+gxhCy 7nzekablY1d0QLQ00CtsQTpNHDGvcROJ+DZ23Jc6GRHoVJmW+Ms4rnf5ewd5V+5YuMYz 1WRg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=HDOLs4Ap; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=canonical.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id o69-v6si14868347pfo.78.2018.11.05.18.04.39; Mon, 05 Nov 2018 18:05:09 -0800 (PST) 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=fail header.i=@gmail.com header.s=20161025 header.b=HDOLs4Ap; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=canonical.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729241AbeKFL0v (ORCPT + 99 others); Tue, 6 Nov 2018 06:26:51 -0500 Received: from mail-pl1-f196.google.com ([209.85.214.196]:37048 "EHLO mail-pl1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726368AbeKFL0v (ORCPT ); Tue, 6 Nov 2018 06:26:51 -0500 Received: by mail-pl1-f196.google.com with SMTP id p6-v6so5376826pll.4; Mon, 05 Nov 2018 18:04:06 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id; bh=19U5nnS+32OVLXwVWLlWkIemkFQKEnGuAOn8fC7twHs=; b=HDOLs4ApedBKIWZ/OBpRz1OMpDdkqI697Nyoi/M796demU//wCxG6HyM4qiGvvoHWm hRpMcvl67TUNd4uO75gt6TWZV4z+kOQzHT95LT9QNCKhzxsX+UXgSi6763Km1t5va5IU 9mU5yesYuautARMkG1pmXpcPsk/Jgi4SDaJVd8U3JPWt/8UXcBpaauo3PiXRE1CMjohD VX/z+7ir8IB9nVuD57585G7c7B3Zo/MVgh7Tw2PfUR3DfH7uZseyDlim2t+f3r2sJMfh l6/UquRbE6YLKENM6IqA8clfhH16T7jndwPAjklNVGqgKf7OnNpgdl84mfaOV1QmReiX O1nQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id; bh=19U5nnS+32OVLXwVWLlWkIemkFQKEnGuAOn8fC7twHs=; b=Cv+wyWGymD9a2gUWelZT5g4S8wfkCJ2wsLuSuILZKFMsaF9SiAUEWlGDcaAyjMzo6m +LivMQ5lqLTz83DiUf14rStA5bJZFTIogDPZs1pRx7Ccc3Cr4uYLq8GgSPiae1qAdj3z ZyCl+opgon1BcMly0AVfzOeqWB7RFNzoOW7j6/tzLzX2XXE8y3+9YGpmYzUw7bH2WtqF 7ee5U2K+XyDGFRT3xR894wTUxOn+Y6htIWhwrsHgZa1GAl6m1x0gcPuLD67SCrykvlH8 G1le2A2f0hPrC9vbN9wzF2SSNCFZe6sJMbm6FZqcHmBsvWridPpZNbykKSPmnknzkNkG HoMA== X-Gm-Message-State: AGRZ1gJooWD2PGhIug9ekppc2sd2/9iiP4TDgeTJNKqFVklG5qOtqTLc iwy2mg0aYQqG2tr/TqmHFcg= X-Received: by 2002:a17:902:9a04:: with SMTP id v4-v6mr23924878plp.247.1541469845887; Mon, 05 Nov 2018 18:04:05 -0800 (PST) Received: from localhost (61-220-137-37.HINET-IP.hinet.net. [61.220.137.37]) by smtp.gmail.com with ESMTPSA id 64-v6sm2591804pfa.120.2018.11.05.18.04.04 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 05 Nov 2018 18:04:04 -0800 (PST) From: AceLan Kao To: Keith Busch , Jens Axboe , Christoph Hellwig , Sagi Grimberg , Bjorn Helgaas , linux-nvme@lists.infradead.org, linux-kernel@vger.kernel.org, linux-pci@vger.kernel.org Subject: [PATCH 1/2] pci: prevent sk hynix nvme from entering D3 Date: Tue, 6 Nov 2018 10:04:01 +0800 Message-Id: <20181106020402.21120-1-acelan.kao@canonical.com> X-Mailer: git-send-email 2.17.1 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org It leads to the power consumption raises to 2.2W during s2idle, while it consumes less than 1W during long idle if put SK hynix nvme to D3 and then enter s2idle. From SK hynix FE, MS Windows doesn't put nvme to D3, and uses its own APST feature to do the power management. To leverage its APST feature during s2idle, we can't disable nvme device while suspending, too. BTW, prevent it from entering D3 will increase the power consumtion around 0.13W ~ 0.15W during short/long idle, and the power consumption during s2idle becomes 0.77W. Signed-off-by: AceLan Kao --- drivers/pci/quirks.c | 1 + include/linux/pci_ids.h | 2 ++ 2 files changed, 3 insertions(+) diff --git a/drivers/pci/quirks.c b/drivers/pci/quirks.c index 4700d24e5d55..b7e6492e8311 100644 --- a/drivers/pci/quirks.c +++ b/drivers/pci/quirks.c @@ -1332,6 +1332,7 @@ DECLARE_PCI_FIXUP_CLASS_EARLY(PCI_VENDOR_ID_AL, PCI_ANY_ID, occur when mode detecting */ DECLARE_PCI_FIXUP_CLASS_EARLY(PCI_VENDOR_ID_VIA, PCI_ANY_ID, PCI_CLASS_STORAGE_IDE, 8, quirk_no_ata_d3); +DECLARE_PCI_FIXUP_EARLY(PCI_VENDOR_ID_SK_HYNIX, 0x1527, quirk_no_ata_d3); /* * This was originally an Alpha-specific thing, but it really fits here. diff --git a/include/linux/pci_ids.h b/include/linux/pci_ids.h index 69f0abe1ba1a..5f5adda07de0 100644 --- a/include/linux/pci_ids.h +++ b/include/linux/pci_ids.h @@ -3090,4 +3090,6 @@ #define PCI_VENDOR_ID_NCUBE 0x10ff +#define PCI_VENDOR_ID_SK_HYNIX 0x1c5c + #endif /* _LINUX_PCI_IDS_H */ -- 2.17.1