]> rtime.felk.cvut.cz Git - sojka/nv-tegra/linux-3.10.git/commitdiff
pci: host: tegra: removes forcing aspm states
authorVidya Sagar <vidyas@nvidia.com>
Fri, 25 Jul 2014 16:28:44 +0000 (21:58 +0530)
committerLaxman Dewangan <ldewangan@nvidia.com>
Wed, 13 Aug 2014 08:39:55 +0000 (01:39 -0700)
removes the code that forcefully enables aspm states.
It will be enabled through config option

Bug 200011678

Change-Id: I42668ae1b1393b19f8ed52485b8d84756f4b231e
Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
Reviewed-on: http://git-master/r/447664
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
Tested-by: Laxman Dewangan <ldewangan@nvidia.com>
drivers/pci/host/pci-tegra.c

index 5616e289ff94d0add87d60bdf831d4f4f306ce63..80d86cadba9e106190cbedbf506eb4c672c0e0be 100644 (file)
@@ -2371,10 +2371,9 @@ static void tegra_pcie_config_clkreq(struct tegra_pcie *pcie, bool enable)
 /* Enable ASPM support of all devices based on it's capability */
 static void tegra_pcie_enable_aspm(struct tegra_pcie *pcie)
 {
+#if defined(CONFIG_ARCH_TEGRA_21x_SOC)
        struct pci_dev *pdev = NULL;
-       u16 val = 0;
        u32 aspm = 0;
-#if defined(CONFIG_ARCH_TEGRA_21x_SOC)
        int pos = 0;
        bool config_l1ss = true;
 #endif
@@ -2384,20 +2383,6 @@ static void tegra_pcie_enable_aspm(struct tegra_pcie *pcie)
                dev_info(pcie->dev, "PCIE: ASPM not enabled\n");
                return;
        }
-       for_each_pci_dev(pdev) {
-               /* Find ASPM capability */
-               pcie_capability_read_dword(pdev, PCI_EXP_LNKCAP, &aspm);
-               aspm &= PCI_EXP_LNKCAP_ASPMS;
-
-               /* Enable ASPM support as per capability */
-               pcie_capability_read_word(pdev, PCI_EXP_LNKCTL, &val);
-               val |= (u16)aspm >> 10;
-               pcie_capability_write_word(pdev, PCI_EXP_LNKCTL, val);
-#if defined CONFIG_ARCH_TEGRA_12x_SOC
-               pcie_capability_clear_word(pdev, PCI_EXP_LNKCTL,
-                               PCI_EXP_LNKCTL_ASPM_L0S);
-#endif
-       }
 #if defined(CONFIG_ARCH_TEGRA_21x_SOC)
        /* L1SS configuration as per IAS */
        for_each_pci_dev(pdev) {