2019-01-29 10:59:19

by Colin King

[permalink] [raw]
Subject: [PATCH][next] mtd: rawnand: meson: fix missing assignment of ret on a call to meson_chip_buffer_init

From: Colin Ian King <[email protected]>

The call to meson_chip_buffer_init is not assigning ret, however, ret
is being checked for failure. Fix this by adding in the missing assignment.

Fixes: 2d570b34b41a ("mtd: rawnand: meson: add support for Amlogic NAND flash controller")
Signed-off-by: Colin Ian King <[email protected]>
---
drivers/mtd/nand/raw/meson_nand.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mtd/nand/raw/meson_nand.c b/drivers/mtd/nand/raw/meson_nand.c
index e858d58d97b0..b9c543d1054c 100644
--- a/drivers/mtd/nand/raw/meson_nand.c
+++ b/drivers/mtd/nand/raw/meson_nand.c
@@ -1206,7 +1206,7 @@ static int meson_nand_attach_chip(struct nand_chip *nand)
dev_err(nfc->dev, "16bits bus width not supported");
return -EINVAL;
}
- meson_chip_buffer_init(nand);
+ ret = meson_chip_buffer_init(nand);
if (ret)
return -ENOMEM;

--
2.19.1



2019-01-30 05:35:31

by Liang Yang

[permalink] [raw]
Subject: Re: [PATCH][next] mtd: rawnand: meson: fix missing assignment of ret on a call to meson_chip_buffer_init

Hello Colin,

On 2019/1/29 18:57, Colin King wrote:
> From: Colin Ian King <[email protected]>
>
> The call to meson_chip_buffer_init is not assigning ret, however, ret
> is being checked for failure. Fix this by adding in the missing assignment.
>
ok. thanks for your time.

> Fixes: 2d570b34b41a ("mtd: rawnand: meson: add support for Amlogic NAND flash controller")
> Signed-off-by: Colin Ian King <[email protected]>
> ---
> drivers/mtd/nand/raw/meson_nand.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/mtd/nand/raw/meson_nand.c b/drivers/mtd/nand/raw/meson_nand.c
> index e858d58d97b0..b9c543d1054c 100644
> --- a/drivers/mtd/nand/raw/meson_nand.c
> +++ b/drivers/mtd/nand/raw/meson_nand.c
> @@ -1206,7 +1206,7 @@ static int meson_nand_attach_chip(struct nand_chip *nand)
> dev_err(nfc->dev, "16bits bus width not supported");
> return -EINVAL;
> }
> - meson_chip_buffer_init(nand);
> + ret = meson_chip_buffer_init(nand); > if (ret)
> return -ENOMEM;
>
>

2019-01-30 09:27:46

by Liang Yang

[permalink] [raw]
Subject: Re: [PATCH][next] mtd: rawnand: meson: fix missing assignment of ret on a call to meson_chip_buffer_init

Hi Colin,

On 2019/1/29 18:57, Colin King wrote:
> From: Colin Ian King <[email protected]>
>
> The call to meson_chip_buffer_init is not assigning ret, however, ret
> is being checked for failure. Fix this by adding in the missing assignment.
>
> Fixes: 2d570b34b41a ("mtd: rawnand: meson: add support for Amlogic NAND flash controller")
> Signed-off-by: Colin Ian King <[email protected]>
> ---
> drivers/mtd/nand/raw/meson_nand.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/mtd/nand/raw/meson_nand.c b/drivers/mtd/nand/raw/meson_nand.c
> index e858d58d97b0..b9c543d1054c 100644
> --- a/drivers/mtd/nand/raw/meson_nand.c
> +++ b/drivers/mtd/nand/raw/meson_nand.c
> @@ -1206,7 +1206,7 @@ static int meson_nand_attach_chip(struct nand_chip *nand)
> dev_err(nfc->dev, "16bits bus width not supported");
> return -EINVAL;
> }
> - meson_chip_buffer_init(nand);
> + ret = meson_chip_buffer_init(nand);

Looks good to me:

Acked-by: Liang Yang <[email protected]>

> if (ret)
> return -ENOMEM;
>
>

2019-01-30 09:34:42

by Miquel Raynal

[permalink] [raw]
Subject: Re: [PATCH][next] mtd: rawnand: meson: fix missing assignment of ret on a call to meson_chip_buffer_init

Hi Liang, Colin,

Liang Yang <[email protected]> wrote on Wed, 30 Jan 2019 17:26:49
+0800:

> Hi Colin,
>
> On 2019/1/29 18:57, Colin King wrote:
> > From: Colin Ian King <[email protected]>
> >
> > The call to meson_chip_buffer_init is not assigning ret, however, ret
> > is being checked for failure. Fix this by adding in the missing assignment.
> >
> > Fixes: 2d570b34b41a ("mtd: rawnand: meson: add support for Amlogic NAND flash controller")
> > Signed-off-by: Colin Ian King <[email protected]>
> > ---
> > drivers/mtd/nand/raw/meson_nand.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/drivers/mtd/nand/raw/meson_nand.c b/drivers/mtd/nand/raw/meson_nand.c
> > index e858d58d97b0..b9c543d1054c 100644
> > --- a/drivers/mtd/nand/raw/meson_nand.c
> > +++ b/drivers/mtd/nand/raw/meson_nand.c
> > @@ -1206,7 +1206,7 @@ static int meson_nand_attach_chip(struct nand_chip *nand)
> > dev_err(nfc->dev, "16bits bus width not supported");
> > return -EINVAL;
> > }
> > - meson_chip_buffer_init(nand);
> > + ret = meson_chip_buffer_init(nand);
>
> Looks good to me:
>
> Acked-by: Liang Yang <[email protected]>

