| Haavard Skinnemoen | 5f97f7f | 2006-09-25 23:32:13 -0700 | [diff] [blame] | 1 | /* | 
 | 2 |  * Copyright (C) 2004-2006 Atmel Corporation | 
 | 3 |  * | 
 | 4 |  * This program is free software; you can redistribute it and/or modify | 
 | 5 |  * it under the terms of the GNU General Public License version 2 as | 
 | 6 |  * published by the Free Software Foundation. | 
 | 7 |  */ | 
 | 8 | #include <linux/linkage.h> | 
 | 9 | #include <asm/page.h> | 
 | 10 |  | 
 | 11 | /* | 
 | 12 |  * copy_page | 
 | 13 |  * | 
 | 14 |  * r12		to (P1 address) | 
 | 15 |  * r11		from (P1 address) | 
 | 16 |  * r8-r10	scratch | 
 | 17 |  */ | 
 | 18 | 	.text | 
 | 19 | 	.global copy_page | 
 | 20 | copy_page: | 
 | 21 | 	sub	r10, r11, -(1 << PAGE_SHIFT) | 
 | 22 | 	/* pref	r11[0] */ | 
 | 23 | 1:	/* pref	r11[8] */ | 
 | 24 | 	ld.d	r8, r11++ | 
 | 25 | 	st.d	r12++, r8 | 
 | 26 | 	cp	r11, r10 | 
 | 27 | 	brlo	1b | 
 | 28 | 	mov	pc, lr |