2023-03-22 18:47:24

by Arseniy Krasnov

[permalink] [raw]
Subject: [PATCH v1] mtd: rawnand: meson: fix bitmask for length in command word

Valid mask is 0x3FFF, without this patch the following problems were
found:

1) [ 0.938914] Could not find a valid ONFI parameter page, trying
bit-wise majority to recover it
[ 0.947384] ONFI parameter recovery failed, aborting

2) Read with disabled ECC mode was broken.

Fixes: 8fae856c5350 ("mtd: rawnand: meson: add support for Amlogic NAND flash controller")
Signed-off-by: Arseniy Krasnov <[email protected]>
---
drivers/mtd/nand/raw/meson_nand.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/mtd/nand/raw/meson_nand.c b/drivers/mtd/nand/raw/meson_nand.c
index a28574c00900..074e14225c06 100644
--- a/drivers/mtd/nand/raw/meson_nand.c
+++ b/drivers/mtd/nand/raw/meson_nand.c
@@ -280,7 +280,7 @@ static void meson_nfc_cmd_access(struct nand_chip *nand, int raw, bool dir,

if (raw) {
len = mtd->writesize + mtd->oobsize;
- cmd = (len & GENMASK(5, 0)) | scrambler | DMA_DIR(dir);
+ cmd = (len & GENMASK(13, 0)) | scrambler | DMA_DIR(dir);
writel(cmd, nfc->reg_base + NFC_REG_CMD);
return;
}
@@ -544,7 +544,7 @@ static int meson_nfc_read_buf(struct nand_chip *nand, u8 *buf, int len)
if (ret)
goto out;

- cmd = NFC_CMD_N2M | (len & GENMASK(5, 0));
+ cmd = NFC_CMD_N2M | (len & GENMASK(13, 0));
writel(cmd, nfc->reg_base + NFC_REG_CMD);

meson_nfc_drain_cmd(nfc);
@@ -568,7 +568,7 @@ static int meson_nfc_write_buf(struct nand_chip *nand, u8 *buf, int len)
if (ret)
return ret;

- cmd = NFC_CMD_M2N | (len & GENMASK(5, 0));
+ cmd = NFC_CMD_M2N | (len & GENMASK(13, 0));
writel(cmd, nfc->reg_base + NFC_REG_CMD);

meson_nfc_drain_cmd(nfc);
--
2.35.0


2023-03-22 20:45:23

by Martin Blumenstingl

[permalink] [raw]
Subject: Re: [PATCH v1] mtd: rawnand: meson: fix bitmask for length in command word

Hello Arseniy,

thank you for submitting this fix!

On Wed, Mar 22, 2023 at 7:45 PM Arseniy Krasnov
<[email protected]> wrote:
>
> Valid mask is 0x3FFF, without this patch the following problems were
> found:
>
> 1) [ 0.938914] Could not find a valid ONFI parameter page, trying
> bit-wise majority to recover it
> [ 0.947384] ONFI parameter recovery failed, aborting
>
> 2) Read with disabled ECC mode was broken.
>
> Fixes: 8fae856c5350 ("mtd: rawnand: meson: add support for Amlogic NAND flash controller")
> Signed-off-by: Arseniy Krasnov <[email protected]>
This matches what I can see in the old vendor driver, so:
Acked-by: Martin Blumenstingl <[email protected]>

[...]
> - cmd = (len & GENMASK(5, 0)) | scrambler | DMA_DIR(dir);
> + cmd = (len & GENMASK(13, 0)) | scrambler | DMA_DIR(dir);
My understanding of the vendor driver is that this "len" is only used
for "raw" access (my own words: any access that doesn't use the HW ECC
engine).
As a future improvement (no need to update re-send this patch) it
would be great to have a #define with a meaningful name for
"GENMASK(13, 0)" (maybe something like NFC_CMD_RAW_LENGTH) as it's
used in multiple places now


Best regards,
Martin

2023-03-23 08:18:20

by Arseniy Krasnov

[permalink] [raw]
Subject: Re: [PATCH v1] mtd: rawnand: meson: fix bitmask for length in command word



