linux/drivers/video/backlight
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
..
88pm860x_bl.c backlight: 88pm860x_bl: Simplify with scoped for each OF child loop 2024-10-02 13:46:34 +01:00
aat2870_bl.c Get rid of 'remove_new' relic from platform driver struct 2024-12-01 15:12:43 -08:00
adp5520_bl.c Get rid of 'remove_new' relic from platform driver struct 2024-12-01 15:12:43 -08:00
adp8860_bl.c
adp8870_bl.c
ams369fg06.c
apple_bl.c
arcxcnn_bl.c
as3711_bl.c
backlight.c backlight: Remove notifier 2024-10-09 15:42:48 +01:00
bd6107.c
corgi_lcd.c backlight: lcd: Remove struct fb_videomode from set_mode callback 2024-09-30 16:49:42 +01:00
da903x_bl.c
da9052_bl.c Get rid of 'remove_new' relic from platform driver struct 2024-12-01 15:12:43 -08:00
ep93xx_bl.c
gpio_backlight.c
hp680_bl.c Get rid of 'remove_new' relic from platform driver struct 2024-12-01 15:12:43 -08:00
hx8357.c
ili922x.c
ili9320.c
ili9320.h
ipaq_micro_bl.c
jornada720_bl.c
jornada720_lcd.c
kb3886_bl.c
Kconfig
ktd253-backlight.c
ktd2801-backlight.c module: Convert symbol namespace to string literal 2024-12-02 11:34:44 -08:00
ktz8866.c backlight: ktz8866: Fix module autoloading 2024-10-02 13:46:34 +01:00
l4f00242t03.c
lcd.c backlight: lcd: Remove struct fb_videomode from set_mode callback 2024-09-30 16:49:42 +01:00
led_bl.c Get rid of 'remove_new' relic from platform driver struct 2024-12-01 15:12:43 -08:00
lm3509_bl.c
lm3533_bl.c Get rid of 'remove_new' relic from platform driver struct 2024-12-01 15:12:43 -08:00
lm3630a_bl.c
lm3639_bl.c
lms283gf05.c
lms501kf03.c
locomolcd.c
lp855x_bl.c
lp8788_bl.c Get rid of 'remove_new' relic from platform driver struct 2024-12-01 15:12:43 -08:00
ltv350qv.c
ltv350qv.h
lv5207lp.c
Makefile
max8925_bl.c
mp3309c.c
mt6370-backlight.c Get rid of 'remove_new' relic from platform driver struct 2024-12-01 15:12:43 -08:00
omap1_bl.c
otm3225a.c
pandora_bl.c
pcf50633-backlight.c
platform_lcd.c
pwm_bl.c Get rid of 'remove_new' relic from platform driver struct 2024-12-01 15:12:43 -08:00
qcom-wled.c Get rid of 'remove_new' relic from platform driver struct 2024-12-01 15:12:43 -08:00
rave-sp-backlight.c
rt4831-backlight.c Get rid of 'remove_new' relic from platform driver struct 2024-12-01 15:12:43 -08:00
sky81452-backlight.c Get rid of 'remove_new' relic from platform driver struct 2024-12-01 15:12:43 -08:00
tdo24m.c backlight: lcd: Remove struct fb_videomode from set_mode callback 2024-09-30 16:49:42 +01:00
tps65217_bl.c
vgg2432a4.c
wm831x_bl.c