public inbox for openembedded-core@lists.openembedded.org
 help / color / mirror / Atom feed
* [PATCH v2] wic/bootimg-efi: if fixed-size is set then use that for mkdosfs
@ 2023-04-21 21:26 Randolph Sapp
  2023-04-24  8:48 ` [OE-core] " Luca Ceresoli
  0 siblings, 1 reply; 6+ messages in thread
From: Randolph Sapp @ 2023-04-21 21:26 UTC (permalink / raw)
  To: zarkakareem, reatmon, denis, afd; +Cc: openembedded-core, Randolph Sapp

This is a bit of a compatibility issue more than anything. Some devices
get upset if the FAT file system contains less blocks than the
partition.

The fixed-size argument is currently respected by the partition creation
step but not by the file system creation step. Let's make it so the file
system respects this value as well.

Signed-off-by: Randolph Sapp <rs@ti.com>
---

Ugh. I muddied up the log statement in the last revision. Fix that here.

 scripts/lib/wic/plugins/source/bootimg-efi.py | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/scripts/lib/wic/plugins/source/bootimg-efi.py b/scripts/lib/wic/plugins/source/bootimg-efi.py
index a65a5b9780..c28d3917c2 100644
--- a/scripts/lib/wic/plugins/source/bootimg-efi.py
+++ b/scripts/lib/wic/plugins/source/bootimg-efi.py
@@ -390,6 +390,13 @@ class BootimgEFIPlugin(SourcePlugin):
         logger.debug("Added %d extra blocks to %s to get to %d total blocks",
                      extra_blocks, part.mountpoint, blocks)
 
+        # required for compatibility with certain devices expecting file system
+        # block count to be equal to partition block count
+        if blocks < part.fixed_size:
+            blocks = part.fixed_size
+            logger.debug("Overriding %s to %d total blocks for compatibility",
+                     part.mountpoint, blocks)
+
         # dosfs image, created by mkdosfs
         bootimg = "%s/boot.img" % cr_workdir
 
-- 
2.40.0



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

* Re: [OE-core] [PATCH v2] wic/bootimg-efi: if fixed-size is set then use that for mkdosfs
  2023-04-21 21:26 [PATCH v2] wic/bootimg-efi: if fixed-size is set then use that for mkdosfs Randolph Sapp
@ 2023-04-24  8:48 ` Luca Ceresoli
  2023-04-24 15:32   ` [EXTERNAL] " Randolph Sapp
  0 siblings, 1 reply; 6+ messages in thread
From: Luca Ceresoli @ 2023-04-24  8:48 UTC (permalink / raw)
  To: Randolph Sapp via lists.openembedded.org
  Cc: rs, zarkakareem, reatmon, denis, afd, openembedded-core

Hello Randolph,

On Fri, 21 Apr 2023 16:26:13 -0500
"Randolph Sapp via lists.openembedded.org"
<rs=ti.com@lists.openembedded.org> wrote:
 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

As you can see your sender address has been mangled, and as a result
the patch is rejected by the the openembedded git server. This is not
your fault, but we need you to modify your git configuration to prevent
this from happening in the future. Have a look at the wiki for more
info and how to solve that:

https://www.openembedded.org/wiki/How_to_submit_a_patch_to_OpenEmbedded#Fixing_your_From_identity

I'm taking your patch for testing on the autobuilders, fixing it
manually so you don't need to resend your patch this time.

Best regards,
Luca

-- 
Luca Ceresoli, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com


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

* Re: [EXTERNAL] Re: [OE-core] [PATCH v2] wic/bootimg-efi: if fixed-size is set then use that for mkdosfs
  2023-04-24  8:48 ` [OE-core] " Luca Ceresoli
@ 2023-04-24 15:32   ` Randolph Sapp
  2023-04-26  9:06     ` Paresh Bhagat
  0 siblings, 1 reply; 6+ messages in thread
From: Randolph Sapp @ 2023-04-24 15:32 UTC (permalink / raw)
  To: Luca Ceresoli, Randolph Sapp via lists.openembedded.org
  Cc: zarkakareem, reatmon, denis, afd, openembedded-core