On 22.03.2023 23:10, Martin Blumenstingl wrote:
> Hello Arseniy,
>
> thank you for submitting this fix!
Thanks!
>
> On Wed, Mar 22, 2023 at 7:45 PM Arseniy Krasnov
> <[email protected]> wrote:
>>
>> Valid mask is 0x3FFF, without this patch the following problems were
>> found:
>>
>> 1) [ 0.938914] Could not find a valid ONFI parameter page, trying
>> bit-wise majority to recover it
>> [ 0.947384] ONFI parameter recovery failed, aborting
>>
>> 2) Read with disabled ECC mode was broken.
>>
>> Fixes: 8fae856c5350 ("mtd: rawnand: meson: add support for Amlogic NAND flash controller")
>> Signed-off-by: Arseniy Krasnov <[email protected]>
> This matches what I can see in the old vendor driver, so:
Moreover it was clear that mask of 0x3f is too small for length of data in
bytes, for example for 2048 + OOB size.
> Acked-by: Martin Blumenstingl <[email protected]>
>
> [...]
>> - cmd = (len & GENMASK(5, 0)) | scrambler | DMA_DIR(dir);
>> + cmd = (len & GENMASK(13, 0)) | scrambler | DMA_DIR(dir);
> My understanding of the vendor driver is that this "len" is only used
> for "raw" access (my own words: any access that doesn't use the HW ECC
> engine).
Exactly, 'len' is only for raw access.
> As a future improvement (no need to update re-send this patch) it
> would be great to have a #define with a meaningful name for
> "GENMASK(13, 0)" (maybe something like NFC_CMD_RAW_LENGTH) as it's
> used in multiple places now
Ack

Thanks, Arseniy
>
>
> Best regards,
> Martin

2023-03-28 16:10:43

by Arseniy Krasnov

[permalink] [raw]
Subject: Re: [PATCH v1] mtd: rawnand: meson: fix bitmask for length in command word

Hello!

@Miquel Raynal, what is the status of this patch?

Thanks, Arseniy

On 23.03.2023 10:57, Arseniy Krasnov wrote:
>
>
> On 22.03.2023 23:10, Martin Blumenstingl wrote:
>> Hello Arseniy,
>>
>> thank you for submitting this fix!
> Thanks!
>>
>> On Wed, Mar 22, 2023 at 7:45 PM Arseniy Krasnov
>> <[email protected]> wrote:
>>>
>>> Valid mask is 0x3FFF, without this patch the following problems were
>>> found:
>>>
>>> 1) [ 0.938914] Could not find a valid ONFI parameter page, trying
>>> bit-wise majority to recover it
>>> [ 0.947384] ONFI parameter recovery failed, aborting
>>>
>>> 2) Read with disabled ECC mode was broken.
>>>
>>> Fixes: 8fae856c5350 ("mtd: rawnand: meson: add support for Amlogic NAND flash controller")
>>> Signed-off-by: Arseniy Krasnov <[email protected]>
>> This matches what I can see in the old vendor driver, so:
> Moreover it was clear that mask of 0x3f is too small for length of data in
> bytes, for example for 2048 + OOB size.
>> Acked-by: Martin Blumenstingl <[email protected]>
>>
>> [...]
>>> - cmd = (len & GENMASK(5, 0)) | scrambler | DMA_DIR(dir);
>>> + cmd = (len & GENMASK(13, 0)) | scrambler | DMA_DIR(dir);
>> My understanding of the vendor driver is that this "len" is only used
>> for "raw" access (my own words: any access that doesn't use the HW ECC
>> engine).
> Exactly, 'len' is only for raw access.
>> As a future improvement (no need to update re-send this patch) it
>> would be great to have a #define with a meaningful name for
>> "GENMASK(13, 0)" (maybe something like NFC_CMD_RAW_LENGTH) as it's
>> used in multiple places now
> Ack
>
> Thanks, Arseniy
>>
>>
>> Best regards,
>> Martin

2023-03-28 16:56:34

by Miquel Raynal

[permalink] [raw]
Subject: Re: [PATCH v1] mtd: rawnand: meson: fix bitmask for length in command word

Hi Arseniy,

[email protected] wrote on Tue, 28 Mar 2023 18:56:19 +0300:

> Hello!
>
> @Miquel Raynal, what is the status of this patch?

Please, it's been 6 days, there is also a maintainer (Liang) in
between, I'm fine with the patch but it was too late to take it as
part of my previous fixes PR. As said earlier today on the mailing list
to Christophe I will make another fixes PR next week (I'll wait for the
current one to be part of the next -rc tag).

