Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 30c89465 authored by Shaohua Li's avatar Shaohua Li
Browse files

raid5: handle register_shrinker failure



register_shrinker() now can fail. When it happens, shrinker.nr_deferred is
null. We use it to determine if unregister_shrinker is required.

Signed-off-by: default avatarShaohua Li <shli@fb.com>
parent 6a0f53ff
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -6372,7 +6372,7 @@ static void free_conf(struct r5conf *conf)
{
	if (conf->log)
		r5l_exit_log(conf->log);
	if (conf->shrinker.seeks)
	if (conf->shrinker.nr_deferred)
		unregister_shrinker(&conf->shrinker);

	free_thread_groups(conf);