Commit 13459d22 authored by Julian Schroeder's avatar Julian Schroeder Committed by Greg Kroah-Hartman
Browse files

nfsd: destroy percpu stats counters after reply cache shutdown



[ Upstream commit fd5e363e ]

Upon nfsd shutdown any pending DRC cache is freed. DRC cache use is
tracked via a percpu counter. In the current code the percpu counter
is destroyed before. If any pending cache is still present,
percpu_counter_add is called with a percpu counter==NULL. This causes
a kernel crash.
The solution is to destroy the percpu counter after the cache is freed.

Fixes: e567b98c (“nfsd: protect concurrent access to nfsd stats counters”)
Signed-off-by: default avatarJulian Schroeder <jumaco@amazon.com>
Signed-off-by: default avatarChuck Lever <chuck.lever@oracle.com>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent 15081df0
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment