Skip to content

Instantly share code, notes, and snippets.

@jabbas
Created March 11, 2017 07:25
Show Gist options
  • Save jabbas/a8785710a5e8655045fc0be67385e887 to your computer and use it in GitHub Desktop.
Save jabbas/a8785710a5e8655045fc0be67385e887 to your computer and use it in GitHub Desktop.
#!/bin/bash
for d in /sys/kernel/iommu_groups/*/devices/*; do
n=${d#*/iommu_groups/*}; n=${n%%/*}
printf 'IOMMU Group %s ' "$n"
lspci -nns "${d##*/}"
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment