From: Bjorn Helgaas <helgaas@kernel.org>
To: Qipeng Zha <qipeng.zha@intel.com>
Cc: linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org,
bhelgaas@google.com, mika.westerberg@intel.com,
Qi Zheng <qi.zheng@intel.com>,
"Rafael J. Wysocki" <rafael.j.wysocki@intel.com>
Subject: Re: [PATCH 2/2] PCI/PM: enable runtime PM support for Intel Broxton platform.
Date: Tue, 19 Jan 2016 15:55:27 -0600 [thread overview]
Message-ID: <20160119215527.GI14080@localhost> (raw)
In-Reply-To: <1452868065-96999-2-git-send-email-qipeng.zha@intel.com>
[+cc Rafael]
On Fri, Jan 15, 2016 at 10:27:45PM +0800, Qipeng Zha wrote:
> The PCIe runtime PM is disabled by default, add special treatment
> to allow runtime PM for Intel Broxton platform.
Hmmm. I assume this only applies to Broxton now, but will likely
apply to future Intel platforms as well. I really don't want to be
adding quirks for every new Intel platform that comes along.
> Signed-off-by: Qi Zheng <qi.zheng@intel.com>
> Signed-off-by: Qipeng Zha <qipeng.zha@intel.com>
> ---
> drivers/pci/quirks.c | 13 +++++++++++++
> include/linux/pci_ids.h | 2 ++
> 2 files changed, 15 insertions(+)
>
> diff --git a/drivers/pci/quirks.c b/drivers/pci/quirks.c
> index 7e32730..a745d06 100644
> --- a/drivers/pci/quirks.c
> +++ b/drivers/pci/quirks.c
> @@ -25,6 +25,7 @@
> #include <linux/sched.h>
> #include <linux/ktime.h>
> #include <linux/mm.h>
> +#include <linux/pm_runtime.h>
> #include <asm/dma.h> /* isa_dma_bridge_buggy */
> #include "pci.h"
>
> @@ -2989,6 +2990,18 @@ static void quirk_intel_ntb(struct pci_dev *dev)
> DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x0e08, quirk_intel_ntb);
> DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x0e0d, quirk_intel_ntb);
>
> +
> +/*PCIe ports on Intel Broxton should support runtime PM*/
Missing spaces at beginning and end of comment.
> +static void quirk_pcie_enable_rtpm(struct pci_dev *dev)
> +{
> + pm_runtime_put_noidle(&dev->dev);
> + pm_runtime_allow(&dev->dev);
> +}
> +DECLARE_PCI_FIXUP_ENABLE(PCI_VENDOR_ID_INTEL,
> + PCI_DEVICE_ID_INTEL_BXT_B0_PCIe_0, quirk_pcie_enable_rtpm);
> +DECLARE_PCI_FIXUP_ENABLE(PCI_VENDOR_ID_INTEL,
> + PCI_DEVICE_ID_INTEL_BXT_B0_PCIe_1, quirk_pcie_enable_rtpm);
> +
> static ktime_t fixup_debug_start(struct pci_dev *dev,
> void (*fn)(struct pci_dev *dev))
> {
> diff --git a/include/linux/pci_ids.h b/include/linux/pci_ids.h
> index d9ba49c..731f05f 100644
> --- a/include/linux/pci_ids.h
> +++ b/include/linux/pci_ids.h
> @@ -2596,6 +2596,8 @@
> #define PCI_DEVICE_ID_INTEL_82840_HB 0x1a21
> #define PCI_DEVICE_ID_INTEL_82845_HB 0x1a30
> #define PCI_DEVICE_ID_INTEL_IOAT 0x1a38
> +#define PCI_DEVICE_ID_INTEL_BXT_B0_PCIe_0 0x1ad6
> +#define PCI_DEVICE_ID_INTEL_BXT_B0_PCIe_1 0x1ad7
> #define PCI_DEVICE_ID_INTEL_COUGARPOINT_LPC_MIN 0x1c41
> #define PCI_DEVICE_ID_INTEL_COUGARPOINT_LPC_MAX 0x1c5f
> #define PCI_DEVICE_ID_INTEL_PATSBURG_LPC_0 0x1d40
> --
> 1.8.3.2
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-pci" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2016-01-19 21:55 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-01-15 14:27 [PATCH 1/2] PCI/PM: Revert "PCI/PM: Drop unused runtime PM support code for PCIe ports" Qipeng Zha
2016-01-15 14:27 ` [PATCH 2/2] PCI/PM: enable runtime PM support for Intel Broxton platform Qipeng Zha
2016-01-19 21:55 ` Bjorn Helgaas [this message]
2016-01-19 21:52 ` [PATCH 1/2] PCI/PM: Revert "PCI/PM: Drop unused runtime PM support code for PCIe ports" Bjorn Helgaas
2016-01-19 22:10 ` Rafael J. Wysocki
-- strict thread matches above, loose matches on Subject: below --
2016-02-18 9:43 Qipeng Zha
2016-02-18 9:43 ` [PATCH 2/2] PCI/PM: enable runtime PM support for Intel Broxton platform Qipeng Zha
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160119215527.GI14080@localhost \
--to=helgaas@kernel.org \
--cc=bhelgaas@google.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=mika.westerberg@intel.com \
--cc=qi.zheng@intel.com \
--cc=qipeng.zha@intel.com \
--cc=rafael.j.wysocki@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).