mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Purna Chandra Mandal <purna.mandal@microchip.com>
To: <linux-kernel@vger.kernel.org>
Cc: <kbuild-all@01.org>, <linux-spi@vger.kernel.org>,
	Purna Chandra Mandal <purna.mandal@microchip.com>,
	Mark Brown <broonie@kernel.org>
Subject: [PATCH] spi: pic32-sqi: Fix linker error, undefined reference to `bad_dma_ops'.
Date: Fri, 13 May 2016 14:12:53 +0530	[thread overview]
Message-ID: <1463128973-29831-1-git-send-email-purna.mandal@microchip.com> (raw)

Even if DMA support is disabled code using DMA mapping APIs compiles fine,
but fails in linking.
-------
drivers/built-in.o: In function `ring_desc_ring_free':
spi-pic32-sqi.c:(.text+0x2cfbe0): undefined reference to `bad_dma_ops'
spi-pic32-sqi.c:(.text+0x2cfbe4): undefined reference to `bad_dma_ops'
drivers/built-in.o: In function `pic32_sqi_probe':
spi-pic32-sqi.c:(.text+0x2cfe48): undefined reference to `bad_dma_ops'
spi-pic32-sqi.c:(.text+0x2cfeb0): undefined reference to `bad_dma_ops'
spi-pic32-sqi.c:(.text+0x2cff38): undefined reference to `bad_dma_ops'
--------
Correct dependency by adding 'depends on HAS_DMA' in Kconfig.

Signed-off-by: Purna Chandra Mandal <purna.mandal@microchip.com>

---

 drivers/spi/Kconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/spi/Kconfig b/drivers/spi/Kconfig
index 281ed5d..0f50755 100644
--- a/drivers/spi/Kconfig
+++ b/drivers/spi/Kconfig
@@ -445,6 +445,7 @@ config SPI_PIC32
 config SPI_PIC32_SQI
 	tristate "Microchip PIC32 Quad SPI driver"
 	depends on MACH_PIC32 || COMPILE_TEST
+	depends on HAS_DMA
 	help
 	  SPI driver for PIC32 Quad SPI controller.
 
-- 
1.8.3.1

             reply	other threads:[~2016-05-13  8:44 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-13  8:42 Purna Chandra Mandal [this message]
2016-05-13 12:38 ` Applied "spi: pic32-sqi: Fix linker error, undefined reference to `bad_dma_ops'." to the spi tree Mark Brown

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=1463128973-29831-1-git-send-email-purna.mandal@microchip.com \
    --to=purna.mandal@microchip.com \
    --cc=broonie@kernel.org \
    --cc=kbuild-all@01.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-spi@vger.kernel.org \
    /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

all inboxes | Powered by JetHome®