cregit-Linux how code gets into the kernel

Release 4.12 include/net/tc_act/tc_pedit.h

#ifndef __NET_TC_PED_H

#define __NET_TC_PED_H

#include <net/act_api.h>
#include <linux/tc_act/tc_pedit.h>


struct tcf_pedit_key_ex {
	
enum pedit_header_type htype;
	
enum pedit_cmd cmd;
};


struct tcf_pedit {
	
struct tc_action	common;
	
unsigned char		tcfp_nkeys;
	
unsigned char		tcfp_flags;
	
struct tc_pedit_key	*tcfp_keys;
	
struct tcf_pedit_key_ex	*tcfp_keys_ex;
};

#define to_pedit(a) ((struct tcf_pedit *)a)


static inline bool is_tcf_pedit(const struct tc_action *a) { #ifdef CONFIG_NET_CLS_ACT if (a->ops && a->ops->type == TCA_ACT_PEDIT) return true; #endif return false; }

Contributors

PersonTokensPropCommitsCommitProp
Or Gerlitz38100.00%1100.00%
Total38100.00%1100.00%


static inline int tcf_pedit_nkeys(const struct tc_action *a) { return to_pedit(a)->tcfp_nkeys; }

Contributors

PersonTokensPropCommitsCommitProp
Or Gerlitz21100.00%1100.00%
Total21100.00%1100.00%


static inline u32 tcf_pedit_htype(const struct tc_action *a, int index) { if (to_pedit(a)->tcfp_keys_ex) return to_pedit(a)->tcfp_keys_ex[index].htype; return TCA_PEDIT_KEY_EX_HDR_TYPE_NETWORK; }

Contributors

PersonTokensPropCommitsCommitProp
Or Gerlitz41100.00%1100.00%
Total41100.00%1100.00%


static inline u32 tcf_pedit_cmd(const struct tc_action *a, int index) { if (to_pedit(a)->tcfp_keys_ex) return to_pedit(a)->tcfp_keys_ex[index].cmd; return __PEDIT_CMD_MAX; }

Contributors

PersonTokensPropCommitsCommitProp
Or Gerlitz41100.00%1100.00%
Total41100.00%1100.00%


static inline u32 tcf_pedit_mask(const struct tc_action *a, int index) { return to_pedit(a)->tcfp_keys[index].mask; }

Contributors

PersonTokensPropCommitsCommitProp
Or Gerlitz29100.00%1100.00%
Total29100.00%1100.00%


static inline u32 tcf_pedit_val(const struct tc_action *a, int index) { return to_pedit(a)->tcfp_keys[index].val; }

Contributors

PersonTokensPropCommitsCommitProp
Or Gerlitz29100.00%1100.00%
Total29100.00%1100.00%


static inline u32 tcf_pedit_offset(const struct tc_action *a, int index) { return to_pedit(a)->tcfp_keys[index].off; }

Contributors

PersonTokensPropCommitsCommitProp
Or Gerlitz29100.00%1100.00%
Total29100.00%1100.00%

#endif /* __NET_TC_PED_H */

Overall Contributors

PersonTokensPropCommitsCommitProp
Or Gerlitz23179.66%110.00%
Jamal Hadi Salim248.28%110.00%
Amir Vadai186.21%220.00%
David S. Miller134.48%220.00%
Américo Wang31.03%330.00%
Patrick McHardy10.34%110.00%
Total290100.00%10100.00%
Information contained on this website is for historical information purposes only and does not indicate or represent copyright ownership.
Created with cregit.