Re: [PATCH] migrate/ram: let ram_save_target_page_legacy() return if qemu file got error

2023-09-04 Thread Guoyi Tu
Hi Juan, what do you think of this patch? Can it be merged into the upstream? On 2023/8/15 15:21, Guoyi Tu wrote: When the migration process of a virtual machine using huge pages is cancelled, QEMU will continue to complete the processing of the current huge page through the qemu file object

Re: [PATCH] migrate/ram: let ram_save_target_page_legacy() return if qemu file got error

2023-08-17 Thread Guoyi Tu
I apologize for the previous email being cut off. I am resending it here. It sounds very reasonable. the return value of the QEMUFile interface cannot accurately reflect the actual situation, and the way these interfaces are being called during the migration process also is a little bit weird.

Re: [PATCH] migrate/ram: let ram_save_target_page_legacy() return if qemu file got error

2023-08-17 Thread Guoyi Tu
Thank you for the reminder. There might be some issues with the company's email service. I also noticed this morning that I missed receiving an email in response from Fabiano. On 2023/8/17 21:35, 【外部账号】 Peter Xu wrote: On Thu, Aug 17, 2023 at 10:19:19AM +0800, Guoyi Tu wrote: On 2023/8/16

Re: [PATCH] migrate/ram: let ram_save_target_page_legacy() return if qemu file got error

2023-08-17 Thread Peter Xu
On Thu, Aug 17, 2023 at 10:19:19AM +0800, Guoyi Tu wrote: > > > On 2023/8/16 23:15, 【外部账号】 Fabiano Rosas wrote: > > Peter Xu writes: > > > > > On Tue, Aug 15, 2023 at 07:42:24PM -0300, Fabiano Rosas wrote: > > > > Yep, I see that. I meant explicitly move the code into the loop. Feels a > > > >

Re: [PATCH] migrate/ram: let ram_save_target_page_legacy() return if qemu file got error

2023-08-16 Thread Guoyi Tu
On 2023/8/16 23:15, 【外部账号】 Fabiano Rosas wrote: Peter Xu writes: On Tue, Aug 15, 2023 at 07:42:24PM -0300, Fabiano Rosas wrote: Yep, I see that. I meant explicitly move the code into the loop. Feels a bit weird to check the QEMUFile for errors first thing inside the function when nothing

Re: [PATCH] migrate/ram: let ram_save_target_page_legacy() return if qemu file got error

2023-08-16 Thread Fabiano Rosas
Peter Xu writes: > On Tue, Aug 15, 2023 at 07:42:24PM -0300, Fabiano Rosas wrote: >> Yep, I see that. I meant explicitly move the code into the loop. Feels a >> bit weird to check the QEMUFile for errors first thing inside the >> function when nothing around it should have touched the QEMUFile.

Re: [PATCH] migrate/ram: let ram_save_target_page_legacy() return if qemu file got error

2023-08-16 Thread Peter Xu
On Tue, Aug 15, 2023 at 07:42:24PM -0300, Fabiano Rosas wrote: > Yep, I see that. I meant explicitly move the code into the loop. Feels a > bit weird to check the QEMUFile for errors first thing inside the > function when nothing around it should have touched the QEMUFile. Valid point. This

Re: [PATCH] migrate/ram: let ram_save_target_page_legacy() return if qemu file got error

2023-08-16 Thread Fabiano Rosas
Guoyi Tu writes: > When the migration process of a virtual machine using huge pages is > cancelled, > QEMU will continue to complete the processing of the current huge page > through the qemu file object got an error set. These processing, such as > compression and encryption, will consume a

Re: [PATCH] migrate/ram: let ram_save_target_page_legacy() return if qemu file got error

2023-08-15 Thread Guoyi Tu
On 2023/8/16 6:19, 【外部账号】 Peter Xu wrote: On Tue, Aug 15, 2023 at 09:35:19AM -0300, Fabiano Rosas wrote: Guoyi Tu writes: When the migration process of a virtual machine using huge pages is cancelled, QEMU will continue to complete the processing of the current huge page through the qemu

Re: [PATCH] migrate/ram: let ram_save_target_page_legacy() return if qemu file got error

2023-08-15 Thread Guoyi Tu
On 2023/8/15 20:35, 【外部账号】 Fabiano Rosas wrote: Guoyi Tu writes: When the migration process of a virtual machine using huge pages is cancelled, QEMU will continue to complete the processing of the current huge page through the qemu file object got an error set. These processing, such as

Re: [PATCH] migrate/ram: let ram_save_target_page_legacy() return if qemu file got error

2023-08-15 Thread Fabiano Rosas
Peter Xu writes: > On Tue, Aug 15, 2023 at 09:35:19AM -0300, Fabiano Rosas wrote: >> Guoyi Tu writes: >> >> > When the migration process of a virtual machine using huge pages is >> > cancelled, >> > QEMU will continue to complete the processing of the current huge page >> > through the qemu

Re: [PATCH] migrate/ram: let ram_save_target_page_legacy() return if qemu file got error

2023-08-15 Thread Peter Xu
On Tue, Aug 15, 2023 at 09:35:19AM -0300, Fabiano Rosas wrote: > Guoyi Tu writes: > > > When the migration process of a virtual machine using huge pages is > > cancelled, > > QEMU will continue to complete the processing of the current huge page > > through the qemu file object got an error

Re: [PATCH] migrate/ram: let ram_save_target_page_legacy() return if qemu file got error

2023-08-15 Thread Fabiano Rosas
Guoyi Tu writes: > When the migration process of a virtual machine using huge pages is > cancelled, > QEMU will continue to complete the processing of the current huge page > through the qemu file object got an error set. These processing, such as > compression and encryption, will consume a

[PATCH] migrate/ram: let ram_save_target_page_legacy() return if qemu file got error

2023-08-15 Thread Guoyi Tu
When the migration process of a virtual machine using huge pages is cancelled, QEMU will continue to complete the processing of the current huge page through the qemu file object got an error set. These processing, such as compression and encryption, will consume a lot of CPU resources which may