Linux NFS development
 help / color / mirror / Atom feed
From: Greg Banks <gnb@sgi.com>
To: Neil Brown <neilb@suse.de>
Cc: Thomas Talpey <Thomas.Talpey@netapp.com>,
	Linux NFS Mailing List <nfs@lists.sourceforge.net>,
	Peter Leckie <pleckie@melbourne.sgi.com>
Subject: Re: [RFC,PATCH 2/14] knfsd: delete per transport
Date: Fri, 18 May 2007 15:56:31 +1000	[thread overview]
Message-ID: <20070518055631.GE5104@sgi.com> (raw)
In-Reply-To: <17996.12924.211214.309207@notabene.brown>

On Thu, May 17, 2007 at 08:46:20PM +1000, Neil Brown wrote:
> On Thursday May 17, gnb@sgi.com wrote:
> >  
> > @@ -886,7 +883,9 @@ svc_udp_sendto(struct svc_rqst *rqstp)
> >  static const struct svc_sock_ops svc_udp_ops = {
> >  	.sko_name = "udp",
> >  	.sko_recvfrom = svc_udp_recvfrom,
> > -	.sko_sendto = svc_udp_sendto
> > +	.sko_sendto = svc_udp_sendto,
> > +	.sko_detach = svc_tcpip_detach,
> > +	.sko_free = svc_tcpip_free
> >  };
> 
> Tiny nit:
>   Despite widespread usage, I don't see udp as being a part of
>   tcp/ip.  So having a function names *tcpip* in the svc_udp_ops looks
>   just wrong.
>   Maybe svc_ipsock_detach, svc_ipsock_free ??

I struggled with this.

The obvious thing would have been to use the word "sock" because what
these functions have in common is that they deal with sockets rather
than TCP/IP or even IP.  None of "tcpip" or "ipsock" accurately
reflect what these functions do.

But unfortunately our abstract structure is called "svc_sock".  So
doing the obvious would result in enormous confusion: is svc_sock_foo()
a generic transport function or a specific sockets-based one?

I considered renaming the existing svc_sock to svc_xprt, which
would be another horribly unpronouncable identifier(*) but would at
least be appropriately abstract and consistent with the client.

Then the naming would all be obvious and correct: svc_xprt_foo()
is a generic transport function, svc_sock_foo() is a more specific
socket-based transport function used as common code between TCP
and UDP transports.  Yay.

But it would be a much larger patch so I shied away.

I'm happy to do the naming any way you want, just let me know.

 * what did the Sun people who originally coined RPC terminology
   have against vowels, I wonder?

Greg.
-- 
Greg Banks, R&D Software Engineer, SGI Australian Software Group.
Apparently, I'm Bedevere.  Which MPHG character are you?
I don't speak for SGI.

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
NFS maillist  -  NFS@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nfs

  reply	other threads:[~2007-05-18  5:56 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-05-16 19:19 [RFC,PATCH 2/14] knfsd: delete per transport Greg Banks
2007-05-16 20:51 ` J. Bruce Fields
2007-05-17  6:38   ` Greg Banks
2007-05-17 10:46 ` Neil Brown
2007-05-18  5:56   ` Greg Banks [this message]
2007-05-18  6:44     ` Neil Brown
2007-05-18  7:55       ` Greg Banks

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=20070518055631.GE5104@sgi.com \
    --to=gnb@sgi.com \
    --cc=Thomas.Talpey@netapp.com \
    --cc=neilb@suse.de \
    --cc=nfs@lists.sourceforge.net \
    --cc=pleckie@melbourne.sgi.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