RE: [PATCH v12 net-next 1/1] hv_sock: introduce Hyper-V Sockets

From: Dexuan Cui
Date: Tue Jun 28 2016 - 11:29:56 EST


> From: David Miller [mailto:davem@xxxxxxxxxxxxx]
> Sent: Tuesday, June 28, 2016 21:45
> To: Dexuan Cui <decui@xxxxxxxxxxxxx>
> Cc: gregkh@xxxxxxxxxxxxxxxxxxx; netdev@xxxxxxxxxxxxxxx; linux-
> kernel@xxxxxxxxxxxxxxx; devel@xxxxxxxxxxxxxxxxxxxxxx; olaf@xxxxxxxxx;
> apw@xxxxxxxxxxxxx; jasowang@xxxxxxxxxx; vkuznets@xxxxxxxxxx;
> cavery@xxxxxxxxxx; KY Srinivasan <kys@xxxxxxxxxxxxx>; Haiyang Zhang
> <haiyangz@xxxxxxxxxxxxx>; joe@xxxxxxxxxxx
> Subject: Re: [PATCH v12 net-next 1/1] hv_sock: introduce Hyper-V Sockets
>
> From: Dexuan Cui <decui@xxxxxxxxxxxxx>
> Date: Tue, 28 Jun 2016 09:59:21 +0000
>
> > The idea here is: IMO the syscalls sys_read()/write() shoudn't return
> > -ENOMEM, so I have to make sure the buffer allocation succeeds?
>
> You have to fail if resources cannot be allocated.

OK, I'll try to fix this, probably by returning -EAGAIN or -ERESTARTSYS.

I'll report back ASAP.

Thanks,
-- Dexuan