source: rtems-libbsd/rtemsbsd/include/machine/cpu.h @ 94d04f8

4.1155-freebsd-126-freebsd-12freebsd-9.3
Last change on this file since 94d04f8 was de3ef24, checked in by Sebastian Huber <sebastian.huber@…>, on 10/24/13 at 08:52:40

Move cpu_spinwait() definition

  • Property mode set to 100644
File size: 749 bytes
Line 
1/**
2 * @file
3 *
4 * @ingroup rtems_bsd_rtems
5 *
6 * @brief TODO.
7 */
8
9/*
10 * COPYRIGHT (c) 2012.
11 * On-Line Applications Research Corporation (OAR).
12 *
13 * The license and distribution terms for this file may be
14 * found in the file LICENSE in this distribution or at
15 * http://www.rtems.com/license/LICENSE.
16 */
17
18#ifndef _RTEMS_BSD_MACHINE_CPU_H_
19#define _RTEMS_BSD_MACHINE_CPU_H_
20
21#ifndef _RTEMS_BSD_MACHINE_RTEMS_BSD_CONFIG_H_
22#error "the header file <freebsd/machine/rtems-bsd-config.h> must be included first"
23#endif
24
25#define cpu_spinwait() do { } while (0)
26
27/* FIXME: This implementation is a security problem */
28static __inline uint64_t
29get_cyclecount(void)
30{
31        return rtems_clock_get_ticks_since_boot();
32}
33
34#endif /* _RTEMS_BSD_MACHINE_CPU_H_ */
Note: See TracBrowser for help on using the repository browser.