convert from svn repository: remove tags directory
[lttv.git] / trunk / tests / user / ltt-facility-loader-user_tests.c
CommitLineData
ff2341d9 1/*
2 * ltt-facility-loader-user_tests.c
3 *
4 * (C) Copyright 2005 -
5 * Mathieu Desnoyers (mathieu.desnoyers@polymtl.ca)
6 *
7 * Contains the LTT user space facility loader.
8 *
9 */
10
11
12#define LTT_TRACE
13#include <error.h>
14#include <stdio.h>
15#include <ltt/ltt-usertrace.h>
16#include "ltt-facility-loader-user_tests.h"
17
18static struct user_facility_info facility = {
19 .name = LTT_FACILITY_NAME,
20 .num_events = LTT_FACILITY_NUM_EVENTS,
21#ifndef LTT_PACK
22 .alignment = sizeof(void*),
23#else
24 .alignment = 0,
25#endif //LTT_PACK
26 .checksum = LTT_FACILITY_CHECKSUM,
27 .int_size = sizeof(int),
28 .long_size = sizeof(long),
29 .pointer_size = sizeof(void*),
30 .size_t_size = sizeof(size_t)
31};
32
33static void __attribute__((constructor)) __ltt_user_init(void)
34{
35 int err;
36#ifdef LTT_SHOW_DEBUG
37 printf("LTT : ltt-facility-user_tests init in userspace\n");
38#endif //LTT_SHOW_DEBUG
39
40 err = ltt_register_generic(&LTT_FACILITY_SYMBOL, &facility);
41 LTT_FACILITY_CHECKSUM_SYMBOL = LTT_FACILITY_SYMBOL;
42
43 if(err) {
44#ifdef LTT_SHOW_DEBUG
45 perror("Error in ltt_register_generic");
46#endif //LTT_SHOW_DEBUG
47 }
48}
49
This page took 0.036603 seconds and 4 git commands to generate.