Re: [Qemu-devel] using fdt_setprop() to set properties to empty values

2017-03-02 Thread David Gibson
On Mon, Feb 27, 2017 at 10:11:57AM +, Peter Maydell wrote: > On 27 February 2017 at 01:05, David Gibson > wrote: > > On Fri, Feb 24, 2017 at 10:35:35AM +, Peter Maydell wrote: > >> On 24 February 2017 at 00:16, David Gibson > >> wrote: > >> > Ok, I've pushed libfdt upstream patches to (

Re: [Qemu-devel] using fdt_setprop() to set properties to empty values

2017-02-28 Thread David Gibson
On Wed, Mar 01, 2017 at 11:16:02AM +1100, David Gibson wrote: > On Mon, Feb 27, 2017 at 10:11:57AM +, Peter Maydell wrote: > > On 27 February 2017 at 01:05, David Gibson > > wrote: > > > On Fri, Feb 24, 2017 at 10:35:35AM +, Peter Maydell wrote: > > >> On 24 February 2017 at 00:16, David

Re: [Qemu-devel] using fdt_setprop() to set properties to empty values

2017-02-28 Thread David Gibson
On Mon, Feb 27, 2017 at 10:11:57AM +, Peter Maydell wrote: > On 27 February 2017 at 01:05, David Gibson > wrote: > > On Fri, Feb 24, 2017 at 10:35:35AM +, Peter Maydell wrote: > >> On 24 February 2017 at 00:16, David Gibson > >> wrote: > >> > Ok, I've pushed libfdt upstream patches to (

Re: [Qemu-devel] using fdt_setprop() to set properties to empty values

2017-02-27 Thread Peter Maydell
On 27 February 2017 at 01:05, David Gibson wrote: > On Fri, Feb 24, 2017 at 10:35:35AM +, Peter Maydell wrote: >> On 24 February 2017 at 00:16, David Gibson >> wrote: >> > Ok, I've pushed libfdt upstream patches to (a) make passing NULL to >> > setprop() with zero length explicitly safe and

Re: [Qemu-devel] using fdt_setprop() to set properties to empty values

2017-02-26 Thread David Gibson
On Fri, Feb 24, 2017 at 10:35:35AM +, Peter Maydell wrote: > On 24 February 2017 at 00:16, David Gibson > wrote: > > Ok, I've pushed libfdt upstream patches to (a) make passing NULL to > > setprop() with zero length explicitly safe and (b) add an > > fdt_setprop_empty() helper macro. Do you

Re: [Qemu-devel] using fdt_setprop() to set properties to empty values

2017-02-24 Thread Peter Maydell
On 24 February 2017 at 00:16, David Gibson wrote: > Ok, I've pushed libfdt upstream patches to (a) make passing NULL to > setprop() with zero length explicitly safe and (b) add an > fdt_setprop_empty() helper macro. Do you want me to make a pullreq to > update the qemu submodule? Yes, please. Ar

Re: [Qemu-devel] using fdt_setprop() to set properties to empty values

2017-02-23 Thread David Gibson
On Fri, Feb 24, 2017 at 09:49:11AM +1100, David Gibson wrote: > On Thu, Feb 23, 2017 at 08:52:01AM -0600, Eric Blake wrote: > > On 02/23/2017 06:33 AM, Peter Maydell wrote: > > > What's the right way to use libfdt's fdt_setprop to set a property > > > to have an empty value? At the moment in QEMU w

Re: [Qemu-devel] using fdt_setprop() to set properties to empty values

2017-02-23 Thread David Gibson
On Thu, Feb 23, 2017 at 08:52:01AM -0600, Eric Blake wrote: > On 02/23/2017 06:33 AM, Peter Maydell wrote: > > What's the right way to use libfdt's fdt_setprop to set a property > > to have an empty value? At the moment in QEMU we tend to use > > fdt_setprop(fdt, nodeoffset, "propertyname", NULL,

Re: [Qemu-devel] using fdt_setprop() to set properties to empty values

2017-02-23 Thread Eric Blake
On 02/23/2017 06:33 AM, Peter Maydell wrote: > What's the right way to use libfdt's fdt_setprop to set a property > to have an empty value? At the moment in QEMU we tend to use > fdt_setprop(fdt, nodeoffset, "propertyname", NULL, 0); > > and git grep 'fdt_setprop.*NULL' produces examples of this

[Qemu-devel] using fdt_setprop() to set properties to empty values

2017-02-23 Thread Peter Maydell
What's the right way to use libfdt's fdt_setprop to set a property to have an empty value? At the moment in QEMU we tend to use fdt_setprop(fdt, nodeoffset, "propertyname", NULL, 0); and git grep 'fdt_setprop.*NULL' produces examples of this usage in PPC and ARM fdt creation code. However the f