All of lore.kernel.org
 help / color / mirror / Atom feed
* Re: [PATCH -next] mtd: spinand: Fix missing unlock on error path
  2018-07-04  8:29 ` Wei Yongjun
@ 2018-07-04  8:25   ` Boris Brezillon
  -1 siblings, 0 replies; 14+ messages in thread
From: Boris Brezillon @ 2018-07-04  8:25 UTC (permalink / raw)
  To: Wei Yongjun
  Cc: Miquel Raynal, Richard Weinberger, David Woodhouse, Brian Norris,
	Marek Vasut, Peter Pan, Frieder Schrempf, linux-mtd,
	linux-kernel, kernel-janitors

On Wed, 4 Jul 2018 08:29:39 +0000
Wei Yongjun <weiyongjun1@huawei.com> wrote:

> Add the missing unlock before return from function
> spinand_mtd_(read|write) in the error handling case.
> 
> Fixes: c898e0526fb6 ("mtd: nand: Add core infrastructure to support SPI NANDs")
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
> ---
>  drivers/mtd/nand/spi/core.c | 12 ++++++++----
>  1 file changed, 8 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/mtd/nand/spi/core.c b/drivers/mtd/nand/spi/core.c
> index 17d207a..8ac1ba95 100644
> --- a/drivers/mtd/nand/spi/core.c
> +++ b/drivers/mtd/nand/spi/core.c
> @@ -560,12 +560,16 @@ static int spinand_mtd_read(struct mtd_info *mtd, loff_t from,
>  
>  	nanddev_io_for_each_page(nand, from, ops, &iter) {
>  		ret = spinand_select_target(spinand, iter.req.pos.target);
> -		if (ret)
> +		if (ret) {
> +			mutex_unlock(&spinand->lock);
>  			return ret;
> +		}

Why not
		if (ret)
			break;

?

>  
>  		ret = spinand_ecc_enable(spinand, enable_ecc);
> -		if (ret)
> +		if (ret) {
> +			mutex_unlock(&spinand->lock);
>  			return ret;
> +		}

Ditto.

>  
>  		ret = spinand_read_page(spinand, &iter.req, enable_ecc);
>  		if (ret < 0 && ret != -EBADMSG)
> @@ -609,11 +613,11 @@ static int spinand_mtd_write(struct mtd_info *mtd, loff_t to,
>  	nanddev_io_for_each_page(nand, to, ops, &iter) {
>  		ret = spinand_select_target(spinand, iter.req.pos.target);
>  		if (ret)
> -			return ret;
> +			break;
>  
>  		ret = spinand_ecc_enable(spinand, enable_ecc);
>  		if (ret)
> -			return ret;
> +			break;
>  
>  		ret = spinand_write_page(spinand, &iter.req);
>  		if (ret)
> 

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

* Re: [PATCH -next] mtd: spinand: Fix missing unlock on error path
@ 2018-07-04  8:25   ` Boris Brezillon
  0 siblings, 0 replies; 14+ messages in thread
From: Boris Brezillon @ 2018-07-04  8:25 UTC (permalink / raw)
  To: Wei Yongjun
  Cc: Miquel Raynal, Richard Weinberger, David Woodhouse, Brian Norris,
	Marek Vasut, Peter Pan, Frieder Schrempf, linux-mtd,
	linux-kernel, kernel-janitors

On Wed, 4 Jul 2018 08:29:39 +0000
Wei Yongjun <weiyongjun1@huawei.com> wrote:

> Add the missing unlock before return from function
> spinand_mtd_(read|write) in the error handling case.
> 
> Fixes: c898e0526fb6 ("mtd: nand: Add core infrastructure to support SPI NANDs")
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
> ---
>  drivers/mtd/nand/spi/core.c | 12 ++++++++----
>  1 file changed, 8 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/mtd/nand/spi/core.c b/drivers/mtd/nand/spi/core.c
> index 17d207a..8ac1ba95 100644
> --- a/drivers/mtd/nand/spi/core.c
> +++ b/drivers/mtd/nand/spi/core.c
> @@ -560,12 +560,16 @@ static int spinand_mtd_read(struct mtd_info *mtd, loff_t from,
>  
>  	nanddev_io_for_each_page(nand, from, ops, &iter) {
>  		ret = spinand_select_target(spinand, iter.req.pos.target);
> -		if (ret)
> +		if (ret) {
> +			mutex_unlock(&spinand->lock);
>  			return ret;
> +		}

Why not
		if (ret)
			break;

?

>  
>  		ret = spinand_ecc_enable(spinand, enable_ecc);
> -		if (ret)
> +		if (ret) {
> +			mutex_unlock(&spinand->lock);
>  			return ret;
> +		}

Ditto.

>  
>  		ret = spinand_read_page(spinand, &iter.req, enable_ecc);
>  		if (ret < 0 && ret != -EBADMSG)
> @@ -609,11 +613,11 @@ static int spinand_mtd_write(struct mtd_info *mtd, loff_t to,
>  	nanddev_io_for_each_page(nand, to, ops, &iter) {
>  		ret = spinand_select_target(spinand, iter.req.pos.target);
>  		if (ret)
> -			return ret;
> +			break;
>  
>  		ret = spinand_ecc_enable(spinand, enable_ecc);
>  		if (ret)
> -			return ret;
> +			break;
>  
>  		ret = spinand_write_page(spinand, &iter.req);
>  		if (ret)
> 

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

* [PATCH -next] mtd: spinand: Fix missing unlock on error path
  2018-07-04  8:25   ` Boris Brezillon
@ 2018-07-04  8:29 ` Wei Yongjun
  -1 siblings, 0 replies; 14+ messages in thread
From: Wei Yongjun @ 2018-07-04  8:29 UTC (permalink / raw)
  To: Boris Brezillon, Miquel Raynal, Richard Weinberger,
	David Woodhouse, Brian Norris, Marek Vasut, Peter Pan,
	Frieder Schrempf
  Cc: Wei Yongjun, linux-mtd, linux-kernel, kernel-janitors

Add the missing unlock before return from function
spinand_mtd_(read|write) in the error handling case.

Fixes: c898e0526fb6 ("mtd: nand: Add core infrastructure to support SPI NANDs")
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
 drivers/mtd/nand/spi/core.c | 12 ++++++++----
 1 file changed, 8 insertions(+), 4 deletions(-)

diff --git a/drivers/mtd/nand/spi/core.c b/drivers/mtd/nand/spi/core.c
index 17d207a..8ac1ba95 100644
--- a/drivers/mtd/nand/spi/core.c
+++ b/drivers/mtd/nand/spi/core.c
@@ -560,12 +560,16 @@ static int spinand_mtd_read(struct mtd_info *mtd, loff_t from,
 
 	nanddev_io_for_each_page(nand, from, ops, &iter) {
 		ret = spinand_select_target(spinand, iter.req.pos.target);
-		if (ret)
+		if (ret) {
+			mutex_unlock(&spinand->lock);
 			return ret;
+		}
 
 		ret = spinand_ecc_enable(spinand, enable_ecc);
-		if (ret)
+		if (ret) {
+			mutex_unlock(&spinand->lock);
 			return ret;
+		}
 
 		ret = spinand_read_page(spinand, &iter.req, enable_ecc);
 		if (ret < 0 && ret != -EBADMSG)
@@ -609,11 +613,11 @@ static int spinand_mtd_write(struct mtd_info *mtd, loff_t to,
 	nanddev_io_for_each_page(nand, to, ops, &iter) {
 		ret = spinand_select_target(spinand, iter.req.pos.target);
 		if (ret)
-			return ret;
+			break;
 
 		ret = spinand_ecc_enable(spinand, enable_ecc);
 		if (ret)
-			return ret;
+			break;
 
 		ret = spinand_write_page(spinand, &iter.req);
 		if (ret)


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

* [PATCH -next] mtd: spinand: Fix missing unlock on error path
@ 2018-07-04  8:29 ` Wei Yongjun
  0 siblings, 0 replies; 14+ messages in thread
From: Wei Yongjun @ 2018-07-04  8:29 UTC (permalink / raw)
  To: Boris Brezillon, Miquel Raynal, Richard Weinberger,
	David Woodhouse, Brian Norris, Marek Vasut, Peter Pan,
	Frieder Schrempf
  Cc: Wei Yongjun, linux-mtd, linux-kernel, kernel-janitors

Add the missing unlock before return from function
spinand_mtd_(read|write) in the error handling case.

Fixes: c898e0526fb6 ("mtd: nand: Add core infrastructure to support SPI NANDs")
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
 drivers/mtd/nand/spi/core.c | 12 ++++++++----
 1 file changed, 8 insertions(+), 4 deletions(-)

diff --git a/drivers/mtd/nand/spi/core.c b/drivers/mtd/nand/spi/core.c
index 17d207a..8ac1ba95 100644
--- a/drivers/mtd/nand/spi/core.c
+++ b/drivers/mtd/nand/spi/core.c
@@ -560,12 +560,16 @@ static int spinand_mtd_read(struct mtd_info *mtd, loff_t from,
 
 	nanddev_io_for_each_page(nand, from, ops, &iter) {
 		ret = spinand_select_target(spinand, iter.req.pos.target);
-		if (ret)
+		if (ret) {
+			mutex_unlock(&spinand->lock);
 			return ret;
+		}
 
 		ret = spinand_ecc_enable(spinand, enable_ecc);
-		if (ret)
+		if (ret) {
+			mutex_unlock(&spinand->lock);
 			return ret;
+		}
 
 		ret = spinand_read_page(spinand, &iter.req, enable_ecc);
 		if (ret < 0 && ret != -EBADMSG)
@@ -609,11 +613,11 @@ static int spinand_mtd_write(struct mtd_info *mtd, loff_t to,
 	nanddev_io_for_each_page(nand, to, ops, &iter) {
 		ret = spinand_select_target(spinand, iter.req.pos.target);
 		if (ret)
-			return ret;
+			break;
 
 		ret = spinand_ecc_enable(spinand, enable_ecc);
 		if (ret)
-			return ret;
+			break;
 
 		ret = spinand_write_page(spinand, &iter.req);
 		if (ret)


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

* [PATCH -next v2] mtd: spinand: fix missing unlock on error
  2018-07-04  8:29 ` Wei Yongjun
@ 2018-07-04  9:21   ` Wei Yongjun
  -1 siblings, 0 replies; 14+ messages in thread
From: Wei Yongjun @ 2018-07-04  9:21 UTC (permalink / raw)
  To: Boris Brezillon, Miquel Raynal, Richard Weinberger,
	David Woodhouse, Brian Norris, Marek Vasut, Peter Pan,
	Frieder Schrempf
  Cc: Wei Yongjun, linux-mtd, linux-kernel, kernel-janitors

Add the missing unlock before return from function
spinand_mtd_(read|write) in the error handling case.

Fixes: c898e0526fb6 ("mtd: nand: Add core infrastructure to support SPI NANDs")
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
v1 -> v2: using break instead of return
---
 drivers/mtd/nand/spi/core.c | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/drivers/mtd/nand/spi/core.c b/drivers/mtd/nand/spi/core.c
index 17d207a..e072464 100644
--- a/drivers/mtd/nand/spi/core.c
+++ b/drivers/mtd/nand/spi/core.c
@@ -561,11 +561,12 @@ static int spinand_mtd_read(struct mtd_info *mtd, loff_t from,
 	nanddev_io_for_each_page(nand, from, ops, &iter) {
 		ret = spinand_select_target(spinand, iter.req.pos.target);
 		if (ret)
-			return ret;
+			break;
 
 		ret = spinand_ecc_enable(spinand, enable_ecc);
 		if (ret)
-			return ret;
+			break;
+
 
 		ret = spinand_read_page(spinand, &iter.req, enable_ecc);
 		if (ret < 0 && ret != -EBADMSG)
@@ -609,11 +610,11 @@ static int spinand_mtd_write(struct mtd_info *mtd, loff_t to,
 	nanddev_io_for_each_page(nand, to, ops, &iter) {
 		ret = spinand_select_target(spinand, iter.req.pos.target);
 		if (ret)
-			return ret;
+			break;
 
 		ret = spinand_ecc_enable(spinand, enable_ecc);
 		if (ret)
-			return ret;
+			break;
 
 		ret = spinand_write_page(spinand, &iter.req);
 		if (ret)


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

* [PATCH -next v2] mtd: spinand: fix missing unlock on error
@ 2018-07-04  9:21   ` Wei Yongjun
  0 siblings, 0 replies; 14+ messages in thread
From: Wei Yongjun @ 2018-07-04  9:21 UTC (permalink / raw)
  To: Boris Brezillon, Miquel Raynal, Richard Weinberger,
	David Woodhouse, Brian Norris, Marek Vasut, Peter Pan,
	Frieder Schrempf
  Cc: Wei Yongjun, linux-mtd, linux-kernel, kernel-janitors

Add the missing unlock before return from function
spinand_mtd_(read|write) in the error handling case.

Fixes: c898e0526fb6 ("mtd: nand: Add core infrastructure to support SPI NANDs")
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
v1 -> v2: using break instead of return
---
 drivers/mtd/nand/spi/core.c | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/drivers/mtd/nand/spi/core.c b/drivers/mtd/nand/spi/core.c
index 17d207a..e072464 100644
--- a/drivers/mtd/nand/spi/core.c
+++ b/drivers/mtd/nand/spi/core.c
@@ -561,11 +561,12 @@ static int spinand_mtd_read(struct mtd_info *mtd, loff_t from,
 	nanddev_io_for_each_page(nand, from, ops, &iter) {
 		ret = spinand_select_target(spinand, iter.req.pos.target);
 		if (ret)
-			return ret;
+			break;
 
 		ret = spinand_ecc_enable(spinand, enable_ecc);
 		if (ret)
-			return ret;
+			break;
+
 
 		ret = spinand_read_page(spinand, &iter.req, enable_ecc);
 		if (ret < 0 && ret != -EBADMSG)
@@ -609,11 +610,11 @@ static int spinand_mtd_write(struct mtd_info *mtd, loff_t to,
 	nanddev_io_for_each_page(nand, to, ops, &iter) {
 		ret = spinand_select_target(spinand, iter.req.pos.target);
 		if (ret)
-			return ret;
+			break;
 
 		ret = spinand_ecc_enable(spinand, enable_ecc);
 		if (ret)
-			return ret;
+			break;
 
 		ret = spinand_write_page(spinand, &iter.req);
 		if (ret)


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

* [PATCH -next v3] mtd: spinand: fix missing unlock on error
  2018-07-04  9:21   ` Wei Yongjun
@ 2018-07-04  9:30     ` Wei Yongjun
  -1 siblings, 0 replies; 14+ messages in thread
From: Wei Yongjun @ 2018-07-04  9:30 UTC (permalink / raw)
  To: Boris Brezillon, Miquel Raynal, Richard Weinberger,
	David Woodhouse, Brian Norris, Marek Vasut, Frieder Schrempf
  Cc: Wei Yongjun, linux-mtd, linux-kernel, kernel-janitors

Add the missing unlock before return from function
spinand_mtd_(read|write) in the error handling case.

Fixes: c898e0526fb6 ("mtd: nand: Add core infrastructure to support SPI NANDs")
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
v2 -> v3: remove blank line
v1 -> v2: using break instead of return
---
 drivers/mtd/nand/spi/core.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/mtd/nand/spi/core.c b/drivers/mtd/nand/spi/core.c
index 17d207a..8998dca 100644
--- a/drivers/mtd/nand/spi/core.c
+++ b/drivers/mtd/nand/spi/core.c
@@ -561,11 +561,11 @@ static int spinand_mtd_read(struct mtd_info *mtd, loff_t from,
 	nanddev_io_for_each_page(nand, from, ops, &iter) {
 		ret = spinand_select_target(spinand, iter.req.pos.target);
 		if (ret)
-			return ret;
+			break;
 
 		ret = spinand_ecc_enable(spinand, enable_ecc);
 		if (ret)
-			return ret;
+			break;
 
 		ret = spinand_read_page(spinand, &iter.req, enable_ecc);
 		if (ret < 0 && ret != -EBADMSG)
@@ -609,11 +609,11 @@ static int spinand_mtd_write(struct mtd_info *mtd, loff_t to,
 	nanddev_io_for_each_page(nand, to, ops, &iter) {
 		ret = spinand_select_target(spinand, iter.req.pos.target);
 		if (ret)
-			return ret;
+			break;
 
 		ret = spinand_ecc_enable(spinand, enable_ecc);
 		if (ret)
-			return ret;
+			break;
 
 		ret = spinand_write_page(spinand, &iter.req);
 		if (ret)


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

* [PATCH -next v3] mtd: spinand: fix missing unlock on error
@ 2018-07-04  9:30     ` Wei Yongjun
  0 siblings, 0 replies; 14+ messages in thread
From: Wei Yongjun @ 2018-07-04  9:30 UTC (permalink / raw)
  To: Boris Brezillon, Miquel Raynal, Richard Weinberger,
	David Woodhouse, Brian Norris, Marek Vasut, Frieder Schrempf
  Cc: Wei Yongjun, linux-mtd, linux-kernel, kernel-janitors

Add the missing unlock before return from function
spinand_mtd_(read|write) in the error handling case.

Fixes: c898e0526fb6 ("mtd: nand: Add core infrastructure to support SPI NANDs")
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
v2 -> v3: remove blank line
v1 -> v2: using break instead of return
---
 drivers/mtd/nand/spi/core.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/mtd/nand/spi/core.c b/drivers/mtd/nand/spi/core.c
index 17d207a..8998dca 100644
--- a/drivers/mtd/nand/spi/core.c
+++ b/drivers/mtd/nand/spi/core.c
@@ -561,11 +561,11 @@ static int spinand_mtd_read(struct mtd_info *mtd, loff_t from,
 	nanddev_io_for_each_page(nand, from, ops, &iter) {
 		ret = spinand_select_target(spinand, iter.req.pos.target);
 		if (ret)
-			return ret;
+			break;
 
 		ret = spinand_ecc_enable(spinand, enable_ecc);
 		if (ret)
-			return ret;
+			break;
 
 		ret = spinand_read_page(spinand, &iter.req, enable_ecc);
 		if (ret < 0 && ret != -EBADMSG)
@@ -609,11 +609,11 @@ static int spinand_mtd_write(struct mtd_info *mtd, loff_t to,
 	nanddev_io_for_each_page(nand, to, ops, &iter) {
 		ret = spinand_select_target(spinand, iter.req.pos.target);
 		if (ret)
-			return ret;
+			break;
 
 		ret = spinand_ecc_enable(spinand, enable_ecc);
 		if (ret)
-			return ret;
+			break;
 
 		ret = spinand_write_page(spinand, &iter.req);
 		if (ret)


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

* Re: [PATCH -next v3] mtd: spinand: fix missing unlock on error
  2018-07-04  9:30     ` Wei Yongjun
@ 2018-07-05  6:59       ` Miquel Raynal
  -1 siblings, 0 replies; 14+ messages in thread
From: Miquel Raynal @ 2018-07-05  6:59 UTC (permalink / raw)
  To: Wei Yongjun
  Cc: Boris Brezillon, Richard Weinberger, David Woodhouse,
	Brian Norris, Marek Vasut, Frieder Schrempf, linux-mtd,
	linux-kernel, kernel-janitors

Hi Wei,

Wei Yongjun <weiyongjun1@huawei.com> wrote on Wed, 4 Jul 2018 09:30:27
+0000:

> Add the missing unlock before return from function
> spinand_mtd_(read|write) in the error handling case.
> 
> Fixes: c898e0526fb6 ("mtd: nand: Add core infrastructure to support SPI NANDs")
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
> ---

Thanks for the two fixes over the spinand work. As this code is not
yet upstream, do you mind if I fold those fixes directly with the
initial patch?

Thanks,
Miquèl

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

* Re: [PATCH -next v3] mtd: spinand: fix missing unlock on error
@ 2018-07-05  6:59       ` Miquel Raynal
  0 siblings, 0 replies; 14+ messages in thread
From: Miquel Raynal @ 2018-07-05  6:59 UTC (permalink / raw)
  To: Wei Yongjun
  Cc: Boris Brezillon, Richard Weinberger, David Woodhouse,
	Brian Norris, Marek Vasut, Frieder Schrempf, linux-mtd,
	linux-kernel, kernel-janitors

Hi Wei,

Wei Yongjun <weiyongjun1@huawei.com> wrote on Wed, 4 Jul 2018 09:30:27
+0000:

> Add the missing unlock before return from function
> spinand_mtd_(read|write) in the error handling case.
> 
> Fixes: c898e0526fb6 ("mtd: nand: Add core infrastructure to support SPI NANDs")
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
> ---

Thanks for the two fixes over the spinand work. As this code is not
yet upstream, do you mind if I fold those fixes directly with the
initial patch?

Thanks,
Miquèl
--
To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* RE: [PATCH -next v3] mtd: spinand: fix missing unlock on error
  2018-07-05  6:59       ` Miquel Raynal
@ 2018-07-05  8:48         ` weiyongjun (A)
  -1 siblings, 0 replies; 14+ messages in thread
From: weiyongjun (A) @ 2018-07-05  8:48 UTC (permalink / raw)
  To: Miquel Raynal
  Cc: Boris Brezillon, Richard Weinberger, David Woodhouse,
	Brian Norris, Marek Vasut, Frieder Schrempf, linux-mtd,
	linux-kernel, kernel-janitors

> 
> Hi Wei,
> 
> Wei Yongjun <weiyongjun1@huawei.com> wrote on Wed, 4 Jul 2018
> 09:30:27
> +0000:
> 
> > Add the missing unlock before return from function
> > spinand_mtd_(read|write) in the error handling case.
> >
> > Fixes: c898e0526fb6 ("mtd: nand: Add core infrastructure to support SPI
> NANDs")
> > Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
> > ---
> 
> Thanks for the two fixes over the spinand work. As this code is not
> yet upstream, do you mind if I fold those fixes directly with the
> initial patch?

No, I don't. Feel free to fold them to the initial patch.

Regards,
Wei yongjun

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

* RE: [PATCH -next v3] mtd: spinand: fix missing unlock on error
@ 2018-07-05  8:48         ` weiyongjun (A)
  0 siblings, 0 replies; 14+ messages in thread
From: weiyongjun (A) @ 2018-07-05  8:48 UTC (permalink / raw)
  To: Miquel Raynal
  Cc: Boris Brezillon, Richard Weinberger, David Woodhouse,
	Brian Norris, Marek Vasut, Frieder Schrempf, linux-mtd,
	linux-kernel, kernel-janitors

PiANCj4gSGkgV2VpLA0KPiANCj4gV2VpIFlvbmdqdW4gPHdlaXlvbmdqdW4xQGh1YXdlaS5jb20+
IHdyb3RlIG9uIFdlZCwgNCBKdWwgMjAxOA0KPiAwOTozMDoyNw0KPiArMDAwMDoNCj4gDQo+ID4g
QWRkIHRoZSBtaXNzaW5nIHVubG9jayBiZWZvcmUgcmV0dXJuIGZyb20gZnVuY3Rpb24NCj4gPiBz
cGluYW5kX210ZF8ocmVhZHx3cml0ZSkgaW4gdGhlIGVycm9yIGhhbmRsaW5nIGNhc2UuDQo+ID4N
Cj4gPiBGaXhlczogYzg5OGUwNTI2ZmI2ICgibXRkOiBuYW5kOiBBZGQgY29yZSBpbmZyYXN0cnVj
dHVyZSB0byBzdXBwb3J0IFNQSQ0KPiBOQU5EcyIpDQo+ID4gU2lnbmVkLW9mZi1ieTogV2VpIFlv
bmdqdW4gPHdlaXlvbmdqdW4xQGh1YXdlaS5jb20+DQo+ID4gLS0tDQo+IA0KPiBUaGFua3MgZm9y
IHRoZSB0d28gZml4ZXMgb3ZlciB0aGUgc3BpbmFuZCB3b3JrLiBBcyB0aGlzIGNvZGUgaXMgbm90
DQo+IHlldCB1cHN0cmVhbSwgZG8geW91IG1pbmQgaWYgSSBmb2xkIHRob3NlIGZpeGVzIGRpcmVj
dGx5IHdpdGggdGhlDQo+IGluaXRpYWwgcGF0Y2g/DQoNCk5vLCBJIGRvbid0LiBGZWVsIGZyZWUg
dG8gZm9sZCB0aGVtIHRvIHRoZSBpbml0aWFsIHBhdGNoLg0KDQpSZWdhcmRzLA0KV2VpIHlvbmdq
dW4NCg=

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

* Re: [PATCH -next v3] mtd: spinand: fix missing unlock on error
  2018-07-04  9:30     ` Wei Yongjun
@ 2018-07-08 21:50       ` Miquel Raynal
  -1 siblings, 0 replies; 14+ messages in thread
From: Miquel Raynal @ 2018-07-08 21:50 UTC (permalink / raw)
  To: Wei Yongjun
  Cc: Boris Brezillon, Richard Weinberger, David Woodhouse,
	Brian Norris, Marek Vasut, Frieder Schrempf, linux-mtd,
	linux-kernel, kernel-janitors

Hi Wei,

Wei Yongjun <weiyongjun1@huawei.com> wrote on Wed, 4 Jul 2018 09:30:27
+0000:

> Add the missing unlock before return from function
> spinand_mtd_(read|write) in the error handling case.
> 
> Fixes: c898e0526fb6 ("mtd: nand: Add core infrastructure to support SPI NANDs")
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
> ---
> v2 -> v3: remove blank line
> v1 -> v2: using break instead of return
> ---

Merged with the original commit too.

Thanks,
Miquèl

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

* Re: [PATCH -next v3] mtd: spinand: fix missing unlock on error
@ 2018-07-08 21:50       ` Miquel Raynal
  0 siblings, 0 replies; 14+ messages in thread
From: Miquel Raynal @ 2018-07-08 21:50 UTC (permalink / raw)
  To: Wei Yongjun
  Cc: Boris Brezillon, Richard Weinberger, David Woodhouse,
	Brian Norris, Marek Vasut, Frieder Schrempf, linux-mtd,
	linux-kernel, kernel-janitors

Hi Wei,

Wei Yongjun <weiyongjun1@huawei.com> wrote on Wed, 4 Jul 2018 09:30:27
+0000:

> Add the missing unlock before return from function
> spinand_mtd_(read|write) in the error handling case.
> 
> Fixes: c898e0526fb6 ("mtd: nand: Add core infrastructure to support SPI NANDs")
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
> ---
> v2 -> v3: remove blank line
> v1 -> v2: using break instead of return
> ---

Merged with the original commit too.

Thanks,
Miquèl
--
To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

end of thread, other threads:[~2018-07-08 21:50 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-07-04  8:29 [PATCH -next] mtd: spinand: Fix missing unlock on error path Wei Yongjun
2018-07-04  8:29 ` Wei Yongjun
2018-07-04  8:25 ` Boris Brezillon
2018-07-04  8:25   ` Boris Brezillon
2018-07-04  9:21 ` [PATCH -next v2] mtd: spinand: fix missing unlock on error Wei Yongjun
2018-07-04  9:21   ` Wei Yongjun
2018-07-04  9:30   ` [PATCH -next v3] " Wei Yongjun
2018-07-04  9:30     ` Wei Yongjun
2018-07-05  6:59     ` Miquel Raynal
2018-07-05  6:59       ` Miquel Raynal
2018-07-05  8:48       ` weiyongjun (A)
2018-07-05  8:48         ` weiyongjun (A)
2018-07-08 21:50     ` Miquel Raynal
2018-07-08 21:50       ` Miquel Raynal

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.