Julian Schroeder 075564ed40 nfsd: destroy percpu stats counters after reply cache shutdown
[ Upstream commit fd5e363eac77ef81542db77ddad0559fa0f9204e ]

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: e567b98ce9a4b (“nfsd: protect concurrent access to nfsd stats counters”)
Signed-off-by: Julian Schroeder <jumaco@amazon.com>
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2022-06-09 10:23:12 +02:00
..
2021-02-23 13:39:45 -08:00
2021-01-25 09:36:28 -05:00
2020-09-25 18:01:26 -04:00
2022-03-08 19:12:33 +01:00
2021-01-24 14:27:17 +01:00
2021-01-25 09:36:28 -05:00