All of lore.kernel.org
 help / color / mirror / Atom feed
From: Eric Biggers <ebiggers@kernel.org>
To: Borislav Petkov <bp@alien8.de>
Cc: linux-kernel@vger.kernel.org, linux-crypto@vger.kernel.org,
	x86@kernel.org, linux-block@vger.kernel.org,
	Ard Biesheuvel <ardb@kernel.org>, Keith Busch <kbusch@kernel.org>,
	Kent Overstreet <kent.overstreet@linux.dev>,
	"Martin K . Petersen" <martin.petersen@oracle.com>,
	Ingo Molnar <mingo@kernel.org>
Subject: Re: [PATCH v4 1/6] x86: move ZMM exclusion list into CPU feature flag
Date: Mon, 10 Feb 2025 13:37:05 -0800	[thread overview]
Message-ID: <20250210213705.GD348261@sol.localdomain> (raw)
In-Reply-To: <20250210211710.GCZ6ps1pNklAXyqD0p@fat_crate.local>

On Mon, Feb 10, 2025 at 10:17:10PM +0100, Borislav Petkov wrote:
> On Mon, Feb 10, 2025 at 01:01:03PM -0800, Eric Biggers wrote:
> > I see that cpu_feature_enabled() uses code patching while boot_cpu_has() does
> > not.  All these checks occur once at module load time, though, so code patching
> > wouldn't be beneficial.
> 
> We want to convert all code to use a single interface for testing CPU features
> - cpu_feature_enabled() - and the implementation shouldn't be important to
> users - it should just work.
> 
> Since you're adding new code, you might as well use the proper interface. As
> to converting crypto/ and the rest of the tree, that should happen at some
> point... eventually...

Well, it's new code in a function that already has a bunch of boot_cpu_has()
checks.  I don't really like leaving around random inconsistencies.  If there is
a new way to do it, we should just update it everywhere.

I'll also note that boot_cpu_has() is missing a comment that says it is
deprecated (if it really is).

- Eric

  reply	other threads:[~2025-02-10 21:37 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-10 17:45 [PATCH v4 0/6] x86 CRC optimizations Eric Biggers
2025-02-10 17:45 ` [PATCH v4 1/6] x86: move ZMM exclusion list into CPU feature flag Eric Biggers
2025-02-10 20:40   ` Borislav Petkov
2025-02-10 21:01     ` Eric Biggers
2025-02-10 21:17       ` Borislav Petkov
2025-02-10 21:37         ` Eric Biggers [this message]
2025-02-10 21:49           ` Borislav Petkov
2025-02-10 17:45 ` [PATCH v4 2/6] scripts/gen-crc-consts: add gen-crc-consts.py Eric Biggers
2025-02-10 17:45 ` [PATCH v4 3/6] x86/crc: add "template" for [V]PCLMULQDQ based CRC functions Eric Biggers
2025-02-10 17:45 ` [PATCH v4 4/6] x86/crc32: implement crc32_le using new template Eric Biggers
2025-02-10 17:45 ` [PATCH v4 5/6] x86/crc-t10dif: implement crc_t10dif " Eric Biggers
2025-02-10 17:45 ` [PATCH v4 6/6] x86/crc64: implement crc64_be and crc64_nvme " Eric Biggers
2025-02-10 18:01 ` [PATCH v4 0/6] x86 CRC optimizations Eric Biggers

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=20250210213705.GD348261@sol.localdomain \
    --to=ebiggers@kernel.org \
    --cc=ardb@kernel.org \
    --cc=bp@alien8.de \
    --cc=kbusch@kernel.org \
    --cc=kent.overstreet@linux.dev \
    --cc=linux-block@vger.kernel.org \
    --cc=linux-crypto@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=martin.petersen@oracle.com \
    --cc=mingo@kernel.org \
    --cc=x86@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.