This is nand/next material, so if you don't mind I would like to squash
the two fixes you sent into the original commit inserting the driver.


Thanks,
Miquèl

2019-01-30 09:35:07

by Colin King

[permalink] [raw]
Subject: Re: [PATCH][next] mtd: rawnand: meson: fix missing assignment of ret on a call to meson_chip_buffer_init

On 30/01/2019 09:32, Miquel Raynal wrote:
> Hi Liang, Colin,
>
> Liang Yang <[email protected]> wrote on Wed, 30 Jan 2019 17:26:49
> +0800:
>
>> Hi Colin,
>>
>> On 2019/1/29 18:57, Colin King wrote:
>>> From: Colin Ian King <[email protected]>
>>>
>>> The call to meson_chip_buffer_init is not assigning ret, however, ret
>>> is being checked for failure. Fix this by adding in the missing assignment.
>>>
>>> Fixes: 2d570b34b41a ("mtd: rawnand: meson: add support for Amlogic NAND flash controller")
>>> Signed-off-by: Colin Ian King <[email protected]>
>>> ---
>>> drivers/mtd/nand/raw/meson_nand.c | 2 +-
>>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>>
>>> diff --git a/drivers/mtd/nand/raw/meson_nand.c b/drivers/mtd/nand/raw/meson_nand.c
>>> index e858d58d97b0..b9c543d1054c 100644
>>> --- a/drivers/mtd/nand/raw/meson_nand.c
>>> +++ b/drivers/mtd/nand/raw/meson_nand.c
>>> @@ -1206,7 +1206,7 @@ static int meson_nand_attach_chip(struct nand_chip *nand)
>>> dev_err(nfc->dev, "16bits bus width not supported");
>>> return -EINVAL;
>>> }
>>> - meson_chip_buffer_init(nand);
>>> + ret = meson_chip_buffer_init(nand);
>>
>> Looks good to me:
>>
>> Acked-by: Liang Yang <[email protected]>
>
> This is nand/next material, so if you don't mind I would like to squash
> the two fixes you sent into the original commit inserting the driver.

Sure, ok with me, squashing them makes sense.

Colin
>
>
> Thanks,
> Miquèl
>


2019-01-30 09:42:59

by Liang Yang

[permalink] [raw]
Subject: Re: [PATCH][next] mtd: rawnand: meson: fix missing assignment of ret on a call to meson_chip_buffer_init

Hi Miquel, Colin,

On 2019/1/30 17:34, Colin Ian King wrote:
> On 30/01/2019 09:32, Miquel Raynal wrote:
>> Hi Liang, Colin,
>>
>> Liang Yang <[email protected]> wrote on Wed, 30 Jan 2019 17:26:49
>> +0800:
>>
>>> Hi Colin,
>>>
>>> On 2019/1/29 18:57, Colin King wrote:
>>>> From: Colin Ian King <[email protected]>
>>>>
>>>> The call to meson_chip_buffer_init is not assigning ret, however, ret
>>>> is being checked for failure. Fix this by adding in the missing assignment.
>>>>
>>>> Fixes: 2d570b34b41a ("mtd: rawnand: meson: add support for Amlogic NAND flash controller")
>>>> Signed-off-by: Colin Ian King <[email protected]>
>>>> ---
>>>> drivers/mtd/nand/raw/meson_nand.c | 2 +-
>>>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>>>
>>>> diff --git a/drivers/mtd/nand/raw/meson_nand.c b/drivers/mtd/nand/raw/meson_nand.c
>>>> index e858d58d97b0..b9c543d1054c 100644
>>>> --- a/drivers/mtd/nand/raw/meson_nand.c
>>>> +++ b/drivers/mtd/nand/raw/meson_nand.c
>>>> @@ -1206,7 +1206,7 @@ static int meson_nand_attach_chip(struct nand_chip *nand)
>>>> dev_err(nfc->dev, "16bits bus width not supported");
>>>> return -EINVAL;
>>>> }
>>>> - meson_chip_buffer_init(nand);
>>>> + ret = meson_chip_buffer_init(nand);
>>>
>>> Looks good to me:
>>>
>>> Acked-by: Liang Yang <[email protected]>
>>
>> This is nand/next material, so if you don't mind I would like to squash
>> the two fixes you sent into the original commit inserting the driver.
>
> Sure, ok with me, squashing them makes sense.
>
> Colin

ok.

>>
>>
>> Thanks,
>> Miquèl
>>
>
> .
>

2019-02-05 19:07:46

by Miquel Raynal

[permalink] [raw]
Subject: Re: [PATCH][next] mtd: rawnand: meson: fix missing assignment of ret on a call to meson_chip_buffer_init

Hi Colin,

Colin King <[email protected]> wrote on Tue, 29 Jan 2019
10:57:57 +0000:

> From: Colin Ian King <[email protected]>
>
> The call to meson_chip_buffer_init is not assigning ret, however, ret
> is being checked for failure. Fix this by adding in the missing assignment.
>
> Fixes: 2d570b34b41a ("mtd: rawnand: meson: add support for Amlogic NAND flash controller")
> Signed-off-by: Colin Ian King <[email protected]>
> ---
> drivers/mtd/nand/raw/meson_nand.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>

Merged in nand/next with the original commit.


Thanks,
Miquèl