cpu-kvm: Added informative error message
authorRyan Gambord <gambordr@oregonstate.edu>
Thu, 21 Mar 2019 14:01:29 +0000 (07:01 -0700)
committerRyan Gambord <gambordr@oregonstate.edu>
Thu, 21 Mar 2019 14:24:48 +0000 (14:24 +0000)
commit541d89953a4d2264702b90204ed91bb589a056ae
treea9cfaf0addf09239d6efc0d20c50ef79859b2aeb
parent81e34b308f3738cc9e88ae3066b5ed47c918c9de
cpu-kvm: Added informative error message

PerfKvmCounter::attach fails if the user doesn't have privileges to make
the perf_event_open syscall. This is the default privilege setting since
kernel 4.6. I've seen some users in the mailing list resort to running
as root; changing the perf_event_paranoid setting is an alternative.

Change-Id: I2bc6f76abb6e97bf34b408a611f64b1910f50a43
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/17508
Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com>
Maintainer: Andreas Sandberg <andreas.sandberg@arm.com>
src/cpu/kvm/perfevent.cc