Re: [PATCH 1/1] command: oftree: support load device tree from memory

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



That sounds good. Thanks for the direction.

My workaround look like:
memcpy -d /tmp/rpi.dtb 0xf42400 0 0x10000
of_dump -f /tmp/rpi.dtb > /dev/null
oftree -f -l /tmp/rpi.dtb

Without 'of_dump', the 'oftree' give a bad magic 0x5.... error.

I need add support for HassOS to raspberry and in a second round I
will try to implement your suggestion.

best regards
Pascal

2018-06-07 10:53 GMT+02:00 Sascha Hauer <s.hauer@xxxxxxxxxxxxxx>:
> On Thu, Jun 07, 2018 at 10:29:53AM +0200, Pascal Vizeli wrote:
>> Thanks for this workaround. I will use this.
>>
>> I will later send a patch they store the device tree address on
>> raspberry into a variable.
>> So that user can load this, if he need it.
>>
>> The question is now, would you allow to load a device tree with a
>> memory address on oftree utility?
>> And if yes, where is the best place to add this function.
>
> Instead of a command I would prefer if you could just store r2 from
> the original bootloader you have been started with, and in a board
> specific initcall you copy the devicetree you found in memory to a
> file. Then the user has access to the devicetree with regular file
> commands and there is no need to guess the memory address where the
> original bootloader stored the device tree.
>
> Sascha
>
> --
> Pengutronix e.K.                           |                             |
> Industrial Linux Solutions                 | http://www.pengutronix.de/  |
> Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
> Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

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



[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux