diff options
author | Scott Wood <scottwood@freescale.com> | 2014-04-07 23:49:35 (GMT) |
---|---|---|
committer | Scott Wood <scottwood@freescale.com> | 2014-04-07 23:49:35 (GMT) |
commit | 62b8c978ee6b8d135d9e7953221de58000dba986 (patch) | |
tree | 683b04b2e627f6710c22c151b23c8cc9a165315e /arch/arm/lib | |
parent | 78fd82238d0e5716578c326404184a27ba67fd6e (diff) | |
download | linux-fsl-qoriq-62b8c978ee6b8d135d9e7953221de58000dba986.tar.xz |
Rewind v3.13-rc3+ (78fd82238d0e5716) to v3.12
Diffstat (limited to 'arch/arm/lib')
-rw-r--r-- | arch/arm/lib/Makefile | 1 | ||||
-rw-r--r-- | arch/arm/lib/bitops.h | 5 | ||||
-rw-r--r-- | arch/arm/lib/delay-loop.S | 1 | ||||
-rw-r--r-- | arch/arm/lib/io-shark.c | 13 | ||||
-rw-r--r-- | arch/arm/lib/uaccess_with_memcpy.c | 41 |
5 files changed, 17 insertions, 44 deletions
diff --git a/arch/arm/lib/Makefile b/arch/arm/lib/Makefile index 47d7338..bd454b0 100644 --- a/arch/arm/lib/Makefile +++ b/arch/arm/lib/Makefile @@ -41,6 +41,7 @@ else endif lib-$(CONFIG_ARCH_RPC) += ecard.o io-acorn.o floppydma.o +lib-$(CONFIG_ARCH_SHARK) += io-shark.o $(obj)/csumpartialcopy.o: $(obj)/csumpartialcopygeneric.S $(obj)/csumpartialcopyuser.o: $(obj)/csumpartialcopygeneric.S diff --git a/arch/arm/lib/bitops.h b/arch/arm/lib/bitops.h index 52886b8..d6408d1 100644 --- a/arch/arm/lib/bitops.h +++ b/arch/arm/lib/bitops.h @@ -10,11 +10,6 @@ UNWIND( .fnstart ) and r3, r0, #31 @ Get bit offset mov r0, r0, lsr #5 add r1, r1, r0, lsl #2 @ Get word offset -#if __LINUX_ARM_ARCH__ >= 7 && defined(CONFIG_SMP) - .arch_extension mp - ALT_SMP(W(pldw) [r1]) - ALT_UP(W(nop)) -#endif mov r3, r2, lsl r3 1: ldrex r2, [r1] \instr r2, r2, r3 diff --git a/arch/arm/lib/delay-loop.S b/arch/arm/lib/delay-loop.S index bc1033b..36b668d 100644 --- a/arch/arm/lib/delay-loop.S +++ b/arch/arm/lib/delay-loop.S @@ -40,7 +40,6 @@ ENTRY(__loop_const_udelay) @ 0 <= r0 <= 0x7fffff06 /* * loops = r0 * HZ * loops_per_jiffy / 1000000 */ - .align 3 @ Delay routine ENTRY(__loop_delay) diff --git a/arch/arm/lib/io-shark.c b/arch/arm/lib/io-shark.c new file mode 100644 index 0000000..8242539 --- /dev/null +++ b/arch/arm/lib/io-shark.c @@ -0,0 +1,13 @@ +/* + * linux/arch/arm/lib/io-shark.c + * + * by Alexander Schulz + * + * derived from: + * linux/arch/arm/lib/io-ebsa.S + * Copyright (C) 1995, 1996 Russell King + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ diff --git a/arch/arm/lib/uaccess_with_memcpy.c b/arch/arm/lib/uaccess_with_memcpy.c index 3e58d71..025f742 100644 --- a/arch/arm/lib/uaccess_with_memcpy.c +++ b/arch/arm/lib/uaccess_with_memcpy.c @@ -18,7 +18,6 @@ #include <linux/hardirq.h> /* for in_atomic() */ #include <linux/gfp.h> #include <linux/highmem.h> -#include <linux/hugetlb.h> #include <asm/current.h> #include <asm/page.h> @@ -41,35 +40,7 @@ pin_page_for_write(const void __user *_addr, pte_t **ptep, spinlock_t **ptlp) return 0; pmd = pmd_offset(pud, addr); - if (unlikely(pmd_none(*pmd))) - return 0; - - /* - * A pmd can be bad if it refers to a HugeTLB or THP page. - * - * Both THP and HugeTLB pages have the same pmd layout - * and should not be manipulated by the pte functions. - * - * Lock the page table for the destination and check - * to see that it's still huge and whether or not we will - * need to fault on write, or if we have a splitting THP. - */ - if (unlikely(pmd_thp_or_huge(*pmd))) { - ptl = ¤t->mm->page_table_lock; - spin_lock(ptl); - if (unlikely(!pmd_thp_or_huge(*pmd) - || pmd_hugewillfault(*pmd) - || pmd_trans_splitting(*pmd))) { - spin_unlock(ptl); - return 0; - } - - *ptep = NULL; - *ptlp = ptl; - return 1; - } - - if (unlikely(pmd_bad(*pmd))) + if (unlikely(pmd_none(*pmd) || pmd_bad(*pmd))) return 0; pte = pte_offset_map_lock(current->mm, pmd, addr, &ptl); @@ -123,10 +94,7 @@ __copy_to_user_memcpy(void __user *to, const void *from, unsigned long n) from += tocopy; n -= tocopy; - if (pte) - pte_unmap_unlock(pte, ptl); - else - spin_unlock(ptl); + pte_unmap_unlock(pte, ptl); } if (!atomic) up_read(¤t->mm->mmap_sem); @@ -179,10 +147,7 @@ __clear_user_memset(void __user *addr, unsigned long n) addr += tocopy; n -= tocopy; - if (pte) - pte_unmap_unlock(pte, ptl); - else - spin_unlock(ptl); + pte_unmap_unlock(pte, ptl); } up_read(¤t->mm->mmap_sem); |