timer.cc (10073:2360411a16be) timer.cc (11793:ef606668d247)
1/*
2 * Copyright (c) 2012 ARM Limited
3 * All rights reserved
4 *
5 * The license below extends only to copyright in the software and shall
6 * not be construed as granting a license to any other intellectual
7 * property including but not limited to intellectual property relating
8 * to a hardware implementation of the functionality of the software

--- 23 unchanged lines hidden (view full) ---

32 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
33 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
34 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
35 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
36 *
37 * Authors: Andreas Sandberg
38 */
39
1/*
2 * Copyright (c) 2012 ARM Limited
3 * All rights reserved
4 *
5 * The license below extends only to copyright in the software and shall
6 * not be construed as granting a license to any other intellectual
7 * property including but not limited to intellectual property relating
8 * to a hardware implementation of the functionality of the software

--- 23 unchanged lines hidden (view full) ---

32 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
33 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
34 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
35 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
36 *
37 * Authors: Andreas Sandberg
38 */
39
40#include "cpu/kvm/timer.hh"
41
42#include <sys/syscall.h>
43#include <unistd.h>
44
40#include <algorithm>
41#include <csignal>
42#include <ctime>
45#include <algorithm>
46#include <csignal>
47#include <ctime>
43#include <unistd.h>
44#include <sys/syscall.h>
45
46#include "base/misc.hh"
47#include "base/trace.hh"
48
49#include "base/misc.hh"
50#include "base/trace.hh"
48#include "cpu/kvm/timer.hh"
49#include "debug/KvmTimer.hh"
50
51/* According to timer_create(2), the value SIGEV_THREAD_ID can be used
52 * to specify which thread a timer signal gets delivered to. According
53 * to the man page, the member sigev_notify_thread is used to specify
54 * the TID. This member is currently not defined by default in
55 * siginfo.h on x86, so we define it here as a workaround.
56 */

--- 132 unchanged lines hidden ---
51#include "debug/KvmTimer.hh"
52
53/* According to timer_create(2), the value SIGEV_THREAD_ID can be used
54 * to specify which thread a timer signal gets delivered to. According
55 * to the man page, the member sigev_notify_thread is used to specify
56 * the TID. This member is currently not defined by default in
57 * siginfo.h on x86, so we define it here as a workaround.
58 */

--- 132 unchanged lines hidden ---