Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

netmap: Release lock to avoid deadlock #10335

Closed
wants to merge 1 commit into from
Closed

Conversation

jlucovsky
Copy link
Contributor

Issue: 6755

When NetmapOpen encounters an error opening the netmap device, it'll retry a bit. When the retry limit is reached, it'll shutdown Suricata.

This commit ensures that the device list lock is not held when before closing all open devices before terminating Suricata.

Link to redmine ticket: 6755

Describe changes:

  • Release devlist lock before closing all devices

Provide values to any of the below to override the defaults.

To use a pull request use a branch name like pr/N where N is the
pull request number.

Alternatively, SV_BRANCH may also be a link to an
OISF/suricata-verify pull-request.

SV_REPO=
SV_BRANCH=
SU_REPO=
SU_BRANCH=
LIBHTP_REPO=
LIBHTP_BRANCH=

Issue: 6755

When NetmapOpen encounters an error opening the netmap device, it'll
retry a bit. When the retry limit is reached, it'll shutdown Suricata.

This commit ensures that the device list lock is not held when before
closing all open devices before terminating Suricata.
Copy link

codecov bot commented Feb 8, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (80abc22) 82.32% compared to head (d75d292) 82.32%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master   #10335      +/-   ##
==========================================
- Coverage   82.32%   82.32%   -0.01%     
==========================================
  Files         978      978              
  Lines      272142   272142              
==========================================
- Hits       224053   224035      -18     
- Misses      48089    48107      +18     
Flag Coverage Δ
fuzzcorpus 63.59% <ø> (-0.01%) ⬇️
suricata-verify 61.46% <ø> (-0.03%) ⬇️
unittests 62.83% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

@suricata-qa
Copy link

Information: QA ran without warnings.

Pipeline 18249

@jlucovsky
Copy link
Contributor Author

Continued in #10349

@jlucovsky jlucovsky closed this Feb 9, 2024
@jlucovsky jlucovsky deleted the 6755/1 branch February 25, 2024 15:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants