From: Takashi Iwai <tiwai@suse.de>
To: kbuild test robot <lkp@intel.com>
Cc: alsa-devel@alsa-project.org,
Kai-Heng Feng <kai.heng.feng@canonical.com>,
kbuild-all@lists.01.org
Subject: Re: [alsa-devel] [sound:for-next 2/20] drivers/pci/pci.c:5859:6: error: redefinition of 'pci_pr3_present'
Date: Thu, 17 Oct 2019 12:04:23 +0200 [thread overview]
Message-ID: <s5h7e53it7c.wl-tiwai@suse.de> (raw)
In-Reply-To: <201910171743.2X4agjN2%lkp@intel.com>
On Thu, 17 Oct 2019 11:42:47 +0200,
kbuild test robot wrote:
>
> tree: https://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git for-next
> head: fa5a68b2abcefe2204075c80662e02cf59567a9f
> commit: 2e1a529c10e18e62da55eac42c278f11216dddaa [2/20] PCI: Add pci_pr3_present() helper to check Power Resource for D3hot
> config: parisc-c3000_defconfig (attached as .config)
> compiler: hppa-linux-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
> git checkout 2e1a529c10e18e62da55eac42c278f11216dddaa
> # save the attached .config to linux build tree
> GCC_VERSION=7.4.0 make.cross ARCH=parisc
>
> If you fix the issue, kindly add following tag
> Reported-by: kbuild test robot <lkp@intel.com>
>
> All errors (new ones prefixed by >>):
>
> >> drivers/pci/pci.c:5859:6: error: redefinition of 'pci_pr3_present'
> bool pci_pr3_present(struct pci_dev *pdev)
> ^~~~~~~~~~~~~~~
> In file included from include/linux/of_pci.h:5:0,
> from drivers/pci/pci.c:17:
> include/linux/pci.h:2317:13: note: previous definition of 'pci_pr3_present' was here
> static bool pci_pr3_present(struct pci_dev *pdev) { return false; }
> ^~~~~~~~~~~~~~~
It looks like the ifdef CONFIG_ACPI is missing in pci_pr3_present()
definition in pci.c.
I drop the two patches for now.
Kai-Heng, could you resubmit with the proper fix?
thanks,
Takashi
> drivers/pci/pci.c: In function 'pci_pr3_present':
> >> drivers/pci/pci.c:5870:13: error: dereferencing pointer to incomplete type 'struct acpi_device'
> return adev->power.flags.power_resources &&
> ^~
> >> drivers/pci/pci.c:5871:3: error: implicit declaration of function 'acpi_has_method'; did you mean 'acpi_has_watchdog'? [-Werror=implicit-function-declaration]
> acpi_has_method(adev->handle, "_PR3");
> ^~~~~~~~~~~~~~~
> acpi_has_watchdog
> In file included from include/linux/of_pci.h:5:0,
> from drivers/pci/pci.c:17:
> At top level:
> include/linux/pci.h:2317:13: warning: 'pci_pr3_present' defined but not used [-Wunused-function]
> static bool pci_pr3_present(struct pci_dev *pdev) { return false; }
> ^~~~~~~~~~~~~~~
> cc1: some warnings being treated as errors
>
> vim +/pci_pr3_present +5859 drivers/pci/pci.c
>
> 5858
> > 5859 bool pci_pr3_present(struct pci_dev *pdev)
> 5860 {
> 5861 struct acpi_device *adev;
> 5862
> 5863 if (acpi_disabled)
> 5864 return false;
> 5865
> 5866 adev = ACPI_COMPANION(&pdev->dev);
> 5867 if (!adev)
> 5868 return false;
> 5869
> > 5870 return adev->power.flags.power_resources &&
> > 5871 acpi_has_method(adev->handle, "_PR3");
> 5872 }
> 5873 EXPORT_SYMBOL_GPL(pci_pr3_present);
> 5874
_______________________________________________
Alsa-devel mailing list
Alsa-devel@alsa-project.org
https://mailman.alsa-project.org/mailman/listinfo/alsa-devel
prev parent reply other threads:[~2019-10-17 10:05 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-10-17 9:42 [alsa-devel] [sound:for-next 2/20] drivers/pci/pci.c:5859:6: error: redefinition of 'pci_pr3_present' kbuild test robot
2019-10-17 10:04 ` Takashi Iwai [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=s5h7e53it7c.wl-tiwai@suse.de \
--to=tiwai@suse.de \
--cc=alsa-devel@alsa-project.org \
--cc=kai.heng.feng@canonical.com \
--cc=kbuild-all@lists.01.org \
--cc=lkp@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox