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
..
2024-12-02 11:34:44 -08:00
2024-11-04 17:53:09 +09:00
2024-12-02 11:34:44 -08:00
2024-11-12 16:41:45 +00:00
2024-11-29 11:58:27 -08:00
2024-11-26 18:05:44 -08:00
2024-12-01 15:12:43 -08:00
2024-12-02 11:34:44 -08:00
2024-12-02 11:34:44 -08:00
2024-12-01 15:12:43 -08:00
2024-12-01 15:12:43 -08:00
2024-12-01 15:12:43 -08:00
2024-11-29 11:58:27 -08:00
2024-12-01 15:12:43 -08:00
2024-12-02 11:34:44 -08:00
2024-12-01 15:12:43 -08:00
2024-12-02 11:34:44 -08:00
2024-12-01 15:12:43 -08:00
2024-11-05 14:01:07 +01:00
2024-12-02 11:34:44 -08:00
2024-11-23 10:44:31 -08:00
2024-12-01 15:12:43 -08:00
2024-12-02 11:34:44 -08:00
2024-12-02 11:34:44 -08:00
2024-12-02 11:34:44 -08:00
2024-12-01 15:12:43 -08:00
2024-12-02 11:34:44 -08:00
2024-12-02 11:34:44 -08:00
2024-12-01 15:12:43 -08:00
2024-12-01 15:12:43 -08:00
2024-11-25 17:12:54 -08:00
2024-12-02 11:34:44 -08:00
2024-12-02 11:34:44 -08:00
2024-12-01 15:12:43 -08:00
2024-12-02 11:34:44 -08:00
2024-12-02 11:34:44 -08:00
2024-11-05 05:33:46 +01:00
2024-12-02 11:34:44 -08:00
2024-12-01 15:12:43 -08:00
2024-12-01 15:12:43 -08:00
2024-12-01 15:12:43 -08:00
2024-12-02 11:34:44 -08:00
2024-12-01 15:12:43 -08:00
2024-12-01 15:12:43 -08:00
2024-12-02 11:34:44 -08:00
2024-12-01 15:12:43 -08:00
2024-11-11 15:48:50 +01:00
2024-12-02 11:34:44 -08:00
2024-12-02 11:34:44 -08:00
2024-11-25 10:31:39 -08:00
2024-11-05 01:32:05 +02:00
2024-12-02 11:34:44 -08:00
2024-12-01 12:37:58 -08:00
2024-11-09 09:14:12 -08:00
2024-12-02 11:34:44 -08:00
2024-12-01 15:12:43 -08:00
2024-11-30 09:03:16 -08:00
2024-12-02 11:34:44 -08:00
2024-11-30 15:47:29 -08:00
2024-12-02 11:34:44 -08:00
2024-12-01 15:12:43 -08:00
2024-12-01 15:12:43 -08:00
2024-11-06 20:46:07 -05:00
2024-12-02 11:34:44 -08:00
2024-12-02 11:34:44 -08:00
2024-11-20 12:51:32 -08:00
2024-11-30 10:32:47 -08:00
2024-12-02 11:34:44 -08:00
2024-12-02 11:34:44 -08:00
2024-12-02 11:34:44 -08:00
2024-12-01 15:12:43 -08:00
2024-12-01 15:12:43 -08:00
2024-11-27 14:40:33 -08:00
2024-12-01 15:12:43 -08:00
2024-12-01 15:12:43 -08:00
2024-12-02 11:34:44 -08:00
2024-12-01 15:12:43 -08:00
2024-12-02 11:34:44 -08:00
2024-12-02 11:34:44 -08:00
2024-11-29 11:43:29 -08:00
2024-12-02 11:34:44 -08:00
2024-12-02 11:34:44 -08:00
2024-12-01 15:12:43 -08:00
2024-11-28 09:28:09 -08:00
2024-12-02 11:34:44 -08:00
2024-12-01 15:12:43 -08:00
2024-11-15 00:32:29 +11:00
2024-12-01 15:12:43 -08:00
2024-12-02 11:34:44 -08:00
2024-11-28 09:40:53 -08:00
2024-11-15 20:36:27 -08:00
2024-12-02 11:34:44 -08:00
2024-12-01 15:12:43 -08:00
2024-12-02 11:34:44 -08:00
2024-11-29 11:43:29 -08:00
2024-12-01 15:12:43 -08:00
2024-11-29 11:43:29 -08:00
2024-11-30 14:45:29 -08:00
2024-12-01 15:12:43 -08:00
2024-11-21 08:28:08 -08:00
2024-12-02 11:34:44 -08:00
2024-12-02 11:34:44 -08:00
2024-12-01 15:12:43 -08:00
2024-12-02 11:34:44 -08:00
2024-11-25 18:50:55 -08:00
2024-11-12 15:48:08 +01:00
2024-12-01 15:12:43 -08:00
2024-12-02 11:34:44 -08:00
2024-11-29 11:19:31 -08:00
2024-12-02 11:34:44 -08:00
2024-12-01 15:12:43 -08:00
2024-12-01 15:12:43 -08:00
2024-12-02 11:34:44 -08:00
2024-11-12 18:05:05 -05:00
2024-12-02 11:34:44 -08:00
2024-11-11 10:56:27 -08:00
2024-12-02 11:34:44 -08:00
2024-12-01 15:12:43 -08:00
2024-12-02 11:34:44 -08:00
2024-12-01 15:12:43 -08:00
2024-12-02 11:34:44 -08:00
2024-12-02 11:34:44 -08:00