yocto.lists.yoctoproject.org archive mirror
 help / color / mirror / Atom feed
* Remove kernel image from IMAGE_BOOT_FILES for WIC boot partition
@ 2023-06-07 12:09 Konstantin Kletschke
  2023-06-07 12:16 ` [yocto] " Alexander Kanavin
  0 siblings, 1 reply; 6+ messages in thread
From: Konstantin Kletschke @ 2023-06-07 12:09 UTC (permalink / raw)
  To: yocto

Hi There,

I want to create a WIC image for sdcards which generally works.
I use beaglebone-yocto with barebox instead of u-boot.

This works with overwriting IMAGE_BOOT_FILES in my
meta-insidem2m/recipes-core/images/sdcard.bb:

IMAGE_BOOT_FILES="barebox/barebox.bin;barebox.bin barebox-pbl/MLO;MLO zImage am335x-bone.dtb am335x-boneblack.dtb am335x-bonegreen.dtb"

I use bootloader spec booting with barebox, so I need only MLO and
barbox.bin in the boot partition, so I went:

IMAGE_BOOT_FILES="barebox/barebox.bin;barebox.bin barebox-pbl/MLO;MLO"

bitbake -e reflects the change:

bitbake -e sdcard|grep ^IMAGE_BOOT
IMAGE_BOOT_FILES="barebox/barebox.bin;barebox.bin barebox-pbl/MLO;MLO"

Then "bitbake sdcard" complains:

| NOTE: Installed into sysroot: []
| NOTE: Skipping as already exists in sysroot: ['cross-localedef-native', 'ldconfig-native', 'cdrtools-native', 'qemuwrapper-cross', 'depmodwrapper-cross', 'update-rc.d-native', 'apt-native', 'btrfs-tools-native', 'dosfstools-native', 'dpkg-native', 'e2fsprogs-native', 'gptfdisk-native', 'makedevs-native', 'mtools-native', 'opkg-utils-native', 'pseudo-native', 'squashfs-tools-native', 'syslinux-native', 'parted-native', 'pigz-native', 'bmap-tools-native', 'openssl-native', 'debianutils-native', 'kmod-native', 'systemd-systemctl-native', 'shadow-native', 'qemu-native', 'python3-six-native', 'python3-setuptools-native', 'python3-installer-native', 'python3-native', 'python3-wheel-native', 'coreutils-native', 'zlib-native', 'perl-native', 'gnutls-native', 'lz4-native', 'xz-native', 'xxhash-native', 'db-native', 'cmake-native', 'libgcrypt-native', 'attr-native', 'lzo-native', 'zstd-native', 'libtool-native', 'texinfo-dummy-native', 'readline-native', 'util-linux-native', 'ncurses-native', 'gettext-minimal-native', 'popt-native', 'shared-mime-info-native', 'nasm-native', 'bzip2-native', 'gettext-native', 'glib-2.0-native', 'python3-flit-core-native', 'unzip-native', 'gdbm-native', 'libtirpc-native', 'util-linux-libuuid-native', 'libffi-native', 'libnsl2-native', 'sqlite3-native', 'make-native', 'nettle-native', 'libunistring-native', 'libidn2-native', 'gmp-native', 'curl-native', 'libgpg-error-native', 'libcap-native', 'libcap-ng-native', 'libpcre2-native', 'libxml2-native', 'itstool-native', 'groff-native', 'libpcre-native']
| DEBUG: Python function extend_recipe_sysroot finished
| DEBUG: Executing python function set_image_size
| DEBUG: 345274.800000 = 265596 * 1.300000
| DEBUG: 345274.800000 = max(345274.800000, 65536)[345274.800000] + 0
| DEBUG: 345275.000000 = int(345274.800000)
| DEBUG: 345275 = aligned(345275)
| DEBUG: returning 345275
| DEBUG: Python function set_image_size finished
| DEBUG: Executing shell function do_image_wic
| INFO: Creating image(s)...
|
| ERROR: No kernel file found
|
| WARNING: exit code 1 from a shell command.

How do I remove the requirement for a kernel image? I suppose if I
manage to do that, the dtb files are missng too, then.


Kind Regards
Konstantin

-- 
INSIDE M2M GmbH
Konstantin Kletschke
Berenbosteler Straße 76 B
30823 Garbsen

Telefon: +49 (0) 5137 90950136
Mobil: +49 (0) 151 15256238
Fax: +49 (0) 5137 9095010

konstantin.kletschke@inside-m2m.de
http://www.inside-m2m.de 

Geschäftsführung: Michael Emmert, Derek Uhlig
HRB: 111204, AG Hannover



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

* Re: [yocto] Remove kernel image from IMAGE_BOOT_FILES for WIC boot partition
  2023-06-07 12:09 Remove kernel image from IMAGE_BOOT_FILES for WIC boot partition Konstantin Kletschke
@ 2023-06-07 12:16 ` Alexander Kanavin
  2023-06-07 12:20   ` Konstantin Kletschke
  0 siblings, 1 reply; 6+ messages in thread
From: Alexander Kanavin @ 2023-06-07 12:16 UTC (permalink / raw)
  To: Konstantin Kletschke; +Cc: yocto

I don't have a ready solution, but you could grep for the error
message, see where it happens and what can be done to 'not make it
happen'.

Alex

On Wed, 7 Jun 2023 at 14:10, Konstantin Kletschke
<konstantin.kletschke@inside-m2m.de> wrote:
>
> Hi There,
>
> I want to create a WIC image for sdcards which generally works.
> I use beaglebone-yocto with barebox instead of u-boot.
>
> This works with overwriting IMAGE_BOOT_FILES in my
> meta-insidem2m/recipes-core/images/sdcard.bb:
>
> IMAGE_BOOT_FILES="barebox/barebox.bin;barebox.bin barebox-pbl/MLO;MLO zImage am335x-bone.dtb am335x-boneblack.dtb am335x-bonegreen.dtb"
>
> I use bootloader spec booting with barebox, so I need only MLO and
> barbox.bin in the boot partition, so I went:
>
> IMAGE_BOOT_FILES="barebox/barebox.bin;barebox.bin barebox-pbl/MLO;MLO"
>
> bitbake -e reflects the change:
>
> bitbake -e sdcard|grep ^IMAGE_BOOT
> IMAGE_BOOT_FILES="barebox/barebox.bin;barebox.bin barebox-pbl/MLO;MLO"
>
> Then "bitbake sdcard" complains:
>
> | NOTE: Installed into sysroot: []
> | NOTE: Skipping as already exists in sysroot: ['cross-localedef-native', 'ldconfig-native', 'cdrtools-native', 'qemuwrapper-cross', 'depmodwrapper-cross', 'update-rc.d-native', 'apt-native', 'btrfs-tools-native', 'dosfstools-native', 'dpkg-native', 'e2fsprogs-native', 'gptfdisk-native', 'makedevs-native', 'mtools-native', 'opkg-utils-native', 'pseudo-native', 'squashfs-tools-native', 'syslinux-native', 'parted-native', 'pigz-native', 'bmap-tools-native', 'openssl-native', 'debianutils-native', 'kmod-native', 'systemd-systemctl-native', 'shadow-native', 'qemu-native', 'python3-six-native', 'python3-setuptools-native', 'python3-installer-native', 'python3-native', 'python3-wheel-native', 'coreutils-native', 'zlib-native', 'perl-native', 'gnutls-native', 'lz4-native', 'xz-native', 'xxhash-native', 'db-native', 'cmake-native', 'libgcrypt-native', 'attr-native', 'lzo-native', 'zstd-native', 'libtool-native', 'texinfo-dummy-native', 'readline-native', 'util-linux-native', 'ncurses-native', 'gettext-minimal-native', 'popt-native', 'shared-mime-info-native', 'nasm-native', 'bzip2-native', 'gettext-native', 'glib-2.0-native', 'python3-flit-core-native', 'unzip-native', 'gdbm-native', 'libtirpc-native', 'util-linux-libuuid-native', 'libffi-native', 'libnsl2-native', 'sqlite3-native', 'make-native', 'nettle-native', 'libunistring-native', 'libidn2-native', 'gmp-native', 'curl-native', 'libgpg-error-native', 'libcap-native', 'libcap-ng-native', 'libpcre2-native', 'libxml2-native', 'itstool-native', 'groff-native', 'libpcre-native']
> | DEBUG: Python function extend_recipe_sysroot finished
> | DEBUG: Executing python function set_image_size
> | DEBUG: 345274.800000 = 265596 * 1.300000
> | DEBUG: 345274.800000 = max(345274.800000, 65536)[345274.800000] + 0
> | DEBUG: 345275.000000 = int(345274.800000)
> | DEBUG: 345275 = aligned(345275)
> | DEBUG: returning 345275
> | DEBUG: Python function set_image_size finished
> | DEBUG: Executing shell function do_image_wic
> | INFO: Creating image(s)...
> |
> | ERROR: No kernel file found
> |
> | WARNING: exit code 1 from a shell command.
>
> How do I remove the requirement for a kernel image? I suppose if I
> manage to do that, the dtb files are missng too, then.
>
>
> Kind Regards
> Konstantin
>
> --
> INSIDE M2M GmbH
> Konstantin Kletschke
> Berenbosteler Straße 76 B
> 30823 Garbsen
>
> Telefon: +49 (0) 5137 90950136
> Mobil: +49 (0) 151 15256238
> Fax: +49 (0) 5137 9095010
>
> konstantin.kletschke@inside-m2m.de
> http://www.inside-m2m.de
>
> Geschäftsführung: Michael Emmert, Derek Uhlig
> HRB: 111204, AG Hannover
>
>
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#60202): https://lists.yoctoproject.org/g/yocto/message/60202
> Mute This Topic: https://lists.yoctoproject.org/mt/99383061/1686489
> Group Owner: yocto+owner@lists.yoctoproject.org
> Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [alex.kanavin@gmail.com]
> -=-=-=-=-=-=-=-=-=-=-=-
>


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

* Re: [yocto] Remove kernel image from IMAGE_BOOT_FILES for WIC boot partition
  2023-06-07 12:16 ` [yocto] " Alexander Kanavin
