That shows modules that are loaded. Those aren't necessarily active.kldstat shows modules in use
dmesg
shows u3g started when I am using a wired connection and no modem in use. So module is showing in kldstat with its memory address used but it is not in use..Dynamically loaded but not in use until called. top
or ps
correct?: ${_DIR_TREE_MODULES:="$(find /usr/src/sys/modules -type d | egrep -v "tests|dtb" | awk -F "/usr/src/sys/modules/" '{ print $2 }' )"}
_LIST_MENU="$(echo "${_DIR_TREE_MODULES}" | awk -v path="/usr/src/sys/modules" '{ print "awk -F \x27KMOD\x27 \x27/^KMOD/ {print \""$1 "\" $2 \" off \"}\x27 "path"/"$1"/Makefile" }' | egrep -v "^&" | tr '\t' ' ' | sh 2>/dev/null | sed 's|=| |g' | tr '\t' ' ')"
lol. Maybe some explanation is needed here? Looks amazing, but what does it do? Not sure anyone will want to copy/paste and run this on their system without having a summary of what it's doing. ?Code:: ${_DIR_TREE_MODULES:="$(find /usr/src/sys/modules -type d | egrep -v "tests|dtb" | awk -F "/usr/src/sys/modules/" '{ print $2 }' )"} _LIST_MENU="$(echo "${_DIR_TREE_MODULES}" | awk -v path="/usr/src/sys/modules" '{ print "awk -F \x27KMOD\x27 \x27/^KMOD/ {print \""$1 "\" $2 \" off \"}\x27 "path"/"$1"/Makefile" }' | egrep -v "^&" | tr '\t' ' ' | sh 2>/dev/null | sed 's|=| |g' | tr '\t' ' ')"