mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] spi: davinci: Fix compilation warning.
@ 2017-06-05 12:14 Arvind Yadav
  2017-06-05 13:07 ` Geert Uytterhoeven
  0 siblings, 1 reply; 4+ messages in thread
From: Arvind Yadav @ 2017-06-05 12:14 UTC (permalink / raw)
  To: broonie; +Cc: linux-spi, linux-kernel

If CONFIG_OF is disable, it'll through compilation warning.

drivers/spi/spi-davinci.c: In function ‘spi_davinci_get_pdata’:
drivers/spi/spi-davinci.c:880:2: warning: return makes pointer from integer without a cast [enabled by default]
  return -ENODEV;

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
---
 drivers/spi/spi-davinci.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/spi/spi-davinci.c b/drivers/spi/spi-davinci.c
index 2b0805d..93a4009 100644
--- a/drivers/spi/spi-davinci.c
+++ b/drivers/spi/spi-davinci.c
@@ -877,7 +877,7 @@ static int spi_davinci_get_pdata(struct platform_device *pdev,
 	*spi_davinci_get_pdata(struct platform_device *pdev,
 		struct davinci_spi *dspi)
 {
-	return -ENODEV;
+	return ERR_PTR(-ENODEV);
 }
 #endif
 
-- 
1.9.1

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

end of thread, other threads:[~2017-06-05 13:38 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-06-05 12:14 [PATCH] spi: davinci: Fix compilation warning Arvind Yadav
2017-06-05 13:07 ` Geert Uytterhoeven
2017-06-05 13:29   ` Arvind Yadav
2017-06-05 13:37     ` Mark Brown

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®