mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Sascha Hauer <s.hauer@pengutronix.de>
To: Lucas Stach <l.stach@pengutronix.de>
Cc: barebox@lists.infradead.org
Subject: Re: [PATCH 1/4] gpmc: depend on MTD
Date: Wed, 19 Aug 2015 16:10:58 +0200	[thread overview]
Message-ID: <20150819141058.GB18700@pengutronix.de> (raw)
In-Reply-To: <1439369205-26787-1-git-send-email-l.stach@pengutronix.de>

On Wed, Aug 12, 2015 at 10:46:42AM +0200, Lucas Stach wrote:
> From: Lucas Stach <dev@lynxeye.de>
> 
> Fixes:
> drivers/built-in.o: In function `gpmc_probe':
> :(.text.gpmc_probe+0x164): undefined reference to `of_get_nand_bus_width'
> 
> Signed-off-by: Lucas Stach <dev@lynxeye.de>
> ---
>  drivers/bus/Kconfig | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/bus/Kconfig b/drivers/bus/Kconfig
> index 202df59762e8..61f9064f5d3a 100644
> --- a/drivers/bus/Kconfig
> +++ b/drivers/bus/Kconfig
> @@ -4,6 +4,7 @@ config BUS_OMAP_GPMC
>  	depends on ARCH_OMAP
>  	depends on OFDEVICE
>  	depends on OMAP_GPMC
> +	depends on MTD

Not a good idea. The GPMC is also used as a general parallel bus for
example to connect external ethernet controllers. This should work
without MTD support. What we could to instead is:


diff --git a/drivers/bus/omap-gpmc.c b/drivers/bus/omap-gpmc.c
index 8ae909a..6b3d49a 100644
--- a/drivers/bus/omap-gpmc.c
+++ b/drivers/bus/omap-gpmc.c
@@ -624,7 +624,7 @@ static int gpmc_probe(struct device_d *dev)
 		if (!child->name)
 			continue;
 
-		if (!strncmp(child->name, "nand", 4))
+		if (IS_ENABLED(CONFIG_MTD) && !strncmp(child->name, "nand", 4))
 			ret = gpmc_probe_nand_child(dev, child);
 		else if (strncmp(child->name, "ethernet", 8) == 0 ||
 				strncmp(child->name, "nor", 3) == 0 ||
-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

      parent reply	other threads:[~2015-08-19 14:11 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-08-12  8:46 Lucas Stach
2015-08-12  8:46 ` [PATCH 2/4] video: MTL017: depend on I2C Lucas Stach
2015-08-19 14:11   ` Sascha Hauer
2015-08-12  8:46 ` [PATCH 3/4] video: simple-panel: mode support depends on I2C and EDID Lucas Stach
2015-08-19 14:12   ` Sascha Hauer
2015-08-12  8:46 ` [PATCH 4/4] video: backlight: add fallbacks for client functions Lucas Stach
2015-08-19 14:13   ` Sascha Hauer
2015-08-19 14:10 ` Sascha Hauer [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=20150819141058.GB18700@pengutronix.de \
    --to=s.hauer@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    --cc=l.stach@pengutronix.de \
    /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