* [PATCH] sh: use kmem_cache_zalloc instead of kmem_cache_alloc with GFP_ZERO flag
@ 2020-08-29 18:38 Emin Ghuliev
0 siblings, 0 replies; only message in thread
From: Emin Ghuliev @ 2020-08-29 18:38 UTC (permalink / raw)
To: ysato; +Cc: dalias, eminusgh, linux-kernel, willy, linux-sh
use kmem_cache_zalloc function which does kmem_cache_alloc and zero out
instead of manually setting kmem_cache_alloc with GFP_ZERO flag.
Signed-off-by: Emin Ghuliev <eminusgh@gmail.com>
---
arch/sh/mm/pgtable.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/sh/mm/pgtable.c b/arch/sh/mm/pgtable.c
index cf7ce4b57359..6e17d921f5f5 100644
--- a/arch/sh/mm/pgtable.c
+++ b/arch/sh/mm/pgtable.c
@@ -47,7 +47,7 @@ void pud_populate(struct mm_struct *mm, pud_t *pud, pmd_t *pmd)
pmd_t *pmd_alloc_one(struct mm_struct *mm, unsigned long address)
{
- return kmem_cache_alloc(pmd_cachep, GFP_KERNEL | __GFP_ZERO);
+ return kmem_cache_zalloc(pmd_cachep, GFP_KERNEL);
}
void pmd_free(struct mm_struct *mm, pmd_t *pmd)
--
2.17.1
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2020-08-29 18:38 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-29 18:38 [PATCH] sh: use kmem_cache_zalloc instead of kmem_cache_alloc with GFP_ZERO flag Emin Ghuliev
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®