From: Bjorn Helgaas <bhelgaas@google.com>
To: Aaron Lu <aaron.lu@intel.com>
Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net>,
ACPI Devel Mailing List <linux-acpi@vger.kernel.org>,
Linux PCI <linux-pci@vger.kernel.org>
Subject: Re: [PATCH v2 2/2] PCI / ACPI: PCI delay optimization from ACPI
Date: Tue, 24 Mar 2015 17:10:39 -0500 [thread overview]
Message-ID: <20150324221039.GE2495@google.com> (raw)
In-Reply-To: <5511849F.3050903@intel.com>
On Tue, Mar 24, 2015 at 11:37:03PM +0800, Aaron Lu wrote:
> On 03/24/2015 10:08 PM, Bjorn Helgaas wrote:
> > On Tue, Mar 24, 2015 at 05:04:58PM +0800, Aaron Lu wrote:
> >> @@ -575,6 +637,9 @@ static void pci_acpi_setup(struct device *dev)
> >> if (!adev)
> >> return;
> >>
> >> + if (pci_dev->pm_cap)
> >> + pci_acpi_delay_optimize(pci_dev, adev->handle);
> >
> > Is the "pm_cap" test really necessary? If we do it this way, we then have
> > to convince ourselves that pdev->d3cold_delay and pdev->d3_delay are only
> > needed when pdev has a pm_cap.
> >
> > If we *always* fill in the delay values, it's possible they won't be used,
> > but we don't have to prove any connection between them and a pm_cap, so
> > the code is easier to analyze.
>
> I remembered why I did the pm_cap test: the d3cold_delay and d3_delay is
> only filled when pm_cap is set in pci_pm_init - if the device doesn't
> have PCI_CAP_ID_PM set, its pm_cap will be 0 and d3cold_delay, d3_delay
> will not be assigned.
Yes, that's true, so I can see why you'd test pm_cap here, too. But I
don't think it's necessary to propagate that connection here, so I'd omit
the test.
Bjorn
next prev parent reply other threads:[~2015-03-24 22:10 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-09 7:46 [PATCH] PCI / ACPI: PCI delay optimization from ACPI Aaron Lu
2015-03-09 14:33 ` Rafael J. Wysocki
2015-03-10 6:47 ` Aaron Lu
2015-03-10 6:48 ` [PATCH update] " Aaron Lu
2015-03-20 6:14 ` Aaron Lu
2015-03-20 12:39 ` Rafael J. Wysocki
2015-03-20 21:03 ` Bjorn Helgaas
2015-03-23 5:35 ` Aaron Lu
2015-03-23 9:15 ` Aaron Lu
2015-03-23 9:16 ` [PATCH 1/2] PCI: rename dsm uuid for PCI Aaron Lu
2015-03-24 0:24 ` Rafael J. Wysocki
2015-03-24 0:35 ` Aaron Lu
2015-03-24 1:03 ` Rafael J. Wysocki
2015-03-24 9:04 ` [PATCH v2 1/2] PCI: rename _DSM UUID array Aaron Lu
2015-03-24 21:57 ` Rafael J. Wysocki
2015-03-23 9:17 ` [PATCH 2/2] PCI / ACPI: PCI delay optimization from ACPI Aaron Lu
2015-03-23 15:09 ` Bjorn Helgaas
2015-03-24 9:04 ` [PATCH v2 " Aaron Lu
2015-03-24 14:08 ` Bjorn Helgaas
2015-03-24 15:16 ` Aaron Lu
2015-03-24 22:09 ` Bjorn Helgaas
2015-03-24 15:37 ` Aaron Lu
2015-03-24 22:10 ` Bjorn Helgaas [this message]
2015-03-25 6:30 ` [PATCH v3 0/3] " Aaron Lu
2015-03-25 6:31 ` [PATCH v3 1/3] PCI: rename _DSM UUID array Aaron Lu
2015-03-25 6:32 ` [PATCH v3 2/3] PCI: rename find_pci_host_bridge and export it Aaron Lu
2015-03-25 6:37 ` [PATCH v3 3/3] PCI / ACPI: PCI delay optimization from ACPI Aaron Lu
2015-03-29 14:17 ` [PATCH v3 0/3] " Aaron Lu
2015-04-08 21:32 ` Bjorn Helgaas
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=20150324221039.GE2495@google.com \
--to=bhelgaas@google.com \
--cc=aaron.lu@intel.com \
--cc=linux-acpi@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=rjw@rjwysocki.net \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.