Update README.md for supported kernel
[lttng-modules.git] / lttng-cpuhotplug.h
CommitLineData
b7cdc182 1/* SPDX-License-Identifier: (GPL-2.0-only or LGPL-2.1-only)
9f36eaed 2 *
1e367326
MD
3 * lttng-cpuhotplug.h
4 *
5 * Copyright (C) 2016 Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
1e367326
MD
6 */
7
9f36eaed
MJ
8#ifndef LTTNG_CPUHOTPLUG_H
9#define LTTNG_CPUHOTPLUG_H
10
1e367326
MD
11struct lttng_cpuhp_node;
12
da3b99a6
MD
13#include <linux/cpuhotplug.h>
14
1e367326
MD
15enum lttng_cpuhp_component {
16 LTTNG_RING_BUFFER_FRONTEND,
17 LTTNG_RING_BUFFER_BACKEND,
18 LTTNG_RING_BUFFER_ITER,
19 LTTNG_CONTEXT_PERF_COUNTERS,
20};
21
22struct lttng_cpuhp_node {
23 enum lttng_cpuhp_component component;
24 struct hlist_node node;
25};
26
27extern enum cpuhp_state lttng_hp_prepare;
28extern enum cpuhp_state lttng_hp_online;
29
30int lttng_cpuhp_rb_backend_prepare(unsigned int cpu,
31 struct lttng_cpuhp_node *node);
32int lttng_cpuhp_rb_frontend_dead(unsigned int cpu,
33 struct lttng_cpuhp_node *node);
34int lttng_cpuhp_rb_frontend_online(unsigned int cpu,
35 struct lttng_cpuhp_node *node);
36int lttng_cpuhp_rb_frontend_offline(unsigned int cpu,
37 struct lttng_cpuhp_node *node);
38int lttng_cpuhp_rb_iter_online(unsigned int cpu,
39 struct lttng_cpuhp_node *node);
40
41/* Ring buffer is a separate library. */
42void lttng_rb_set_hp_prepare(enum cpuhp_state val);
43void lttng_rb_set_hp_online(enum cpuhp_state val);
44
45extern enum cpuhp_state lttng_rb_hp_prepare;
46extern enum cpuhp_state lttng_rb_hp_online;
47
1e367326 48#endif /* LTTNG_CPUHOTPLUG_H */
This page took 0.028629 seconds and 4 git commands to generate.