From: Paolo Abeni <pabeni@redhat.com>
To: Willem de Bruijn <willemdebruijn.kernel@gmail.com>
Cc: Network Development <netdev@vger.kernel.org>,
"David S. Miller" <davem@davemloft.net>
Subject: Re: [PATCH net-next 5/5] ipv4: use indirect call wrappers for {tcp,udp}_{recv,send}msg()
Date: Tue, 02 Jul 2019 15:03:50 +0200 [thread overview]
Message-ID: <a2806dab7e472b5316da87318f1b8e48ff68cd4b.camel@redhat.com> (raw)
In-Reply-To: <CA+FuTSfHF_LRuZeW3ZiX5a662=fdAu9zmmpa67WpOkZqkt8Srw@mail.gmail.com>
On Mon, 2019-07-01 at 15:07 -0400, Willem de Bruijn wrote:
> On Mon, Jul 1, 2019 at 1:10 PM Paolo Abeni <pabeni@redhat.com> wrote:
> > This avoids an indirect call per syscall for common ipv4 transports
> >
> > Signed-off-by: Paolo Abeni <pabeni@redhat.com>
> > ---
> > net/ipv4/af_inet.c | 12 +++++++++---
> > 1 file changed, 9 insertions(+), 3 deletions(-)
> >
> > diff --git a/net/ipv4/af_inet.c b/net/ipv4/af_inet.c
> > index 8421e2f5bbb3..9a2f17d0c5f5 100644
> > --- a/net/ipv4/af_inet.c
> > +++ b/net/ipv4/af_inet.c
> > @@ -797,6 +797,8 @@ int inet_send_prepare(struct sock *sk)
> > }
> > EXPORT_SYMBOL_GPL(inet_send_prepare);
> >
> > +INDIRECT_CALLABLE_DECLARE(int udp_sendmsg(struct sock *, struct msghdr *,
> > + size_t));
>
> Small nit: this is already defined in include/net/udp.h, which is
> included. So like tcp_sendmsg, probably no need to declare.
Thank you for the review!
You are right, that declaration can be dropped.
>
> If defining inet6_sendmsg and inet6_recvmsg in include/net/ipv6.h,
> perhaps do the same for the other missing functions, instead of these
> indirect declarations at the callsite?
Uhm... since inet6_{send,recv}msg exists only for retpoline sake and
are not exported, I think is probably better move their declaration to
socket.c via INDIRECT_CALLABLE_DECLARE(), to that ICWs are all self-
contained.
Unless there are objections about spamming, I can repost the series
with the above changes.
Cheers,
Paolo
next prev parent reply other threads:[~2019-07-02 13:03 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-07-01 17:09 [PATCH net-next 0/5] net: use ICW for sk_proto->{send,recv}msg Paolo Abeni
2019-07-01 17:09 ` [PATCH net-next 1/5] inet: factor out inet_send_prepare() Paolo Abeni
2019-07-01 17:09 ` [PATCH net-next 2/5] ipv6: provide and use ipv6 specific version for {recv,send}msg Paolo Abeni
2019-07-01 17:09 ` [PATCH net-next 3/5] net: adjust socket level ICW to cope with ipv6 variant of {recv,send}msg Paolo Abeni
2019-07-01 17:09 ` [PATCH net-next 4/5] ipv6: use indirect call wrappers for {tcp,udpv6}_{recv,send}msg() Paolo Abeni
2019-07-01 17:09 ` [PATCH net-next 5/5] ipv4: use indirect call wrappers for {tcp,udp}_{recv,send}msg() Paolo Abeni
2019-07-01 19:07 ` Willem de Bruijn
2019-07-02 13:03 ` Paolo Abeni [this message]
2019-07-02 14:38 ` Willem de Bruijn
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=a2806dab7e472b5316da87318f1b8e48ff68cd4b.camel@redhat.com \
--to=pabeni@redhat.com \
--cc=davem@davemloft.net \
--cc=netdev@vger.kernel.org \
--cc=willemdebruijn.kernel@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).