Re: [PATCH] Add basic PM support for Nvidia and ATI AGP bridges

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi!

> I retrieved these from the swsusp2 patchset, but they seem to be 
> independently useful. As a result, I'm not sure who the original author 
> is - however, they seem to be pretty obvious.
> 
> ## All lines beginning with `## DP:' are a description of the patch.
> ## DP: Description: Add suspend/resume support to ATI and Nvidia AGP bridges
> ## DP: Patch author: Unknown
> ## DP: Upstream status: Not submitted
> 
> . $(dirname $0)/DPATCH

> @@ -507,6 +507,33 @@ static void __devexit agp_ati_remove(str
>  	agp_put_bridge(bridge);
>  }
>  
> +#ifdef CONFIG_PM
> +
> +static int agp_ati_suspend(struct pci_dev *pdev, pm_message_t state)
> +{
> +	pci_save_state (pdev);
> +	pci_set_power_state (pdev, 3);

PCI_D3hot, please.

> +static int agp_ati_resume(struct pci_dev *pdev)
> +{
> +	struct agp_bridge_data *bridge = pci_get_drvdata(pdev);
> +
> +	/* set power state 0 and restore PCI space */
> +	pci_set_power_state (pdev, 0);

PCI_D0... ....and same in other two functions. Otherwise it looks ok.

								Pavel
-- 
Thanks, Sharp!
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux