Only try removing snd_hda_intel if it's actually loaded, and let the errors through to the logs if removal fails. This is a clue if i915 removal fails later. Signed-off-by: Jani Nikula <jani.nikula@xxxxxxxxx> --- tests/drv_module_reload_basic | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/drv_module_reload_basic b/tests/drv_module_reload_basic index 4f3172788eca..a221d65f725a 100755 --- a/tests/drv_module_reload_basic +++ b/tests/drv_module_reload_basic @@ -32,7 +32,9 @@ function reload() { # The sound driver uses our power well pkill alsactl snd_hda_intel_unloaded=0 - rmmod snd_hda_intel &> /dev/null && snd_hda_intel_unloaded=1 + if mod_loaded snd_hda_intel; then + rmmod snd_hda_intel && snd_hda_intel_unloaded=1 + fi #ignore errors in ips - gen5 only rmmod intel_ips &> /dev/null -- 2.1.4 _______________________________________________ Intel-gfx mailing list Intel-gfx@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/intel-gfx