All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] nand: brcmnand: return without disabling clock
@ 2020-04-02  8:37 Álvaro Fernández Rojas
  2020-04-02  9:15 ` Daniel Schwierzeck
  2020-04-23 19:10 ` Daniel Schwierzeck
  0 siblings, 2 replies; 5+ messages in thread
From: Álvaro Fernández Rojas @ 2020-04-02  8:37 UTC (permalink / raw)
  To: u-boot

Linux Broadcom NAND driver only disabled clock if no childs are initialized.
This section of the code seems to have been accidentally dropped when it was
imported in U-Boot.

Signed-off-by: ?lvaro Fern?ndez Rojas <noltari@gmail.com>
---
 drivers/mtd/nand/raw/brcmnand/brcmnand.c | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/drivers/mtd/nand/raw/brcmnand/brcmnand.c b/drivers/mtd/nand/raw/brcmnand/brcmnand.c
index 5232328e1e..7bdebf5869 100644
--- a/drivers/mtd/nand/raw/brcmnand/brcmnand.c
+++ b/drivers/mtd/nand/raw/brcmnand/brcmnand.c
@@ -2714,6 +2714,14 @@ int brcmnand_probe(struct udevice *dev, struct brcmnand_soc *soc)
 	}
 #endif /* __UBOOT__ */
 
+	/* No chip-selects could initialize properly */
+	if (list_empty(&ctrl->host_list)) {
+		ret = -ENODEV;
+		goto err;
+	}
+
+	return 0;
+
 err:
 #ifndef __UBOOT__
 	clk_disable_unprepare(ctrl->clk);
@@ -2722,7 +2730,6 @@ err:
 		clk_disable(ctrl->clk);
 #endif /* __UBOOT__ */
 	return ret;
-
 }
 EXPORT_SYMBOL_GPL(brcmnand_probe);
 
-- 
2.20.1

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

* [PATCH] nand: brcmnand: return without disabling clock
  2020-04-02  8:37 [PATCH] nand: brcmnand: return without disabling clock Álvaro Fernández Rojas
@ 2020-04-02  9:15 ` Daniel Schwierzeck
  2020-04-02 15:49   ` Tom Rini
  2020-04-23 19:10 ` Daniel Schwierzeck
  1 sibling, 1 reply; 5+ messages in thread
From: Daniel Schwierzeck @ 2020-04-02  9:15 UTC (permalink / raw)
  To: u-boot



Am 02.04.20 um 10:37 schrieb ?lvaro Fern?ndez Rojas:
> Linux Broadcom NAND driver only disabled clock if no childs are initialized.
> This section of the code seems to have been accidentally dropped when it was
> imported in U-Boot.
> 
> Signed-off-by: ?lvaro Fern?ndez Rojas <noltari@gmail.com>
> ---
>  drivers/mtd/nand/raw/brcmnand/brcmnand.c | 9 ++++++++-
>  1 file changed, 8 insertions(+), 1 deletion(-)
> 

Reviewed-by: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>

-- 
- Daniel

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

* [PATCH] nand: brcmnand: return without disabling clock
  2020-04-02  9:15 ` Daniel Schwierzeck
@ 2020-04-02 15:49   ` Tom Rini
  2020-04-02 15:57     ` Álvaro Fernández Rojas
  0 siblings, 1 reply; 5+ messages in thread
From: Tom Rini @ 2020-04-02 15:49 UTC (permalink / raw)
  To: u-boot

On Thu, Apr 02, 2020 at 11:15:51AM +0200, Daniel Schwierzeck wrote:
> 
> 
> Am 02.04.20 um 10:37 schrieb ?lvaro Fern?ndez Rojas:
> > Linux Broadcom NAND driver only disabled clock if no childs are initialized.
> > This section of the code seems to have been accidentally dropped when it was
> > imported in U-Boot.
> > 
> > Signed-off-by: ?lvaro Fern?ndez Rojas <noltari@gmail.com>
> > ---
> >  drivers/mtd/nand/raw/brcmnand/brcmnand.c | 9 ++++++++-
> >  1 file changed, 8 insertions(+), 1 deletion(-)
> > 
> 
> Reviewed-by: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>

Does this need to go in to v2020.04?  Thanks!

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 659 bytes
Desc: not available
URL: <https://lists.denx.de/pipermail/u-boot/attachments/20200402/84496567/attachment.sig>

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

* [PATCH] nand: brcmnand: return without disabling clock
  2020-04-02 15:49   ` Tom Rini
@ 2020-04-02 15:57     ` Álvaro Fernández Rojas
  0 siblings, 0 replies; 5+ messages in thread
From: Álvaro Fernández Rojas @ 2020-04-02 15:57 UTC (permalink / raw)
  To: u-boot



> El 2 abr 2020, a las 17:49, Tom Rini <trini@konsulko.com> escribi?:
> 
> On Thu, Apr 02, 2020 at 11:15:51AM +0200, Daniel Schwierzeck wrote:
>> 
>> 
>> Am 02.04.20 um 10:37 schrieb ?lvaro Fern?ndez Rojas:
>>> Linux Broadcom NAND driver only disabled clock if no childs are initialized.
>>> This section of the code seems to have been accidentally dropped when it was
>>> imported in U-Boot.
>>> 
>>> Signed-off-by: ?lvaro Fern?ndez Rojas <noltari@gmail.com>
>>> ---
>>> drivers/mtd/nand/raw/brcmnand/brcmnand.c | 9 ++++++++-
>>> 1 file changed, 8 insertions(+), 1 deletion(-)
>>> 
>> 
>> Reviewed-by: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
> 
> Does this need to go in to v2020.04?  Thanks!
> 
> -- 
> Tom

Not really. I tested it with a development branch and this affects bcm6362 devices (nand not currently supported), but it doesn?t affect bcm63268 devices (1 device supported).

Best regards,
?lvaro.

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

* [PATCH] nand: brcmnand: return without disabling clock
  2020-04-02  8:37 [PATCH] nand: brcmnand: return without disabling clock Álvaro Fernández Rojas
  2020-04-02  9:15 ` Daniel Schwierzeck
@ 2020-04-23 19:10 ` Daniel Schwierzeck
  1 sibling, 0 replies; 5+ messages in thread
From: Daniel Schwierzeck @ 2020-04-23 19:10 UTC (permalink / raw)
  To: u-boot



Am 02.04.20 um 10:37 schrieb ?lvaro Fern?ndez Rojas:
> Linux Broadcom NAND driver only disabled clock if no childs are initialized.
> This section of the code seems to have been accidentally dropped when it was
> imported in U-Boot.
> 
> Signed-off-by: ?lvaro Fern?ndez Rojas <noltari@gmail.com>
> ---
>  drivers/mtd/nand/raw/brcmnand/brcmnand.c | 9 ++++++++-
>  1 file changed, 8 insertions(+), 1 deletion(-)
> 

applied to u-boot-mips, thanks.

-- 
- Daniel

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

end of thread, other threads:[~2020-04-23 19:10 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-02  8:37 [PATCH] nand: brcmnand: return without disabling clock Álvaro Fernández Rojas
2020-04-02  9:15 ` Daniel Schwierzeck
2020-04-02 15:49   ` Tom Rini
2020-04-02 15:57     ` Álvaro Fernández Rojas
2020-04-23 19:10 ` Daniel Schwierzeck

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.