lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Mon, 28 Nov 2022 11:59:59 +0800
From:   Herbert Xu <herbert@...dor.apana.org.au>
To:     Catalin Marinas <catalin.marinas@....com>
Cc:     Ard Biesheuvel <ardb@...nel.org>, Will Deacon <will@...nel.org>,
        Marc Zyngier <maz@...nel.org>, Arnd Bergmann <arnd@...db.de>,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        Andrew Morton <akpm@...ux-foundation.org>,
        Linus Torvalds <torvalds@...ux-foundation.org>,
        Linux Memory Management List <linux-mm@...ck.org>,
        Linux ARM <linux-arm-kernel@...ts.infradead.org>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        "David S. Miller" <davem@...emloft.net>,
        Linux Crypto Mailing List <linux-crypto@...r.kernel.org>
Subject: Re: [v2 PATCH 2/9] crypto: api - Add crypto_tfm_ctx_dma

On Fri, Nov 25, 2022 at 11:31:56AM +0000, Catalin Marinas wrote:
> 
> Is the CRYPTO_DMA_PADDING used anywhere? I couldn't find it in this
> series and I'd rather drop it, together with CRYPTO_DMA_ALIGN (see
> below).

Yes it's used by caam which needs it in a struct initialiser.

> We have a generic dma_get_cache_alignment() function which currently is
> either 1 or ARCH_DMA_MINALIGN, if the latter is defined. My plan is to
> make eventually make this dynamic based on the actual cache line size
> (on most arm64 systems it would be 64 rather than 128). So could you use
> this instead of defining a CRYPTO_DMA_ALIGN? The only difference would
> be that dma_get_cache_alignment() returns 1 rather than
> ARCH_KMALLOC_MINALIGN if ARCH_DMA_MINALIGN is not defined, but I don't
> think that's an issue.

I'm trying to make the driver patches as robotic as possible.

We could always improve upon this with driver-specific patches
to change the struct initialiser to a run-time assignment to
improve things further.

Thanks,
-- 
Email: Herbert Xu <herbert@...dor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