By the way any reason not to have Cc'ed stable?

>
> Thanks, Arseniy
>
> On 23.03.2023 10:57, Arseniy Krasnov wrote:
> >
> >
> > On 22.03.2023 23:10, Martin Blumenstingl wrote:
> >> Hello Arseniy,
> >>
> >> thank you for submitting this fix!
> > Thanks!
> >>
> >> On Wed, Mar 22, 2023 at 7:45 PM Arseniy Krasnov
> >> <[email protected]> wrote:
> >>>
> >>> Valid mask is 0x3FFF, without this patch the following problems were
> >>> found:
> >>>
> >>> 1) [ 0.938914] Could not find a valid ONFI parameter page, trying
> >>> bit-wise majority to recover it
> >>> [ 0.947384] ONFI parameter recovery failed, aborting
> >>>
> >>> 2) Read with disabled ECC mode was broken.
> >>>
> >>> Fixes: 8fae856c5350 ("mtd: rawnand: meson: add support for Amlogic NAND flash controller")
> >>> Signed-off-by: Arseniy Krasnov <[email protected]>
> >> This matches what I can see in the old vendor driver, so:
> > Moreover it was clear that mask of 0x3f is too small for length of data in
> > bytes, for example for 2048 + OOB size.
> >> Acked-by: Martin Blumenstingl <[email protected]>
> >>
> >> [...]
> >>> - cmd = (len & GENMASK(5, 0)) | scrambler | DMA_DIR(dir);
> >>> + cmd = (len & GENMASK(13, 0)) | scrambler | DMA_DIR(dir);
> >> My understanding of the vendor driver is that this "len" is only used
> >> for "raw" access (my own words: any access that doesn't use the HW ECC
> >> engine).
> > Exactly, 'len' is only for raw access.
> >> As a future improvement (no need to update re-send this patch) it
> >> would be great to have a #define with a meaningful name for
> >> "GENMASK(13, 0)" (maybe something like NFC_CMD_RAW_LENGTH) as it's
> >> used in multiple places now
> > Ack
> >
> > Thanks, Arseniy
> >>
> >>
> >> Best regards,
> >> Martin


Thanks,
Miquèl

2023-03-28 18:43:55

by Arseniy Krasnov

[permalink] [raw]
Subject: Re: [PATCH v1] mtd: rawnand: meson: fix bitmask for length in command word



On 28.03.2023 19:50, Miquel Raynal wrote:
> Hi Arseniy,
>
> [email protected] wrote on Tue, 28 Mar 2023 18:56:19 +0300:
>
>> Hello!
>>
>> @Miquel Raynal, what is the status of this patch?
>
> Please, it's been 6 days, there is also a maintainer (Liang) in
> between, I'm fine with the patch but it was too late to take it as
> part of my previous fixes PR. As said earlier today on the mailing list
> to Christophe I will make another fixes PR next week (I'll wait for the
> current one to be part of the next -rc tag).

Thanks for details, sure no problem for PR on the next week! Yes, Liang is a
maintainer, but i didn't see any feedbacks from him on my previous fixes for
this driver.

>
> By the way any reason not to have Cc'ed stable?

Sorry, what do You mean? I've included linux-mtd mailing lists, there is
one more list for mtd reviews? I will appreciate if You can point me

Thanks, Arseniy

