Re: [PATCH net] tun: handle copy failure in tun_put_user()

2014-01-20 Thread Michael S. Tsirkin
On Mon, Jan 20, 2014 at 05:32:02PM +0800, Jason Wang wrote: > On 01/20/2014 04:43 PM, Michael S. Tsirkin wrote: > > On Sun, Jan 19, 2014 at 07:48:56PM -0800, David Miller wrote: > >> From: Jason Wang > >> Date: Mon, 20 Jan 2014 11:16:48 +0800 > >> > >>> This patch return the error code of copy hel

Re: [PATCH net] tun: handle copy failure in tun_put_user()

2014-01-20 Thread Jason Wang
On 01/20/2014 04:43 PM, Michael S. Tsirkin wrote: > On Sun, Jan 19, 2014 at 07:48:56PM -0800, David Miller wrote: >> From: Jason Wang >> Date: Mon, 20 Jan 2014 11:16:48 +0800 >> >>> This patch return the error code of copy helpers in tun_put_user() instead >>> of >>> ignoring them. >>> >>> Cc: Mi

Re: [PATCH net] tun: handle copy failure in tun_put_user()

2014-01-20 Thread Michael S. Tsirkin
On Sun, Jan 19, 2014 at 07:48:56PM -0800, David Miller wrote: > From: Jason Wang > Date: Mon, 20 Jan 2014 11:16:48 +0800 > > > This patch return the error code of copy helpers in tun_put_user() instead > > of > > ignoring them. > > > > Cc: Michael S. Tsirkin > > Signed-off-by: Jason Wang I'm

Re: [PATCH net] tun: handle copy failure in tun_put_user()

2014-01-19 Thread Jason Wang
On 01/20/2014 11:48 AM, David Miller wrote: > From: Jason Wang > Date: Mon, 20 Jan 2014 11:16:48 +0800 > >> This patch return the error code of copy helpers in tun_put_user() instead of >> ignoring them. >> >> Cc: Michael S. Tsirkin >> Signed-off-by: Jason Wang > If you perform some of the copy

Re: [PATCH net] tun: handle copy failure in tun_put_user()

2014-01-19 Thread David Miller
From: Jason Wang Date: Mon, 20 Jan 2014 11:16:48 +0800 > This patch return the error code of copy helpers in tun_put_user() instead of > ignoring them. > > Cc: Michael S. Tsirkin > Signed-off-by: Jason Wang If you perform some of the copy successfully, you have to report that length rather th

[PATCH net] tun: handle copy failure in tun_put_user()

2014-01-19 Thread Jason Wang
This patch return the error code of copy helpers in tun_put_user() instead of ignoring them. Cc: Michael S. Tsirkin Signed-off-by: Jason Wang --- drivers/net/tun.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/net/tun.c b/drivers/net/tun.c index ecec802..4e