2 * linux/arch/arm/lib/copypage-xsc3.S
4 * Copyright (C) 2004 Intel Corp.
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License version 2 as
8 * published by the Free Software Foundation.
10 * Adapted for 3rd gen XScale core, no more mini-dcache
11 * Author: Matt Gilbert (matthew.m.gilbert@intel.com)
14 #include <linux/linkage.h>
15 #include <linux/init.h>
16 #include <asm/asm-offsets.h>
20 * We don't really want write-allocate cache behaviour for these functions
21 * since that will just eat through 8K of the cache.
27 * XSC3 optimised copy_user_page
30 * r2 = virtual user address of ultimate destination page
32 * The source page may have some clean entries in the cache already, but we
33 * can safely ignore them - break_cow() will flush them out of the cache
34 * if we eventually end up using our copied page.
37 ENTRY(xsc3_mc_copy_user_page)
38 stmfd sp!, {r4, r5, lr}
49 mcr p15, 0, ip, c7, c6, 1 @ invalidate
59 mcr p15, 0, ip, c7, c6, 1 @ invalidate
70 ldmfd sp!, {r4, r5, pc}
74 * XScale optimised clear_user_page
76 * r1 = virtual user address of ultimate destination page
78 ENTRY(xsc3_mc_clear_user_page)
82 1: mcr p15, 0, r0, c7, c6, 1 @ invalidate line
93 .type xsc3_mc_user_fns, #object
94 ENTRY(xsc3_mc_user_fns)
95 .long xsc3_mc_clear_user_page
96 .long xsc3_mc_copy_user_page
97 .size xsc3_mc_user_fns, . - xsc3_mc_user_fns