>
>>
>> Thanks, Arseniy
>>
>> On 23.03.2023 10:57, Arseniy Krasnov wrote:
>>>
>>>
>>> On 22.03.2023 23:10, Martin Blumenstingl wrote:
>>>> Hello Arseniy,
>>>>
>>>> thank you for submitting this fix!
>>> Thanks!
>>>>
>>>> On Wed, Mar 22, 2023 at 7:45 PM Arseniy Krasnov
>>>> <[email protected]> wrote:
>>>>>
>>>>> Valid mask is 0x3FFF, without this patch the following problems were
>>>>> found:
>>>>>
>>>>> 1) [ 0.938914] Could not find a valid ONFI parameter page, trying
>>>>> bit-wise majority to recover it
>>>>> [ 0.947384] ONFI parameter recovery failed, aborting
>>>>>
>>>>> 2) Read with disabled ECC mode was broken.
>>>>>
>>>>> Fixes: 8fae856c5350 ("mtd: rawnand: meson: add support for Amlogic NAND flash controller")
>>>>> Signed-off-by: Arseniy Krasnov <[email protected]>
>>>> This matches what I can see in the old vendor driver, so:
>>> Moreover it was clear that mask of 0x3f is too small for length of data in
>>> bytes, for example for 2048 + OOB size.
>>>> Acked-by: Martin Blumenstingl <[email protected]>
>>>>
>>>> [...]
>>>>> - cmd = (len & GENMASK(5, 0)) | scrambler | DMA_DIR(dir);
>>>>> + cmd = (len & GENMASK(13, 0)) | scrambler | DMA_DIR(dir);
>>>> My understanding of the vendor driver is that this "len" is only used
>>>> for "raw" access (my own words: any access that doesn't use the HW ECC
>>>> engine).
>>> Exactly, 'len' is only for raw access.
>>>> As a future improvement (no need to update re-send this patch) it
>>>> would be great to have a #define with a meaningful name for
>>>> "GENMASK(13, 0)" (maybe something like NFC_CMD_RAW_LENGTH) as it's
>>>> used in multiple places now
>>> Ack
>>>
>>> Thanks, Arseniy
>>>>
>>>>
>>>> Best regards,
>>>> Martin
>
>
> Thanks,
> Miquèl

2023-03-28 20:28:25

by Martin Blumenstingl

[permalink] [raw]
Subject: Re: [PATCH v1] mtd: rawnand: meson: fix bitmask for length in command word

Hi Arseniy,

On Tue, Mar 28, 2023 at 8:39 PM Arseniy Krasnov
<[email protected]> wrote:
[...]
> >
> > By the way any reason not to have Cc'ed stable?
>
> Sorry, what do You mean? I've included linux-mtd mailing lists, there is
> one more list for mtd reviews? I will appreciate if You can point me
"stable" typically refers to the stable tree where fixes for already
released kernel versions are maintained.
When Miquel applies the patch it will either land in the next -rc of
the current development cycle (typically applies to fixes - currently
6.3-rc5) or -rc1 of the next kernel version (typically applies to new
features, cleanups, etc. - currently 6.4-rc1).

