Igt-dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Lucas De Marchi <lucas.demarchi@intel.com>
To: igt-dev@lists.freedesktop.org
Cc: Lucas De Marchi <lucas.demarchi@intel.com>
Subject: [PATCH i-g-t 4/9] lib/igt_kmod: Remove unused low level __igt_intel_driver_unload()
Date: Mon,  4 Nov 2024 22:18:40 -0800	[thread overview]
Message-ID: <20241105061845.2486557-5-lucas.demarchi@intel.com> (raw)
In-Reply-To: <20241105061845.2486557-1-lucas.demarchi@intel.com>

__igt_intel_driver_unload() is now unused and not needed.

Signed-off-by: Lucas De Marchi <lucas.demarchi@intel.com>
---
 lib/igt_kmod.c | 47 -----------------------------------------------
 lib/igt_kmod.h |  6 ------
 2 files changed, 53 deletions(-)

diff --git a/lib/igt_kmod.c b/lib/igt_kmod.c
index 0c093ec62..972dc490d 100644
--- a/lib/igt_kmod.c
+++ b/lib/igt_kmod.c
@@ -605,53 +605,6 @@ int igt_audio_driver_unload(char **who)
 	return igt_always_unload_audio_driver(who);
 }
 
-int __igt_intel_driver_unload(char **who, const char *driver)
-{
-	int ret;
-
-	const char *aux[] = {
-		/* gen5: ips uses symbol_get() so only a soft module dependency */
-		"intel_ips",
-		/* mei_gsc uses an i915 aux dev and the other mei mods depend on it */
-		"mei_pxp",
-		"mei_hdcp",
-		"mei_gsc",
-		NULL,
-	};
-
-	/* unbind vt */
-	bind_fbcon(false);
-
-	ret = igt_audio_driver_unload(who);
-	if (ret)
-		return ret;
-
-	for (const char **m = aux; *m; m++) {
-		if (!igt_kmod_is_loaded(*m))
-			continue;
-
-		ret = igt_kmod_unload(*m);
-		if (ret) {
-			if (who)
-				*who = strdup_realloc(*who, *m);
-
-			return ret;
-		}
-	}
-
-	if (igt_kmod_is_loaded(driver)) {
-		ret = igt_kmod_unload(driver);
-		if (ret) {
-			if (who)
-				*who = strdup_realloc(*who, driver);
-
-			return ret;
-		}
-	}
-
-	return 0;
-}
-
 /*
  * Unbind driver from devices. Currently supports only PCI bus
  */
diff --git a/lib/igt_kmod.h b/lib/igt_kmod.h
index 88d4a51e6..67ae6833f 100644
--- a/lib/igt_kmod.h
+++ b/lib/igt_kmod.h
@@ -42,7 +42,6 @@ int igt_audio_driver_unload(char **whom);
 
 int igt_intel_driver_load(const char *opts, const char *driver);
 int igt_intel_driver_unload(const char *driver);
-int __igt_intel_driver_unload(char **who, const char *driver);
 
 static inline int igt_i915_driver_load(const char *opts)
 {
@@ -54,11 +53,6 @@ static inline int igt_i915_driver_unload(void)
 	return igt_intel_driver_unload("i915");
 }
 
-static inline int __igt_i915_driver_unload(char **whom)
-{
-	return __igt_intel_driver_unload(whom, "i915");
-};
-
 static inline int igt_xe_driver_load(const char *opts)
 {
 	return igt_intel_driver_load(opts, "xe");
-- 
2.47.0


  parent reply	other threads:[~2024-11-05  6:19 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-11-05  6:18 [PATCH i-g-t 0/9] i915: unload refactors Lucas De Marchi
2024-11-05  6:18 ` [PATCH i-g-t 1/9] lib/igt_kmod: Remove unused module_ref Lucas De Marchi
2024-11-06 22:09   ` [i-g-t,1/9] " Taylor, Clinton A
2024-11-05  6:18 ` [PATCH i-g-t 2/9] tests/intel/perf_pmu: Remove trial unload Lucas De Marchi
2024-11-19  1:15   ` Matt Roper
2024-11-05  6:18 ` [PATCH i-g-t 3/9] lib/igt_kmod: Share xe's unload logic with i915 Lucas De Marchi
2024-11-19  1:20   ` Matt Roper
2024-11-05  6:18 ` Lucas De Marchi [this message]
2024-11-19  1:21   ` [PATCH i-g-t 4/9] lib/igt_kmod: Remove unused low level __igt_intel_driver_unload() Matt Roper
2024-11-05  6:18 ` [PATCH i-g-t 5/9] tests/core_hotunplug: Stop unloading audio Lucas De Marchi
2024-11-19  1:23   ` Matt Roper
2024-11-05  6:18 ` [PATCH i-g-t 6/9] tests/device_reset: " Lucas De Marchi
2024-11-19  1:24   ` Matt Roper
2024-11-05  6:18 ` [PATCH i-g-t 7/9] lib: Remove unused audio-related helpers Lucas De Marchi
2024-11-19  1:28   ` Matt Roper
2024-11-05  6:18 ` [PATCH i-g-t 8/9] i915_module_load: Stop caring about snd Lucas De Marchi
2024-11-19  1:34   ` Matt Roper
2024-11-05  6:18 ` [PATCH i-g-t 9/9] xe_module_load: " Lucas De Marchi
2024-11-19  1:35   ` Matt Roper
2024-11-05  9:30 ` ✓ Fi.CI.BAT: success for i915: unload refactors Patchwork
2024-11-05  9:34 ` ✓ CI.xeBAT: " Patchwork
2024-11-06  4:37 ` ✗ Fi.CI.IGT: failure " Patchwork
2024-11-06  9:39 ` ✗ CI.xeFULL: " Patchwork
2024-11-06 17:11   ` Lucas De Marchi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20241105061845.2486557-5-lucas.demarchi@intel.com \
    --to=lucas.demarchi@intel.com \
    --cc=igt-dev@lists.freedesktop.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox