Re: [PATCH v7 03/13] PCI: tegra194: Don't force the device into the D0 state before L2

From: Manivannan Sadhasivam

Date: Sun Mar 15 2026 - 21:25:36 EST


On Sun, Mar 15, 2026 at 06:51:23PM +0530, Manikanta Maddireddy wrote:
>
>
> On 05/03/26 3:10 pm, Manivannan Sadhasivam wrote:
> > On Tue, Mar 03, 2026 at 12:24:38PM +0530, Manikanta Maddireddy wrote:
> > > From: Vidya Sagar <vidyas@xxxxxxxxxx>
> > >
> > > As per PCIe CEM spec rev 4.0 ver 1.0 sec 2.3, the PCIe Endpoint device
> > > should be in D3 state to assert wake# pin. This takes precedence over PCI
> >
> > WAKE#
> >
> > > Express Base r4.0 v1.0 September 27-2017, 5.2 Link State Power Management
> > > which states that the device can be put into D0 state before taking the
> > > link to L2 state. To enable the wake functionality for Endpoint devices,
> > > do not force the devices to D0 state before taking the link to L2 state.
> > > There is no functional issue with the Endpoint devices where the link
> > > doesn't go into L2 state (the reason why the earlier change was made in
> > > the first place) as the Root Port proceeds with the usual flow post PME
> > > timeout.
> > >
> >
> > So the previous claim in the comments is not true?
> >
> > I agree with this patch in principle, but just want to know why the comment
> > claimed there is an issue if the devices are not in D0 state.
> >
> > - Mani
> No, previous claim is true. D0 fix is done to fix L2 timeout with a specific
> Endpoint. However, later realized that it is breaking wake functionality
> with other Endpoints. As I mentioned in the commit message reverting D0 fix
> still causes L2 timeout with that specific Endpoint, but it doesn't cause
> any functional issue.
>

Okay, I just looked up the mentioned section in r4.0. The spec suggests that it
is possible to initiate power removal without transitioning the device into
D3Hot. It didn't explicitly say that "put device into D0", which is quite
misleading.

Anyway, the previous comment as well as the workaround is not correct. So ammend
the commit message as per above in next version.

- Mani

--
மணிவண்ணன் சதாசிவம்