[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CO2PR03MB2182D011056AA151CCEF4EFFBF0E0@CO2PR03MB2182.namprd03.prod.outlook.com>
Date: Tue, 26 Jul 2016 03:09:16 +0000
From: Dexuan Cui <decui@...rosoft.com>
To: David Miller <davem@...emloft.net>
CC: "gregkh@...uxfoundation.org" <gregkh@...uxfoundation.org>,
"netdev@...r.kernel.org" <netdev@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"devel@...uxdriverproject.org" <devel@...uxdriverproject.org>,
"olaf@...fle.de" <olaf@...fle.de>,
"apw@...onical.com" <apw@...onical.com>,
"jasowang@...hat.com" <jasowang@...hat.com>,
"vkuznets@...hat.com" <vkuznets@...hat.com>,
"cavery@...hat.com" <cavery@...hat.com>,
KY Srinivasan <kys@...rosoft.com>,
"joe@...ches.com" <joe@...ches.com>,
"rolf.neugebauer@...ker.com" <rolf.neugebauer@...ker.com>,
"mkubecek@...e.cz" <mkubecek@...e.cz>,
Haiyang Zhang <haiyangz@...rosoft.com>,
"dave.scott@...ker.com" <dave.scott@...ker.com>
Subject: RE: [PATCH v18 net-next 1/1] hv_sock: introduce Hyper-V Sockets
> From: David Miller [mailto:davem@...emloft.net]
>
> From: Dexuan Cui <decui@...rosoft.com>
> Date: Sat, 23 Jul 2016 01:35:51 +0000
>
> > +static struct sock *hvsock_create(struct net *net, struct socket *sock,
> > + gfp_t priority, unsigned short type)
> > +{
> > + struct hvsock_sock *hvsk;
> > + struct sock *sk;
> > +
> > + sk = sk_alloc(net, AF_HYPERV, priority, &hvsock_proto, 0);
> > + if (!sk)
> > + return NULL;
> ...
> > + /* Looks stream-based socket doesn't need this. */
> > + sk->sk_backlog_rcv = NULL;
> > +
> > + sk->sk_state = 0;
> > + sock_reset_flag(sk, SOCK_DONE);
>
> All of these are unnecessary initializations, since sk_alloc() zeroes
> out the 'sk' object for you.
Hi David,
Thanks for the comment! I'll remove the 3 lines.
May I know if you have more comments?
BTW, during the past month, at least 7 other people also reviewed
the patch and gave me quite a few good comments, which have
been addressed. Though only one of them gave the Reviewed-by
line for now, I guess I would get more if I ping them to have a look
at the latest version of the patch, i.e., v19 -- I'm going to post it
with the aforementioned 3 lines removed and if you've more
comments, I'm ready to address them too. :-)
Thanks,
-- Dexuan
Powered by blists - more mailing lists