mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Sascha Hauer <sha@pengutronix.de>
To: Frank Wunderlich <frank-w@public-files.de>
Cc: barebox@lists.infradead.org
Subject: Re: Re: barebox - rk3568
Date: Tue, 4 Jan 2022 15:16:20 +0100	[thread overview]
Message-ID: <20220104141620.GA22780@pengutronix.de> (raw)
In-Reply-To: <trinity-08e4162e-f564-43b8-859c-2e24b4247c1c-1641295251349@3c-app-gmx-bap27>

On Tue, Jan 04, 2022 at 12:20:51PM +0100, Frank Wunderlich wrote:
> Hi,
> 
> thanks, got it compiled and booting...currently looking around how to do things ;)
> have successful booted linux+dtb+initrd manually and pinged my router as network test.
> 
> now i looks how to include scripts that i don't need to write all again and again...
> 
> documentation says that a direktory will be used in boards directory, but this seems not working
> 
> so i used the config-approach
> 
> DEFAULT_ENVIRONMENT_PATH=arch/arm/boards/rockchip-rk3568-evb/defaultenv
> 
> i'm not sure how the saveenv works (where the environment is
> stored...i have no /dev/env0). in uboot i can define a device (mmc),
> partition (1:1), filename (uboot.env) for storing environment onto a
> fat-partition. i guess you have something similar too

You don't need a /dev/env0. The EVB device tree has:

               environment-sd {
                       compatible = "barebox,environment";
                       device-path = &environment_sd;
                       status = "disabled";
               };

               environment-emmc {
                       compatible = "barebox,environment";
                       device-path = &environment_emmc;
                       status = "disabled";
               };

One of these nodes will be enabled based on the current bootsource:

       if (bootsource == BOOTSOURCE_MMC && instance == 1)
               of_device_enable_path("/chosen/environment-sd");
       else
               of_device_enable_path("/chosen/environment-emmc");

As you have exchanged the device tree you either don't have the nodes
in your device tree or the device tree doesn't match the board code:

The EVB board code has:

static const struct of_device_id rk3568_evb_of_match[] = {
       { .compatible = "rockchip,rk3568-evb1-v10" },
       { /* Sentinel */},
};

Which matches the EVB device tree:

       compatible = "rockchip,rk3568-evb1-v10", "rockchip,rk3568";

I don't know exactly what you have changed and what not, but I think your
problem is somewhere here.

Sascha

-- 
Pengutronix e.K.                           |                             |
Steuerwalder Str. 21                       | http://www.pengutronix.de/  |
31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox


  reply	other threads:[~2022-01-04 14:18 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-04  8:39 Frank Wunderlich
2022-01-04 10:51 ` Sascha Hauer
2022-01-04 11:20   ` Aw: " Frank Wunderlich
2022-01-04 14:16     ` Sascha Hauer [this message]
2022-01-05 12:08 ` Ahmad Fatoum
2022-01-05 15:42   ` Aw: " Frank Wunderlich
2022-01-05 16:08     ` Ahmad Fatoum

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=20220104141620.GA22780@pengutronix.de \
    --to=sha@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    --cc=frank-w@public-files.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox