This file is indexed.

/usr/include/babeltrace/ctf-ir/clock.h is in libbabeltrace-dev 1.5.5-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
#ifndef BABELTRACE_CTF_IR_CLOCK_H
#define BABELTRACE_CTF_IR_CLOCK_H

/*
 * BabelTrace - CTF IR: Clock
 *
 * Copyright 2013, 2014 Jérémie Galarneau <jeremie.galarneau@efficios.com>
 *
 * Author: Jérémie Galarneau <jeremie.galarneau@efficios.com>
 *
 * Permission is hereby granted, free of charge, to any person obtaining a copy
 * of this software and associated documentation files (the "Software"), to deal
 * in the Software without restriction, including without limitation the rights
 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
 * copies of the Software, and to permit persons to whom the Software is
 * furnished to do so, subject to the following conditions:
 *
 * The above copyright notice and this permission notice shall be included in
 * all copies or substantial portions of the Software.
 *
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
 * SOFTWARE.
 *
 * The Common Trace Format (CTF) Specification is available at
 * http://www.efficios.com/ctf
 */

#include <stdint.h>

#ifdef __cplusplus
extern "C" {
#endif

struct bt_ctf_clock;

/*
 * bt_ctf_clock_create: create a clock.
 *
 * Allocate a new clock setting its reference count to 1.
 *
 * @param name Name of the clock (will be copied).
 *
 * Returns an allocated clock on success, NULL on error.
 */
extern struct bt_ctf_clock *bt_ctf_clock_create(const char *name);

/*
 * bt_ctf_clock_set_description: set a clock's description.
 *
 * Set the clock's description. The description appears in the clock's TSDL
 * meta-data.
 *
 * @param clock Clock instance.
 * @param desc Description of the clock.
 *
 * Returns 0 on success, a negative value on error.
 */
extern int bt_ctf_clock_set_description(struct bt_ctf_clock *clock,
		const char *desc);

/*
 * bt_ctf_clock_set_frequency: set a clock's frequency.
 *
 * Set the clock's frequency (Hz).
 *
 * @param clock Clock instance.
 * @param freq Clock's frequency in Hz, defaults to 1 000 000 000 Hz (1ns).
 *
 * Returns 0 on success, a negative value on error.
 */
extern int bt_ctf_clock_set_frequency(struct bt_ctf_clock *clock,
		uint64_t freq);

/*
 * bt_ctf_clock_set_precision: set a clock's precision.
 *
 * Set the clock's precision.
 *
 * @param clock Clock instance.
 * @param precision Clock's precision in clock ticks, defaults to 1.
 *
 * Returns 0 on success, a negative value on error.
 */
extern int bt_ctf_clock_set_precision(struct bt_ctf_clock *clock,
		uint64_t precision);

/*
 * bt_ctf_clock_set_offset_s: set a clock's offset in seconds.
 *
 * Set the clock's offset in seconds from POSIX.1 Epoch, 1970-01-01,
 * defaults to 0.
 *
 * @param clock Clock instance.
 * @param offset_s Clock's offset in seconds, defaults to 0.
 *
 * Returns 0 on success, a negative value on error.
 */
extern int bt_ctf_clock_set_offset_s(struct bt_ctf_clock *clock,
		int64_t offset_s);

/*
 * bt_ctf_clock_set_offset: set a clock's offset in ticks.
 *
 * Set the clock's offset in ticks from Epoch + offset_s.
 *
 * @param clock Clock instance.
 * @param offset Clock's offset in ticks from Epoch + offset_s, defaults to 0.
 *
 * Returns 0 on success, a negative value on error.
 */
extern int bt_ctf_clock_set_offset(struct bt_ctf_clock *clock,
		int64_t offset);

/*
 * bt_ctf_clock_set_is_absolute: set a clock's absolute attribute.
 *
 * Set the clock's absolute attribute. A clock is absolute if the clock is a
 * global reference across the trace's other clocks.
 *
 * @param clock Clock instance.
 * @param is_absolute Clock's absolute attribute, defaults to FALSE.
 *
 * Returns 0 on success, a negative value on error.
 */
extern int bt_ctf_clock_set_is_absolute(struct bt_ctf_clock *clock,
		int is_absolute);

/*
 * bt_ctf_clock_set_time: set a clock's current time value.
 *
 * Set the current time in nanoseconds since the clock's origin (offset and
 * offset_s attributes). Defaults to 0.
 *
 * Returns 0 on success, a negative value on error.
 */
extern int bt_ctf_clock_set_time(struct bt_ctf_clock *clock, int64_t time);

#ifdef __cplusplus
}
#endif

#endif /* BABELTRACE_CTF_IR_CLOCK_H */