Changeset fdd0a700930bdd04bc8827ef88dc5039ecc5b6ce
- Timestamp:
- 03/01/10 22:30:51 (6 months ago)
- Author:
- Harald Welte <laforge@gnumonks.org>
- Parents:
- d284cd9f43a6954be338d85470a17ac6796b56d5
- Children:
- f08eabf2341de43993918246e89ce30c3651f378
- git-committer:
- Harald Welte <laforge@gnumonks.org> / 2010-03-01T22:30:51Z+0100
- Message:
-
add msgb_l1() and msgb_l1len() inline functions
- Files:
-
Legend:
- Unmodified
- Added
- Removed
-
|
r00096ac
|
rfdd0a700
|
|
| 68 | 68 | extern void msgb_reset(struct msgb *m); |
| 69 | 69 | |
| | 70 | #define msgb_l1(m) ((void *)(m->l1h)) |
| 70 | 71 | #define msgb_l2(m) ((void *)(m->l2h)) |
| 71 | 72 | #define msgb_l3(m) ((void *)(m->l3h)) |
| 72 | 73 | #define msgb_sms(m) ((void *)(m->smsh)) |
| | 74 | |
| | 75 | static inline unsigned int msgb_l1len(const struct msgb *msgb) |
| | 76 | { |
| | 77 | return msgb->tail - (uint8_t *)msgb_l1(msgb); |
| | 78 | } |
| 73 | 79 | |
| 74 | 80 | static inline unsigned int msgb_l2len(const struct msgb *msgb) |