netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Joe Perches <joe@perches.com>
To: Eric Dumazet <dada1@cosmosbay.com>
Cc: David Miller <davem@davemloft.net>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>
Subject: Re: [XFRM]: constify 'struct xfrm_type'
Date: Thu, 24 Jan 2008 10:37:38 -0800	[thread overview]
Message-ID: <1201199858.16268.46.camel@localhost> (raw)
In-Reply-To: <4798D7B9.5090406@cosmosbay.com>

On Thu, 2008-01-24 at 19:23 +0100, Eric Dumazet wrote:
> Having const data is nice because moving them from .data to .rodata,
> but what would be practical gains to use a const pointer ???

const data is good, using pointers to const data is good.
using const pointers to const data is good.
using const pointers to data not specified as const is not so good.

Here's what you are doing now.

+static void xfrm_put_type(const struct xfrm_type *type)
[...]
+	const struct xfrm_type *type;

cheers, Joe


  reply	other threads:[~2008-01-24 18:38 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-01-24 11:26 [XFRM]: constify 'struct xfrm_type' Eric Dumazet
2008-01-24 17:17 ` Joe Perches
2008-01-24 18:23   ` Eric Dumazet
2008-01-24 18:37     ` Joe Perches [this message]
2008-01-24 19:24       ` Eric Dumazet
2008-01-24 19:37         ` Joe Perches
2008-01-31  3:12 ` David Miller

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=1201199858.16268.46.camel@localhost \
    --to=joe@perches.com \
    --cc=dada1@cosmosbay.com \
    --cc=davem@davemloft.net \
    --cc=netdev@vger.kernel.org \
    /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).