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

Commit 42c8c99c authored by Zhao Jin's avatar Zhao Jin Committed by Pekka Enberg
Browse files

slab, cleanup: remove unneeded return



The procedure ends right after the if-statement, so remove ``return''.
Also move the last common statement outside.

Signed-off-by: default avatarZhao Jin <cronozhj@gmail.com>
Acked-by: default avatarDavid Rientjes <rientjes@google.com>
Acked-by: default avatarChristoph Lameter <cl@linux.com>
Signed-off-by: default avatarPekka Enberg <penberg@kernel.org>
parent dcd6c922
Loading
Loading
Loading
Loading
+2 −3
Original line number Diff line number Diff line
@@ -3693,13 +3693,12 @@ static inline void __cache_free(struct kmem_cache *cachep, void *objp,

	if (likely(ac->avail < ac->limit)) {
		STATS_INC_FREEHIT(cachep);
		ac->entry[ac->avail++] = objp;
		return;
	} else {
		STATS_INC_FREEMISS(cachep);
		cache_flusharray(cachep, ac);
		ac->entry[ac->avail++] = objp;
	}

	ac->entry[ac->avail++] = objp;
}

/**