Skip to content

sol: proper deallocation of struct sol_config#448

Merged
AltraMayor merged 4 commits intomasterfrom
cleanup_sol
Dec 22, 2020
Merged

sol: proper deallocation of struct sol_config#448
AltraMayor merged 4 commits intomasterfrom
cleanup_sol

Conversation

@AltraMayor
Copy link
Owner

The SOL block was originally designed to have a single instance, so the code was not accounting for multiple deallocations. This patch adds the reference count that is employed in the GK and GT blocks to deal with the issue.

While Gatekeeper was not finishing cleanly, this issue was ONLY creating stranger log entries.

@AltraMayor AltraMayor added the bug label Dec 17, 2020
@AltraMayor AltraMayor added this to the First deployment milestone Dec 17, 2020
@mengxiang0811 mengxiang0811 self-requested a review December 17, 2020 16:42
@mengxiang0811
Copy link
Collaborator

Patch ggu: fix cleanup stack of run_ggu() is ready for merge.

@mengxiang0811
Copy link
Collaborator

Patch sol: review included headers in SOL's header is ready for merge.

Copy link
Collaborator

@mengxiang0811 mengxiang0811 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sol: proper deallocation of struct sol_config

The cleanup stack of run_ggu() was missing a put on the gk_config.

This bug has likely never been triggered.
The header of the SOL block was including headers that are
no longer needed.

This patch moves the headers still needed to sol/main.c.
This patch improves comments on the reference counting of
struct gk_config.
The SOL block was originally designed to have a single instance,
so the code was not accounting for multiple deallocations.

This patch adds the reference count that is employed in the GK and
GT blocks to deal with the issue.

On top of the multiple deallocations, there is a race condition
during the deallocations, so the errors that are logged vary.
The following is only an example of what can be found:
RING: Cannot free ring, not created with rte_ring_create()

The problem becomes more pronounced with the increase of
NUMA nodes since a SOL instance is allocated to each NUMA node.

While Gatekeeper was not finishing cleanly, this issue was ONLY
creating stranger log entries.
@AltraMayor
Copy link
Owner Author

It's ready for another review.

All the patches moved because the branch was rebased in relation to the master branch.

@mengxiang0811
Copy link
Collaborator

sol: proper deallocation of struct sol_config is ready for merge

@AltraMayor AltraMayor merged commit 4145bac into master Dec 22, 2020
@AltraMayor AltraMayor deleted the cleanup_sol branch December 22, 2020 13:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants