spectre_v2を担当するモジュールを確認するには?

spectre_v2を担当するモジュールを確認するには?
SERVER:~ # cat /sys/devices/system/cpu/vulnerabilities/spectre_v2
Mitigation: Full generic retpoline, IBPB, STIBP, RSB filling - vulnerable module loaded
SERVER:~ #

質問:ところで、lsmod(?)のどのモジュールがspectre_v2に脆弱であるかをどのように検出できますか? SLES 12.3。

答え1

SERVER:~ # awk '{module=$1; retpcheck="modinfo "module" | grep -c retpoline"; retpcheck | getline found;  close(retpcheck); if (!found) {print "VULNERABLE - No Retpoline found - "module}}' /proc/modules
VULNERABLE - No Retpoline found - mlx4_ib
VULNERABLE - No Retpoline found - mlx4_en
VULNERABLE - No Retpoline found - mlx4_core
VULNERABLE - No Retpoline found - mlx5_ib
VULNERABLE - No Retpoline found - mlx5_core
VULNERABLE - No Retpoline found - mlxfw
VULNERABLE - No Retpoline found - mlx_compat
SERVER:~ #

関連情報