linux-spi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] spi: pxa2xx: fix PCI dependency
@ 2018-10-17 18:50 Arnd Bergmann
  2018-10-17 20:53 ` Geert Uytterhoeven
  2018-10-19 12:30 ` Applied "spi: pxa2xx: fix PCI dependency" to the spi tree Mark Brown
  0 siblings, 2 replies; 4+ messages in thread
From: Arnd Bergmann @ 2018-10-17 18:50 UTC (permalink / raw)
  To: Daniel Mack, Haojian Zhuang, Robert Jarzmik, Mark Brown
  Cc: Arnd Bergmann, Jarkko Nikula, Lubomir Rintel, linux-arm-kernel,
	linux-spi, linux-kernel

The code reorganization broke building without CONFIG_PCI:

drivers/spi/spi-pxa2xx.c: In function 'pxa2xx_spi_init_pdata':
drivers/spi/spi-pxa2xx.c:1457:15: error: implicit declaration of function 'pci_match_id'; did you mean 'pci_map_sg'? [-Werror=implicit-function-declaration]

Add back an #ifdef around the code block that requires it.

Fixes: 87ae1d2d7077 ("spi: pxa2xx: Add devicetree support")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 drivers/spi/spi-pxa2xx.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/spi/spi-pxa2xx.c b/drivers/spi/spi-pxa2xx.c
index 612cc49db28f..c1c30109dd1f 100644
--- a/drivers/spi/spi-pxa2xx.c
+++ b/drivers/spi/spi-pxa2xx.c
@@ -1453,9 +1453,11 @@ pxa2xx_spi_init_pdata(struct platform_device *pdev)
 	if (pdev->dev.of_node)
 		of_id = of_match_device(pdev->dev.driver->of_match_table,
 					&pdev->dev);
+#ifdef CONFIG_PCI
 	else if (dev_is_pci(pdev->dev.parent))
 		pcidev_id = pci_match_id(pxa2xx_spi_pci_compound_match,
 					 to_pci_dev(pdev->dev.parent));
+#endif
 	else if (adev)
 		adev_id = acpi_match_device(pdev->dev.driver->acpi_match_table,
 					    &pdev->dev);
-- 
2.18.0

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] spi: pxa2xx: fix PCI dependency
  2018-10-17 18:50 [PATCH] spi: pxa2xx: fix PCI dependency Arnd Bergmann
@ 2018-10-17 20:53 ` Geert Uytterhoeven
  2018-10-19 12:30 ` Applied "spi: pxa2xx: fix PCI dependency" to the spi tree Mark Brown
  1 sibling, 0 replies; 4+ messages in thread
From: Geert Uytterhoeven @ 2018-10-17 20:53 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: Daniel Mack, Haojian Zhuang, Robert Jarzmik, Mark Brown,
	Linux Kernel Mailing List, linux-spi, Lubomir Rintel,
	Jarkko Nikula, Linux ARM

Hi Arnd,

On Wed, Oct 17, 2018 at 8:52 PM Arnd Bergmann <arnd@arndb.de> wrote:
> The code reorganization broke building without CONFIG_PCI:
>
> drivers/spi/spi-pxa2xx.c: In function 'pxa2xx_spi_init_pdata':
> drivers/spi/spi-pxa2xx.c:1457:15: error: implicit declaration of function 'pci_match_id'; did you mean 'pci_map_sg'? [-Werror=implicit-function-declaration]
>
> Add back an #ifdef around the code block that requires it.
>
> Fixes: 87ae1d2d7077 ("spi: pxa2xx: Add devicetree support")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>