Let's say you are fixing a bug now but want the fix to be included in
6.1 LTS (long term stable) or other stable release.
In this case it's recommended to Cc the maintainers of the stable
trees as part of your patch, see [0].
That way once the commit with your fix hits Linus Torvalds linux tree
it will be backported by the stable team within a few days (assuming
of course that the patch applies cleanly to older versions, if not
they're notifying you).
Note: even without Cc'ing the stable maintainers your commit may be
backported (semi-automatically) if it has a Fixes tag and the stable
maintainers find your commit. But my understanding is that it's
easiest for them if they're explicitly Cc'ed on the patch.

I hope this makes sense. If not: don't hesitate to ask.


Best regards,
Martin


[0] https://www.kernel.org/doc/html/v4.15/process/stable-kernel-rules.html#option-1

2023-03-29 07:22:19

by Arseniy Krasnov

[permalink] [raw]
Subject: Re: [PATCH v1] mtd: rawnand: meson: fix bitmask for length in command word



On 28.03.2023 23:25, Martin Blumenstingl wrote:
> Hi Arseniy,
>
> On Tue, Mar 28, 2023 at 8:39 PM Arseniy Krasnov
> <[email protected]> wrote:
> [...]
>>>
>>> By the way any reason not to have Cc'ed stable?
>>
>> Sorry, what do You mean? I've included linux-mtd mailing lists, there is
>> one more list for mtd reviews? I will appreciate if You can point me
> "stable" typically refers to the stable tree where fixes for already
> released kernel versions are maintained.
> When Miquel applies the patch it will either land in the next -rc of
> the current development cycle (typically applies to fixes - currently
> 6.3-rc5) or -rc1 of the next kernel version (typically applies to new
> features, cleanups, etc. - currently 6.4-rc1).
>
> Let's say you are fixing a bug now but want the fix to be included in
> 6.1 LTS (long term stable) or other stable release.
> In this case it's recommended to Cc the maintainers of the stable
> trees as part of your patch, see [0].
> That way once the commit with your fix hits Linus Torvalds linux tree
> it will be backported by the stable team within a few days (assuming
> of course that the patch applies cleanly to older versions, if not
> they're notifying you).
> Note: even without Cc'ing the stable maintainers your commit may be
> backported (semi-automatically) if it has a Fixes tag and the stable
> maintainers find your commit. But my understanding is that it's
> easiest for them if they're explicitly Cc'ed on the patch.
>
> I hope this makes sense. If not: don't hesitate to ask.

Hello! Thanks for this detailed explanation, that really helps!

Thanks, Arseniy

>
>
> Best regards,
> Martin
>
>
> [0] https://www.kernel.org/doc/html/v4.15/process/stable-kernel-rules.html#option-1

2023-03-29 07:46:44

by Miquel Raynal

[permalink] [raw]
Subject: Re: [PATCH v1] mtd: rawnand: meson: fix bitmask for length in command word

Hello,

[email protected] wrote on Wed, 29 Mar 2023 10:12:10 +0300:

> On 28.03.2023 23:25, Martin Blumenstingl wrote:
> > Hi Arseniy,
> >
> > On Tue, Mar 28, 2023 at 8:39 PM Arseniy Krasnov
> > <[email protected]> wrote:
> > [...]
> >>>
> >>> By the way any reason not to have Cc'ed stable?
> >>
> >> Sorry, what do You mean? I've included linux-mtd mailing lists, there is
> >> one more list for mtd reviews? I will appreciate if You can point me
> > "stable" typically refers to the stable tree where fixes for already
> > released kernel versions are maintained.
> > When Miquel applies the patch it will either land in the next -rc of
> > the current development cycle (typically applies to fixes - currently
> > 6.3-rc5) or -rc1 of the next kernel version (typically applies to new
> > features, cleanups, etc. - currently 6.4-rc1).
> >
> > Let's say you are fixing a bug now but want the fix to be included in
> > 6.1 LTS (long term stable) or other stable release.
> > In this case it's recommended to Cc the maintainers of the stable
> > trees as part of your patch, see [0].
> > That way once the commit with your fix hits Linus Torvalds linux tree
> > it will be backported by the stable team within a few days (assuming
> > of course that the patch applies cleanly to older versions, if not
> > they're notifying you).
> > Note: even without Cc'ing the stable maintainers your commit may be
> > backported (semi-automatically) if it has a Fixes tag and the stable
> > maintainers find your commit. But my understanding is that it's
> > easiest for them if they're explicitly Cc'ed on the patch.
> >
> > I hope this makes sense. If not: don't hesitate to ask.

That is an excellent summary, I should copy/paste it sometimes :)

>
> Hello! Thanks for this detailed explanation, that really helps!

So IOW, I am asking you to send a v2 with an additional line in the
commit, right next "Fixes":

Cc: [email protected]

Thanks,
Miquèl

2023-03-29 07:52:31

by Arseniy Krasnov

[permalink] [raw]
Subject: Re: [PATCH v1] mtd: rawnand: meson: fix bitmask for length in command word



On 29.03.2023 10:31, Miquel Raynal wrote:
> Hello,
>
> [email protected] wrote on Wed, 29 Mar 2023 10:12:10 +0300:
>
>> On 28.03.2023 23:25, Martin Blumenstingl wrote:
>>> Hi Arseniy,
>>>
>>> On Tue, Mar 28, 2023 at 8:39 PM Arseniy Krasnov
>>> <[email protected]> wrote:
>>> [...]
>>>>>
>>>>> By the way any reason not to have Cc'ed stable?
>>>>
>>>> Sorry, what do You mean? I've included linux-mtd mailing lists, there is
>>>> one more list for mtd reviews? I will appreciate if You can point me
>>> "stable" typically refers to the stable tree where fixes for already
>>> released kernel versions are maintained.
>>> When Miquel applies the patch it will either land in the next -rc of
>>> the current development cycle (typically applies to fixes - currently
>>> 6.3-rc5) or -rc1 of the next kernel version (typically applies to new
>>> features, cleanups, etc. - currently 6.4-rc1).
>>>
>>> Let's say you are fixing a bug now but want the fix to be included in
>>> 6.1 LTS (long term stable) or other stable release.
>>> In this case it's recommended to Cc the maintainers of the stable
>>> trees as part of your patch, see [0].
>>> That way once the commit with your fix hits Linus Torvalds linux tree
>>> it will be backported by the stable team within a few days (assuming
>>> of course that the patch applies cleanly to older versions, if not
>>> they're notifying you).
>>> Note: even without Cc'ing the stable maintainers your commit may be
>>> backported (semi-automatically) if it has a Fixes tag and the stable
>>> maintainers find your commit. But my understanding is that it's
>>> easiest for them if they're explicitly Cc'ed on the patch.
>>>
>>> I hope this makes sense. If not: don't hesitate to ask.
>
> That is an excellent summary, I should copy/paste it sometimes :)
>
>>
>> Hello! Thanks for this detailed explanation, that really helps!
>
> So IOW, I am asking you to send a v2 with an additional line in the
> commit, right next "Fixes":
>
> Cc: [email protected]

Done!

Thanks, Arseniy

>
> Thanks,
> Miquèl

2023-03-29 08:31:46

by Tudor Ambarus

[permalink] [raw]
Subject: Re: [PATCH v1] mtd: rawnand: meson: fix bitmask for length in command word



On 3/29/23 09:17, Dmitry Rokosov wrote:
> On Wed, Mar 29, 2023 at 09:31:45AM +0200, Miquel Raynal wrote:
>> Hello,
>>
>> [email protected] wrote on Wed, 29 Mar 2023 10:12:10 +0300:
>>
>>> On 28.03.2023 23:25, Martin Blumenstingl wrote:
>>>> Hi Arseniy,
>>>>
>>>> On Tue, Mar 28, 2023 at 8:39 PM Arseniy Krasnov
>>>> <[email protected]> wrote:
>>>> [...]
>>>>>>
>>>>>> By the way any reason not to have Cc'ed stable?
>>>>>
>>>>> Sorry, what do You mean? I've included linux-mtd mailing lists, there is
>>>>> one more list for mtd reviews? I will appreciate if You can point me
>>>> "stable" typically refers to the stable tree where fixes for already
>>>> released kernel versions are maintained.
>>>> When Miquel applies the patch it will either land in the next -rc of
>>>> the current development cycle (typically applies to fixes - currently
>>>> 6.3-rc5) or -rc1 of the next kernel version (typically applies to new
>>>> features, cleanups, etc. - currently 6.4-rc1).
>>>>
>>>> Let's say you are fixing a bug now but want the fix to be included in
>>>> 6.1 LTS (long term stable) or other stable release.
>>>> In this case it's recommended to Cc the maintainers of the stable
>>>> trees as part of your patch, see [0].
>>>> That way once the commit with your fix hits Linus Torvalds linux tree
>>>> it will be backported by the stable team within a few days (assuming
>>>> of course that the patch applies cleanly to older versions, if not
>>>> they're notifying you).
>>>> Note: even without Cc'ing the stable maintainers your commit may be
>>>> backported (semi-automatically) if it has a Fixes tag and the stable
>>>> maintainers find your commit. But my understanding is that it's
>>>> easiest for them if they're explicitly Cc'ed on the patch.
>>>>
>>>> I hope this makes sense. If not: don't hesitate to ask.
>>
>> That is an excellent summary, I should copy/paste it sometimes :)
>>
>
> Finally I fully understand why 'Fixes' tag is so helpful!
> Thank you Martin!
>

Here's the official documentation:
https://www.kernel.org/doc/html/latest/process/stable-kernel-rules.html

2023-03-29 08:33:40

by Dmitry Rokosov

[permalink] [raw]
Subject: Re: [PATCH v1] mtd: rawnand: meson: fix bitmask for length in command word

On Wed, Mar 29, 2023 at 09:31:45AM +0200, Miquel Raynal wrote:
> Hello,
>
> [email protected] wrote on Wed, 29 Mar 2023 10:12:10 +0300:
>
> > On 28.03.2023 23:25, Martin Blumenstingl wrote:
> > > Hi Arseniy,
> > >
> > > On Tue, Mar 28, 2023 at 8:39 PM Arseniy Krasnov
> > > <[email protected]> wrote:
> > > [...]
> > >>>
> > >>> By the way any reason not to have Cc'ed stable?
> > >>
> > >> Sorry, what do You mean? I've included linux-mtd mailing lists, there is
> > >> one more list for mtd reviews? I will appreciate if You can point me
> > > "stable" typically refers to the stable tree where fixes for already
> > > released kernel versions are maintained.
> > > When Miquel applies the patch it will either land in the next -rc of
> > > the current development cycle (typically applies to fixes - currently
> > > 6.3-rc5) or -rc1 of the next kernel version (typically applies to new
> > > features, cleanups, etc. - currently 6.4-rc1).
> > >
> > > Let's say you are fixing a bug now but want the fix to be included in
> > > 6.1 LTS (long term stable) or other stable release.
> > > In this case it's recommended to Cc the maintainers of the stable
> > > trees as part of your patch, see [0].
> > > That way once the commit with your fix hits Linus Torvalds linux tree
> > > it will be backported by the stable team within a few days (assuming
> > > of course that the patch applies cleanly to older versions, if not
> > > they're notifying you).
> > > Note: even without Cc'ing the stable maintainers your commit may be
> > > backported (semi-automatically) if it has a Fixes tag and the stable
> > > maintainers find your commit. But my understanding is that it's
> > > easiest for them if they're explicitly Cc'ed on the patch.
> > >
> > > I hope this makes sense. If not: don't hesitate to ask.
>
> That is an excellent summary, I should copy/paste it sometimes :)
>

Finally I fully understand why 'Fixes' tag is so helpful!
Thank you Martin!

[...]

--
Thank you,
Dmitry

2023-03-29 10:02:16

by Dmitry Rokosov

[permalink] [raw]
Subject: Re: [PATCH v1] mtd: rawnand: meson: fix bitmask for length in command word

On Wed, Mar 29, 2023 at 09:20:14AM +0100, Tudor Ambarus wrote:
>
>
> On 3/29/23 09:17, Dmitry Rokosov wrote:
> > On Wed, Mar 29, 2023 at 09:31:45AM +0200, Miquel Raynal wrote:
> >> Hello,
> >>
> >> [email protected] wrote on Wed, 29 Mar 2023 10:12:10 +0300:
> >>
> >>> On 28.03.2023 23:25, Martin Blumenstingl wrote:
> >>>> Hi Arseniy,
> >>>>
> >>>> On Tue, Mar 28, 2023 at 8:39 PM Arseniy Krasnov
> >>>> <[email protected]> wrote:
> >>>> [...]
> >>>>>>
> >>>>>> By the way any reason not to have Cc'ed stable?
> >>>>>
> >>>>> Sorry, what do You mean? I've included linux-mtd mailing lists, there is
> >>>>> one more list for mtd reviews? I will appreciate if You can point me
> >>>> "stable" typically refers to the stable tree where fixes for already
> >>>> released kernel versions are maintained.
> >>>> When Miquel applies the patch it will either land in the next -rc of
> >>>> the current development cycle (typically applies to fixes - currently
> >>>> 6.3-rc5) or -rc1 of the next kernel version (typically applies to new
> >>>> features, cleanups, etc. - currently 6.4-rc1).
> >>>>
> >>>> Let's say you are fixing a bug now but want the fix to be included in
> >>>> 6.1 LTS (long term stable) or other stable release.
> >>>> In this case it's recommended to Cc the maintainers of the stable
> >>>> trees as part of your patch, see [0].
> >>>> That way once the commit with your fix hits Linus Torvalds linux tree
> >>>> it will be backported by the stable team within a few days (assuming
> >>>> of course that the patch applies cleanly to older versions, if not
> >>>> they're notifying you).
> >>>> Note: even without Cc'ing the stable maintainers your commit may be
> >>>> backported (semi-automatically) if it has a Fixes tag and the stable
> >>>> maintainers find your commit. But my understanding is that it's
> >>>> easiest for them if they're explicitly Cc'ed on the patch.
> >>>>
> >>>> I hope this makes sense. If not: don't hesitate to ask.
> >>
> >> That is an excellent summary, I should copy/paste it sometimes :)
> >>
> >
> > Finally I fully understand why 'Fixes' tag is so helpful!
> > Thank you Martin!
> >
>
> Here's the official documentation:
> https://www.kernel.org/doc/html/latest/process/stable-kernel-rules.html

Tudor thank you for suggestion!

I don't see anything about Fixes: tag on this page, but looks like
'Submitting patches' tutorial has it:

"""
A Fixes: tag indicates that the patch fixes an issue in a previous
commit. It is used to make it easy to determine where a bug originated,
which can help review a bug fix. This tag also assists the stable kernel
team in determining which stable kernel versions should receive your
fix. This is the preferred method for indicating a bug fixed by the
patch. See Describe your changes for more details.
"""
--
Thank you,
Dmitry