Re: [PATCH v2] splice: sendfile() at once fails for big files

2015-05-06 Thread Jens Axboe
On 05/06/2015 08:40 AM, Jens Axboe wrote: On 05/06/2015 08:38 AM, leroy christophe wrote: Le 06/05/2015 16:23, Jens Axboe a écrit : On 05/05/2015 09:41 PM, Linus Torvalds wrote: Jens, ping? The test results should make this a no-brainer, but I hate how random these flag ops. Missed the

Re: [PATCH v2] splice: sendfile() at once fails for big files

2015-05-06 Thread Jens Axboe
On 05/06/2015 08:38 AM, leroy christophe wrote: Le 06/05/2015 16:23, Jens Axboe a écrit : On 05/05/2015 09:41 PM, Linus Torvalds wrote: Jens, ping? The test results should make this a no-brainer, but I hate how random these flag ops. Missed the original, apparently. I too am confused how

Re: [PATCH v2] splice: sendfile() at once fails for big files

2015-05-06 Thread leroy christophe
Le 06/05/2015 16:23, Jens Axboe a écrit : On 05/05/2015 09:41 PM, Linus Torvalds wrote: Jens, ping? The test results should make this a no-brainer, but I hate how random these flag ops. Missed the original, apparently. I too am confused how this is a correctness fix and not just an

Re: [PATCH v2] splice: sendfile() at once fails for big files

2015-05-06 Thread Jens Axboe
On 05/05/2015 09:41 PM, Linus Torvalds wrote: Jens, ping? The test results should make this a no-brainer, but I hate how random these flag ops. Missed the original, apparently. I too am confused how this is a correctness fix and not just an optimization. + if (read_len < len)

Re: [PATCH v2] splice: sendfile() at once fails for big files

2015-05-06 Thread leroy christophe
Le 06/05/2015 16:23, Jens Axboe a écrit : On 05/05/2015 09:41 PM, Linus Torvalds wrote: Jens, ping? The test results should make this a no-brainer, but I hate how random these flag ops. Missed the original, apparently. I too am confused how this is a correctness fix and not just an

Re: [PATCH v2] splice: sendfile() at once fails for big files

2015-05-06 Thread Jens Axboe
On 05/05/2015 09:41 PM, Linus Torvalds wrote: Jens, ping? The test results should make this a no-brainer, but I hate how random these flag ops. Missed the original, apparently. I too am confused how this is a correctness fix and not just an optimization. + if (read_len len)

Re: [PATCH v2] splice: sendfile() at once fails for big files

2015-05-06 Thread Jens Axboe
On 05/06/2015 08:38 AM, leroy christophe wrote: Le 06/05/2015 16:23, Jens Axboe a écrit : On 05/05/2015 09:41 PM, Linus Torvalds wrote: Jens, ping? The test results should make this a no-brainer, but I hate how random these flag ops. Missed the original, apparently. I too am confused how

Re: [PATCH v2] splice: sendfile() at once fails for big files

2015-05-06 Thread Jens Axboe
On 05/06/2015 08:40 AM, Jens Axboe wrote: On 05/06/2015 08:38 AM, leroy christophe wrote: Le 06/05/2015 16:23, Jens Axboe a écrit : On 05/05/2015 09:41 PM, Linus Torvalds wrote: Jens, ping? The test results should make this a no-brainer, but I hate how random these flag ops. Missed the

Re: [PATCH v2] splice: sendfile() at once fails for big files

2015-05-05 Thread Christoph Hellwig
On Tue, May 05, 2015 at 08:41:05PM -0700, Linus Torvalds wrote: > Jens, ping? > > The test results should make this a no-brainer, but I hate how random > these flag ops. Not Jens here, but: (a) the patch looks correct, we do want to set the more flag if there is more data (b) I think

Re: [PATCH v2] splice: sendfile() at once fails for big files

2015-05-05 Thread Linus Torvalds
Jens, ping? The test results should make this a no-brainer, but I hate how random these flag ops. Linus On Mon, Apr 27, 2015 at 12:01 AM, Herbert Xu wrote: > Christophe Leroy wrote: >> Using sendfile with below small program to get MD5 sums of some files, >> it appear

Re: [PATCH v2] splice: sendfile() at once fails for big files

2015-05-05 Thread Linus Torvalds
Jens, ping? The test results should make this a no-brainer, but I hate how random these flag ops. Linus On Mon, Apr 27, 2015 at 12:01 AM, Herbert Xu herb...@gondor.apana.org.au wrote: Christophe Leroy christophe.le...@c-s.fr wrote: Using sendfile with below small

Re: [PATCH v2] splice: sendfile() at once fails for big files

2015-05-05 Thread Christoph Hellwig
On Tue, May 05, 2015 at 08:41:05PM -0700, Linus Torvalds wrote: Jens, ping? The test results should make this a no-brainer, but I hate how random these flag ops. Not Jens here, but: (a) the patch looks correct, we do want to set the more flag if there is more data (b) I think the

Re: [PATCH v2] splice: sendfile() at once fails for big files

2015-04-27 Thread Herbert Xu
Christophe Leroy wrote: > Using sendfile with below small program to get MD5 sums of some files, > it appear that big files (over 64kbytes with 4k pages system) get a > wrong MD5 sum while small files get the correct sum. > This program uses sendfile() to send a file to an AF_ALG socket > for

Re: [PATCH v2] splice: sendfile() at once fails for big files

2015-04-27 Thread Herbert Xu
Christophe Leroy christophe.le...@c-s.fr wrote: Using sendfile with below small program to get MD5 sums of some files, it appear that big files (over 64kbytes with 4k pages system) get a wrong MD5 sum while small files get the correct sum. This program uses sendfile() to send a file to an

[PATCH v2] splice: sendfile() at once fails for big files

2015-04-23 Thread Christophe Leroy
Using sendfile with below small program to get MD5 sums of some files, it appear that big files (over 64kbytes with 4k pages system) get a wrong MD5 sum while small files get the correct sum. This program uses sendfile() to send a file to an AF_ALG socket for hashing. /* md5sum2.c */ #include

[PATCH v2] splice: sendfile() at once fails for big files

2015-04-23 Thread Christophe Leroy
Using sendfile with below small program to get MD5 sums of some files, it appear that big files (over 64kbytes with 4k pages system) get a wrong MD5 sum while small files get the correct sum. This program uses sendfile() to send a file to an AF_ALG socket for hashing. /* md5sum2.c */ #include