All of lore.kernel.org
 help / color / mirror / Atom feed
* [meta-oe][PATCH] image_types_sparse: stop using ext2simg
@ 2021-08-18 15:39 Dmitry Baryshkov
  2021-08-18 18:22 ` [oe] " Khem Raj
  0 siblings, 1 reply; 8+ messages in thread
From: Dmitry Baryshkov @ 2021-08-18 15:39 UTC (permalink / raw)
  To: openembedded-devel

Under some conditions ext2simg can corrupt the file system (see
https://lore.kernel.org/linux-ext4/CAP71WjwVdqmLEq1NGWK36JkEd-i05YcAu4jeY6GFjsk6TS=Mtg@mail.gmail.com/).
This has been reproduced with the ext2simg currently found meta-oe's
android-tools-native). Stop using ext2simg and always use img2simg. This
results in bigger images, but without the risk of image corruption.

Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
---
 meta-oe/classes/image_types_sparse.bbclass | 12 ++----------
 1 file changed, 2 insertions(+), 10 deletions(-)

diff --git a/meta-oe/classes/image_types_sparse.bbclass b/meta-oe/classes/image_types_sparse.bbclass
index 65d980fd913f..4263593a8dd1 100644
--- a/meta-oe/classes/image_types_sparse.bbclass
+++ b/meta-oe/classes/image_types_sparse.bbclass
@@ -2,15 +2,7 @@ inherit image_types
 
 CONVERSIONTYPES += "sparse"
 CONVERSION_CMD:sparse = " \
-    case "${type}" in \
-        ext*) \
-            ext2simg "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" \
-                     "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}.sparse" \
-            ;; \
-        *) \
-            img2simg "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" \
-                     "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}.sparse" \
-            ;; \
-    esac \
+    img2simg "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" \
+             "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}.sparse" \
 "
 CONVERSION_DEPENDS_sparse = "android-tools-native"
-- 
2.30.2


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

* Re: [oe] [meta-oe][PATCH] image_types_sparse: stop using ext2simg
  2021-08-18 15:39 [meta-oe][PATCH] image_types_sparse: stop using ext2simg Dmitry Baryshkov
@ 2021-08-18 18:22 ` Khem Raj
  2021-08-20 14:43   ` Dmitry Baryshkov
  0 siblings, 1 reply; 8+ messages in thread
From: Khem Raj @ 2021-08-18 18:22 UTC (permalink / raw)
  To: Dmitry Baryshkov; +Cc: openembeded-devel

On Wed, Aug 18, 2021 at 8:39 AM Dmitry Baryshkov <dbaryshkov@gmail.com> wrote:
>
> Under some conditions ext2simg can corrupt the file system (see
> https://lore.kernel.org/linux-ext4/CAP71WjwVdqmLEq1NGWK36JkEd-i05YcAu4jeY6GFjsk6TS=Mtg@mail.gmail.com/).
> This has been reproduced with the ext2simg currently found meta-oe's
> android-tools-native). Stop using ext2simg and always use img2simg. This
> results in bigger images, but without the risk of image corruption.

how big are the images ?

>
> Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
> ---
>  meta-oe/classes/image_types_sparse.bbclass | 12 ++----------
>  1 file changed, 2 insertions(+), 10 deletions(-)
>
> diff --git a/meta-oe/classes/image_types_sparse.bbclass b/meta-oe/classes/image_types_sparse.bbclass
> index 65d980fd913f..4263593a8dd1 100644
> --- a/meta-oe/classes/image_types_sparse.bbclass
> +++ b/meta-oe/classes/image_types_sparse.bbclass
> @@ -2,15 +2,7 @@ inherit image_types
>
>  CONVERSIONTYPES += "sparse"
>  CONVERSION_CMD:sparse = " \
> -    case "${type}" in \
> -        ext*) \
> -            ext2simg "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" \
> -                     "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}.sparse" \
> -            ;; \
> -        *) \
> -            img2simg "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" \
> -                     "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}.sparse" \
> -            ;; \
> -    esac \
> +    img2simg "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" \
> +             "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}.sparse" \
>  "
>  CONVERSION_DEPENDS_sparse = "android-tools-native"
> --
> 2.30.2
>
>
> 
>

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

* Re: [oe] [meta-oe][PATCH] image_types_sparse: stop using ext2simg
  2021-08-18 18:22 ` [oe] " Khem Raj
