Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-08 Thread Jason Wang
On Wed, Sep 8, 2021 at 11:19 PM Peter Xu wrote: > > On Wed, Sep 08, 2021 at 09:19:27AM +0100, Dr. David Alan Gilbert wrote: > > * Jason Wang (jasow...@redhat.com) wrote: > > > On Wed, Sep 8, 2021 at 2:32 AM Peter Xu wrote: > > > > > > > > On Thu, Sep 02, 2021 at 04:22:55AM -0300, Leonardo Bras

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-08 Thread Daniel P . Berrangé
On Tue, Sep 07, 2021 at 12:13:28PM +0100, Dr. David Alan Gilbert wrote: > * Daniel P. Berrangé (berra...@redhat.com) wrote: > > On Wed, Sep 01, 2021 at 11:35:33AM -0400, Peter Xu wrote: > > > On Wed, Sep 01, 2021 at 09:53:07AM +0100, Daniel P. Berrangé wrote: > > > > On Tue, Aug 31, 2021 at

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-08 Thread Peter Xu
On Wed, Sep 08, 2021 at 09:19:27AM +0100, Dr. David Alan Gilbert wrote: > * Jason Wang (jasow...@redhat.com) wrote: > > On Wed, Sep 8, 2021 at 2:32 AM Peter Xu wrote: > > > > > > On Thu, Sep 02, 2021 at 04:22:55AM -0300, Leonardo Bras Soares Passos > > > wrote: > > > > > I don't think it is

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-08 Thread Dr. David Alan Gilbert
* Jason Wang (jasow...@redhat.com) wrote: > On Wed, Sep 8, 2021 at 2:32 AM Peter Xu wrote: > > > > On Thu, Sep 02, 2021 at 04:22:55AM -0300, Leonardo Bras Soares Passos wrote: > > > > I don't think it is valid to unconditionally enable this feature due to > > > > the > > > > resource usage

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-07 Thread Jason Wang
On Wed, Sep 8, 2021 at 11:24 AM Peter Xu wrote: > > On Wed, Sep 08, 2021 at 10:59:57AM +0800, Jason Wang wrote: > > On Wed, Sep 8, 2021 at 2:32 AM Peter Xu wrote: > > > > > > On Thu, Sep 02, 2021 at 04:22:55AM -0300, Leonardo Bras Soares Passos > > > wrote: > > > > > I don't think it is valid

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-07 Thread Peter Xu
On Wed, Sep 08, 2021 at 10:59:57AM +0800, Jason Wang wrote: > On Wed, Sep 8, 2021 at 2:32 AM Peter Xu wrote: > > > > On Thu, Sep 02, 2021 at 04:22:55AM -0300, Leonardo Bras Soares Passos wrote: > > > > I don't think it is valid to unconditionally enable this feature due to > > > > the > > > >

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-07 Thread Jason Wang
On Wed, Sep 8, 2021 at 2:32 AM Peter Xu wrote: > > On Thu, Sep 02, 2021 at 04:22:55AM -0300, Leonardo Bras Soares Passos wrote: > > > I don't think it is valid to unconditionally enable this feature due to > > > the > > > resource usage implications > > > > > >

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-07 Thread Peter Xu
On Thu, Sep 02, 2021 at 04:22:55AM -0300, Leonardo Bras Soares Passos wrote: > > I don't think it is valid to unconditionally enable this feature due to the > > resource usage implications > > > > https://www.kernel.org/doc/html/v5.4/networking/msg_zerocopy.html > > > > "A zerocopy failure will

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-07 Thread Dr. David Alan Gilbert
* Daniel P. Berrangé (berra...@redhat.com) wrote: > On Thu, Sep 02, 2021 at 05:52:15AM -0300, Leonardo Bras Soares Passos wrote: > > On Thu, Sep 2, 2021 at 5:21 AM Daniel P. Berrangé > > wrote: > > > > > > On Thu, Sep 02, 2021 at 04:22:55AM -0300, Leonardo Bras Soares Passos > > > wrote: > > >

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-07 Thread Dr. David Alan Gilbert
* Daniel P. Berrangé (berra...@redhat.com) wrote: > On Wed, Sep 01, 2021 at 11:35:33AM -0400, Peter Xu wrote: > > On Wed, Sep 01, 2021 at 09:53:07AM +0100, Daniel P. Berrangé wrote: > > > On Tue, Aug 31, 2021 at 04:29:09PM -0400, Peter Xu wrote: > > > > On Tue, Aug 31, 2021 at 02:16:42PM +0100,

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-02 Thread Leonardo Bras Soares Passos
On Thu, Sep 2, 2021 at 6:59 AM Daniel P. Berrangé wrote: > > On Thu, Sep 02, 2021 at 06:49:06AM -0300, Leonardo Bras Soares Passos wrote: > > On Thu, Sep 2, 2021 at 6:20 AM Daniel P. Berrangé > > wrote: > > > > > > On Thu, Sep 02, 2021 at 05:52:15AM -0300, Leonardo Bras Soares Passos > > >

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-02 Thread Daniel P . Berrangé
On Thu, Sep 02, 2021 at 06:49:06AM -0300, Leonardo Bras Soares Passos wrote: > On Thu, Sep 2, 2021 at 6:20 AM Daniel P. Berrangé wrote: > > > > On Thu, Sep 02, 2021 at 05:52:15AM -0300, Leonardo Bras Soares Passos wrote: > > > On Thu, Sep 2, 2021 at 5:21 AM Daniel P. Berrangé > > > wrote: > > >

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-02 Thread Leonardo Bras Soares Passos
On Thu, Sep 2, 2021 at 6:20 AM Daniel P. Berrangé wrote: > > On Thu, Sep 02, 2021 at 05:52:15AM -0300, Leonardo Bras Soares Passos wrote: > > On Thu, Sep 2, 2021 at 5:21 AM Daniel P. Berrangé > > wrote: > > > > > > On Thu, Sep 02, 2021 at 04:22:55AM -0300, Leonardo Bras Soares Passos > > >

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-02 Thread Daniel P . Berrangé
On Thu, Sep 02, 2021 at 05:52:15AM -0300, Leonardo Bras Soares Passos wrote: > On Thu, Sep 2, 2021 at 5:21 AM Daniel P. Berrangé wrote: > > > > On Thu, Sep 02, 2021 at 04:22:55AM -0300, Leonardo Bras Soares Passos wrote: > > > Hello Daniel, thanks for the feedback ! > > > > > > On Tue, Aug 31,

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-02 Thread Leonardo Bras Soares Passos
On Thu, Sep 2, 2021 at 5:21 AM Daniel P. Berrangé wrote: > > On Thu, Sep 02, 2021 at 04:22:55AM -0300, Leonardo Bras Soares Passos wrote: > > Hello Daniel, thanks for the feedback ! > > > > On Tue, Aug 31, 2021 at 10:17 AM Daniel P. Berrangé > > wrote: > > > > > > On Tue, Aug 31, 2021 at

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-02 Thread Daniel P . Berrangé
On Thu, Sep 02, 2021 at 04:22:55AM -0300, Leonardo Bras Soares Passos wrote: > Hello Daniel, thanks for the feedback ! > > On Tue, Aug 31, 2021 at 10:17 AM Daniel P. Berrangé > wrote: > > > > On Tue, Aug 31, 2021 at 08:02:39AM -0300, Leonardo Bras wrote: > > > Call

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-02 Thread Leonardo Bras Soares Passos
Thanks for contributing Jason! On Thu, Sep 2, 2021 at 4:23 AM Jason Wang wrote: > > > 在 2021/9/1 下午11:35, Peter Xu 写道: > > On Wed, Sep 01, 2021 at 09:53:07AM +0100, Daniel P. Berrangé wrote: > >> On Tue, Aug 31, 2021 at 04:29:09PM -0400, Peter Xu wrote: > >>> On Tue, Aug 31, 2021 at 02:16:42PM

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-02 Thread Leonardo Bras Soares Passos
A few more comments on this one: On Wed, Sep 1, 2021 at 12:44 PM Daniel P. Berrangé wrote: > > > From the safe side we may want to only enable one of them until we prove > > they'll work together I guess.. > > MPTCP is good when we're network limited for migration > > KTLS will be good when

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-02 Thread Leonardo Bras Soares Passos
Hello Peter, thank you for this feedback! On Tue, Aug 31, 2021 at 5:29 PM Peter Xu wrote: > Yes it would be great to be a migration capability in parallel to multifd. At > initial phase if it's easy to be implemented on multi-fd only, we can add a > dependency between the caps. In the future we

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-02 Thread Jason Wang
在 2021/9/1 下午11:35, Peter Xu 写道: On Wed, Sep 01, 2021 at 09:53:07AM +0100, Daniel P. Berrangé wrote: On Tue, Aug 31, 2021 at 04:29:09PM -0400, Peter Xu wrote: On Tue, Aug 31, 2021 at 02:16:42PM +0100, Daniel P. Berrangé wrote: On Tue, Aug 31, 2021 at 08:02:39AM -0300, Leonardo Bras wrote:

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-02 Thread Leonardo Bras Soares Passos
Hello Daniel, thanks for the feedback ! On Tue, Aug 31, 2021 at 10:17 AM Daniel P. Berrangé wrote: > > On Tue, Aug 31, 2021 at 08:02:39AM -0300, Leonardo Bras wrote: > > Call qio_channel_set_zerocopy(true) in the start of every multifd thread. > > > > Change the send_write() interface of

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-01 Thread Peter Xu
On Wed, Sep 01, 2021 at 04:44:30PM +0100, Daniel P. Berrangé wrote: > QEMU has mptcp support already: > > commit 8bd1078aebcec5eac196a83ef1a7e74be0ba67b7 > Author: Dr. David Alan Gilbert > Date: Wed Apr 21 12:28:34 2021 +0100 > > sockets: Support multipath TCP > > Multipath

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-01 Thread Daniel P . Berrangé
On Wed, Sep 01, 2021 at 11:35:33AM -0400, Peter Xu wrote: > On Wed, Sep 01, 2021 at 09:53:07AM +0100, Daniel P. Berrangé wrote: > > On Tue, Aug 31, 2021 at 04:29:09PM -0400, Peter Xu wrote: > > > On Tue, Aug 31, 2021 at 02:16:42PM +0100, Daniel P. Berrangé wrote: > > > > On Tue, Aug 31, 2021 at

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-01 Thread Peter Xu
On Wed, Sep 01, 2021 at 09:53:07AM +0100, Daniel P. Berrangé wrote: > On Tue, Aug 31, 2021 at 04:29:09PM -0400, Peter Xu wrote: > > On Tue, Aug 31, 2021 at 02:16:42PM +0100, Daniel P. Berrangé wrote: > > > On Tue, Aug 31, 2021 at 08:02:39AM -0300, Leonardo Bras wrote: > > > > Call

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-09-01 Thread Daniel P . Berrangé
On Tue, Aug 31, 2021 at 04:29:09PM -0400, Peter Xu wrote: > On Tue, Aug 31, 2021 at 02:16:42PM +0100, Daniel P. Berrangé wrote: > > On Tue, Aug 31, 2021 at 08:02:39AM -0300, Leonardo Bras wrote: > > > Call qio_channel_set_zerocopy(true) in the start of every multifd thread. > > > > > > Change the

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-08-31 Thread Peter Xu
On Tue, Aug 31, 2021 at 02:16:42PM +0100, Daniel P. Berrangé wrote: > On Tue, Aug 31, 2021 at 08:02:39AM -0300, Leonardo Bras wrote: > > Call qio_channel_set_zerocopy(true) in the start of every multifd thread. > > > > Change the send_write() interface of multifd, allowing it to pass down > >

Re: [PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-08-31 Thread Daniel P . Berrangé
On Tue, Aug 31, 2021 at 08:02:39AM -0300, Leonardo Bras wrote: > Call qio_channel_set_zerocopy(true) in the start of every multifd thread. > > Change the send_write() interface of multifd, allowing it to pass down > flags for qio_channel_write*(). > > Pass down MSG_ZEROCOPY flag for sending

[PATCH v1 3/3] migration: multifd: Enable zerocopy

2021-08-31 Thread Leonardo Bras
Call qio_channel_set_zerocopy(true) in the start of every multifd thread. Change the send_write() interface of multifd, allowing it to pass down flags for qio_channel_write*(). Pass down MSG_ZEROCOPY flag for sending memory pages, while keeping the other data being sent at the default copying