qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH 4/6] device_tree: Add support for reading device


From: Peter Maydell
Subject: Re: [Qemu-devel] [PATCH 4/6] device_tree: Add support for reading device tree properties
Date: Fri, 6 Jul 2012 08:18:12 +0100

On 6 July 2012 02:56, Peter Crosthwaite <address@hidden> wrote:
> On Fri, Jul 6, 2012 at 3:00 AM, Peter Maydell <address@hidden> wrote:
>> +uint32_t qemu_devtree_getprop_cell(void *fdt, const char *node_path,
>> +                                   const char *property)
>
> Hi Peter,
>
> Can we generalise and get functionality for reading cells with offsets
> as well? Your function assumes (and asserts) that the property is a
> single cell, but can we add a index parameter for reading a non-0th
> property out of a multi-cell prop? Needed for reading things like
> ranges, regs and interrupt properties.

We could, but in this instance I was just following the pattern
of the existing qemu_devtree_setprop_cell(), which also works only
on single-celled properties. Maybe 'set one cell in a multicell prop'
should be qemu_devtree_setprop_one_cell() ?

-- PMM



reply via email to

[Prev in Thread] Current Thread [Next in Thread]