All of lore.kernel.org
 help / color / mirror / Atom feed
From: Steffen Klassert <steffen.klassert@secunet.com>
To: David Miller <davem@davemloft.net>
Cc: herbert@gondor.apana.org.au, linux-crypto@vger.kernel.org,
	netdev@vger.kernel.org
Subject: Re: [RFC] [PATCH 2/7] crypto: authenc - convert to ahash
Date: Mon, 20 Jul 2009 08:26:43 +0200	[thread overview]
Message-ID: <20090720062643.GA20288@secunet.com> (raw)
In-Reply-To: <20090717.100334.160030992.davem@davemloft.net>

On Fri, Jul 17, 2009 at 10:03:34AM -0700, David Miller wrote:
> From: Steffen Klassert <steffen.klassert@secunet.com>
> Date: Thu, 16 Jul 2009 13:17:47 +0200
> 
> > +	/* 
> > +	 * head must be a scatterlist with two entries.
> > +	 * We remove a potentially set termination bit
> > +	 * on the first enty.
> > +	 */
> > +	head->page_link &= ~0x02;
> > +
> >  	if (chain) {
> >  		head->length += sg->length;
> 
> Isn't there some interface to do this, rather than revealing the
> implementation details of how the scatter list marking works?

We have sg_mark_end() which sets the termination bit on a sg list entry,
but we don't have an interface to remove the termination bit from a sg
list entry. 

> 
> If not, such an interface should be created and used here.  Otherwise
> any change in that implementation will break this code.

A grep over the kernel tree showed that just the block and the
crypto-layer doing this to chain sg lists. So we could create
sg_unmark_end() and use it there. If desired, I would do it.

  reply	other threads:[~2009-07-20  6:24 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-07-16 11:15 [RFC] [PATCH 0/7] IPsec: convert to ahash Steffen Klassert
2009-07-16 11:16 ` [RFC] [PATCH 1/7] esp: Add an additional scatterlist entry for the assoc data Steffen Klassert
2009-07-16 11:17 ` [RFC] [PATCH 2/7] crypto: authenc - convert to ahash Steffen Klassert
2009-07-17 17:03   ` David Miller
2009-07-20  6:26     ` Steffen Klassert [this message]
2009-07-20  6:55       ` Herbert Xu
2009-07-20  7:57         ` Steffen Klassert
2009-07-20  8:21           ` Herbert Xu
2009-07-20  8:36             ` Steffen Klassert
2009-07-20  8:50               ` Herbert Xu
2009-07-16 11:18 ` [RFC] [PATCH 3/7] ah: Add struct crypto_ahash to ah_data Steffen Klassert
2009-07-16 11:19 ` [RFC] [PATCH 4/7] ah4: convert to ahash Steffen Klassert
2009-07-21  6:53   ` Herbert Xu
2009-07-16 11:19 ` [RFC] [PATCH 5/7] ah6: " Steffen Klassert
2009-07-16 11:20 ` [RFC] [PATCH 6/7] ah: Remove obsolete code Steffen Klassert
2009-07-16 11:21 ` [RFC] [PATCH 7/7] xfrm: remove skb_icv_walk Steffen Klassert
2009-07-16 15:46 ` [RFC] [PATCH 0/7] IPsec: convert to ahash Herbert Xu
2009-07-17  6:11   ` Steffen Klassert
2009-07-17  7:42   ` Steffen Klassert

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=20090720062643.GA20288@secunet.com \
    --to=steffen.klassert@secunet.com \
    --cc=davem@davemloft.net \
    --cc=herbert@gondor.apana.org.au \
    --cc=linux-crypto@vger.kernel.org \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.