[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <201910290508.m8t5ycxs%lkp@intel.com>
Date: Tue, 29 Oct 2019 05:33:47 +0800
From: kbuild test robot <lkp@...el.com>
To: Lorenzo Bianconi <lorenzo@...nel.org>
Cc: kbuild-all@...ts.01.org, kvalo@...eaurora.org,
linux-wireless@...r.kernel.org, nbd@....name, hkallweit1@...il.com,
sgruszka@...hat.com, lorenzo.bianconi@...hat.com,
oleksandr@...alenko.name, netdev@...r.kernel.org
Subject: Re: [PATCH v2 wireless-drivers 1/2] mt76: mt76x2e: disable pcie_aspm
by default
Hi Lorenzo,
I love your patch! Yet something to improve:
[auto build test ERROR on wireless-drivers/master]
url: https://github.com/0day-ci/linux/commits/Lorenzo-Bianconi/fix-mt76x2e-hangs-on-U7612E-mini-pcie/20191029-024127
base: https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/wireless-drivers.git master
config: c6x-allyesconfig (attached as .config)
compiler: c6x-elf-gcc (GCC) 7.4.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
GCC_VERSION=7.4.0 make.cross ARCH=c6x
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp@...el.com>
All errors (new ones prefixed by >>):
drivers/net//wireless/mediatek/mt76/mmio.c: In function 'mt76_mmio_disable_aspm':
drivers/net//wireless/mediatek/mt76/mmio.c:88:2: error: implicit declaration of function 'pcie_capability_read_word'; did you mean 'has_capability_noaudit'? [-Werror=implicit-function-declaration]
pcie_capability_read_word(pdev, PCI_EXP_LNKCTL, &aspm_conf);
^~~~~~~~~~~~~~~~~~~~~~~~~
has_capability_noaudit
>> drivers/net//wireless/mediatek/mt76/mmio.c:108:9: error: implicit declaration of function 'pci_disable_link_state'; did you mean 'pci_disable_ats'? [-Werror=implicit-function-declaration]
err = pci_disable_link_state(pdev, aspm_conf);
^~~~~~~~~~~~~~~~~~~~~~
pci_disable_ats
drivers/net//wireless/mediatek/mt76/mmio.c:116:2: error: implicit declaration of function 'pcie_capability_clear_word'; did you mean 'has_capability_noaudit'? [-Werror=implicit-function-declaration]
pcie_capability_clear_word(pdev, PCI_EXP_LNKCTL, aspm_conf);
^~~~~~~~~~~~~~~~~~~~~~~~~~
has_capability_noaudit
cc1: some warnings being treated as errors
vim +108 drivers/net//wireless/mediatek/mt76/mmio.c
82
83 void mt76_mmio_disable_aspm(struct pci_dev *pdev)
84 {
85 struct pci_dev *parent = pdev->bus->self;
86 u16 aspm_conf, parent_aspm_conf = 0;
87
> 88 pcie_capability_read_word(pdev, PCI_EXP_LNKCTL, &aspm_conf);
89 aspm_conf &= PCI_EXP_LNKCTL_ASPMC;
90 if (parent) {
91 pcie_capability_read_word(parent, PCI_EXP_LNKCTL,
92 &parent_aspm_conf);
93 parent_aspm_conf &= PCI_EXP_LNKCTL_ASPMC;
94 }
95
96 if (!aspm_conf && (!parent || !parent_aspm_conf)) {
97 /* aspm already disabled */
98 return;
99 }
100
101 dev_info(&pdev->dev, "disabling ASPM %s %s\n",
102 (aspm_conf & PCI_EXP_LNKCTL_ASPM_L0S) ? "L0s" : "",
103 (aspm_conf & PCI_EXP_LNKCTL_ASPM_L1) ? "L1" : "");
104
105 if (IS_ENABLED(CONFIG_PCIEASPM)) {
106 int err;
107
> 108 err = pci_disable_link_state(pdev, aspm_conf);
109 if (!err)
110 return;
111 }
112
113 /* both device and parent should have the same ASPM setting.
114 * disable ASPM in downstream component first and then upstream.
115 */
116 pcie_capability_clear_word(pdev, PCI_EXP_LNKCTL, aspm_conf);
117 if (parent)
118 pcie_capability_clear_word(parent, PCI_EXP_LNKCTL,
119 aspm_conf);
120 }
121 EXPORT_SYMBOL_GPL(mt76_mmio_disable_aspm);
122
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
Download attachment ".config.gz" of type "application/gzip" (50155 bytes)
Powered by blists - more mailing lists