mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: David Howells <dhowells@redhat.com>
To: Ignat Korchagin <ignat@cloudflare.com>
Cc: dhowells@redhat.com, Lukas Wunner <lukas@wunner.de>,
	Jarkko Sakkinen <jarkko@kernel.org>,
	Herbert Xu <herbert@gondor.apana.org.au>,
	Eric Biggers <ebiggers@kernel.org>,
	Luis Chamberlain <mcgrof@kernel.org>,
	Petr Pavlu <petr.pavlu@suse.com>,
	Daniel Gomez <da.gomez@kernel.org>,
	Sami Tolvanen <samitolvanen@google.com>,
	"Jason A . Donenfeld" <Jason@zx2c4.com>,
	Ard Biesheuvel <ardb@kernel.org>,
	Stephan Mueller <smueller@chronox.de>,
	linux-crypto@vger.kernel.org, keyrings@vger.kernel.org,
	linux-modules@vger.kernel.org, linux-kernel@vger.kernel.org,
	Tadeusz Struk <tadeusz.struk@intel.com>,
	"David S. Miller" <davem@davemloft.net>
Subject: Re: [PATCH v11 6/8] crypto: Add RSASSA-PSS support
Date: Thu, 08 Jan 2026 11:29:30 +0000	[thread overview]
Message-ID: <2708430.1767871770@warthog.procyon.org.uk> (raw)
In-Reply-To: <CALrw=nHhs61yqkLkK9F4UGU_ujnniMzrkbhjRDc+Aa69XTFTvg@mail.gmail.com>

Ignat Korchagin <ignat@cloudflare.com> wrote:

> A lot of pointers and arithmetic here. Wouldn't it be easier to do
> something like in [1]?

Fair point.

> > +DEFINE_FREE(crypto_free_shash, struct crypto_shash*,
> > +           if (!IS_ERR_OR_NULL(_T)) { crypto_free_shash(_T); });
> 
> Is this useful enough to go into some commonly used header for shash?

Maybe - I guess there's no actual cost to doing so as it generates an inline
function.

> > +       struct crypto_shash *hash_tfm __free(crypto_free_shash) = NULL;
> > +       struct shash_desc *Hash __free(kfree) = NULL;
> 
> So even though x509/pkcs7 code now has a counterexample (partially due
> to my fault) seems the consensus [2] is to declare and initialise the
> variable with the __free attribute at the same time meaning it is OK
> to declare the variables later and not follow the "declaration at the
> top" rule.

Ok, I'll move the decls.

David


  parent reply	other threads:[~2026-01-08 11:29 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-01-05 15:21 [PATCH v11 0/8] x509, pkcs7, crypto: Add ML-DSA and RSASSA-PSS signing David Howells
2026-01-05 15:21 ` [PATCH v11 1/8] crypto: Add ML-DSA crypto_sig support David Howells
2026-01-05 15:21 ` [PATCH v11 2/8] pkcs7: Allow the signing algo to calculate the digest itself David Howells
2026-01-05 20:19   ` Ignat Korchagin
2026-01-07 13:53   ` David Howells
2026-01-07 13:59     ` Ignat Korchagin
2026-01-08 12:59   ` David Howells
2026-01-05 15:21 ` [PATCH v11 3/8] pkcs7, x509: Add ML-DSA support David Howells
2026-01-06  8:02   ` Eric Biggers
2026-01-06  8:22     ` Eric Biggers
2026-01-06  9:37   ` David Howells
2026-01-08 14:38   ` David Howells
2026-01-05 15:21 ` [PATCH v11 4/8] modsign: Enable ML-DSA module signing David Howells
2026-01-06  8:10   ` Eric Biggers
2026-01-05 15:21 ` [PATCH v11 5/8] crypto: Add supplementary info param to asymmetric key signature verification David Howells
2026-01-07 14:23   ` Ignat Korchagin
2026-01-05 15:21 ` [PATCH v11 6/8] crypto: Add RSASSA-PSS support David Howells
2026-01-07 16:24   ` Ignat Korchagin
2026-01-08 11:29   ` David Howells [this message]
2026-01-08 13:15   ` Jarkko Sakkinen
2026-01-08 14:39   ` David Howells
2026-01-05 15:21 ` [PATCH v11 7/8] pkcs7, x509: " David Howells
2026-01-07 16:36   ` Ignat Korchagin
2026-01-08 11:53   ` David Howells
2026-01-05 15:21 ` [PATCH v11 8/8] modsign: Enable RSASSA-PSS module signing David Howells
2026-01-07 16:38   ` Ignat Korchagin

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=2708430.1767871770@warthog.procyon.org.uk \
    --to=dhowells@redhat.com \
    --cc=Jason@zx2c4.com \
    --cc=ardb@kernel.org \
    --cc=da.gomez@kernel.org \
    --cc=davem@davemloft.net \
    --cc=ebiggers@kernel.org \
    --cc=herbert@gondor.apana.org.au \
    --cc=ignat@cloudflare.com \
    --cc=jarkko@kernel.org \
    --cc=keyrings@vger.kernel.org \
    --cc=linux-crypto@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-modules@vger.kernel.org \
    --cc=lukas@wunner.de \
    --cc=mcgrof@kernel.org \
    --cc=petr.pavlu@suse.com \
    --cc=samitolvanen@google.com \
    --cc=smueller@chronox.de \
    --cc=tadeusz.struk@intel.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

all inboxes | Powered by JetHome®