#!/bin/bash # load_kmods_in_dir # Load all modules into the Kernel within the PWD. # # Example usage: # $ cd /lib/modules/6.6.14-armv8/kernel/drivers/pci # Run this script find . -type f -name '*.ko.*' | while read mod; do modprobe $( basename $mod .ko.xz ) ; done