memory allocated by kmem_cache_alloc() should be freed using kmem_cache_free(), not kfree().
Showing the changes to kernel/workqueue.c (1 of 1 file). Show all
Unified · Split
| @@ -3750,7 +3750,7 @@ static void free_unbound_pwq(struct pool_workqueue *pwq) · 3749 unmodified lines | ||
| 3750 | 3750 | |
| 3751 | 3751 | if (pwq) { |
| 3752 | 3752 | put_unbound_pool(pwq->pool); |
| 3753 | − kfree(pwq); | |
| 3753 | + kmem_cache_free(pwq_cache, pwq); | |
| 3754 | 3754 | } |
| 3755 | 3755 | } |
| 3756 | 3756 | |