@ 2021-08-20 14:43   ` Dmitry Baryshkov
  2021-08-20 18:03     ` Khem Raj
  0 siblings, 1 reply; 8+ messages in thread
From: Dmitry Baryshkov @ 2021-08-20 14:43 UTC (permalink / raw)
  To: Khem Raj; +Cc: openembeded-devel

ср, 18 авг. 2021 г. в 21:23, Khem Raj <raj.khem@gmail.com>:
>
> On Wed, Aug 18, 2021 at 8:39 AM Dmitry Baryshkov <dbaryshkov@gmail.com> wrote:
> >
> > Under some conditions ext2simg can corrupt the file system (see
> > https://lore.kernel.org/linux-ext4/CAP71WjwVdqmLEq1NGWK36JkEd-i05YcAu4jeY6GFjsk6TS=Mtg@mail.gmail.com/).
> > This has been reproduced with the ext2simg currently found meta-oe's
> > android-tools-native). Stop using ext2simg and always use img2simg. This
> > results in bigger images, but without the risk of image corruption.
>
> how big are the images ?

Just checked. I've 1GB (964 MB) ext4 image. gzipped it takes 227 MB.
Given that I got:
ext2simg - 518MB
img2simg - 655 MB

>
> >
> > Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
> > ---
> >  meta-oe/classes/image_types_sparse.bbclass | 12 ++----------
> >  1 file changed, 2 insertions(+), 10 deletions(-)
> >
> > diff --git a/meta-oe/classes/image_types_sparse.bbclass b/meta-oe/classes/image_types_sparse.bbclass
> > index 65d980fd913f..4263593a8dd1 100644
> > --- a/meta-oe/classes/image_types_sparse.bbclass
> > +++ b/meta-oe/classes/image_types_sparse.bbclass
> > @@ -2,15 +2,7 @@ inherit image_types
> >
> >  CONVERSIONTYPES += "sparse"
> >  CONVERSION_CMD:sparse = " \
> > -    case "${type}" in \
> > -        ext*) \
> > -            ext2simg "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" \
> > -                     "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}.sparse" \
> > -            ;; \
> > -        *) \
> > -            img2simg "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" \
> > -                     "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}.sparse" \
> > -            ;; \
> > -    esac \
> > +    img2simg "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" \
> > +             "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}.sparse" \
> >  "
> >  CONVERSION_DEPENDS_sparse = "android-tools-native"
> > --
> > 2.30.2
> >
> >
> > 
> >



-- 
With best wishes
Dmitry

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

* Re: [oe] [meta-oe][PATCH] image_types_sparse: stop using ext2simg
  2021-08-20 14:43   ` Dmitry Baryshkov
@ 2021-08-20 18:03     ` Khem Raj
  2021-08-25 19:45       ` Dmitry Baryshkov
  2021-08-30 20:36       ` Dmitry Baryshkov
  0 siblings, 2 replies; 8+ messages in thread
From: Khem Raj @ 2021-08-20 18:03 UTC (permalink / raw)
  To: Dmitry Baryshkov; +Cc: openembeded-devel

[-- Attachment #1: Type: text/plain, Size: 2355 bytes --]

On Fri, Aug 20, 2021 at 7:43 AM Dmitry Baryshkov <dbaryshkov@gmail.com>
wrote:

> ср, 18 авг. 2021 г. в 21:23, Khem Raj <raj.khem@gmail.com>:
> >
> > On Wed, Aug 18, 2021 at 8:39 AM Dmitry Baryshkov <dbaryshkov@gmail.com>
> wrote:
> > >
> > > Under some conditions ext2simg can corrupt the file system (see
> > >
> https://lore.kernel.org/linux-ext4/CAP71WjwVdqmLEq1NGWK36JkEd-i05YcAu4jeY6GFjsk6TS=Mtg@mail.gmail.com/
> ).
> > > This has been reproduced with the ext2simg currently found meta-oe's
> > > android-tools-native). Stop using ext2simg and always use img2simg.
> This
> > > results in bigger images, but without the risk of image corruption.
> >
> > how big are the images ?
>
> Just checked. I've 1GB (964 MB) ext4 image. gzipped it takes 227 MB.
> Given that I got:
> ext2simg - 518MB
> img2simg - 655 MB


