Re: [Qemu-devel] [PATCH v2 08/23] pflash_cfi01: change to new-style MMIO accessors

2015-06-17 Thread Markus Armbruster
Paolo Bonzini writes: > On 09/06/2015 20:08, Richard Henderson wrote: >> > > +bool be = !!(pfl->features & (1 << PFLASH_BE)); >> > > >> > > !!() not needed. Otherwise >> > >> > I don't like magic bool-ification... >> >> I don't like !! just as much. If you don't like implicit conversion, t

Re: [Qemu-devel] [PATCH v2 08/23] pflash_cfi01: change to new-style MMIO accessors

2015-06-17 Thread Paolo Bonzini
On 09/06/2015 20:08, Richard Henderson wrote: > > > +bool be = !!(pfl->features & (1 << PFLASH_BE)); > > > > > > !!() not needed. Otherwise > > > > I don't like magic bool-ification... > > I don't like !! just as much. If you don't like implicit conversion, then use > != 0. Fair enough, l

Re: [Qemu-devel] [PATCH v2 08/23] pflash_cfi01: change to new-style MMIO accessors

2015-06-09 Thread Michael S. Tsirkin
On Tue, Jun 09, 2015 at 11:08:31AM -0700, Richard Henderson wrote: > On 06/04/2015 01:02 AM, Paolo Bonzini wrote: > > > > > > On 04/06/2015 08:19, Peter Crosthwaite wrote: > >> On Wed, Jun 3, 2015 at 10:08 AM, Paolo Bonzini wrote: > >>> This is a required step to implement read_with_attrs and wr

Re: [Qemu-devel] [PATCH v2 08/23] pflash_cfi01: change to new-style MMIO accessors

2015-06-09 Thread Richard Henderson
On 06/04/2015 01:02 AM, Paolo Bonzini wrote: > > > On 04/06/2015 08:19, Peter Crosthwaite wrote: >> On Wed, Jun 3, 2015 at 10:08 AM, Paolo Bonzini wrote: >>> This is a required step to implement read_with_attrs and write_with_attrs. >>> >>> Signed-off-by: Paolo Bonzini >>> --- >>> hw/block/pfl

Re: [Qemu-devel] [PATCH v2 08/23] pflash_cfi01: change to new-style MMIO accessors

2015-06-04 Thread Laszlo Ersek
On 06/04/15 10:02, Paolo Bonzini wrote: > > > On 04/06/2015 08:19, Peter Crosthwaite wrote: >> On Wed, Jun 3, 2015 at 10:08 AM, Paolo Bonzini wrote: >>> This is a required step to implement read_with_attrs and write_with_attrs. >>> >>> Signed-off-by: Paolo Bonzini >>> --- >>> hw/block/pflash_c

Re: [Qemu-devel] [PATCH v2 08/23] pflash_cfi01: change to new-style MMIO accessors

2015-06-04 Thread Paolo Bonzini
On 04/06/2015 08:19, Peter Crosthwaite wrote: > On Wed, Jun 3, 2015 at 10:08 AM, Paolo Bonzini wrote: >> This is a required step to implement read_with_attrs and write_with_attrs. >> >> Signed-off-by: Paolo Bonzini >> --- >> hw/block/pflash_cfi01.c | 96 >> ++--

Re: [Qemu-devel] [PATCH v2 08/23] pflash_cfi01: change to new-style MMIO accessors

2015-06-03 Thread Peter Crosthwaite
On Wed, Jun 3, 2015 at 10:08 AM, Paolo Bonzini wrote: > This is a required step to implement read_with_attrs and write_with_attrs. > > Signed-off-by: Paolo Bonzini > --- > hw/block/pflash_cfi01.c | 96 > ++--- Nice stats. > 1 file changed, 10 insert

[Qemu-devel] [PATCH v2 08/23] pflash_cfi01: change to new-style MMIO accessors

2015-06-03 Thread Paolo Bonzini
This is a required step to implement read_with_attrs and write_with_attrs. Signed-off-by: Paolo Bonzini --- hw/block/pflash_cfi01.c | 96 ++--- 1 file changed, 10 insertions(+), 86 deletions(-) diff --git a/hw/block/pflash_cfi01.c b/hw/block/pflash_cf