summaryrefslogtreecommitdiffstats
path: root/src
AgeCommit message (Expand)AuthorFilesLines
2018-01-22vom: acl: Fix l3 acl handle populateMohsin Kazmi3-0/+21
2018-01-22vom: ip_route: fix handle populateMohsin Kazmi1-5/+15
2018-01-22vom: Fix connection to VAPI and add disconnect functionMohsin Kazmi6-28/+48
2018-01-22svm: queue sub: Add conditional timed waitMohsin Kazmi11-22/+71
2018-01-22NAT44: asymmetrical static mapping rule (VPP-1135)Matus Fabian4-24/+40
2018-01-21vhost_user: 'nregions' saves the actual number of mapped guest physical addre...Haiyang Tan1-1/+2
2018-01-20VCL/LD_PRELOAD: Fix unfiltered debug output.Dave Wallace2-5/+4
2018-01-19Fix MP hazard in interrupt node schedulingDave Barach1-2/+8
2018-01-19SRv6 static proxy pluginFrancois Clad7-0/+1267
2018-01-19LD_PRELOAD: Fix Coverity Warning CID 182227Dave Wallace1-1/+1
2018-01-19vxlan:restructure encap loopEyal Bari1-321/+198
2018-01-19Sub-Interface deletion not cleanup hash's properly (VPP-1136)John Lo3-18/+24
2018-01-19Elog entries for VCLKeith Burns (alagalah)1-2/+225
2018-01-18LD_PRELOAD: Fix coverity warningsDave Wallace1-4/+13
2018-01-18vlib: add vlib_buffer_alloc_to_ring APIDamjan Marion3-11/+33
2018-01-18tapv2: add option to set host-side default gwDamjan Marion9-3/+115
2018-01-18VPP-1119: PPPoE's destination MAC was overwrittenHongjun Ni1-1/+2
2018-01-18Event log entries for VCLKeith Burns (alagalah)1-1/+300
2018-01-18FIB Inherited SrouceNeale Ranns18-137/+1621
2018-01-18VPP-1122 dpdk/ipsec: fix transport mode pkt lenRadu Nicolau1-3/+7
2018-01-17LD_PRELOAD: stateless LDPDave Wallace10-7372/+3777
2018-01-17ssvm: reuse clib mem infra for memfd segmentsFlorin Coras5-79/+119
2018-01-17stats: Fix per interface statsMohsin Kazmi2-150/+115
2018-01-17stn: add vat supportFlorin Coras5-24/+260
2018-01-17Fix api test_client.c compilationPierre Pfister1-1/+0
2018-01-17Fix checksum offload sssue caused by overwriten lX_hdr_offsetDamjan Marion1-2/+2
2018-01-17ELOG additions for VCLKeith Burns (alagalah)1-41/+148
2018-01-16acl-plugin: multicore: use pool_init_fixed for per-worker preallocated poolsAndrew Yourtchenko1-1/+7
2018-01-16Tolerate missing nodes during feature arc initialisationNeale Ranns1-2/+8
2018-01-16api: fix api_format.c soft link to vatFlorin Coras2-23526/+2
2018-01-16tapv2: deleting tap interface may leak buffers (VPP-1124)Steven4-11/+34
2018-01-15bfd: fix bfd_auth_keys_dumpFlorin Coras1-1/+1
2018-01-15svm: refactor memfd and remove ssvm_ethFlorin Coras16-1343/+157
2018-01-15fix udp_ping api naming errorGabriel Ganne3-35/+17
2018-01-15Marvell device pluginDamjan Marion11-0/+1547
2018-01-14vabits - subtract from the 'end' address instead of from 'bits'.Gabriel Ganne1-2/+3
2018-01-13Improve "show xxx tunnel" and "show int addr" outputJohn Lo6-146/+118
2018-01-11api: fix handlers that explicitly depend on svm queueFlorin Coras8-88/+102
2018-01-11tcp: make proxy server uri cli configurableFlorin Coras2-3/+18
2018-01-11api: remove transport specific code from handlersFlorin Coras38-895/+808
2018-01-11Remove vpp_api_test interface name filter catalogDave Barach3-68/+13
2018-01-11Handle a mix of CNAME, A/AAAA recordsDave Barach1-10/+30
2018-01-11VPP-1131: doxygen: Documentation for Debug CLI stops at src/plugin/l2eBilly McFall1-3/+3
2018-01-11NAT44: asymmetrical load balancing static mapping rule (VPP-1132)Matus Fabian5-22/+38
2018-01-11Add support for MAP-T CE (VPP-1058)Juraj Sloboda5-162/+441
2018-01-11Add basic support for DS-Lite CE (VPP-1059)Juraj Sloboda11-13/+683
2018-01-10svm: calc base address on AArch64 based on autodetected VA space sizeGabriel Ganne1-4/+3
2018-01-10makefile set CXXFLAGS so they are propageted to sub-buildsNeale Ranns1-2/+1
2018-01-10Fix stn rules dump api (VPP-1123)Florin Coras1-20/+25
2018-01-10Functional improvements, bug fixesDave Barach4-25/+152
/span> * heap_header (void *v) { return vec_header (v, sizeof (heap_header_t)); } always_inline uword heap_header_bytes () { return vec_header_bytes (sizeof (heap_header_t)); } always_inline void heap_dup_header (heap_header_t * old, heap_header_t * new) { uword i; new[0] = old[0]; new->elts = vec_dup (new->elts); new->free_elts = vec_dup (new->free_elts); new->free_lists = vec_dup (new->free_lists); for (i = 0; i < vec_len (new->free_lists); i++) new->free_lists[i] = vec_dup (new->free_lists[i]); new->used_elt_bitmap = clib_bitmap_dup (new->used_elt_bitmap); new->small_free_elt_free_index = vec_dup (new->small_free_elt_free_index); } /* Make a duplicate copy of a heap. */ #define heap_dup(v) _heap_dup(v, vec_len (v) * sizeof (v[0])) always_inline void * _heap_dup (void *v_old, uword v_bytes) { heap_header_t *h_old, *h_new; void *v_new; h_old = heap_header (v_old); if (!v_old) return v_old; v_new = 0; v_new = _vec_resize (v_new, _vec_len (v_old), v_bytes, sizeof (heap_header_t), HEAP_DATA_ALIGN); h_new = heap_header (v_new); heap_dup_header (h_old, h_new); clib_memcpy (v_new, v_old, v_bytes); return v_new; } always_inline uword heap_elts (void *v) { heap_header_t *h = heap_header (v); return h->used_count; } uword heap_bytes (void *v); always_inline void * _heap_new (u32 len, u32 n_elt_bytes) { void *v = _vec_resize (0, len, (uword) len * n_elt_bytes, sizeof (heap_header_t), HEAP_DATA_ALIGN); heap_header (v)->elt_bytes = n_elt_bytes; return v; } #define heap_new(v) (v) = _heap_new (0, sizeof ((v)[0])) always_inline void heap_set_format (void *v, format_function_t * format_elt) { ASSERT (v); heap_header (v)->format_elt = format_elt; } always_inline void heap_set_max_len (void *v, uword max_len) { ASSERT (v); heap_header (v)->max_len = max_len; } always_inline uword heap_get_max_len (void *v) { return v ? heap_header (v)->max_len : 0; } /* Create fixed size heap with given block of memory. */ always_inline void * heap_create_from_memory (void *memory, uword max_len, uword elt_bytes) { heap_header_t *h; void *v; if (max_len * elt_bytes < sizeof (h[0])) return 0; h = memory; memset (h, 0, sizeof (h[0])); h->max_len = max_len; h->elt_bytes = elt_bytes; h->flags = HEAP_IS_STATIC; v = (void *) (memory + heap_header_bytes ()); _vec_len (v) = 0; return v; } /* Execute BODY for each allocated heap element. */ #define heap_foreach(var,len,heap,body) \ do { \ if (vec_len (heap) > 0) \ { \ heap_header_t * _h = heap_header (heap); \ heap_elt_t * _e = _h->elts + _h->head; \ heap_elt_t * _end = _h->elts + _h->tail; \ while (1) \ { \ if (! heap_is_free (_e)) \ { \ (var) = (heap) + heap_offset (_e); \ (len) = heap_elt_size ((heap), _e); \ do { body; } while (0); \ } \ if (_e == _end) \ break; \ _e = heap_next (_e); \ } \ } \ } while (0) #define heap_elt_at_index(v,index) vec_elt_at_index(v,index) always_inline heap_elt_t * heap_get_elt (void *v, uword handle) { heap_header_t *h = heap_header (v); heap_elt_t *e = vec_elt_at_index (h->elts, handle); ASSERT (!heap_is_free (e)); return e; } #define heap_elt_with_handle(v,handle) \ ({ \ heap_elt_t * _e = heap_get_elt ((v), (handle)); \ (v) + heap_offset (_e); \ }) always_inline uword heap_is_free_handle (void *v, uword heap_handle) { heap_header_t *h = heap_header (v); heap_elt_t *e = vec_elt_at_index (h->elts, heap_handle); return heap_is_free (e); } extern uword heap_len (void *v, word handle); /* Low level allocation call. */ extern void *_heap_alloc (void *v, uword size, uword alignment, uword elt_bytes, uword * offset, uword * handle); #define heap_alloc_aligned(v,size,align,handle) \ ({ \ uword _o, _h; \ uword _a = (align); \ uword _s = (size); \ (v) = _heap_alloc ((v), _s, _a, sizeof ((v)[0]), &_o, &_h); \ (handle) = _h; \ _o; \ }) #define heap_alloc(v,size,handle) heap_alloc_aligned((v),(size),0,(handle)) extern void heap_dealloc (void *v, uword handle); extern void heap_validate (void *v); /* Format heap internal data structures as string. */ extern u8 *format_heap (u8 * s, va_list * va); void *_heap_free (void *v); #define heap_free(v) (v)=_heap_free(v) #endif /* included_heap_h */ /* * fd.io coding-style-patch-verification: ON * * Local Variables: * eval: (c-set-style "gnu") * End: */