Already fixed in spi-next by commit 9c2120090586d7e5 ("PCI: Provide
pci_match_id() with CONFIG_PCI=n").

Gr{oetje,eeting}s,

                        Geert

-- 
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Applied "spi: pxa2xx: fix PCI dependency" to the spi tree
  2018-10-17 18:50 [PATCH] spi: pxa2xx: fix PCI dependency Arnd Bergmann
  2018-10-17 20:53 ` Geert Uytterhoeven
@ 2018-10-19 12:30 ` Mark Brown
  2018-10-19 12:32   ` Mark Brown
  1 sibling, 1 reply; 4+ messages in thread
From: Mark Brown @ 2018-10-19 12:30 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: Mark Brown, Daniel Mack, Haojian Zhuang, Robert Jarzmik,
	Mark Brown, Jarkko Nikula, Lubomir Rintel, linux-arm-kernel,
	linux-spi, linux-kernel, linux-spi

The patch

   spi: pxa2xx: fix PCI dependency

has been applied to the spi tree at

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git 

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.  

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark

>From 23aa9fdea2d364924fadf3dcc1509bd578ac1f00 Mon Sep 17 00:00:00 2001
From: Arnd Bergmann <arnd@arndb.de>
Date: Wed, 17 Oct 2018 20:50:52 +0200
Subject: [PATCH] spi: pxa2xx: fix PCI dependency

The code reorganization broke building without CONFIG_PCI:

drivers/spi/spi-pxa2xx.c: In function 'pxa2xx_spi_init_pdata':
drivers/spi/spi-pxa2xx.c:1457:15: error: implicit declaration of function 'pci_match_id'; did you mean 'pci_map_sg'? [-Werror=implicit-function-declaration]

Add back an #ifdef around the code block that requires it.

Fixes: 87ae1d2d7077 ("spi: pxa2xx: Add devicetree support")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Mark Brown <broonie@kernel.org>
---
 drivers/spi/spi-pxa2xx.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/spi/spi-pxa2xx.c b/drivers/spi/spi-pxa2xx.c
index 612cc49db28f..c1c30109dd1f 100644
--- a/drivers/spi/spi-pxa2xx.c
+++ b/drivers/spi/spi-pxa2xx.c
@@ -1453,9 +1453,11 @@ pxa2xx_spi_init_pdata(struct platform_device *pdev)
 	if (pdev->dev.of_node)
 		of_id = of_match_device(pdev->dev.driver->of_match_table,
 					&pdev->dev);
+#ifdef CONFIG_PCI
 	else if (dev_is_pci(pdev->dev.parent))
 		pcidev_id = pci_match_id(pxa2xx_spi_pci_compound_match,
 					 to_pci_dev(pdev->dev.parent));
+#endif
 	else if (adev)
 		adev_id = acpi_match_device(pdev->dev.driver->acpi_match_table,
 					    &pdev->dev);
-- 
2.19.0.rc2

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: Applied "spi: pxa2xx: fix PCI dependency" to the spi tree
  2018-10-19 12:30 ` Applied "spi: pxa2xx: fix PCI dependency" to the spi tree Mark Brown
@ 2018-10-19 12:32   ` Mark Brown
  0 siblings, 0 replies; 4+ messages in thread
From: Mark Brown @ 2018-10-19 12:32 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: Daniel Mack, Haojian Zhuang, Robert Jarzmik, Jarkko Nikula,
	Lubomir Rintel, linux-arm-kernel, linux-spi, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 361 bytes --]

On Fri, Oct 19, 2018 at 01:30:02PM +0100, Mark Brown wrote:
> The patch
> 
>    spi: pxa2xx: fix PCI dependency
> 
> has been applied to the spi tree at
> 
>    https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git 

Sorry, I'll drop this one - I forgot it had already been applied when
it was pointed out that the stub function was added.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2018-10-19 12:32 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-10-17 18:50 [PATCH] spi: pxa2xx: fix PCI dependency Arnd Bergmann
2018-10-17 20:53 ` Geert Uytterhoeven
2018-10-19 12:30 ` Applied "spi: pxa2xx: fix PCI dependency" to the spi tree Mark Brown
2018-10-19 12:32   ` Mark Brown

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).