linux-stable/arch/s390/crypto
Peter Zijlstra cdd30ebb1b module: Convert symbol namespace to string literal
Clean up the existing export namespace code along the same lines of
commit 33def8498f ("treewide: Convert macro and uses of __section(foo)
to __section("foo")") and for the same reason, it is not desired for the
namespace argument to be a macro expansion itself.

Scripted using

  git grep -l -e MODULE_IMPORT_NS -e EXPORT_SYMBOL_NS | while read file;
  do
    awk -i inplace '
      /^#define EXPORT_SYMBOL_NS/ {
        gsub(/__stringify\(ns\)/, "ns");
        print;
        next;
      }
      /^#define MODULE_IMPORT_NS/ {
        gsub(/__stringify\(ns\)/, "ns");
        print;
        next;
      }
      /MODULE_IMPORT_NS/ {
        $0 = gensub(/MODULE_IMPORT_NS\(([^)]*)\)/, "MODULE_IMPORT_NS(\"\\1\")", "g");
      }
      /EXPORT_SYMBOL_NS/ {
        if ($0 ~ /(EXPORT_SYMBOL_NS[^(]*)\(([^,]+),/) {
  	if ($0 !~ /(EXPORT_SYMBOL_NS[^(]*)\(([^,]+), ([^)]+)\)/ &&
  	    $0 !~ /(EXPORT_SYMBOL_NS[^(]*)\(\)/ &&
  	    $0 !~ /^my/) {
  	  getline line;
  	  gsub(/[[:space:]]*\\$/, "");
  	  gsub(/[[:space:]]/, "", line);
  	  $0 = $0 " " line;
  	}

  	$0 = gensub(/(EXPORT_SYMBOL_NS[^(]*)\(([^,]+), ([^)]+)\)/,
  		    "\\1(\\2, \"\\3\")", "g");
        }
      }
      { print }' $file;
  done

Requested-by: Masahiro Yamada <masahiroy@kernel.org>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://mail.google.com/mail/u/2/#inbox/FMfcgzQXKWgMmjdFwwdsfgxzKpVHWPlc
Acked-by: Greg KH <gregkh@linuxfoundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2024-12-02 11:34:44 -08:00
..
aes_s390.c module: Convert symbol namespace to string literal 2024-12-02 11:34:44 -08:00
arch_random.c s390/archrandom: add missing header include 2023-01-10 14:39:08 +01:00
chacha-glue.c s390/fpu: decrease stack usage for some cases 2024-02-16 14:30:16 +01:00
chacha-s390.h s390/crypto: add SIMD implementation for ChaCha20 2021-12-06 14:42:24 +01:00
chacha-s390.S s390/fpu: move, rename, and merge header files 2024-02-16 14:30:14 +01:00
crc32-vx.c s390/crc32: Add missing MODULE_DESCRIPTION() macro 2024-06-28 14:52:30 +02:00
crc32-vx.h s390/crc32le: convert to C 2024-02-16 14:30:18 +01:00
crc32be-vx.c s390/crc32be: convert to C 2024-02-16 14:30:18 +01:00
crc32le-vx.c s390/crc32le: convert to C 2024-02-16 14:30:18 +01:00
des_s390.c s390/cpufeature: rework to allow more than only hwcap bits 2022-07-19 16:18:49 +02:00
ghash_s390.c s390/cpufeature: rework to allow more than only hwcap bits 2022-07-19 16:18:49 +02:00
hmac_s390.c s390/crypto: Add hardware acceleration for HMAC modes 2024-08-29 22:56:33 +02:00
Kconfig s390/crypto: Add hardware acceleration for HMAC modes 2024-08-29 22:56:33 +02:00
Makefile s390/crypto: Add hardware acceleration for HMAC modes 2024-08-29 22:56:33 +02:00
paes_s390.c s390/crypto: Add hardware acceleration for full AES-XTS mode 2024-10-29 11:17:19 +01:00
prng.c s390/crypto: Switch over to sysfs_emit() 2024-10-25 16:03:24 +02:00
sha1_s390.c s390/cpufeature: rework to allow more than only hwcap bits 2022-07-19 16:18:49 +02:00
sha3_256_s390.c s390/sha3: Fix SHA3 selftests failures 2024-09-05 15:17:23 +02:00
sha3_512_s390.c s390/sha3: Fix SHA3 selftests failures 2024-09-05 15:17:23 +02:00
sha256_s390.c s390/cpufeature: rework to allow more than only hwcap bits 2022-07-19 16:18:49 +02:00
sha512_s390.c s390/cpufeature: rework to allow more than only hwcap bits 2022-07-19 16:18:49 +02:00
sha_common.c s390/sha3: Fix SHA3 selftests failures 2024-09-05 15:17:23 +02:00
sha.h s390/sha3: Support sha3 performance enhancements 2024-08-29 22:56:34 +02:00