linux-stable/drivers/auxdisplay
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
..
arm-charlcd.c auxdisplay: Use sizeof(*pointer) instead of sizeof(type) 2024-06-04 10:29:36 +03:00
cfag12864b.c auxdisplay: Remove unused functions 2024-10-08 20:48:18 +03:00
cfag12864bfb.c Get rid of 'remove_new' relic from platform driver struct 2024-12-01 15:12:43 -08:00
charlcd.c [tree-wide] finally take no_llseek out 2024-09-27 08:18:43 -07:00
charlcd.h auxdisplay: charlcd: Provide a forward declaration 2024-05-28 01:09:53 +03:00
hd44780_common.c auxdisplay: hd44780: add missing MODULE_DESCRIPTION() macro 2024-06-04 10:29:36 +03:00
hd44780_common.h auxdisplay: Change gotoxy calling interface 2020-11-04 11:04:04 +01:00
hd44780.c Get rid of 'remove_new' relic from platform driver struct 2024-12-01 15:12:43 -08:00
ht16k33.c module: Convert symbol namespace to string literal 2024-12-02 11:34:44 -08:00
img-ascii-lcd.c module: Convert symbol namespace to string literal 2024-12-02 11:34:44 -08:00
Kconfig auxdisplay: linedisp: Support configuring the boot message 2024-06-04 10:29:36 +03:00
ks0108.c parport: Remove parport_driver.devmodel 2024-07-03 16:44:22 +02:00
lcd2s.c auxdisplay: Drop explicit initialization of struct i2c_device_id::driver_data to 0 2024-09-30 16:22:48 +03:00
line-display.c module: Convert symbol namespace to string literal 2024-12-02 11:34:44 -08:00
line-display.h auxdisplay: linedisp: Allocate buffer for the string 2024-02-26 18:02:19 +02:00
Makefile auxdisplay: linedisp: Group display drivers together 2024-04-02 19:09:14 +03:00
max6959.c module: Convert symbol namespace to string literal 2024-12-02 11:34:44 -08:00
panel.c parport: Remove parport_driver.devmodel 2024-07-03 16:44:22 +02:00
seg-led-gpio.c module: Convert symbol namespace to string literal 2024-12-02 11:34:44 -08:00