[Buildroot] [PATCH v5 2/2] configs/imx8mn_bsh_smm_s2_pro_defconfig: new defconfig

Heiko Thiery heiko.thiery at gmail.com
Fri Sep 9 11:06:31 UTC 2022


Hi Dario,

Am Fr., 9. Sept. 2022 um 11:59 Uhr schrieb Dario Binacchi
<dario.binacchi at amarulasolutions.com>:
>
> Hi Heiko,
>
> On Fri, Sep 9, 2022 at 11:36 AM Heiko Thiery <heiko.thiery at gmail.com> wrote:
> >
> > Hi Dario,
> >
> > Am Do., 8. Sept. 2022 um 21:20 Uhr schrieb Dario Binacchi
> > <dario.binacchi at amarulasolutions.com>:
> > >
> > > From: Michael Trimarchi <michael at amarulasolutions.com>
> > >
> > > BSH SMM S2 PRO (SystemMaster S2 Pro) Board is an add-on board which
> > > provide input and output interfaces to a dedicated carrier board. It is
> > > designed mainly to provide graphical/video and connectivity interfaces
> > > to the appliance.
> > >
> > > Board support package includes the following components:
> > > - mainline Linux kernel 5.19.7
> > > - mainline U-Boot 2022-07
> > > - Default packages from buildroot
> > >
> > > https://www.apertis.org/reference_hardware/imx8mn_bsh_smm_s2pro_setup/
> > >
> > > Add Ariel D'Alessandro and Dario Binacchi as co-maintainer, we work
> > > together on platform mainline
> > >
> > > Build and tested using:
> > > docker pull registry.gitlab.com/buildroot.org/buildroot/base:20220105.2314
> > >
> > > Cc: Ariel D'Alessandro <ariel.dalessandro at collabora.com>
> > > Cc: Jagan Teki <jagan at amarulasolutions.com>
> > > Cc: Heiko Thiery <heiko.thiery at gmail.com>
> > > Cc: Giulio Benetti <giulio.benetti at benettiengineering.com>
> > > Reviewed-by: Giulio Benetti <giulio.benetti at benettiengineering.com>
> > > Signed-off-by: Michael Trimarchi <michael at amarulasolutions.com>
> > > Tested-by: Ariel D'Alessandro <ariel.dalessandro at collabora.com>
> > > Signed-off-by: Dario Binacchi <dario.binacchi at amarulasolutions.com>
> > > ---
> > > Changes in v5:
> > > - Update the commit description.
> > > - Bump the kernel version to 5.19.7.
> > >
> > > Changes in v4:
> > > - Update the commit description.
> > > - Bump the kernel version to 5.18.19.
> > >
> > > Changes in v3:
> > > - Update the commit description.
> > > - Bump U-Boot to version 2022-07.
> > >
> > > Changes in v2:
> > > - Change commit subject line.
> > > - Use the buildroot's output directory if the binaries directory is
> > >   not passed as a parameter to the `flash.sh' script.
> > > - Replace the linux.config file with an architectural defconfig and
> > >   a config fragment for the changes.
> > >
> > > Signed-off-by: Dario Binacchi <dario.binacchi at amarulasolutions.com>
> > > ---
> > >  DEVELOPERS                                    |  4 +
> > >  .../imx8mn-bsh-smm-s2/linux.fragment          |  0
> > >  board/bsh/imx8mn-bsh-smm-s2-pro/extlinux.conf |  4 +
> > >  board/bsh/imx8mn-bsh-smm-s2-pro/flash.sh      | 23 ++++++
> > >  board/bsh/imx8mn-bsh-smm-s2-pro/genimage.cfg  | 17 +++++
> > >  board/bsh/imx8mn-bsh-smm-s2-pro/post-build.sh |  7 ++
> > >  board/bsh/imx8mn-bsh-smm-s2-pro/post-image.sh |  3 +
> > >  board/bsh/imx8mn-bsh-smm-s2-pro/readme.txt    | 73 +++++++++++++++++++
> > >  configs/imx8mn_bsh_smm_s2_defconfig           |  2 +-
> > >  configs/imx8mn_bsh_smm_s2_pro_defconfig       | 41 +++++++++++
> > >  10 files changed, 173 insertions(+), 1 deletion(-)
> > >  rename board/bsh/{ => common}/imx8mn-bsh-smm-s2/linux.fragment (100%)
> > >  create mode 100644 board/bsh/imx8mn-bsh-smm-s2-pro/extlinux.conf
> > >  create mode 100755 board/bsh/imx8mn-bsh-smm-s2-pro/flash.sh
> > >  create mode 100644 board/bsh/imx8mn-bsh-smm-s2-pro/genimage.cfg
> > >  create mode 100755 board/bsh/imx8mn-bsh-smm-s2-pro/post-build.sh
> > >  create mode 100755 board/bsh/imx8mn-bsh-smm-s2-pro/post-image.sh
> > >  create mode 100644 board/bsh/imx8mn-bsh-smm-s2-pro/readme.txt
> > >  create mode 100644 configs/imx8mn_bsh_smm_s2_pro_defconfig
> > >
> > > diff --git a/DEVELOPERS b/DEVELOPERS
> > > index d63cb22cce1d..cb2c10d322fb 100644
> > > --- a/DEVELOPERS
> > > +++ b/DEVELOPERS
> > > @@ -216,6 +216,8 @@ F:  configs/snps_archs38_haps_defconfig
> > >  F:     configs/snps_archs38_hsdk_defconfig
> > >
> > >  N:     Ariel D'Alessandro <ariel at vanguardiasur.com.ar>
> > > +F:     board/bsh/
> > > +F:     configs/imx8mn_bsh_smm_s2_pro_defconfig
> > >  F:     package/axfsutils/
> > >  F:     package/mali-t76x/
> > >
> > > @@ -675,6 +677,7 @@ F:  package/xinetd/
> > >  N:     Dario Binacchi <dario.binacchi at amarulasolutions.com>
> > >  F:     board/bsh/
> > >  F:     configs/imx8mn_bsh_smm_s2_defconfig
> > > +F:     configs/imx8mn_bsh_smm_s2_pro_defconfig
> > >  F:     package/uuu/
> > >
> > >  N:     Dario Binacchi <dariobin at libero.it>
> > > @@ -2108,6 +2111,7 @@ F:        package/python-pyzmq/
> > >  N:     Michael Trimarchi <michael at amarulasolutions.com>
> > >  F:     board/bsh/
> > >  F:     configs/imx8mn_bsh_smm_s2_defconfig
> > > +F:     configs/imx8mn_bsh_smm_s2_pro_defconfig
> > >  F:     package/python-spidev/
> > >
> > >  N:     Michael Vetter <jubalh at iodoru.org>
> > > diff --git a/board/bsh/imx8mn-bsh-smm-s2/linux.fragment b/board/bsh/common/imx8mn-bsh-smm-s2/linux.fragment
> > > similarity index 100%
> > > rename from board/bsh/imx8mn-bsh-smm-s2/linux.fragment
> > > rename to board/bsh/common/imx8mn-bsh-smm-s2/linux.fragment
> > > diff --git a/board/bsh/imx8mn-bsh-smm-s2-pro/extlinux.conf b/board/bsh/imx8mn-bsh-smm-s2-pro/extlinux.conf
> > > new file mode 100644
> > > index 000000000000..911135474253
> > > --- /dev/null
> > > +++ b/board/bsh/imx8mn-bsh-smm-s2-pro/extlinux.conf
> > > @@ -0,0 +1,4 @@
> > > +label buildroot
> > > +  kernel /boot/Image
> > > +  devicetree /boot/freescale/imx8mn-bsh-smm-s2pro.dtb
> > > +  append root=PARTUUID=%PARTUUID% rootwait rw
> > > diff --git a/board/bsh/imx8mn-bsh-smm-s2-pro/flash.sh b/board/bsh/imx8mn-bsh-smm-s2-pro/flash.sh
> > > new file mode 100755
> > > index 000000000000..17b20f009771
> > > --- /dev/null
> > > +++ b/board/bsh/imx8mn-bsh-smm-s2-pro/flash.sh
> > > @@ -0,0 +1,23 @@
> > > +#!/bin/bash
> > > +
> > > +if [ $# -eq 0 ]; then
> > > +    OUTPUT_DIR=output
> > > +else
> > > +    OUTPUT_DIR=$1
> > > +fi
> > > +
> > > +if ! test -d "${OUTPUT_DIR}" ; then
> > > +    echo "ERROR: no output directory specified."
> > > +    echo "Usage: $0 OUTPUT_DIR"
> > > +    echo ""
> > > +    echo "Arguments:"
> > > +    echo "    OUTPUT_DIR    The Buildroot output directory."
> > > +    exit 1
> > > +fi
> > > +
> > > +IMAGES_DIR=${OUTPUT_DIR}/images
> > > +
> > > +${OUTPUT_DIR}/host/bin/uuu -v -b emmc_all \
> > > +  ${IMAGES_DIR}/flash.bin \
> > > +  ${IMAGES_DIR}/sdcard.img
> > > +
> > > diff --git a/board/bsh/imx8mn-bsh-smm-s2-pro/genimage.cfg b/board/bsh/imx8mn-bsh-smm-s2-pro/genimage.cfg
> > > new file mode 100644
> > > index 000000000000..bc100b171dd6
> > > --- /dev/null
> > > +++ b/board/bsh/imx8mn-bsh-smm-s2-pro/genimage.cfg
> > > @@ -0,0 +1,17 @@
> > > +image sdcard.img {
> > > +       hdimage {
> > > +               partition-table-type = "gpt"
> > > +       }
> > > +
> > > +       partition imx-boot {
> > > +               in-partition-table = "no"
> > > +               image = "flash.bin"
> > > +               offset = 33K
> >
> > I was just wondering that the offset here is 33k. I had remembered
> > that for imx8mn boards the offset is 32k. Or am I wrong? Are you sure
> > that you start the bootloader from an SD card and not from eMMC?
>
> The board boots from eMMC. The board/bsh/imx8mn-bsh-smm-s2-pro/flash.sh
> calls the uuu application with the "emmc_all" option.

Ah ok. I'm not familiar with the uuu tool. Nevertheless, the offset in
the genimage config looks wrong to me. If you want to install the
created image without the uuu tool it will probably not work, because
the imx8mn processor expects the bootloader (flash.bin) image at
offset 32k.

> Thanks and regards,
> Dario
>
> >
> > [SNIP]
> >
> > --
> > Heiko
>
>
>
> --
>
> Dario Binacchi
>
> Embedded Linux Developer
>
> dario.binacchi at amarulasolutions.com
>
> __________________________________
>
>
> Amarula Solutions SRL
>
> Via Le Canevare 30, 31100 Treviso, Veneto, IT
>
> T. +39 042 243 5310
> info at amarulasolutions.com
>
> www.amarulasolutions.com



More information about the buildroot mailing list