Received: by 2002:a5b:505:0:0:0:0:0 with SMTP id o5csp5247888ybp; Mon, 14 Oct 2019 18:27:49 -0700 (PDT) X-Google-Smtp-Source: APXvYqzjgVmhrxmlMbAhrNu/BUlPPLgYj6IN77ROveuUfHEJmk8eSzL+9msafVHquhHaqjV1K1TP X-Received: by 2002:aa7:c70d:: with SMTP id i13mr30869636edq.214.1571102868939; Mon, 14 Oct 2019 18:27:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1571102868; cv=none; d=google.com; s=arc-20160816; b=MxAFz4At0AgJHpbx24kwcKuYEzbTNIuGE3Dp8249kJ6SCJxljAapoJ3ego9eRnv1Ba pRqIaqg6QEzyA3QG5AoGr63TZ99ibgV7sWDpRJuTbrTUs4MV9lZGXdeoP1qxnkxibcad gi0kGhGbN0fQm0BrjHY0kMq0X5A/Xaqy7VMcjyjgNVGTLPW5Jxa397Y7mvuf4t2oNHXM iEDDXTUEyDEl3N+wU5cbxbDLG2oBlBAM+Z7ugOZ34hiZphrB7NGirPPZER/mb7m76rW9 OlmQvokXEVolChOBrXwAe50921CDypEas+w3cQk9vwm/AOpU9p/nv3ZP+OmR8o5Z6/ke OEtQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=CTKwbQqEeqMa4j3k49XOwBl4DO7kSa1JGDiy1w9+GPA=; b=00n6VTVIcnBzhyQjFpA2Zvrntn5wQZ9KOFtanIEQGsWzl2NWyFP+uyoN88fapphKOm T2B0jP3nBhQq0ciuQt3yNtkB7BENW35vR7yDUVsW/l+MGG1AO7zhbub+vTiTEi9v9KO6 fn+8eWqv/jWY/wkXHsZRSX6pKBb8T0hQ1XqqtNh84dYikzP7l/lZvetq3NCGIik1l73q PbEeRWAefIG8E8ICWOp33hOp2U6/VFh+666/sjg6MwKi/wPfNbqQGTV9YVNGBQbexSmJ Lz2jQ5iMqo9QcNENEWS0FfOk4N2UsBRfoVSjUcTcjXhhnQuBYnIq0KZSZ3PlvHBU+uyt P7LQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b="p/bpCy46"; 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=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id g31si13384687eda.399.2019.10.14.18.27.24; Mon, 14 Oct 2019 18:27:48 -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=@kernel.org header.s=default header.b="p/bpCy46"; 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=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726215AbfJNXAr (ORCPT + 99 others); Mon, 14 Oct 2019 19:00:47 -0400 Received: from mail.kernel.org ([198.145.29.99]:51280 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726170AbfJNXAr (ORCPT ); Mon, 14 Oct 2019 19:00:47 -0400 Received: from localhost (unknown [69.71.4.100]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 05A332133F; Mon, 14 Oct 2019 23:00:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1571094046; bh=XqPAXn+ga1kYewIdDzsVOZ1HjiGk6w5zCGO+lJ563dw=; h=From:To:Cc:Subject:Date:From; b=p/bpCy46EIZr1Vr/b4SANZeuQBFWndiUiRdCCXHwqLBJ/RHaIAqgbcv9qR7gfB9+0 cG71WcdBmPlE2U2b6quaFh5SnYCBx6ota6CW07Rj7thn0ZIhL+BShMZvSQ9O7B3hFo SgGKIy2F55a5FT4p2SmMU+fjsFBvJee/P8eV1t30= From: Bjorn Helgaas To: Dexuan Cui Cc: "Rafael J . Wysocki" , Lorenzo Pieralisi , Michael Kelley , Sasha Levin , Haiyang Zhang , KY Srinivasan , Stephen Hemminger , olaf@aepfle.de, apw@canonical.com, jasowang@redhat.com, vkuznets@redhat.com, marcelo.cerri@canonical.com, jackm@mellanox.com, linux-pci@vger.kernel.org, linux-hyperv@vger.kernel.org, linux-kernel@vger.kernel.org, driverdev-devel@linuxdriverproject.org, Bjorn Helgaas Subject: [PATCH v3 0/7] PCI: PM: Move to D0 before calling pci_legacy_resume_early() Date: Mon, 14 Oct 2019 18:00:09 -0500 Message-Id: <20191014230016.240912-1-helgaas@kernel.org> X-Mailer: git-send-email 2.23.0.700.g56cf767bdb-goog 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 From: Bjorn Helgaas Dexuan, the important thing here is the first patch, which is your [1], which I modified by doing pci_restore_state() as well as setting to D0: pci_set_power_state(pci_dev, PCI_D0); pci_restore_state(pci_dev); I'm proposing some more patches on top. None are relevant to the problem you're solving; they're just minor doc and other updates in the same area. Rafael, if you have a chance to look at these, I'd appreciate it. I tried to make the doc match the code, but I'm no PM expert. [1] https://lore.kernel.org/r/KU1P153MB016637CAEAD346F0AA8E3801BFAD0@KU1P153MB0166.APCP153.PROD.OUTLOOK.COM Dexuan Cui (1): PCI/PM: Always return devices to D0 when thawing Bjorn Helgaas (6): PCI/PM: Correct pci_pm_thaw_noirq() documentation PCI/PM: Clear PCIe PME Status even for legacy power management PCI/PM: Run resume fixups before disabling wakeup events PCI/PM: Make power management op coding style consistent PCI/PM: Wrap long lines in documentation PCI/MSI: Move power state check out of pci_msi_supported() Documentation/power/pci.rst | 38 +++++++------- drivers/pci/msi.c | 6 +-- drivers/pci/pci-driver.c | 99 ++++++++++++++++++------------------- 3 files changed, 71 insertions(+), 72 deletions(-) -- 2.23.0.700.g56cf767bdb-goog