aboutsummaryrefslogtreecommitdiffstats
path: root/include/openbsc/chan_alloc.h
blob: 0c6d63e643561cdbb38bcee3c2ca15be4558c25e (plain)
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
#ifndef _CHAN_ALLOC_H
#define _CHAN_ALLOC_H

/* Special allocator for C0 of BTS */
struct gsm_bts_trx_ts *ts_c0_alloc(struct gsm_bts *bts,
				   enum gsm_phys_chan_config pchan);

/* Regular physical channel allocator */
struct gsm_bts_trx_ts *ts_alloc(struct gsm_bts *bts,
				enum gsm_phys_chan_config pchan);

/* Regular physical channel (TS) */
void ts_free(struct gsm_bts_trx_ts *ts);


/* Allocate a logical channel (SDCCH, TCH, ...) */
struct gsm_lchan *lchan_alloc(struct gsm_bts *bts, enum gsm_chan_t type);

/* Free a logical channel (SDCCH, TCH, ...) */
void lchan_free(struct gsm_lchan *lchan);

/* Consider releasing the channel */
int lchan_auto_release(struct gsm_lchan *lchan);

#endif /* _CHAN_ALLOC_H */