linux-stable/sound/hda
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
..
ext ALSA: hda: Use *-y instead of *-objs in Makefile 2024-05-08 18:17:42 +02:00
array.c treewide: Add SPDX license identifier for missed files 2019-05-21 10:50:45 +02:00
hda_bus_type.c driver core: have match() callback in struct bus_type take a const * 2024-07-03 15:16:54 +02:00
hdac_bus.c ALSA: hda: Skip event processing for unregistered codecs 2022-07-15 16:26:50 +02:00
hdac_component.c ALSA: hda/i915 - fix list corruption with concurrent probes 2020-10-09 16:46:04 +02:00
hdac_controller.c ALSA: hda: hdac_controller: Implement support for use_pio_for_commands mode 2024-04-18 08:38:54 +02:00
hdac_device.c ALSA: hda/senarytech: add senarytech codec support 2024-06-18 11:59:08 +02:00
hdac_i915.c ALSA: hda: Skip i915 initialization on CNL/LKF-based platforms 2024-03-04 09:17:02 +01:00
hdac_regmap.c ALSA: hda: Use regcache_reg_cached() rather than open coding 2023-07-18 15:05:12 +01:00
hdac_stream.c ALSA: hda: Add missing parameter description for snd_hdac_stream_timecounter_init() 2024-10-03 09:24:45 +02:00
hdac_sysfs.c ALSA: hda: make kobj_type structure constant 2023-02-11 09:37:42 +01:00
hdmi_chmap.c ALSA: hda: Add input value sanity checks to HDMI channel map controls 2024-06-18 12:00:19 +02:00
intel-dsp-config.c module: Convert symbol namespace to string literal 2024-12-02 11:34:44 -08:00
intel-nhlt.c ALSA: hda: intel-nhlt: add intel_nhlt_ssp_device_type() function 2024-03-22 12:40:46 +01:00
intel-sdw-acpi.c module: Convert symbol namespace to string literal 2024-12-02 11:34:44 -08:00
Kconfig ALSA: hda: Allow the default preallocation for x86 again 2024-09-07 10:42:03 +02:00
local.h ALSA: hda: Unexport some local helper functions 2020-05-16 08:29:49 +02:00
Makefile ALSA: hda: Use *-y instead of *-objs in Makefile 2024-05-08 18:17:42 +02:00
trace.c ALSA: hda - Re-add tracepoints to HD-audio core driver 2015-03-23 13:17:58 +01:00
trace.h tracing/treewide: Remove second parameter of __assign_str() 2024-05-22 20:14:47 -04:00