@ 2023-06-07 12:20   ` Konstantin Kletschke
  2023-06-07 12:25     ` Alexander Kanavin
  0 siblings, 1 reply; 6+ messages in thread
From: Konstantin Kletschke @ 2023-06-07 12:20 UTC (permalink / raw)
  To: Alexander Kanavin; +Cc: yocto

On Wed, Jun 07, 2023 at 02:16:34PM +0200, Alexander Kanavin wrote:
> I don't have a ready solution, but you could grep for the error
> message, see where it happens and what can be done to 'not make it

I am still searching for this like you suggested :-D



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

* Re: [yocto] Remove kernel image from IMAGE_BOOT_FILES for WIC boot partition
  2023-06-07 12:20   ` Konstantin Kletschke
@ 2023-06-07 12:25     ` Alexander Kanavin
  2023-06-07 14:58       ` Konstantin Kletschke
  0 siblings, 1 reply; 6+ messages in thread
From: Alexander Kanavin @ 2023-06-07 12:25 UTC (permalink / raw)
  To: Konstantin Kletschke; +Cc: yocto

[ak@fedora poky]$ grep -ir "No kernel file found" scripts/
scripts/lib/wic/plugins/source/bootimg-partition.py:
raise WicError('No kernel file found')


You're welcome.

Alex

On Wed, 7 Jun 2023 at 14:20, Konstantin Kletschke
<konstantin.kletschke@inside-m2m.de> wrote:
>
> On Wed, Jun 07, 2023 at 02:16:34PM +0200, Alexander Kanavin wrote:
> > I don't have a ready solution, but you could grep for the error
> > message, see where it happens and what can be done to 'not make it
>
> I am still searching for this like you suggested :-D
>


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

* Re: [yocto] Remove kernel image from IMAGE_BOOT_FILES for WIC boot partition
  2023-06-07 12:25     ` Alexander Kanavin
