| 1 |
/* SPDX-License-Identifier: LGPL-2.1-only */ |
| 2 |
/* |
| 3 |
* Copyright (c) 2010 Thomas Graf <[email protected]> |
| 4 |
*/ |
| 5 |
|
| 6 |
#ifndef NETLINK_CLS_EMATCH_TEXT_H_ |
| 7 |
#define NETLINK_CLS_EMATCH_TEXT_H_ |
| 8 |
|
| 9 |
#include <netlink/netlink.h> |
| 10 |
#include <netlink/route/cls/ematch.h> |
| 11 |
#include <linux/tc_ematch/tc_em_text.h> |
| 12 |
|
| 13 |
#ifdef __cplusplus |
| 14 |
extern "C" { |
| 15 |
#endif |
| 16 |
|
| 17 |
extern void rtnl_ematch_text_set_from(struct rtnl_ematch *, |
| 18 |
uint8_t, uint16_t); |
| 19 |
extern uint16_t rtnl_ematch_text_get_from_offset(struct rtnl_ematch *); |
| 20 |
extern uint8_t rtnl_ematch_text_get_from_layer(struct rtnl_ematch *); |
| 21 |
extern void rtnl_ematch_text_set_to(struct rtnl_ematch *, |
| 22 |
uint8_t, uint16_t); |
| 23 |
extern uint16_t rtnl_ematch_text_get_to_offset(struct rtnl_ematch *); |
| 24 |
extern uint8_t rtnl_ematch_text_get_to_layer(struct rtnl_ematch *); |
| 25 |
extern void rtnl_ematch_text_set_pattern(struct rtnl_ematch *, |
| 26 |
char *, size_t); |
| 27 |
extern char * rtnl_ematch_text_get_pattern(struct rtnl_ematch *); |
| 28 |
extern size_t rtnl_ematch_text_get_len(struct rtnl_ematch *); |
| 29 |
extern void rtnl_ematch_text_set_algo(struct rtnl_ematch *, const char *); |
| 30 |
extern char * rtnl_ematch_text_get_algo(struct rtnl_ematch *); |
| 31 |
|
| 32 |
#ifdef __cplusplus |
| 33 |
} |
| 34 |
#endif |
| 35 |
|
| 36 |
#endif |