Hmm so Choice is corrupted at times and small or big but not corrupted I
guess we should take the second option as it seems more stable

>
>
> >
> > >
> > > Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
> > > ---
> > >  meta-oe/classes/image_types_sparse.bbclass | 12 ++----------
> > >  1 file changed, 2 insertions(+), 10 deletions(-)
> > >
> > > diff --git a/meta-oe/classes/image_types_sparse.bbclass
> b/meta-oe/classes/image_types_sparse.bbclass
> > > index 65d980fd913f..4263593a8dd1 100644
> > > --- a/meta-oe/classes/image_types_sparse.bbclass
> > > +++ b/meta-oe/classes/image_types_sparse.bbclass
> > > @@ -2,15 +2,7 @@ inherit image_types
> > >
> > >  CONVERSIONTYPES += "sparse"
> > >  CONVERSION_CMD:sparse = " \
> > > -    case "${type}" in \
> > > -        ext*) \
> > > -            ext2simg "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" \
> > > -
>  "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}.sparse" \
> > > -            ;; \
> > > -        *) \
> > > -            img2simg "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" \
> > > -
>  "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}.sparse" \
> > > -            ;; \
> > > -    esac \
> > > +    img2simg "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" \
> > > +             "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}.sparse" \
> > >  "
> > >  CONVERSION_DEPENDS_sparse = "android-tools-native"
> > > --
> > > 2.30.2
> > >
> > >
> > > 
> > >
>
>
>
> --
> With best wishes
> Dmitry
>