@ 2023-06-07 14:58       ` Konstantin Kletschke
  2023-06-07 15:40         ` Konstantin Kletschke
  0 siblings, 1 reply; 6+ messages in thread
From: Konstantin Kletschke @ 2023-06-07 14:58 UTC (permalink / raw)
  To: Alexander Kanavin; +Cc: yocto

On Wed, Jun 07, 2023 at 02:25:15PM +0200, Alexander Kanavin wrote:
> [ak@fedora poky]$ grep -ir "No kernel file found" scripts/
> scripts/lib/wic/plugins/source/bootimg-partition.py:
> raise WicError('No kernel file found')

Yeah... I end up in scripts/lib/wic/engine.py get_custom_config() which
I must prepare to avoid falling into the "No Kernel..." pitfall, what is
that, an u-boot extlinux config? I am trying to find out...



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

* Re: [yocto] Remove kernel image from IMAGE_BOOT_FILES for WIC boot partition
  2023-06-07 14:58       ` Konstantin Kletschke
@ 2023-06-07 15:40         ` Konstantin Kletschke
  0 siblings, 0 replies; 6+ messages in thread
From: Konstantin Kletschke @ 2023-06-07 15:40 UTC (permalink / raw)
  To: Alexander Kanavin; +Cc: yocto

On Wed, Jun 07, 2023 at 04:58:41PM +0200, Konstantin Kletschke wrote:

> Yeah... I end up in scripts/lib/wic/engine.py get_custom_config() which
> I must prepare to avoid falling into the "No Kernel..." pitfall, what is
> that, an u-boot extlinux config? I am trying to find out...

I found out:

In the wks file I have to specifiy an existing configfile like this at
the bottom (--configfile part):

bootloader --append="console=ttyS0,115200" --configfile="directdisk-bootloader-config.cfg"

Then I can use my stripped down set of IMAGE_BOOT_FILES without kernel
and dtb files.

I end up with an unnecessary extlinux/extlinux.conf but this are
~550Bytes and are not avoidable so I can live with that at the moment.


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

end of thread, other threads:[~2023-06-07 15:40 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-06-07 12:09 Remove kernel image from IMAGE_BOOT_FILES for WIC boot partition Konstantin Kletschke
2023-06-07 12:16 ` [yocto] " Alexander Kanavin
2023-06-07 12:20   ` Konstantin Kletschke
2023-06-07 12:25     ` Alexander Kanavin
2023-06-07 14:58       ` Konstantin Kletschke
2023-06-07 15:40         ` Konstantin Kletschke

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).