[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20191009122740.70517-1-yuehaibing@huawei.com>
Date: Wed, 9 Oct 2019 12:27:40 +0000
From: YueHaibing <yuehaibing@...wei.com>
To: Andrea Arcangeli <aarcange@...hat.com>,
"Joel Fernandes (Google)" <joel@...lfernandes.org>,
Andrew Morton <akpm@...ux-foundation.org>,
"Mike Kravetz" <mike.kravetz@...cle.com>,
Stephen Rothwell <sfr@...b.auug.org.au>,
Wei Yang <richardw.yang@...ux.intel.com>,
Hugh Dickins <hughd@...gle.com>
CC: YueHaibing <yuehaibing@...wei.com>, <linux-mm@...ck.org>,
<linux-kernel@...r.kernel.org>, <kernel-janitors@...r.kernel.org>
Subject: [PATCH -next] userfaultfd: remove set but not used variable 'h'
Fixes gcc '-Wunused-but-set-variable' warning:
mm/userfaultfd.c: In function '__mcopy_atomic_hugetlb':
mm/userfaultfd.c:217:17: warning:
variable 'h' set but not used [-Wunused-but-set-variable]
It is not used since commit 78911d0e18ac ("userfaultfd: use vma_pagesize
for all huge page size calculation")
Signed-off-by: YueHaibing <yuehaibing@...wei.com>
---
mm/userfaultfd.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/mm/userfaultfd.c b/mm/userfaultfd.c
index 4cb4ef3d9128..1b0d7abad1d4 100644
--- a/mm/userfaultfd.c
+++ b/mm/userfaultfd.c
@@ -214,7 +214,6 @@ static __always_inline ssize_t __mcopy_atomic_hugetlb(struct mm_struct *dst_mm,
unsigned long src_addr, dst_addr;
long copied;
struct page *page;
- struct hstate *h;
unsigned long vma_hpagesize;
pgoff_t idx;
u32 hash;
@@ -271,8 +270,6 @@ static __always_inline ssize_t __mcopy_atomic_hugetlb(struct mm_struct *dst_mm,
goto out_unlock;
}
- h = hstate_vma(dst_vma);
-
while (src_addr < src_start + len) {
pte_t dst_pteval;
Powered by blists - more mailing lists