blob: eb290e4163a856e4b6580dc3ee76f89dab0369b2 [file] [log] [blame]
Jonathan Santos03fd8d02011-05-25 13:54:02 -04001#ifndef _DEBUG_H
2#define _DEBUG_H
3
4#include <stdio.h>
5#include <osmocore/linuxlist.h>
6
7#define DEBUG
8#include <osmocore/logging.h>
9
10/* Debug Areas of the code */
11enum {
12 DRLL,
13 DCC,
14 DMM,
15 DRR,
16 DRSL,
17 DNM,
18 DMNCC,
19 DSMS,
20 DPAG,
21 DMEAS,
22 DMI,
23 DMIB,
24 DMUX,
25 DINP,
26 DSCCP,
27 DMSC,
28 DMGCP,
29 DHO,
30 DDB,
31 DREF,
32 DGPRS,
33 DNS,
34 DBSSGP,
35 DLLC,
36 DSNDCP,
37 DNAT,
38 Debug_LastEntry,
39};
40
41/* context */
42#define BSC_CTX_LCHAN 0
43#define BSC_CTX_SUBSCR 1
44#define BSC_CTX_BTS 2
45#define BSC_CTX_SCCP 3
46#define BSC_CTX_NSVC 4
47#define BSC_CTX_BVC 5
48
49/* target */
50
51enum {
52 //DEBUG_FILTER_ALL = 1 << 0,
53 LOG_FILTER_IMSI = 1 << 1,
54 LOG_FILTER_NSVC = 1 << 2,
55 LOG_FILTER_BVC = 1 << 3,
56};
57
58/* we don't need a header dependency for this... */
59struct gprs_nsvc;
60struct bssgp_bvc_ctx;
61
62void log_set_imsi_filter(struct log_target *target, const char *imsi);
63void log_set_nsvc_filter(struct log_target *target,
64 struct gprs_nsvc *nsvc);
65void log_set_bvc_filter(struct log_target *target,
66 struct bssgp_bvc_ctx *bctx);
67
68extern const struct log_info log_info;
69
70#endif /* _DEBUG_H */