On 4/24/23 03:48, Luca Ceresoli wrote:
> Hello Randolph,
> 
> On Fri, 21 Apr 2023 16:26:13 -0500
> "Randolph Sapp via lists.openembedded.org"
> <rs=ti.com@lists.openembedded.org> wrote:
>   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> 
> As you can see your sender address has been mangled, and as a result
> the patch is rejected by the the openembedded git server. This is not
> your fault, but we need you to modify your git configuration to prevent
> this from happening in the future. Have a look at the wiki for more
> info and how to solve that:
> 
Ah! Thanks for the heads up. I've just adjust my configs.

> https://www.openembedded.org/wiki/How_to_submit_a_patch_to_OpenEmbedded#Fixing_your_From_identity
> 
> I'm taking your patch for testing on the autobuilders, fixing it
> manually so you don't need to resend your patch this time.
> 
> Best regards,
> Luca
> 
Cool, thanks!


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

* Re: [PATCH v2] wic/bootimg-efi: if fixed-size is set then use that for mkdosfs
  2023-04-24 15:32   ` [EXTERNAL] " Randolph Sapp
@ 2023-04-26  9:06     ` Paresh Bhagat
  2023-05-02 23:02       ` [OE-core] " Denys Dmytriyenko
  0 siblings, 1 reply; 6+ messages in thread
From: Paresh Bhagat @ 2023-04-26  9:06 UTC (permalink / raw)
  To: openembedded-core

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

Hi Randolph

I tested your patch in my local kirkstone build for am62x. SD Card boot is working.
Boot logs here: http://serenity.dal.design.ti.com:7777/ewakutoqom.yaml

Regards,
Paresh

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

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

* Re: [OE-core] [PATCH v2] wic/bootimg-efi: if fixed-size is set then use that for mkdosfs
  2023-04-26  9:06     ` Paresh Bhagat
@ 2023-05-02 23:02       ` Denys Dmytriyenko
  2023-05-02 23:54         ` [EXTERNAL] " Randolph Sapp
  0 siblings, 1 reply; 6+ messages in thread
From: Denys Dmytriyenko @ 2023-05-02 23:02 UTC (permalink / raw)
  To: p-bhagat; +Cc: rs, openembedded-core

On Wed, Apr 26, 2023 at 02:06:59AM -0700, Paresh Bhagat via lists.openembedded.org wrote:
> Hi Randolph
> 
> I tested your patch in my local kirkstone build for am62x. SD Card boot is working.
> Boot logs here: http://serenity.dal.design.ti.com:7777/ewakutoqom.yaml

This is an internal-only resource ^^^
Since you are both TI-ers, don't you think there's a better way to communicate 
this information rather than using a public mailing list? :)

-- 
Denys


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

* Re: [EXTERNAL] Re: [OE-core] [PATCH v2] wic/bootimg-efi: if fixed-size is set then use that for mkdosfs
  2023-05-02 23:02       ` [OE-core] " Denys Dmytriyenko
@ 2023-05-02 23:54         ` Randolph Sapp
  0 siblings, 0 replies; 6+ messages in thread
From: Randolph Sapp @ 2023-05-02 23:54 UTC (permalink / raw)
  To: Denys Dmytriyenko, p-bhagat; +Cc: openembedded-core

On 5/2/23 18:02, Denys Dmytriyenko wrote:
> On Wed, Apr 26, 2023 at 02:06:59AM -0700, Paresh Bhagat via lists.openembedded.org wrote:
>> Hi Randolph
>>
>> I tested your patch in my local kirkstone build for am62x. SD Card boot is working.
>> Boot logs here: http://serenity.dal.design.ti.com:7777/ewakutoqom.yaml
> 
> This is an internal-only resource ^^^
> Since you are both TI-ers, don't you think there's a better way to communicate
> this information rather than using a public mailing list? :)
> 
I was hopping to get a tested-by tag here but I guess that was lost 
somewhere in the communication chain. I already knew this patch worked :)


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

end of thread, other threads:[~2023-05-02 23:54 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-04-21 21:26 [PATCH v2] wic/bootimg-efi: if fixed-size is set then use that for mkdosfs Randolph Sapp
2023-04-24  8:48 ` [OE-core] " Luca Ceresoli
2023-04-24 15:32   ` [EXTERNAL] " Randolph Sapp
2023-04-26  9:06     ` Paresh Bhagat
2023-05-02 23:02       ` [OE-core] " Denys Dmytriyenko
2023-05-02 23:54         ` [EXTERNAL] " Randolph Sapp

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox