All of lore.kernel.org
 help / color / mirror / Atom feed
From: Niek Linnenbank <nieklinnenbank@gmail.com>
To: "Philippe Mathieu-Daudé" <f4bug@amsat.org>
Cc: "Peter Maydell" <peter.maydell@linaro.org>,
	"Alex Bennée" <alex.bennee@linaro.org>,
	jasowang@redhat.com, "QEMU Developers" <qemu-devel@nongnu.org>,
	"Beniamino Galvani" <b.galvani@gmail.com>,
	qemu-arm <qemu-arm@nongnu.org>, "Cleber Rosa" <crosa@redhat.com>,
	"Igor Mammedov" <imammedo@redhat.com>,
	"Philippe Mathieu-Daudé" <philmd@redhat.com>
Subject: Re: [PATCH v4 16/20] tests/boot_linux_console: Add a SLOW test booting Ubuntu on OrangePi PC
Date: Thu, 6 Feb 2020 22:21:34 +0100	[thread overview]
Message-ID: <CAPan3Wq8eftDpzxzGoeY5Qhpvcw8oA0vFebXwmSbT+78UaDRcg@mail.gmail.com> (raw)
In-Reply-To: <6dd1ab52-3a75-c439-f26b-fa04d797059c@amsat.org>

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

Hi Philippe,

On Sun, Jan 19, 2020 at 11:30 PM Philippe Mathieu-Daudé <f4bug@amsat.org>
wrote:

> On 1/19/20 1:50 AM, Niek Linnenbank wrote:
> > From: Philippe Mathieu-Daudé <f4bug@amsat.org>
> >
> > This test boots Ubuntu Bionic on a OrangePi PC board.
> >
> > As it requires 1GB of storage, and is slow, this test is disabled
> > on automatic CI testing.
> >
> > It is useful for workstation testing. Currently Avocado timeouts too
> > quickly, so we can't run userland commands.
> >
> > The kernel image and DeviceTree blob are built by the Armbian
> > project (based on Debian):
> > https://www.armbian.com/orange-pi-pc/
> >
> > The Ubuntu image is downloaded from:
> > https://dl.armbian.com/orangepipc/Bionic_current
>
> I forgot the image is compressed is compressed with 7z, which is not
> provided by avocado.utils.archive. This patch requires more checks, see
> inlined...
>
> >
> > This test can be run using:
> >
> >   $ AVOCADO_ALLOW_LARGE_STORAGE=yes \
> >     avocado --show=app,console run -t machine:orangepi-pc \
> >       tests/acceptance/boot_linux_console.py
> >   console: U-Boot SPL 2019.04-armbian (Nov 18 2019 - 23:08:35 +0100)
> >   console: DRAM: 1024 MiB
> >   console: Failed to set core voltage! Can't set CPU frequency
> >   console: Trying to boot from MMC1
> >   console: U-Boot 2019.04-armbian (Nov 18 2019 - 23:08:35 +0100)
> Allwinner Technology
> >   console: CPU:   Allwinner H3 (SUN8I 0000)
> >   console: Model: Xunlong Orange Pi PC
> >   console: DRAM:  1 GiB
> >   console: MMC:   mmc@1c0f000: 0
> >   [...]
> >   console: Uncompressing Linux... done, booting the kernel.
> >   console: Booting Linux on physical CPU 0x0
> >   console: Linux version 5.3.9-sunxi (root@builder) (gcc version 8.3.0
> (GNU Toolchain for the A-profile Architecture 8.3-2019.03 (arm-rel-8.36)))
> #19.11.3 SMP Mon Nov 18 18:49:43 CET 2019
> >   console: CPU: ARMv7 Processor [410fc075] revision 5 (ARMv7),
> cr=50c5387d
> >   console: CPU: div instructions available: patching division code
> >   console: CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing
> instruction cache
> >   console: OF: fdt: Machine model: Xunlong Orange Pi PC
> >   [...]
> >   console: EXT4-fs (mmcblk0p1): mounted filesystem with writeback data
> mode. Opts: (null)
> >   console: done.
> >   console: Begin: Running /scripts/local-bottom ... done.
> >   console: Begin: Running /scripts/init-bottom ... done.
> >   console: systemd[1]: systemd 237 running in system mode. (...)
> >   console: systemd[1]: Detected architecture arm.
> >   console: Welcome to Ubuntu 18.04.3 LTS!
> >   console: systemd[1]: Set hostname to <orangepipc>.
> >
> > Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
> > [NL: rename in commit message Raspbian to Armbian, remove
> vm.set_machine()]
> > [NL: changed test to boot from SD card via BootROM]
> > Signed-off-by: Niek Linnenbank <nieklinnenbank@gmail.com>
> > ---
> >  tests/acceptance/boot_linux_console.py | 41 ++++++++++++++++++++++++++
> >  1 file changed, 41 insertions(+)
> >
> > diff --git a/tests/acceptance/boot_linux_console.py
> b/tests/acceptance/boot_linux_console.py
> > index 50294e1675..399d5062db 100644
> > --- a/tests/acceptance/boot_linux_console.py
> > +++ b/tests/acceptance/boot_linux_console.py
>
> This patch needs:
>
>   from avocado.utils.path import find_command
>
>   P7ZIP_AVAILABLE = True
>   try:
>       find_command('7z')
>   except CmdNotFoundError:
>       P7ZIP_AVAILABLE = False
>
> > @@ -591,6 +591,47 @@ class BootLinuxConsole(Test):
> >          exec_command_and_wait_for_pattern(self, 'reboot',
> >                                                  'reboot: Restarting
> system')
> >
> > +    @skipUnless(os.getenv('AVOCADO_ALLOW_LARGE_STORAGE'), 'storage
> limited')
>
>        @skipUnless(P7ZIP_AVAILABLE, '7z not installed')
>

Ah indeed, that makes sense. I'll add this check for v5.
Now that we come accross this, I'm thinking that functionality like
decompression
might not be specific to the linux tests and perhaps should eventually come
in a utility/helper .py file.

Regards,
Niek


>
> > +    def test_arm_orangepi_bionic(self):
> > +        """
> > +        :avocado: tags=arch:arm
> > +        :avocado: tags=machine:orangepi-pc
> > +        """
> > +
> > +        # This test download a 196MB compressed image and expand it to
> 932MB...
> > +        image_url = ('https://dl.armbian.com/orangepipc/archive/'
> > +
>  'Armbian_19.11.3_Orangepipc_bionic_current_5.3.9.7z')
> > +        image_hash = '196a8ffb72b0123d92cea4a070894813d305c71e'
> > +        image_path_7z = self.fetch_asset(image_url,
> asset_hash=image_hash)
> > +        image_name =
> 'Armbian_19.11.3_Orangepipc_bionic_current_5.3.9.img'
> > +        image_path = os.path.join(self.workdir, image_name)
> > +        process.run("7z e -o%s %s" % (self.workdir, image_path_7z))
>
> Because here 7z is called ^
>
> > +
> > +        self.vm.set_console()
> > +        self.vm.add_args('-drive', 'file=' + image_path +
> ',if=sd,format=raw',
> > +                         '-nic', 'user',
> > +                         '-no-reboot')
> > +        self.vm.launch()
> > +
> > +        kernel_command_line = (self.KERNEL_COMMON_COMMAND_LINE +
> > +                               'console=ttyS0,115200 '
> > +                               'loglevel=7 '
> > +                               'nosmp '
> > +                               'systemd.default_timeout_start_sec=9000 '
> > +
>  'systemd.mask=armbian-zram-config.service '
> > +                               'systemd.mask=armbian-ramlog.service')
> > +
> > +        self.wait_for_console_pattern('U-Boot SPL')
> > +        self.wait_for_console_pattern('Autoboot in ')
> > +        exec_command_and_wait_for_pattern(self, ' ', '=>')
> > +        exec_command_and_wait_for_pattern(self, "setenv extraargs '" +
> > +                                                kernel_command_line +
> "'", '=>')
> > +        exec_command_and_wait_for_pattern(self, 'boot', 'Starting
> kernel ...');
> > +
> > +        self.wait_for_console_pattern('systemd[1]: Set hostname ' +
> > +                                      'to <orangepipc>')
> > +        self.wait_for_console_pattern('Starting Load Kernel Modules...')
> > +
> >      def test_s390x_s390_ccw_virtio(self):
> >          """
> >          :avocado: tags=arch:s390x
> >
>


-- 
Niek Linnenbank

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

  reply	other threads:[~2020-02-06 21:33 UTC|newest]

Thread overview: 55+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-01-19  0:50 [PATCH v4 00/20] Add Allwinner H3 SoC and Orange Pi PC Machine Niek Linnenbank
2020-01-19  0:50 ` [PATCH v4 01/20] hw/arm: add Allwinner H3 System-on-Chip Niek Linnenbank
2020-01-19 18:01   ` Philippe Mathieu-Daudé
2020-02-01 19:21     ` Niek Linnenbank
2020-02-01 20:52       ` Philippe Mathieu-Daudé
2020-01-19  0:50 ` [PATCH v4 02/20] hw/arm: add Xunlong Orange Pi PC machine Niek Linnenbank
2020-01-19 18:04   ` Philippe Mathieu-Daudé
2020-02-02 22:47     ` Niek Linnenbank
2020-01-21 16:39   ` Igor Mammedov
2020-02-02 22:37     ` Niek Linnenbank
2020-01-19  0:50 ` [PATCH v4 03/20] hw/arm/allwinner-h3: add Clock Control Unit Niek Linnenbank
2020-01-19 18:34   ` Philippe Mathieu-Daudé
2020-02-01 21:15     ` Niek Linnenbank
2020-01-19  0:50 ` [PATCH v4 04/20] hw/arm/allwinner-h3: add USB host controller Niek Linnenbank
2020-01-19 18:37   ` Philippe Mathieu-Daudé
2020-01-19 18:44     ` Philippe Mathieu-Daudé
2020-02-02 19:33       ` Niek Linnenbank
2020-02-12 22:23         ` Philippe Mathieu-Daudé
2020-02-02 19:12     ` Niek Linnenbank
2020-01-19  0:50 ` [PATCH v4 05/20] hw/arm/allwinner-h3: add System Control module Niek Linnenbank
2020-01-19 18:46   ` Philippe Mathieu-Daudé
2020-01-19  0:50 ` [PATCH v4 06/20] hw/arm/allwinner: add CPU Configuration module Niek Linnenbank
2020-01-19 18:52   ` Philippe Mathieu-Daudé
2020-02-02 20:25     ` Niek Linnenbank
2020-01-19  0:50 ` [PATCH v4 07/20] hw/arm/allwinner: add Security Identifier device Niek Linnenbank
2020-01-19 18:57   ` Philippe Mathieu-Daudé
2020-02-02 20:47     ` Niek Linnenbank
2020-01-19  0:50 ` [PATCH v4 08/20] hw/arm/allwinner: add SD/MMC host controller Niek Linnenbank
2020-01-19 19:01   ` Philippe Mathieu-Daudé
2020-02-02 21:43     ` Niek Linnenbank
2020-02-07 21:09       ` Niek Linnenbank
2020-01-19  0:50 ` [PATCH v4 09/20] hw/arm/allwinner-h3: add EMAC ethernet device Niek Linnenbank
2020-01-19  0:50 ` [PATCH v4 10/20] hw/arm/allwinner-h3: add Boot ROM support Niek Linnenbank
2020-01-19 19:14   ` Philippe Mathieu-Daudé
2020-02-02 22:11     ` Niek Linnenbank
2020-01-19  0:50 ` [PATCH v4 11/20] hw/arm/allwinner-h3: add SDRAM controller device Niek Linnenbank
2020-01-19  0:50 ` [PATCH v4 12/20] hw/arm/allwinner: add RTC device support Niek Linnenbank
2020-01-19  0:50 ` [PATCH v4 13/20] tests/boot_linux_console: Add a quick test for the OrangePi PC board Niek Linnenbank
2020-01-19  0:50 ` [PATCH v4 14/20] tests/boot_linux_console: Add initrd test for the Orange Pi " Niek Linnenbank
2020-01-19  0:50 ` [PATCH v4 15/20] tests/boot_linux_console: Add a SD card test for the OrangePi " Niek Linnenbank
2020-01-19  0:50 ` [PATCH v4 16/20] tests/boot_linux_console: Add a SLOW test booting Ubuntu on OrangePi PC Niek Linnenbank
2020-01-19 22:30   ` Philippe Mathieu-Daudé
2020-02-06 21:21     ` Niek Linnenbank [this message]
2020-02-12 22:02       ` Philippe Mathieu-Daudé
2020-01-19  0:50 ` [PATCH v4 17/20] Acceptance tests: Extract _console_interaction() Niek Linnenbank
2020-01-19  0:51 ` [PATCH v4 18/20] Acceptance tests: Add interrupt_interactive_console_until_pattern() Niek Linnenbank
2020-01-19  0:51 ` [PATCH v4 19/20] tests/boot_linux_console: Test booting NetBSD via U-Boot on OrangePi PC Niek Linnenbank
2020-01-19  0:51 ` [PATCH v4 20/20] docs: add Orange Pi PC document Niek Linnenbank
2020-01-19 11:51 ` [PATCH v4 00/20] Add Allwinner H3 SoC and Orange Pi PC Machine Niek Linnenbank
2020-02-12 21:47 ` Niek Linnenbank
2020-02-12 22:12   ` Philippe Mathieu-Daudé
2020-02-17 20:27     ` Niek Linnenbank
2020-02-18  6:46       ` Philippe Mathieu-Daudé
2020-02-18 10:05         ` Peter Maydell
2020-02-18 21:50           ` Niek Linnenbank

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAPan3Wq8eftDpzxzGoeY5Qhpvcw8oA0vFebXwmSbT+78UaDRcg@mail.gmail.com \
    --to=nieklinnenbank@gmail.com \
    --cc=alex.bennee@linaro.org \
    --cc=b.galvani@gmail.com \
    --cc=crosa@redhat.com \
    --cc=f4bug@amsat.org \
    --cc=imammedo@redhat.com \
    --cc=jasowang@redhat.com \
    --cc=peter.maydell@linaro.org \
    --cc=philmd@redhat.com \
    --cc=qemu-arm@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.