[-- Attachment #2: Type: text/html, Size: 3702 bytes --]

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

* Re: [oe] [meta-oe][PATCH] image_types_sparse: stop using ext2simg
  2021-08-20 18:03     ` Khem Raj
@ 2021-08-25 19:45       ` Dmitry Baryshkov
  2021-08-30 20:36       ` Dmitry Baryshkov
  1 sibling, 0 replies; 8+ messages in thread
From: Dmitry Baryshkov @ 2021-08-25 19:45 UTC (permalink / raw)
  To: Khem Raj; +Cc: openembeded-devel

Hi,

пт, 20 авг. 2021 г. в 21:03, Khem Raj <raj.khem@gmail.com>:
>
>
>
> On Fri, Aug 20, 2021 at 7:43 AM Dmitry Baryshkov <dbaryshkov@gmail.com> wrote:
>>
>> ср, 18 авг. 2021 г. в 21:23, Khem Raj <raj.khem@gmail.com>:
>> >
>> > On Wed, Aug 18, 2021 at 8:39 AM Dmitry Baryshkov <dbaryshkov@gmail.com> wrote:
>> > >
>> > > Under some conditions ext2simg can corrupt the file system (see
>> > > https://lore.kernel.org/linux-ext4/CAP71WjwVdqmLEq1NGWK36JkEd-i05YcAu4jeY6GFjsk6TS=Mtg@mail.gmail.com/).
>> > > This has been reproduced with the ext2simg currently found meta-oe's
>> > > android-tools-native). Stop using ext2simg and always use img2simg. This
>> > > results in bigger images, but without the risk of image corruption.
>> >
>> > how big are the images ?
>>
>> Just checked. I've 1GB (964 MB) ext4 image. gzipped it takes 227 MB.
>> Given that I got:
>> ext2simg - 518MB
>> img2simg - 655 MB
>
>
> Hmm so Choice is corrupted at times and small or big but not corrupted I guess we should take the second option as it seems more stable

Pretty much so. I'd also settle for the second option. I've been hit
by ext2simg, thus I had to send this patch. So, can we please get it
queued/applied?

>> > > Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
>> > > ---
>> > >  meta-oe/classes/image_types_sparse.bbclass | 12 ++----------
>> > >  1 file changed, 2 insertions(+), 10 deletions(-)
>> > >
>> > > diff --git a/meta-oe/classes/image_types_sparse.bbclass b/meta-oe/classes/image_types_sparse.bbclass
>> > > index 65d980fd913f..4263593a8dd1 100644
>> > > --- a/meta-oe/classes/image_types_sparse.bbclass
>> > > +++ b/meta-oe/classes/image_types_sparse.bbclass
>> > > @@ -2,15 +2,7 @@ inherit image_types
>> > >
>> > >  CONVERSIONTYPES += "sparse"
>> > >  CONVERSION_CMD:sparse = " \
>> > > -    case "${type}" in \
>> > > -        ext*) \
>> > > -            ext2simg "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" \
>> > > -                     "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}.sparse" \
>> > > -            ;; \
>> > > -        *) \
>> > > -            img2simg "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" \
>> > > -                     "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}.sparse" \
>> > > -            ;; \
>> > > -    esac \
>> > > +    img2simg "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" \
>> > > +             "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}.sparse" \
>> > >  "
>> > >  CONVERSION_DEPENDS_sparse = "android-tools-native"
>> > > --
>> > > 2.30.2
>> > >
>> > >
>> > > 
>> > >
>>
>>
>>
>> --
>> With best wishes
>> Dmitry



-- 
With best wishes
Dmitry

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

* Re: [oe] [meta-oe][PATCH] image_types_sparse: stop using ext2simg
  2021-08-20 18:03     ` Khem Raj
  2021-08-25 19:45       ` Dmitry Baryshkov
@ 2021-08-30 20:36       ` Dmitry Baryshkov
  2021-08-30 20:45         ` Khem Raj
  1 sibling, 1 reply; 8+ messages in thread
From: Dmitry Baryshkov @ 2021-08-30 20:36 UTC (permalink / raw)
  To: Khem Raj; +Cc: openembeded-devel

пт, 20 авг. 2021 г. в 21:03, Khem Raj <raj.khem@gmail.com>:
>
>
>
> On Fri, Aug 20, 2021 at 7:43 AM Dmitry Baryshkov <dbaryshkov@gmail.com> wrote:
>>
>> ср, 18 авг. 2021 г. в 21:23, Khem Raj <raj.khem@gmail.com>:
>> >
>> > On Wed, Aug 18, 2021 at 8:39 AM Dmitry Baryshkov <dbaryshkov@gmail.com> wrote:
>> > >
>> > > Under some conditions ext2simg can corrupt the file system (see
>> > > https://lore.kernel.org/linux-ext4/CAP71WjwVdqmLEq1NGWK36JkEd-i05YcAu4jeY6GFjsk6TS=Mtg@mail.gmail.com/).
>> > > This has been reproduced with the ext2simg currently found meta-oe's
>> > > android-tools-native). Stop using ext2simg and always use img2simg. This
>> > > results in bigger images, but without the risk of image corruption.
>> >
>> > how big are the images ?
>>
>> Just checked. I've 1GB (964 MB) ext4 image. gzipped it takes 227 MB.
>> Given that I got:
>> ext2simg - 518MB
>> img2simg - 655 MB
>
>
> Hmm so Choice is corrupted at times and small or big but not corrupted I guess we should take the second option as it seems more stable

Gracious ping.

>>
>>
>>
>> >
>> > >
>> > > Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
>> > > ---
>> > >  meta-oe/classes/image_types_sparse.bbclass | 12 ++----------
>> > >  1 file changed, 2 insertions(+), 10 deletions(-)
>> > >
>> > > diff --git a/meta-oe/classes/image_types_sparse.bbclass b/meta-oe/classes/image_types_sparse.bbclass
>> > > index 65d980fd913f..4263593a8dd1 100644
>> > > --- a/meta-oe/classes/image_types_sparse.bbclass
>> > > +++ b/meta-oe/classes/image_types_sparse.bbclass
>> > > @@ -2,15 +2,7 @@ inherit image_types
>> > >
>> > >  CONVERSIONTYPES += "sparse"
>> > >  CONVERSION_CMD:sparse = " \
>> > > -    case "${type}" in \
>> > > -        ext*) \
>> > > -            ext2simg "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" \
>> > > -                     "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}.sparse" \
>> > > -            ;; \
>> > > -        *) \
>> > > -            img2simg "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" \
>> > > -                     "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}.sparse" \
>> > > -            ;; \
>> > > -    esac \
>> > > +    img2simg "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" \
>> > > +             "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}.sparse" \
>> > >  "
>> > >  CONVERSION_DEPENDS_sparse = "android-tools-native"
>> > > --
>> > > 2.30.2
>> > >
>> > >
>> > > 
>> > >
>>
>>
>>
>> --
>> With best wishes
>> Dmitry



-- 
With best wishes
Dmitry

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

* Re: [oe] [meta-oe][PATCH] image_types_sparse: stop using ext2simg
  2021-08-30 20:36       ` Dmitry Baryshkov
@ 2021-08-30 20:45         ` Khem Raj
  2021-08-30 20:48           ` Dmitry Baryshkov
  0 siblings, 1 reply; 8+ messages in thread
From: Khem Raj @ 2021-08-30 20:45 UTC (permalink / raw)
  To: Dmitry Baryshkov; +Cc: openembeded-devel



On 8/30/21 1:36 PM, Dmitry Baryshkov wrote:
> пт, 20 авг. 2021 г. в 21:03, Khem Raj <raj.khem@gmail.com>:
>>
>>
>>
>> On Fri, Aug 20, 2021 at 7:43 AM Dmitry Baryshkov <dbaryshkov@gmail.com> wrote:
>>>
>>> ср, 18 авг. 2021 г. в 21:23, Khem Raj <raj.khem@gmail.com>:
>>>>
>>>> On Wed, Aug 18, 2021 at 8:39 AM Dmitry Baryshkov <dbaryshkov@gmail.com> wrote:
>>>>>
>>>>> Under some conditions ext2simg can corrupt the file system (see
>>>>> https://lore.kernel.org/linux-ext4/CAP71WjwVdqmLEq1NGWK36JkEd-i05YcAu4jeY6GFjsk6TS=Mtg@mail.gmail.com/).
>>>>> This has been reproduced with the ext2simg currently found meta-oe's
>>>>> android-tools-native). Stop using ext2simg and always use img2simg. This
>>>>> results in bigger images, but without the risk of image corruption.
>>>>
>>>> how big are the images ?
>>>
>>> Just checked. I've 1GB (964 MB) ext4 image. gzipped it takes 227 MB.
>>> Given that I got:
>>> ext2simg - 518MB
>>> img2simg - 655 MB
>>
>>
>> Hmm so Choice is corrupted at times and small or big but not corrupted I guess we should take the second option as it seems more stable
> 
> Gracious ping.
> 

thanks for reminder, it fell through cracks. I have it in master-next now.

>>>
>>>
>>>
>>>>
>>>>>
>>>>> Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
>>>>> ---
>>>>>   meta-oe/classes/image_types_sparse.bbclass | 12 ++----------
>>>>>   1 file changed, 2 insertions(+), 10 deletions(-)
>>>>>
>>>>> diff --git a/meta-oe/classes/image_types_sparse.bbclass b/meta-oe/classes/image_types_sparse.bbclass
>>>>> index 65d980fd913f..4263593a8dd1 100644
>>>>> --- a/meta-oe/classes/image_types_sparse.bbclass
>>>>> +++ b/meta-oe/classes/image_types_sparse.bbclass
>>>>> @@ -2,15 +2,7 @@ inherit image_types
>>>>>
>>>>>   CONVERSIONTYPES += "sparse"
>>>>>   CONVERSION_CMD:sparse = " \
>>>>> -    case "${type}" in \
>>>>> -        ext*) \
>>>>> -            ext2simg "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" \
>>>>> -                     "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}.sparse" \
>>>>> -            ;; \
>>>>> -        *) \
>>>>> -            img2simg "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" \
>>>>> -                     "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}.sparse" \
>>>>> -            ;; \
>>>>> -    esac \
>>>>> +    img2simg "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" \
>>>>> +             "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}.sparse" \
>>>>>   "
>>>>>   CONVERSION_DEPENDS_sparse = "android-tools-native"
>>>>> --
>>>>> 2.30.2
>>>>>
>>>>>
>>>>> 
>>>>>
>>>
>>>
>>>
>>> --
>>> With best wishes
>>> Dmitry
> 
> 
> 

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

