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

Re: [Xen-devel] [RFC for-4.8 v2 4/7] xen/device-tree: Make dt_match_node match props



Hi Edgar,

On 07/06/2016 21:43, Edgar E. Iglesias wrote:
On Mon, Jun 06, 2016 at 06:39:39PM +0100, Julien Grall wrote:
On 03/06/16 14:29, Edgar E. Iglesias wrote:

[...]

AFAIK, it's needed to instantiate the dynamically sized array of pointers.
Another option is to make __DT_MATCH_PROPS take the char ** pointer.
The descriptor declaration would instead of looking like this:
    {
        __DT_MATCH_COMPATIBLE("mmio-sram"),
        __DT_MATCH_PROPS("no-memory-wc"),
        .data = &mattr_device_rw,
    },

Look something like this:

const char *props_no_mem_wc[] = { "no-memory-wc", NULL };

....

    {
        __DT_MATCH_COMPATIBLE("mmio-sram"),
        __DT_MATCH_PROPS(props_no_mem_wc),
        .data = &mattr_device_rw,
    },


Or do you have better suggestions?

How about defining props with the type "const char *props[]"?

Regards,

--
Julien Grall

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.