On 01/08/2012 08:59 PM, Andreas Färber wrote:
> Am 08.01.2012 18:57, schrieb Avi Kivity:
> > memory_region_set_offset() is used in only one place, and is deprecated.
> > Remove the single use and the function itself.
>
> Does the removal of the offset mean that memory_region_find() can be
> simplified to just return a MemoryRegion* now? :)

No.  In particular, aliases allow almost the same offsetting
capabilities (the difference is that aliases cannot offset beyond ->size
(or before 0) while set_offset() can.

Consider a vga window at 0xa0000 pointing at the framebuffer at
0xe0000000, with alias_offset 0x10000.

A memory_region_find() that finds it will return (mr,
.offset_within_region = 0x10000), .size = 0x8000, there is no way this
can be expressed by returning just a memory region (well you could
return the alias, but that complicates things for the caller).

-- 
error compiling committee.c: too many arguments to function


Reply via email to