All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] ARM: OMAP2+: gpmc: fix: DT NAND child nodes not probed when MTD_NAND is built as module
@ 2014-01-28  6:12 Pekon Gupta
  2014-01-28  6:12 ` [PATCH] ARM: OMAP2+: gpmc: fix: DT ONENAND child nodes not probed when MTD_ONENAND " Pekon Gupta
  2014-02-13 23:11 ` [PATCH] ARM: OMAP2+: gpmc: fix: DT NAND child nodes not probed when MTD_NAND " Tony Lindgren
  0 siblings, 2 replies; 3+ messages in thread
From: Pekon Gupta @ 2014-01-28  6:12 UTC (permalink / raw)
  To: Tony Lindgren; +Cc: linux-omap, Ezequiel Garcia, Daniel Mack

Fixes: commit bc6b1e7b86f5d8e4a6fc1c0189e64bba4077efe0
       ARM: OMAP: gpmc: add DT bindings for GPMC timings and NAND

OMAP SoC(s) depend on GPMC controller driver to parse GPMC DT child nodes and
register them platform_device for NAND driver to probe later. However this does
not happen if generic MTD_NAND framework is built as module (CONFIG_MTD_NAND=m).

Therefore, when MTD/NAND and MTD/NAND/OMAP2 modules are loaded, they are unable
to find any matching platform_device and remain un-binded. This causes on board
NAND flash to remain un-detected.

This patch causes GPMC controller to parse DT nodes when
CONFIG_MTD_NAND=y || CONFIG_MTD_NAND=m

CC: <stable@vger.kernel.org> # 3.9.x+
Signed-off-by: Pekon Gupta <pekon@ti.com>
---
 arch/arm/mach-omap2/gpmc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/mach-omap2/gpmc.c b/arch/arm/mach-omap2/gpmc.c
index d24926e..c77a84b 100644
--- a/arch/arm/mach-omap2/gpmc.c
+++ b/arch/arm/mach-omap2/gpmc.c
@@ -1339,7 +1339,7 @@ static void __maybe_unused gpmc_read_timings_dt(struct device_node *np,
 		of_property_read_bool(np, "gpmc,time-para-granularity");
 }
 
-#ifdef CONFIG_MTD_NAND
+#if IS_ENABLED(CONFIG_MTD_NAND)
 
 static const char * const nand_xfer_types[] = {
 	[NAND_OMAP_PREFETCH_POLLED]		= "prefetch-polled",
-- 
1.8.1


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

* [PATCH] ARM: OMAP2+: gpmc: fix: DT ONENAND child nodes not probed when MTD_ONENAND is built as module
  2014-01-28  6:12 [PATCH] ARM: OMAP2+: gpmc: fix: DT NAND child nodes not probed when MTD_NAND is built as module Pekon Gupta
@ 2014-01-28  6:12 ` Pekon Gupta
  2014-02-13 23:11 ` [PATCH] ARM: OMAP2+: gpmc: fix: DT NAND child nodes not probed when MTD_NAND " Tony Lindgren
  1 sibling, 0 replies; 3+ messages in thread
From: Pekon Gupta @ 2014-01-28  6:12 UTC (permalink / raw)
  To: Tony Lindgren; +Cc: linux-omap, Ezequiel Garcia, Daniel Mack

Fixes: commit 75d3625e0e86b2d8d77b4e9c6f685fd7ea0d5a96
       ARM: OMAP2+: gpmc: add DT bindings for OneNAND

OMAP SoC(s) depend on GPMC controller driver to parse GPMC DT child nodes and
register them platform_device for ONENAND driver to probe later. However this does
not happen if generic MTD_ONENAND framework is built as module (CONFIG_MTD_ONENAND=m).

Therefore, when MTD/ONENAND and MTD/ONENAND/OMAP2 modules are loaded, they are unable
to find any matching platform_device and remain un-binded. This causes on board
ONENAND flash to remain un-detected.

This patch causes GPMC controller to parse DT nodes when
CONFIG_MTD_ONENAND=y || CONFIG_MTD_ONENAND=m

CC: <stable@vger.kernel.org> # 3.9.x+
Signed-off-by: Pekon Gupta <pekon@ti.com>
---
 arch/arm/mach-omap2/gpmc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/mach-omap2/gpmc.c b/arch/arm/mach-omap2/gpmc.c
index c77a84b..ab43755 100644
--- a/arch/arm/mach-omap2/gpmc.c
+++ b/arch/arm/mach-omap2/gpmc.c
@@ -1429,7 +1429,7 @@ static int gpmc_probe_nand_child(struct platform_device *pdev,
 }
 #endif
 
-#ifdef CONFIG_MTD_ONENAND
+#if IS_ENABLED(CONFIG_MTD_ONENAND)
 static int gpmc_probe_onenand_child(struct platform_device *pdev,
 				 struct device_node *child)
 {
-- 
1.8.1


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

* Re: [PATCH] ARM: OMAP2+: gpmc: fix: DT NAND child nodes not probed when MTD_NAND is built as module
  2014-01-28  6:12 [PATCH] ARM: OMAP2+: gpmc: fix: DT NAND child nodes not probed when MTD_NAND is built as module Pekon Gupta
  2014-01-28  6:12 ` [PATCH] ARM: OMAP2+: gpmc: fix: DT ONENAND child nodes not probed when MTD_ONENAND " Pekon Gupta
@ 2014-02-13 23:11 ` Tony Lindgren
  1 sibling, 0 replies; 3+ messages in thread
From: Tony Lindgren @ 2014-02-13 23:11 UTC (permalink / raw)
  To: Pekon Gupta; +Cc: linux-omap, Ezequiel Garcia, Daniel Mack

* Pekon Gupta <pekon@ti.com> [140127 22:15]:
> Fixes: commit bc6b1e7b86f5d8e4a6fc1c0189e64bba4077efe0
>        ARM: OMAP: gpmc: add DT bindings for GPMC timings and NAND
> 
> OMAP SoC(s) depend on GPMC controller driver to parse GPMC DT child nodes and
> register them platform_device for NAND driver to probe later. However this does
> not happen if generic MTD_NAND framework is built as module (CONFIG_MTD_NAND=m).
> 
> Therefore, when MTD/NAND and MTD/NAND/OMAP2 modules are loaded, they are unable
> to find any matching platform_device and remain un-binded. This causes on board
> NAND flash to remain un-detected.
> 
> This patch causes GPMC controller to parse DT nodes when
> CONFIG_MTD_NAND=y || CONFIG_MTD_NAND=m

Applying into omap-for-v3.14/fixes for this and the onenand patch.

Tony

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

end of thread, other threads:[~2014-02-13 23:11 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-01-28  6:12 [PATCH] ARM: OMAP2+: gpmc: fix: DT NAND child nodes not probed when MTD_NAND is built as module Pekon Gupta
2014-01-28  6:12 ` [PATCH] ARM: OMAP2+: gpmc: fix: DT ONENAND child nodes not probed when MTD_ONENAND " Pekon Gupta
2014-02-13 23:11 ` [PATCH] ARM: OMAP2+: gpmc: fix: DT NAND child nodes not probed when MTD_NAND " Tony Lindgren

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.