All of lore.kernel.org
 help / color / mirror / Atom feed
From: Brian Norris <computersforpeace@gmail.com>
To: Javier Martinez Canillas <javier@osg.samsung.com>
Cc: linux-kernel@vger.kernel.org,
	"Fengguang Wu" <fengguang.wu@intel.com>,
	"Luis de Bethencourt" <luisbg@osg.samsung.com>,
	"Michael Ellerman" <mpe@ellerman.id.au>,
	"Jeremy Kerr" <jk@ozlabs.org>,
	linux-mtd@lists.infradead.org,
	"David Woodhouse" <dwmw2@infradead.org>,
	"Neelesh Gupta" <neelegup@linux.vnet.ibm.com>,
	"Cyril Bur" <cyrilbur@gmail.com>,
	"Rafał Miłecki" <zajec5@gmail.com>
Subject: Re: [PATCH] mtd: Make MTD_BCM47XXSFLASH to depend on MIPS
Date: Wed, 14 Oct 2015 09:25:04 -0700	[thread overview]
Message-ID: <20151014162504.GG107187@google.com> (raw)
In-Reply-To: <1444813494-14985-1-git-send-email-javier@osg.samsung.com>

+ Rafał

On Wed, Oct 14, 2015 at 11:04:54AM +0200, Javier Martinez Canillas wrote:
> The bcm47xxsflash driver uses the KSEG0ADDR() function to map an address
> to a certain kernel segment. But that is only defined if the MIPS config
> symbol is enabled. The driver does not have an explicit dependency on it
> and relies on a transitive dependency relation:
> 
> MTD_BCM47XXSFLASH -> BCMA_SFLASH -> BCMA_DRIVER_MIPS -> BCMA && MIPS
> 
> But BCMA_SFLASH and BCMA_DRIVER_MIPS have only runtime and not buildtime
> dependency with MIPS so can be changed to be built test using the config
> COMPILE_TEST symbol. But that would make MTD_BCM47XXSFLASH be built with
> MIPS not enabled and cause the following build error:
> 
> drivers/mtd/devices//bcm47xxsflash.c: In function 'bcm47xxsflash_read':
> drivers/mtd/devices//bcm47xxsflash.c:112:2: error: implicit declaration of function 'KSEG0ADDR' [-Werror=implicit-function-declaration]
>   memcpy_fromio(buf, (void __iomem *)KSEG0ADDR(b47s->window + from),
>   ^
> 
> Make MTD_BCM47XXSFLASH depend on MIPS since has a buildtime dependency.
> 
> Reported-by: Fengguang Wu <fengguang.wu@intel.com>
> Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>
> 
> ---
> 
>  drivers/mtd/devices/Kconfig | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/mtd/devices/Kconfig b/drivers/mtd/devices/Kconfig
> index f73c41697a00..f5eab3c19356 100644
> --- a/drivers/mtd/devices/Kconfig
> +++ b/drivers/mtd/devices/Kconfig
> @@ -114,7 +114,7 @@ config MTD_SST25L
>  
>  config MTD_BCM47XXSFLASH
>  	tristate "R/O support for serial flash on BCMA bus"
> -	depends on BCMA_SFLASH
> +	depends on BCMA_SFLASH && MIPS
>  	help
>  	  BCMA bus can have various flash memories attached, they are
>  	  registered by bcma as platform devices. This enables driver for
> -- 
> 2.4.3
> 

  reply	other threads:[~2015-10-14 16:25 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-10-14  9:04 [PATCH] mtd: Make MTD_BCM47XXSFLASH to depend on MIPS Javier Martinez Canillas
2015-10-14 16:25 ` Brian Norris [this message]
2015-11-04  9:04 ` Rafał Miłecki
2015-11-04 18:53   ` Brian Norris
2016-01-07 21:06     ` Maciej W. Rozycki
2016-01-07 23:05       ` [PATCH] mtd: bcm47xxsflash: use devm_ioremap_nocache() instead of KSEG0ADDR() Brian Norris
2016-01-08  7:53         ` Rafał Miłecki
2016-01-08 14:01           ` Maciej W. Rozycki
2016-01-08 15:26             ` Rafał Miłecki
2016-01-09  2:12               ` Maciej W. Rozycki
2016-01-08 18:51             ` Brian Norris
2016-01-09  2:10               ` Maciej W. Rozycki
2016-01-16  0:38                 ` Rafał Miłecki
2016-01-16 19:36                   ` Maciej W. Rozycki
2016-01-23 21:49                   ` Brian Norris
2016-01-24  9:44                     ` Rafał Miłecki
2016-01-24 20:26                     ` Maciej W. Rozycki
2016-01-24 21:31                       ` Rafał Miłecki
2016-01-24 23:07                         ` Maciej W. Rozycki

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=20151014162504.GG107187@google.com \
    --to=computersforpeace@gmail.com \
    --cc=cyrilbur@gmail.com \
    --cc=dwmw2@infradead.org \
    --cc=fengguang.wu@intel.com \
    --cc=javier@osg.samsung.com \
    --cc=jk@ozlabs.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mtd@lists.infradead.org \
    --cc=luisbg@osg.samsung.com \
    --cc=mpe@ellerman.id.au \
    --cc=neelegup@linux.vnet.ibm.com \
    --cc=zajec5@gmail.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.