Matthew McClintock | e1bcfe4 | 2013-11-22 15:33:09 -0600 | [diff] [blame] | 1 | /* |
| 2 | * User space header to send message to the fast classifier |
Matthew McClintock | a322194 | 2014-01-16 11:44:26 -0600 | [diff] [blame] | 3 | * |
| 4 | * Copyright (c) 2013 Qualcomm Atheros, Inc. |
| 5 | * |
| 6 | * All Rights Reserved. |
| 7 | * Qualcomm Atheros Confidential and Proprietary. |
Matthew McClintock | e1bcfe4 | 2013-11-22 15:33:09 -0600 | [diff] [blame] | 8 | */ |
| 9 | |
Matthew McClintock | cf15735 | 2014-01-10 16:35:40 -0600 | [diff] [blame] | 10 | #include <linux/if_ether.h> |
| 11 | |
Matthew McClintock | 3abf38e | 2014-01-07 17:37:56 -0600 | [diff] [blame] | 12 | #define FAST_CLASSIFIER_GENL_VERSION (1) |
| 13 | #define FAST_CLASSIFIER_GENL_NAME "FC" |
| 14 | #define FAST_CLASSIFIER_GENL_MCGRP "FC_MCGRP" |
| 15 | #define FAST_CLASSIFIER_GENL_HDRSIZE (0) |
Matthew McClintock | e4f9a67 | 2014-01-06 17:04:04 -0600 | [diff] [blame] | 16 | |
Matthew McClintock | 3abf38e | 2014-01-07 17:37:56 -0600 | [diff] [blame] | 17 | enum { |
| 18 | FAST_CLASSIFIER_A_UNSPEC, |
| 19 | FAST_CLASSIFIER_A_TUPLE, |
| 20 | __FAST_CLASSIFIER_A_MAX, |
| 21 | }; |
| 22 | #define FAST_CLASSIFIER_A_MAX (__FAST_CLASSIFIER_A_MAX - 1) |
| 23 | |
| 24 | enum { |
| 25 | FAST_CLASSIFIER_C_UNSPEC, |
| 26 | FAST_CLASSIFIER_C_OFFLOAD, |
| 27 | FAST_CLASSIFIER_C_OFFLOADED, |
| 28 | FAST_CLASSIFIER_C_DONE, |
| 29 | __FAST_CLASSIFIER_C_MAX, |
| 30 | }; |
| 31 | #define FAST_CLASSIFIER_C_MAX (__FAST_CLASSIFIER_C_MAX - 1) |
| 32 | |
| 33 | struct fast_classifier_tuple { |
| 34 | unsigned char proto; |
| 35 | unsigned long src_saddr; |
| 36 | unsigned long dst_saddr; |
| 37 | unsigned short sport; |
| 38 | unsigned short dport; |
Matthew McClintock | d180a7d | 2014-01-17 11:21:35 -0600 | [diff] [blame] | 39 | unsigned char smac[ETH_ALEN]; |
| 40 | unsigned char dmac[ETH_ALEN]; |
Matthew McClintock | 3abf38e | 2014-01-07 17:37:56 -0600 | [diff] [blame] | 41 | }; |