diff options
author | Ivan Khoronzhuk <ivan.khoronzhuk@linaro.org> | 2016-02-12 18:51:20 +0200 |
---|---|---|
committer | Ivan Khoronzhuk <ivan.khoronzhuk@linaro.org> | 2016-02-12 18:55:01 +0200 |
commit | 92f8bbd00ae5770057a9b664d7bd42eacf267a9e (patch) | |
tree | e60798c9cf04893a22cbfed478fb4df22cba1104 /platform | |
parent | aad0e6c6aff5b3497803d4cd5a456402328d04cc (diff) |
linux-ks2: use software parser
For now there is no way to figure out packet was traversing
classification chain, which allows find out level offsets with
h/w, so some packets needs to be updated with software parser.
It one of the topics for todo.
Signed-off-by: Ivan Khoronzhuk <ivan.khoronzhuk@linaro.org>
Diffstat (limited to 'platform')
-rw-r--r-- | platform/linux-keystone2/include/odp_packet_io_internal.h | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/platform/linux-keystone2/include/odp_packet_io_internal.h b/platform/linux-keystone2/include/odp_packet_io_internal.h index f628c585..b2e1f5a7 100644 --- a/platform/linux-keystone2/include/odp_packet_io_internal.h +++ b/platform/linux-keystone2/include/odp_packet_io_internal.h @@ -17,6 +17,9 @@ #include <odp/packet.h> #include <ccan/list/list.h> +#include <odp_packet_internal.h> + +#define SW_PARSING 1 uint16_t _odp_pktio_port_id(odp_pktio_t pktio); @@ -26,9 +29,9 @@ static inline void pktin_update_event(odp_event_t ev, queue_entry_t *qentry) struct odp_pkthdr *hdr = _odp_pkt_hdr(pkt); hdr->input = qentry->pktin; ODP_DBG("Received packet ---------\n"); -//#ifdef SW_PARSING - //_odp_packet_parse(pkt); -//#else +#ifdef SW_PARSING + _odp_packet_parse(pkt); +#else pasahoLongInfo_t *pasa_info = nwal_mGetProtoInfo(Pktlib_getPacketFromDesc(_odp_ev_to_cppi_desc(ev))); @@ -36,7 +39,7 @@ static inline void pktin_update_event(odp_event_t ev, queue_entry_t *qentry) hdr->l2_offset = 0; hdr->l3_offset = PASAHO_LINFO_READ_L3_OFFSET(pasa_info); hdr->l4_offset = PASAHO_LINFO_READ_L4_OFFSET(pasa_info); -//#endif +#endif if (ODP_DEBUG_PRINT == 1) odp_packet_print(pkt); } |