All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stephen Warren <swarren@wwwdotorg.org>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v2 4/8] test: py: add option to select device tree used during compilation
Date: Tue, 21 May 2019 10:21:48 -0600	[thread overview]
Message-ID: <ac06f0cd-27cf-5878-f8f6-b2bcc5570e05@wwwdotorg.org> (raw)
In-Reply-To: <1558357207-7345-5-git-send-email-patrick.delaunay@st.com>

On 5/20/19 7:00 AM, Patrick Delaunay wrote:
> Only used for spl compilation which include the device tree
> (with platdata or embedded device tree).
> For U-boot, test use config.dtb, by default :
>     "build_dir + '/arch/sandbox/dts/test.dtb'"
> 
> Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
> ---
> I need to force o_dt = 'all' to avoid make error:
> 
> make: *** empty string invalid as file name.  Stop.
> 
> But, I don't sure that it is the better solution for pytest.

This feels a bit odd. What board are you compiling for? I would expect 
the same compilation commands to "just work" for all boards, and would 
initially claim that if they don't, it's a bug in the makefiles that 
should be fixed there.

> diff --git a/test/py/conftest.py b/test/py/conftest.py

> +        if device_tree:
> +            o_dt = 'DEVICE_TREE=%s' % device_tree
> +        else:
> +            o_dt = 'all'

You might want to make o_dt be a list that's either empty or contains 
one string. Then ...

>           cmds = (
>               ['make', o_opt, '-s', board_type + '_defconfig'],
> -            ['make', o_opt, '-s', '-j8'],
> +            ['make', o_opt, o_dt, '-s', '-j8'],
>           )

... you can modify that line so that it doesn't add any additional 
options if o_dt is empty, so there's no change to the command-line 
except in the case where a DT is specified, to avoid the potential for 
any change to the existing flow:

             ['make', o_opt, *o_dt, '-s', '-j8'],

or:

             ['make', o_opt, '-s', '-j8'] + o_dt,

  reply	other threads:[~2019-05-21 16:21 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-20 12:59 [U-Boot] [PATCH v2 0/8] fdt: Allow indicating a node is for U-Boot proper only Patrick Delaunay
2019-05-20 13:00 ` [U-Boot] [PATCH v2 1/8] sandbox: add config for SPL boot with devicetree Patrick Delaunay
2019-05-20 15:35   ` Simon Glass
2019-05-20 13:00 ` [U-Boot] [PATCH v2 2/8] fdt: Allow to use EMBEDDED device tree for SPL Patrick Delaunay
2019-05-20 15:35   ` Simon Glass
2019-05-20 13:00 ` [U-Boot] [PATCH v2 3/8] sandbox: add option show_of_embedded for spl test Patrick Delaunay
2019-05-20 15:35   ` Simon Glass
2019-05-20 13:00 ` [U-Boot] [PATCH v2 4/8] test: py: add option to select device tree used during compilation Patrick Delaunay
2019-05-21 16:21   ` Stephen Warren [this message]
2019-05-21 18:32     ` Patrick DELAUNAY
2019-05-21 21:10       ` Stephen Warren
2019-05-20 13:00 ` [U-Boot] [PATCH v2 5/8] test: move SPL test nodes in test device tree Patrick Delaunay
2019-05-20 15:35   ` Simon Glass
2019-05-20 13:00 ` [U-Boot] [PATCH v2 6/8] test: check u-boot properties in SPL " Patrick Delaunay
2019-05-20 15:35   ` Simon Glass
2019-05-20 13:00 ` [U-Boot] [PATCH v2 7/8] fdt: Allow indicating a node is for U-Boot proper only Patrick Delaunay
2019-05-20 13:00 ` [U-Boot] [PATCH v2 8/8] dm: doc: add documentation for pre-reloc properties in SPL and TPL Patrick Delaunay
2019-05-20 16:09   ` Simon Glass
2019-05-20 15:35 ` [U-Boot] [PATCH v2 0/8] fdt: Allow indicating a node is for U-Boot proper only Simon Glass
2019-05-21 16:07   ` Patrick DELAUNAY
2019-05-22  0:53     ` Simon Glass

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=ac06f0cd-27cf-5878-f8f6-b2bcc5570e05@wwwdotorg.org \
    --to=swarren@wwwdotorg.org \
    --cc=u-boot@lists.denx.de \
    /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.