qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH 1/2] memory: allow zero size for adjust_endianne


From: Michael S. Tsirkin
Subject: Re: [Qemu-devel] [PATCH 1/2] memory: allow zero size for adjust_endianness()
Date: Thu, 27 Aug 2015 14:08:47 +0300

On Thu, Aug 27, 2015 at 12:04:49PM +0100, Peter Maydell wrote:
> On 27 August 2015 at 11:53, Michael S. Tsirkin <address@hidden> wrote:
> > On Thu, Aug 27, 2015 at 11:49:32AM +0100, Peter Maydell wrote:
> >> But *why* does it require the size to be zero? I still think
> >> the caller should just avoid trying to do zero-size memory
> >> operations: they don't make sense. What is a zero size
> >> operation supposed to mean?
> 
> > This just mirrors an API we have in kvm: if you pass 0
> > size when registering an ioeventfd, it will match on access
> > of any size.
> 
> Hrm. It feels to me like the memory APIs ought to filter
> out bad access sizes at an earlier stage, rather than
> trying to make them work all the way through.
> 
> -- PMM

Why do you mention APIs? It's all internal to memory.c, isn't it?

-- 
MST



reply via email to

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