Bug 1051 - l2fwd-event: signal unsafe usage
Summary: l2fwd-event: signal unsafe usage
Status: UNCONFIRMED
Alias: None
Product: DPDK
Classification: Unclassified
Component: examples (show other bugs)
Version: 21.11
Hardware: All All
: Normal minor
Target Milestone: ---
Assignee: dev
URL:
Depends on:
Blocks:
 
Reported: 2022-07-11 20:00 CEST by Stephen Hemminger
Modified: 2022-07-11 20:00 CEST (History)
0 users



Attachments

Description Stephen Hemminger 2022-07-11 20:00:08 CEST
The signal_handler in l2fwd-event uses several functions that are not async-signal-safe.

The call to rte_mempool_lookup() in signal_handler could deadlock if interrupted during another lookup.

Also updating variable in signal handler should use __atomic_store

This is not a bug found by inspection. In practice the code is safe.
But examples are used by users to build applications, should be following best practices.

Note You need to log in before you can comment on or make changes to this bug.