lkml.org 
[lkml]   [2005]   [Jul]   [26]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [patch 2.6.13-rc2] pci: restore BAR values from pci_set_power_state for D3hot->D0
On Tue, Jul 26, 2005 at 04:49:34PM -0700, Greg KH wrote:
> On Fri, Jul 08, 2005 at 02:34:56PM -0400, John W. Linville wrote:
> > @@ -301,6 +335,16 @@ pci_set_power_state(struct pci_dev *dev,
> > udelay(200);
> > dev->current_state = state;
> >
> > + /* According to section 5.4.1 of the "PCI BUS POWER MANAGEMENT
> > + * INTERFACE SPECIFICATION, REV. 1.2", a device transitioning
> > + * from D3hot to D0 _may_ perform an internal reset, thereby
> > + * going to "D0 Uninitialized" rather than "D0 Initialized".
> > + * In that case, we need to restore at least the BARs so that
> > + * the device will be accessible to its driver.
> > + */
> > + if (need_restore)
> > + pci_restore_bars(dev);
> > +
>
> This code doesn't even build, as need_restore isn't a global variable.

Hmmm...you must be missing this hunk from the patch posted on July 8?

@@ -239,7 +270,7 @@ pci_find_parent_resource(const struct pc
int
pci_set_power_state(struct pci_dev *dev, pci_power_t state)
{
- int pm;
+ int pm, need_restore = 0;
u16 pmcsr, pmc;
/* bound the state we're entering */

> Care to redo this patch (and merge it with your other one) and resend
> it?

I'll be happy to do so, and include the other comment tweaks that
Grant requested. I should get to it tomorrow morning.

Thanks,

John
--
John W. Linville
linville@tuxdriver.com
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-07-27 03:41    [W:0.121 / U:0.336 seconds]
©2003-2014 Jasper Spaans. Advertise on this site