2 * This file is subject to the terms and conditions of the GNU General Public
3 * License. See the file "COPYING" in the main directory of this archive
6 * Copyright (C) 2009, Wind River Systems Inc
7 * Implemented by fredrik.markstrom@gmail.com and ivarholmqvist@gmail.com
10 #include <linux/export.h>
11 #include <linux/uaccess.h>
13 asm(".global raw_copy_from_user\n"
14 " .type raw_copy_from_user, @function\n"
15 "raw_copy_from_user:\n"
61 ".section __ex_table,\"a\"\n"
68 EXPORT_SYMBOL(raw_copy_from_user);
71 " .global raw_copy_to_user\n"
72 " .type raw_copy_to_user, @function\n"
81 /* Bail if we try to copy zero bytes */
85 /* Copy byte by byte for small copies and if src^dst != 0 */
97 /* If 'to' is an odd address byte copy */
101 /* If 'to' is not divideable by four copy halfwords */
117 /* Copy remaining bytes */
124 ".section __ex_table,\"a\"\n"
130 EXPORT_SYMBOL(raw_copy_to_user);