• Stefan Raspl's avatar
    tools/kvm_stat: fix debugfs handling · 1fd6a708
    Stefan Raspl authored
    Te checks for debugfs assumed that debugfs is always mounted at
    /sys/kernel/debug - which is likely, but not guaranteed. This is addressed
    by checking /proc/mounts for the actual location.
    Furthermore, when debugfs was mounted, but the kvm module not loaded, a
    misleading error pointing towards debugfs not present was given.
    To reproduce,
    (a) run kvm_stat with debugfs mounted at a place different from
        /sys/kernel/debug
    (b) run kvm_stat with debugfs mounted but kvm module not loaded
    Signed-off-by: default avatarStefan Raspl <raspl@linux.vnet.ibm.com>
    Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
    1fd6a708
kvm_stat 53.4 KB