blob: 2ebc0180b79884c063e88fbd71c0c83087421b5b [file] [log] [blame]
Gabe Black396b0722013-09-26 16:22:09 -07001/*
2 * This file is part of the coreboot project.
3 *
4 * Copyright 2013 Google Inc.
5 *
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; version 2 of the License.
9 *
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
Gabe Black396b0722013-09-26 16:22:09 -070014 */
15
Gabe Blackeb623ab2013-10-06 10:54:53 -070016#include <arch/io.h>
17#include <soc/addressmap.h>
Gabe Black396b0722013-09-26 16:22:09 -070018#include <timer.h>
19
20void timer_monotonic_get(struct mono_time *mt)
21{
Gabe Blackeb623ab2013-10-06 10:54:53 -070022 mono_time_set_usecs(mt, read32((void *)TEGRA_TMRUS_BASE));
Gabe Black396b0722013-09-26 16:22:09 -070023}