* [to-be-updated] mm-mempool-add-else-to-split-mutually-exclusive-case.patch removed from -mm tree
@ 2020-08-24 21:45 akpm
0 siblings, 0 replies; only message in thread
From: akpm @ 2020-08-24 21:45 UTC (permalink / raw)
To: akpm, linmiaohe, mm-commits
The patch titled
Subject: mm/mempool: Add 'else' to split mutually exclusive case
has been removed from the -mm tree. Its filename was
mm-mempool-add-else-to-split-mutually-exclusive-case.patch
This patch was dropped because an updated version will be merged
------------------------------------------------------
From: Miaohe Lin <linmiaohe@huawei.com>
Subject: mm/mempool: Add 'else' to split mutually exclusive case
Add else to split mutually exclusive cases and to avoid some unnecessary
check.
akpm: doesn't affect code generation but it's a little cleaner.
[joe@perches.com: style: braces should be added to the first test]
Link: https://lkml.kernel.org/r/37bbda0e0d94d3324210fa807f4061a9e9bd66bc.camel@perches.comLink: https://lkml.kernel.org/r/20200824115354.7879-1-linmiaohe@huawei.com
Signed-off-by: Miaohe Lin <linmiaohe@huawei.com>
Reviewed-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---
mm/mempool.c | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
--- a/mm/mempool.c~mm-mempool-add-else-to-split-mutually-exclusive-case
+++ a/mm/mempool.c
@@ -57,12 +57,12 @@ static void __check_element(mempool_t *p
static void check_element(mempool_t *pool, void *element)
{
- /* Mempools backed by slab allocator */
- if (pool->free == mempool_free_slab || pool->free == mempool_kfree)
+ if (pool->free == mempool_free_slab ||
+ pool->free == mempool_kfree) {
+ /* Mempools backed by slab allocator */
__check_element(pool, element, ksize(element));
-
- /* Mempools backed by page allocator */
- if (pool->free == mempool_free_pages) {
+ } else if (pool->free == mempool_free_pages) {
+ /* Mempools backed by page allocator */
int order = (int)(long)pool->pool_data;
void *addr = kmap_atomic((struct page *)element);
_
Patches currently in -mm which might be from linmiaohe@huawei.com are
mm-migrate-avoid-possible-unnecessary-process-right-check-in-kernel_move_pages.patch
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2020-08-24 21:45 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-24 21:45 [to-be-updated] mm-mempool-add-else-to-split-mutually-exclusive-case.patch removed from -mm tree akpm
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.