Re: [PATCH v3 1/5] device_tree: add qemu_fdt_setprop_strings() helper

2022-08-10 Thread Andrew Jones
On Thu, Jul 28, 2022 at 11:22:27AM +0200, Andrew Jones wrote: > On Wed, Jul 27, 2022 at 11:39:01PM +0100, Ben Dooks wrote: > > Add a helper to set a property from a set of strings > > to reduce the following code: > > > > static const char * const clint_compat[2] = { > > "sifive,clint0

Re: [PATCH v3 1/5] device_tree: add qemu_fdt_setprop_strings() helper

2022-07-28 Thread Ben Dooks
On Thu, Jul 28, 2022 at 11:22:27AM +0200, Andrew Jones wrote: > On Wed, Jul 27, 2022 at 11:39:01PM +0100, Ben Dooks wrote: > > Add a helper to set a property from a set of strings > > to reduce the following code: > > > > static const char * const clint_compat[2] = { > > "sifive,clint0

Re: [PATCH v3 1/5] device_tree: add qemu_fdt_setprop_strings() helper

2022-07-28 Thread Andrew Jones
On Wed, Jul 27, 2022 at 11:39:01PM +0100, Ben Dooks wrote: > Add a helper to set a property from a set of strings > to reduce the following code: > > static const char * const clint_compat[2] = { > "sifive,clint0", "riscv,clint0" > }; > > qemu_fdt_setprop_string_array(fdt, nod

[PATCH v3 1/5] device_tree: add qemu_fdt_setprop_strings() helper

2022-07-27 Thread Ben Dooks
Add a helper to set a property from a set of strings to reduce the following code: static const char * const clint_compat[2] = { "sifive,clint0", "riscv,clint0" }; qemu_fdt_setprop_string_array(fdt, nodename, "compatible", (char **)&clint_compat, ARRAY_SIZE(clint_compa