Re: [Qemu-devel] [PATCH 1/3] memory: drop find_ram_block()

2016-04-29 Thread Gonglei (Arei)
Hi, > > > > @@ -1447,8 +1432,9 @@ void qemu_ram_set_idstr(ram_addr_t addr, const > char *name, DeviceState *dev) > > } > > pstrcat(new_block->idstr, sizeof(new_block->idstr), name); > > > > -QLIST_FOREACH_RCU(block, &ram_list.blocks, next) { > > -if (block != new_block && !st

Re: [Qemu-devel] [PATCH 1/3] memory: drop find_ram_block()

2016-04-29 Thread Fam Zheng
On Wed, 04/20 11:34, Gonglei wrote: > On the one hand, we have already qemu_get_ram_block() whose function > is similar. On the other hand, we can directly use mr->ram_block but > searching RAMblock by ram_addr which is a kind of waste. > > Signed-off-by: Gonglei > --- > exec.c

[Qemu-devel] [PATCH 1/3] memory: drop find_ram_block()

2016-04-19 Thread Gonglei
On the one hand, we have already qemu_get_ram_block() whose function is similar. On the other hand, we can directly use mr->ram_block but searching RAMblock by ram_addr which is a kind of waste. Signed-off-by: Gonglei --- exec.c| 37 + incl