X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=lib%2Flibrte_acl%2Ftb_mem.h;h=ca7af966c318c1ceb939851a3e56d3b0eac4d77b;hb=116ff44aa8e15426aeac930fbebaaeb4755f7999;hp=a3ed795fac67eae31943961c0cd68c1d69732e08;hpb=dc276b5780c29a86c537774b6f7b91379ee0690d;p=dpdk.git diff --git a/lib/librte_acl/tb_mem.h b/lib/librte_acl/tb_mem.h index a3ed795fac..ca7af966c3 100644 --- a/lib/librte_acl/tb_mem.h +++ b/lib/librte_acl/tb_mem.h @@ -37,7 +37,7 @@ /** * @file * - * RTE ACL temporary (build phase) memory managment. + * RTE ACL temporary (build phase) memory management. * Contains structures and functions to manage temporary (used by build only) * memory. Memory allocated in large blocks to speed 'free' when trie is * destructed (finish of build phase). @@ -48,6 +48,7 @@ extern "C" { #endif #include +#include struct tb_mem_block { struct tb_mem_block *next; @@ -61,6 +62,8 @@ struct tb_mem_pool { size_t alignment; size_t min_alloc; size_t alloc; + /* jump target in case of memory allocation failure. */ + sigjmp_buf fail; }; void *tb_alloc(struct tb_mem_pool *pool, size_t size);