All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 2/2] octeon: only build flash_setup code when CONFIG_MTD is set
@ 2009-06-22  9:16 Florian Fainelli
  2009-06-22 14:40 ` Ralf Baechle
  0 siblings, 1 reply; 3+ messages in thread
From: Florian Fainelli @ 2009-06-22  9:16 UTC (permalink / raw)
  To: linux-mips; +Cc: Ralf Baechle, David Daney

This patch makes the flash_setup code be compiled only when
CONFIG_MTD is set, it does make sense to register a physmap
platform driver without the MTD subsystem being enabled.

CC: David Daney <ddaney@caviumnetworks.com>
Signed-off-by: Florian Fainelli <florian@openwrt.org>
---
diff --git a/arch/mips/cavium-octeon/Makefile b/arch/mips/cavium-octeon/Makefile
index 7c0528b..f1b401b 100644
--- a/arch/mips/cavium-octeon/Makefile
+++ b/arch/mips/cavium-octeon/Makefile
@@ -10,9 +10,10 @@
 #
 
 obj-y := setup.o serial.o octeon-irq.o csrc-octeon.o
-obj-y += dma-octeon.o flash_setup.o
+obj-y += dma-octeon.o
 obj-y += octeon-memcpy.o
 
+obj-$(CONFIG_MTD)		      += flash_setup.o
 obj-$(CONFIG_SMP)                     += smp.o
 obj-$(CONFIG_PCI)                     += pci-common.o
 obj-$(CONFIG_PCI)                     += pci.o

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

* Re: [PATCH 2/2] octeon: only build flash_setup code when CONFIG_MTD is set
  2009-06-22  9:16 [PATCH 2/2] octeon: only build flash_setup code when CONFIG_MTD is set Florian Fainelli
@ 2009-06-22 14:40 ` Ralf Baechle
  2009-06-22 21:05   ` Florian Fainelli
  0 siblings, 1 reply; 3+ messages in thread
From: Ralf Baechle @ 2009-06-22 14:40 UTC (permalink / raw)
  To: Florian Fainelli; +Cc: linux-mips, David Daney

On Mon, Jun 22, 2009 at 11:16:21AM +0200, Florian Fainelli wrote:

> This patch makes the flash_setup code be compiled only when
> CONFIG_MTD is set, it does make sense to register a physmap
> platform driver without the MTD subsystem being enabled.

No.  A user might build the MTD subsystem as a module and then insert it
into a running system so the idea is to always register the devices.  This
also keeps the information in /proc/iomem rsp. /proc/iostat and sysfs
more useful.

  Ralf

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

* Re: [PATCH 2/2] octeon: only build flash_setup code when CONFIG_MTD is set
  2009-06-22 14:40 ` Ralf Baechle
@ 2009-06-22 21:05   ` Florian Fainelli
  0 siblings, 0 replies; 3+ messages in thread
From: Florian Fainelli @ 2009-06-22 21:05 UTC (permalink / raw)
  To: Ralf Baechle; +Cc: linux-mips, David Daney

Le Monday 22 June 2009 16:40:42 Ralf Baechle, vous avez écrit :
> On Mon, Jun 22, 2009 at 11:16:21AM +0200, Florian Fainelli wrote:
> > This patch makes the flash_setup code be compiled only when
> > CONFIG_MTD is set, it does make sense to register a physmap
> > platform driver without the MTD subsystem being enabled.
>
> No.  A user might build the MTD subsystem as a module and then insert it
> into a running system so the idea is to always register the devices.  This
> also keeps the information in /proc/iomem rsp. /proc/iostat and sysfs
> more useful.

Right.
-- 
Best regards, Florian Fainelli
Email : florian@openwrt.org
http://openwrt.org
-------------------------------

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

end of thread, other threads:[~2009-06-22 21:09 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-06-22  9:16 [PATCH 2/2] octeon: only build flash_setup code when CONFIG_MTD is set Florian Fainelli
2009-06-22 14:40 ` Ralf Baechle
2009-06-22 21:05   ` Florian Fainelli

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.