mbox series

[v2,0/4] enforce checking on flag values in API's

Message ID 20200424171536.11535-1-stephen@networkplumber.org (mailing list archive)
Headers
Series enforce checking on flag values in API's |

Message

Stephen Hemminger April 24, 2020, 5:15 p.m. UTC
  Since the DPDK api's are lazy about checking for flag values
it means the flags can never be extended in future releases
without causing ABI breakage. This means we end up doing unnecessary
symbol versioning just to work around applications that might
pass in naughty bits.

This is the DPDK analog of the Linux kernel openat() problem.
Openat api was added but since kernel did not check flags it
ended up that another syscall openat2() was necessary before
the flags could be used.

v2 - rebase and fix checkpatch warnings from RFC

Stephen Hemminger (4):
  ring: future proof flag settings
  hash: check flags on creation
  stack: check flags on creation
  cfgfile: check flags value

 lib/librte_cfgfile/rte_cfgfile.c  |  4 ++++
 lib/librte_hash/rte_cuckoo_hash.c |  9 +++++++++
 lib/librte_ring/rte_ring.c        | 10 ++++++++++
 lib/librte_stack/rte_stack.c      |  5 +++++
 4 files changed, 28 insertions(+)