def _modprobe(self, modname): try: from kmodpy import kmod try: kmod.Kmod().modprobe(modname, quiet=True) except kmod.KmodError: pass except ImportError: # Try the ctypes library included with the libkmod itself. try: import kmod kmod.Kmod().modprobe(modname) except Exception as e: pass
def _modprobe(self, modname): try: from kmodpy import kmod try: kmod.Kmod().modprobe(modname, quiet=True) except kmod.KmodError: pass except ImportError: pass