diff mbox series

mtd: rawnand: denali: get ->setup_data_interface() working again

Message ID 1547789438-11899-1-git-send-email-yamada.masahiro@socionext.com
State Accepted
Headers show
Series mtd: rawnand: denali: get ->setup_data_interface() working again | expand

Commit Message

Masahiro Yamada Jan. 18, 2019, 5:30 a.m. UTC
Commit 7a08dbaedd36 ("mtd: rawnand: Move ->setup_data_interface() to
nand_controller_ops") missed to invert the if-conditonal for denali.
Since then, the Denali NAND driver cannnot invoke setup_data_interface.

Fixes: 7a08dbaedd36 ("mtd: rawnand: Move ->setup_data_interface() to nand_controller_ops")
Cc: linux-stable <stable@vger.kernel.org> # v4.20
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
---

 drivers/mtd/nand/raw/denali.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Boris Brezillon Jan. 18, 2019, 6:19 a.m. UTC | #1
On Fri, 18 Jan 2019 14:30:38 +0900
Masahiro Yamada <yamada.masahiro@socionext.com> wrote:

> Commit 7a08dbaedd36 ("mtd: rawnand: Move ->setup_data_interface() to
> nand_controller_ops") missed to invert the if-conditonal for denali.
> Since then, the Denali NAND driver cannnot invoke setup_data_interface.
> 
> Fixes: 7a08dbaedd36 ("mtd: rawnand: Move ->setup_data_interface() to nand_controller_ops")
> Cc: linux-stable <stable@vger.kernel.org> # v4.20

Commit 7a08dbaedd36 was merged in 5.0, I'll drop Cc stable when
applying.

> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
> ---
> 
>  drivers/mtd/nand/raw/denali.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/mtd/nand/raw/denali.c b/drivers/mtd/nand/raw/denali.c
> index eebac35..6e8edc9 100644
> --- a/drivers/mtd/nand/raw/denali.c
> +++ b/drivers/mtd/nand/raw/denali.c
> @@ -1322,7 +1322,7 @@ int denali_init(struct denali_nand_info *denali)
>  	}
>  
>  	/* clk rate info is needed for setup_data_interface */
> -	if (denali->clk_rate && denali->clk_x_rate)
> +	if (!denali->clk_rate || !denali->clk_x_rate)
>  		chip->options |= NAND_KEEP_TIMINGS;
>  
>  	chip->legacy.dummy_controller.ops = &denali_controller_ops;
Masahiro Yamada Jan. 18, 2019, 6:21 a.m. UTC | #2
On Fri, Jan 18, 2019 at 3:19 PM Boris Brezillon <bbrezillon@kernel.org> wrote:
>
> On Fri, 18 Jan 2019 14:30:38 +0900
> Masahiro Yamada <yamada.masahiro@socionext.com> wrote:
>
> > Commit 7a08dbaedd36 ("mtd: rawnand: Move ->setup_data_interface() to
> > nand_controller_ops") missed to invert the if-conditonal for denali.
> > Since then, the Denali NAND driver cannnot invoke setup_data_interface.
> >
> > Fixes: 7a08dbaedd36 ("mtd: rawnand: Move ->setup_data_interface() to nand_controller_ops")
> > Cc: linux-stable <stable@vger.kernel.org> # v4.20
>
> Commit 7a08dbaedd36 was merged in 5.0, I'll drop Cc stable when
> applying.


Ah, right. Thanks.
Miquel Raynal Jan. 18, 2019, 8:52 a.m. UTC | #3
Hi Masahiro,

Masahiro Yamada <yamada.masahiro@socionext.com> wrote on Fri, 18 Jan
2019 14:30:38 +0900:

> Commit 7a08dbaedd36 ("mtd: rawnand: Move ->setup_data_interface() to
> nand_controller_ops") missed to invert the if-conditonal for denali.
> Since then, the Denali NAND driver cannnot invoke setup_data_interface.
> 
> Fixes: 7a08dbaedd36 ("mtd: rawnand: Move ->setup_data_interface() to nand_controller_ops")
> Cc: linux-stable <stable@vger.kernel.org> # v4.20
> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
> ---
> 

Acked-by: Miquel Raynal <miquel.raynal@bootlin.com>


Thanks,
Miquèl
Boris Brezillon Jan. 18, 2019, 11:43 a.m. UTC | #4
On Fri, 2019-01-18 at 05:30:38 UTC, Masahiro Yamada wrote:
> Commit 7a08dbaedd36 ("mtd: rawnand: Move ->setup_data_interface() to
> nand_controller_ops") missed to invert the if-conditonal for denali.
> Since then, the Denali NAND driver cannnot invoke setup_data_interface.
> 
> Fixes: 7a08dbaedd36 ("mtd: rawnand: Move ->setup_data_interface() to nand_controller_ops")
> Cc: linux-stable <stable@vger.kernel.org> # v4.20
> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
> Acked-by: Miquel Raynal <miquel.raynal@bootlin.com>

Applied to http://git.infradead.org/linux-mtd.git mtd/fixes, thanks.

Boris
diff mbox series

Patch

diff --git a/drivers/mtd/nand/raw/denali.c b/drivers/mtd/nand/raw/denali.c
index eebac35..6e8edc9 100644
--- a/drivers/mtd/nand/raw/denali.c
+++ b/drivers/mtd/nand/raw/denali.c
@@ -1322,7 +1322,7 @@  int denali_init(struct denali_nand_info *denali)
 	}
 
 	/* clk rate info is needed for setup_data_interface */
-	if (denali->clk_rate && denali->clk_x_rate)
+	if (!denali->clk_rate || !denali->clk_x_rate)
 		chip->options |= NAND_KEEP_TIMINGS;
 
 	chip->legacy.dummy_controller.ops = &denali_controller_ops;