Openembedded Core Discussions
 help / color / mirror / Atom feed
* [PATCH] Fix #13560 - Partition numbering is broken for MBR primary partition #4
@ 2019-10-03 15:36 Michael Cooper
  2019-10-03 15:59 ` Richard Purdie
  2019-10-03 16:02 ` ✗ patchtest: failure for " Patchwork
  0 siblings, 2 replies; 4+ messages in thread
From: Michael Cooper @ 2019-10-03 15:36 UTC (permalink / raw)
  To: openembedded-core

Bug: When wks describes extra partitions that aren't in the partition
table (e.g. boot loader) and exactly four primary MBR partitions, the
last partition gets added to fstab as partition #5 instead of #4.

https://bugzilla.yoctoproject.org/show_bug.cgi?id=13560

Signed-off-by: Michael Cooper <michaelcooper81@gmail.com>
---
 scripts/lib/wic/plugins/imager/direct.py | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/scripts/lib/wic/plugins/imager/direct.py
b/scripts/lib/wic/plugins/imager/direct.py
index 3ce6ad55b8..2441cc33ad 100644
--- a/scripts/lib/wic/plugins/imager/direct.py
+++ b/scripts/lib/wic/plugins/imager/direct.py
@@ -316,6 +316,7 @@ class PartitionedImage():
         # Size of a sector used in calculations
         self.sector_size = SECTOR_SIZE
         self.native_sysroot = native_sysroot
+        num_real_partitions = len([p for p in self.partitions if not
p.no_table])

         # calculate the real partition number, accounting for partitions not
         # in the partition table and logical partitions
@@ -325,7 +326,7 @@ class PartitionedImage():
                 part.realnum = 0
             else:
                 realnum += 1
-                if self.ptable_format == 'msdos' and realnum > 3 and
len(partitions) > 4:
+                if self.ptable_format == 'msdos' and realnum > 3 and
num_real_partitions > 4:
                     part.realnum = realnum + 1
                     continue
                 part.realnum = realnum
-- 
2.17.1


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

* Re: [PATCH] Fix #13560 - Partition numbering is broken for MBR primary partition #4
  2019-10-03 15:36 [PATCH] Fix #13560 - Partition numbering is broken for MBR primary partition #4 Michael Cooper
@ 2019-10-03 15:59 ` Richard Purdie
  2019-10-03 16:05   ` Michael Cooper
  2019-10-03 16:02 ` ✗ patchtest: failure for " Patchwork
  1 sibling, 1 reply; 4+ messages in thread
From: Richard Purdie @ 2019-10-03 15:59 UTC (permalink / raw)
  To: Michael Cooper, openembedded-core

On Thu, 2019-10-03 at 18:36 +0300, Michael Cooper wrote:
> Bug: When wks describes extra partitions that aren't in the partition
> table (e.g. boot loader) and exactly four primary MBR partitions, the
> last partition gets added to fstab as partition #5 instead of #4.
> 
> https://bugzilla.yoctoproject.org/show_bug.cgi?id=13560
> 
> Signed-off-by: Michael Cooper <michaelcooper81@gmail.com>
> ---
>  scripts/lib/wic/plugins/imager/direct.py | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)

Thanks, I've queued this.

For reference, your patch arrived line wrapped. It was simple enough I
could edit that out by hand (been doing this too long, clearly!).

I also tweaked the shortlog to match our guidelines and tweaked the bug
number reference to the standard [YOCTO #13560]. I just mention these
so you can sort next time, thanks for the patch!

Cheers,

Richard



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

* ✗ patchtest: failure for Fix #13560 - Partition numbering is broken for MBR primary partition #4
  2019-10-03 15:36 [PATCH] Fix #13560 - Partition numbering is broken for MBR primary partition #4 Michael Cooper
  2019-10-03 15:59 ` Richard Purdie
