aboutsummaryrefslogtreecommitdiffstats
path: root/arch/s390/mm/gup.c
diff options
context:
space:
mode:
authorPaul Mundt <lethal@linux-sh.org>2010-11-19 17:04:25 +0900
committerPaul Mundt <lethal@linux-sh.org>2010-11-19 17:04:25 +0900
commitfe040be2fdc49a4132c5f64359c629aeeb8e4947 (patch)
tree40323a8f05d3754372f561bb8f4698ef1a4e9c8f /arch/s390/mm/gup.c
parent2006920a18cc9f499e5cccf9e6f1aa9f6120705e (diff)
parent6722a4016d7f5f107a82ad71a3ee1ccec105532f (diff)
downloadkernel_samsung_smdk4412-fe040be2fdc49a4132c5f64359c629aeeb8e4947.tar.gz
kernel_samsung_smdk4412-fe040be2fdc49a4132c5f64359c629aeeb8e4947.tar.bz2
kernel_samsung_smdk4412-fe040be2fdc49a4132c5f64359c629aeeb8e4947.zip
Merge branch 'common/fbdev-mipi' of master.kernel.org:/pub/scm/linux/kernel/git/lethal/sh-2.6
Diffstat (limited to 'arch/s390/mm/gup.c')
-rw-r--r--arch/s390/mm/gup.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/arch/s390/mm/gup.c b/arch/s390/mm/gup.c
index 38e641cdd97..45b405ca256 100644
--- a/arch/s390/mm/gup.c
+++ b/arch/s390/mm/gup.c
@@ -20,18 +20,17 @@
static inline int gup_pte_range(pmd_t *pmdp, pmd_t pmd, unsigned long addr,
unsigned long end, int write, struct page **pages, int *nr)
{
- unsigned long mask, result;
+ unsigned long mask;
pte_t *ptep, pte;
struct page *page;
- result = write ? 0 : _PAGE_RO;
- mask = result | _PAGE_INVALID | _PAGE_SPECIAL;
+ mask = (write ? _PAGE_RO : 0) | _PAGE_INVALID | _PAGE_SPECIAL;
ptep = ((pte_t *) pmd_deref(pmd)) + pte_index(addr);
do {
pte = *ptep;
barrier();
- if ((pte_val(pte) & mask) != result)
+ if ((pte_val(pte) & mask) != 0)
return 0;
VM_BUG_ON(!pfn_valid(pte_pfn(pte)));
page = pte_page(pte);