logging: Define default logging categories

This commit is contained in:
Holger Hans Peter Freyther 2016-03-21 11:47:25 +01:00
parent a1909e6c80
commit c1879e47ba
2 changed files with 25 additions and 1 deletions

9
src/logging.h Normal file
View File

@ -0,0 +1,9 @@
#pragma once
#include <osmocom/core/logging.h>
enum {
DSIP,
DMNCC,
DAPP,
};

View File

@ -20,9 +20,9 @@
#include "evpoll.h" #include "evpoll.h"
#include "vty.h" #include "vty.h"
#include "logging.h"
#include <osmocom/core/application.h> #include <osmocom/core/application.h>
#include <osmocom/core/logging.h>
#include <osmocom/core/utils.h> #include <osmocom/core/utils.h>
#include <osmocom/core/stats.h> #include <osmocom/core/stats.h>
@ -40,6 +40,21 @@
void *tall_mncc_ctx; void *tall_mncc_ctx;
static struct log_info_cat mncc_sip_categories[] = { static struct log_info_cat mncc_sip_categories[] = {
[DSIP] = {
.name = "DSIP",
.description = "SIP interface",
.enabled = 1, .loglevel = LOGL_NOTICE,
},
[DMNCC] = {
.name = "DMNCC",
.description = "MNCC interface",
.enabled = 1, .loglevel = LOGL_NOTICE,
},
[DAPP] = {
.name = "DAPP",
.description = "Application interface",
.enabled = 1, .loglevel = LOGL_NOTICE,
},
}; };
static const struct log_info mncc_sip_info = { static const struct log_info mncc_sip_info = {