]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
lib/crypto: mips: Move arch/mips/lib/crypto/ into lib/crypto/
authorEric Biggers <ebiggers@kernel.org>
Thu, 19 Jun 2025 19:19:02 +0000 (12:19 -0700)
committerEric Biggers <ebiggers@kernel.org>
Mon, 30 Jun 2025 16:26:20 +0000 (09:26 -0700)
Move the contents of arch/mips/lib/crypto/ into lib/crypto/mips/.

The new code organization makes a lot more sense for how this code
actually works and is developed.  In particular, it makes it possible to
build each algorithm as a single module, with better inlining and dead
code elimination.  For a more detailed explanation, see the patchset
which did this for the CRC library code:
https://lore.kernel.org/r/20250607200454.73587-1-ebiggers@kernel.org/.
Also see the patchset which did this for SHA-512:
https://lore.kernel.org/linux-crypto/20250616014019.415791-1-ebiggers@kernel.org/

This is just a preparatory commit, which does the move to get the files
into their new location but keeps them building the same way as before.
Later commits will make the actual improvements to the way the
arch-optimized code is integrated for each algorithm.

Add a gitignore entry for the removed directory arch/mips/lib/crypto/ so
that people don't accidentally commit leftover generated files.

Acked-by: Ard Biesheuvel <ardb@kernel.org>
Reviewed-by: Martin K. Petersen <martin.petersen@oracle.com>
Reviewed-by: Sohil Mehta <sohil.mehta@intel.com>
Link: https://lore.kernel.org/r/20250619191908.134235-4-ebiggers@kernel.org
Signed-off-by: Eric Biggers <ebiggers@kernel.org>
arch/mips/lib/.gitignore [new file with mode: 0644]
arch/mips/lib/Makefile
lib/crypto/Kconfig
lib/crypto/Makefile
lib/crypto/mips/.gitignore [moved from arch/mips/lib/crypto/.gitignore with 100% similarity]
lib/crypto/mips/Kconfig [moved from arch/mips/lib/crypto/Kconfig with 100% similarity]
lib/crypto/mips/Makefile [moved from arch/mips/lib/crypto/Makefile with 100% similarity]
lib/crypto/mips/chacha-core.S [moved from arch/mips/lib/crypto/chacha-core.S with 100% similarity]
lib/crypto/mips/chacha-glue.c [moved from arch/mips/lib/crypto/chacha-glue.c with 100% similarity]
lib/crypto/mips/poly1305-glue.c [moved from arch/mips/lib/crypto/poly1305-glue.c with 100% similarity]
lib/crypto/mips/poly1305-mips.pl [moved from arch/mips/lib/crypto/poly1305-mips.pl with 100% similarity]

diff --git a/arch/mips/lib/.gitignore b/arch/mips/lib/.gitignore
new file mode 100644 (file)
index 0000000..647d7a9
--- /dev/null
@@ -0,0 +1,4 @@
+# SPDX-License-Identifier: GPL-2.0-only
+
+# This now-removed directory used to contain generated files.
+/crypto/
index 9d75845ef78e186f59495eb7792157ff8ca24aad..9c024e6d5e54c057c3dd196f7a6f7fc6eb8feda9 100644 (file)
@@ -3,8 +3,6 @@
 # Makefile for MIPS-specific library files..
 #
 
-obj-y  += crypto/
-
 lib-y  += bitops.o csum_partial.o delay.o memcpy.o memset.o \
           mips-atomic.o strncpy_user.o \
           strnlen_user.o uncached.o
index fdeb91bf003285f56a8c16d6c33cde2dfdf71db0..43c44316fbbdce966221060dc66be950f9c2d21e 100644 (file)
@@ -196,7 +196,7 @@ if ARM64
 source "lib/crypto/arm64/Kconfig"
 endif
 if MIPS
-source "arch/mips/lib/crypto/Kconfig"
+source "lib/crypto/mips/Kconfig"
 endif
 if PPC
 source "arch/powerpc/lib/crypto/Kconfig"
index 19e9880c5d5f042f871c97197609c28a22edc7fe..f54d2f3edc40eab0aa259fe16a57fae32b62d994 100644 (file)
@@ -109,3 +109,4 @@ libsm3-y                                    := sm3.o
 
 obj-$(CONFIG_ARM) += arm/
 obj-$(CONFIG_ARM64) += arm64/
+obj-$(CONFIG_MIPS) += mips/