1 /* 2 * RSS and Classifier definitions for Marvell PPv2 Network Controller 3 * 4 * Copyright (C) 2014 Marvell 5 * 6 * Marcin Wojtas <mw@semihalf.com> 7 * 8 * This file is licensed under the terms of the GNU General Public 9 * License version 2. This program is licensed "as is" without any 10 * warranty of any kind, whether express or implied. 11 */ 12 13 #ifndef _MVPP2_CLS_H_ 14 #define _MVPP2_CLS_H_ 15 16 /* Classifier constants */ 17 #define MVPP2_CLS_FLOWS_TBL_SIZE 512 18 #define MVPP2_CLS_FLOWS_TBL_DATA_WORDS 3 19 #define MVPP2_CLS_LKP_TBL_SIZE 64 20 #define MVPP2_CLS_RX_QUEUES 256 21 22 /* RSS constants */ 23 #define MVPP22_RSS_TABLE_ENTRIES 32 24 25 struct mvpp2_cls_flow_entry { 26 u32 index; 27 u32 data[MVPP2_CLS_FLOWS_TBL_DATA_WORDS]; 28 }; 29 30 struct mvpp2_cls_lookup_entry { 31 u32 lkpid; 32 u32 way; 33 u32 data; 34 }; 35 36 void mvpp22_init_rss(struct mvpp2_port *port); 37 38 void mvpp2_cls_init(struct mvpp2 *priv); 39 40 void mvpp2_cls_port_config(struct mvpp2_port *port); 41 42 void mvpp2_cls_oversize_rxq_set(struct mvpp2_port *port); 43 44 #endif 45