* Re: [oe] [meta-oe][PATCH] image_types_sparse: stop using ext2simg
  2021-08-30 20:45         ` Khem Raj
@ 2021-08-30 20:48           ` Dmitry Baryshkov
  0 siblings, 0 replies; 8+ messages in thread
From: Dmitry Baryshkov @ 2021-08-30 20:48 UTC (permalink / raw)
  To: Khem Raj; +Cc: openembeded-devel

пн, 30 авг. 2021 г. в 23:45, Khem Raj <raj.khem@gmail.com>:
>
>
>
> On 8/30/21 1:36 PM, Dmitry Baryshkov wrote:
> > пт, 20 авг. 2021 г. в 21:03, Khem Raj <raj.khem@gmail.com>:
> >>
> >>
> >>
> >> On Fri, Aug 20, 2021 at 7:43 AM Dmitry Baryshkov <dbaryshkov@gmail.com> wrote:
> >>>
> >>> ср, 18 авг. 2021 г. в 21:23, Khem Raj <raj.khem@gmail.com>:
> >>>>
> >>>> On Wed, Aug 18, 2021 at 8:39 AM Dmitry Baryshkov <dbaryshkov@gmail.com> wrote:
> >>>>>
> >>>>> Under some conditions ext2simg can corrupt the file system (see
> >>>>> https://lore.kernel.org/linux-ext4/CAP71WjwVdqmLEq1NGWK36JkEd-i05YcAu4jeY6GFjsk6TS=Mtg@mail.gmail.com/).
> >>>>> This has been reproduced with the ext2simg currently found meta-oe's
> >>>>> android-tools-native). Stop using ext2simg and always use img2simg. This
> >>>>> results in bigger images, but without the risk of image corruption.
> >>>>
> >>>> how big are the images ?
> >>>
> >>> Just checked. I've 1GB (964 MB) ext4 image. gzipped it takes 227 MB.
> >>> Given that I got:
> >>> ext2simg - 518MB
> >>> img2simg - 655 MB
> >>
> >>
> >> Hmm so Choice is corrupted at times and small or big but not corrupted I guess we should take the second option as it seems more stable
> >
> > Gracious ping.
> >
>
> thanks for reminder, it fell through cracks. I have it in master-next now.