@ 2019-10-03 16:02 ` Patchwork
  1 sibling, 0 replies; 4+ messages in thread
From: Patchwork @ 2019-10-03 16:02 UTC (permalink / raw)
  To: Michael Cooper; +Cc: openembedded-core

== Series Details ==

Series: Fix #13560 - Partition numbering is broken for MBR primary partition #4
Revision: 1
URL   : https://patchwork.openembedded.org/series/20282/
State : failure

== Summary ==


Thank you for submitting this patch series to OpenEmbedded Core. This is
an automated response. Several tests have been executed on the proposed
series by patchtest resulting in the following failures:



* Issue             Series cannot be parsed correctly due to malformed diff lines [test_mbox_format] 
  Suggested fix    Create the series again using git-format-patch and ensure it can be applied using git am
  Diff line        @@ -325,7 +326,7 @@ class PartitionedImage():


* Issue             Series does not apply on top of target branch [test_series_merge_on_head] 
  Suggested fix    Rebase your series on top of targeted branch
  Targeted branch  master (currently at 520c6f30cd)

* Patch            Fix #13560 - Partition numbering is broken for MBR primary partition #4
 Issue             Shortlog does not follow expected format [test_shortlog_format] 
  Suggested fix    Commit shortlog (first line of commit message) should follow the format "<target>: <summary>"



If you believe any of these test results are incorrect, please reply to the
mailing list (openembedded-core@lists.openembedded.org) raising your concerns.
Otherwise we would appreciate you correcting the issues and submitting a new
version of the patchset if applicable. Please ensure you add/increment the
version number when sending the new version (i.e. [PATCH] -> [PATCH v2] ->
[PATCH v3] -> ...).

---
Guidelines:     https://www.openembedded.org/wiki/Commit_Patch_Message_Guidelines
Test framework: http://git.yoctoproject.org/cgit/cgit.cgi/patchtest
Test suite:     http://git.yoctoproject.org/cgit/cgit.cgi/patchtest-oe



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

* Re: [PATCH] Fix #13560 - Partition numbering is broken for MBR primary partition #4
  2019-10-03 15:59 ` Richard Purdie
@ 2019-10-03 16:05   ` Michael Cooper
  0 siblings, 0 replies; 4+ messages in thread
From: Michael Cooper @ 2019-10-03 16:05 UTC (permalink / raw)
  To: Richard Purdie; +Cc: openembedded-core

Thanks a lot!
I'll try to make git send-email work next time, this one suffered due
to manual copying :(
On Thu, Oct 3, 2019 at 6:59 PM Richard Purdie
<richard.purdie@linuxfoundation.org> wrote:
>
> On Thu, 2019-10-03 at 18:36 +0300, Michael Cooper wrote:
> > Bug: When wks describes extra partitions that aren't in the partition
> > table (e.g. boot loader) and exactly four primary MBR partitions, the
> > last partition gets added to fstab as partition #5 instead of #4.
> >
> > https://bugzilla.yoctoproject.org/show_bug.cgi?id=13560
> >
> > Signed-off-by: Michael Cooper <michaelcooper81@gmail.com>
> > ---
> >  scripts/lib/wic/plugins/imager/direct.py | 3 ++-
> >  1 file changed, 2 insertions(+), 1 deletion(-)
>
> Thanks, I've queued this.
>
> For reference, your patch arrived line wrapped. It was simple enough I
> could edit that out by hand (been doing this too long, clearly!).
>
> I also tweaked the shortlog to match our guidelines and tweaked the bug
> number reference to the standard [YOCTO #13560]. I just mention these
> so you can sort next time, thanks for the patch!
>
> Cheers,
>
> Richard
>


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

end of thread, other threads:[~2019-10-03 16:06 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-10-03 15:36 [PATCH] Fix #13560 - Partition numbering is broken for MBR primary partition #4 Michael Cooper
2019-10-03 15:59 ` Richard Purdie
2019-10-03 16:05   ` Michael Cooper
2019-10-03 16:02 ` ✗ patchtest: failure for " Patchwork

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