On 2018/12/5 上午2:37, Jintack Lim wrote:
Hi, I'm wondering how the current implementation works when logging dirty pages during migration from vhost-net (in kernel) when used vIOMMU. I understand how vhost-net logs GPAs when not using vIOMMU. But when we use vhost with vIOMMU, then shouldn't vhost-net need to log the translated address (GPA) instead of the address written in the descriptor (IOVA) ? The current implementation looks like vhost-net just logs IOVA without translation in vhost_get_vq_desc() in drivers/vhost/net.c. It seems like QEMU doesn't do any further translation of the dirty log when syncing. I might be missing something. Could somebody shed some light on this?
Good catch. It looks like a bug to me. Want to post a patch for this? Thanks
Thanks, Jintack