Thank you!

>
> >>>
> >>>
> >>>
> >>>>
> >>>>>
> >>>>> Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
> >>>>> ---
> >>>>>   meta-oe/classes/image_types_sparse.bbclass | 12 ++----------
> >>>>>   1 file changed, 2 insertions(+), 10 deletions(-)
> >>>>>
> >>>>> diff --git a/meta-oe/classes/image_types_sparse.bbclass b/meta-oe/classes/image_types_sparse.bbclass
> >>>>> index 65d980fd913f..4263593a8dd1 100644
> >>>>> --- a/meta-oe/classes/image_types_sparse.bbclass
> >>>>> +++ b/meta-oe/classes/image_types_sparse.bbclass
> >>>>> @@ -2,15 +2,7 @@ inherit image_types
> >>>>>
> >>>>>   CONVERSIONTYPES += "sparse"
> >>>>>   CONVERSION_CMD:sparse = " \
> >>>>> -    case "${type}" in \
> >>>>> -        ext*) \
> >>>>> -            ext2simg "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" \
> >>>>> -                     "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}.sparse" \
> >>>>> -            ;; \
> >>>>> -        *) \
> >>>>> -            img2simg "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" \
> >>>>> -                     "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}.sparse" \
> >>>>> -            ;; \
> >>>>> -    esac \
> >>>>> +    img2simg "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" \
> >>>>> +             "${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}.sparse" \
> >>>>>   "
> >>>>>   CONVERSION_DEPENDS_sparse = "android-tools-native"
> >>>>> --
> >>>>> 2.30.2
> >>>>>
> >>>>>
> >>>>> 
> >>>>>
> >>>
> >>>
> >>>
> >>> --
> >>> With best wishes
> >>> Dmitry
> >
> >
> >



-- 
With best wishes
Dmitry

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

end of thread, other threads:[~2021-08-30 20:49 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-18 15:39 [meta-oe][PATCH] image_types_sparse: stop using ext2simg Dmitry Baryshkov
2021-08-18 18:22 ` [oe] " Khem Raj
2021-08-20 14:43   ` Dmitry Baryshkov
2021-08-20 18:03     ` Khem Raj
2021-08-25 19:45       ` Dmitry Baryshkov
2021-08-30 20:36       ` Dmitry Baryshkov
2021-08-30 20:45         ` Khem Raj
2021-08-30 20:48           ` Dmitry Baryshkov

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.