2 * This file is part of OMAP DSP driver (DSP Gateway version 3.3.1)
4 * Copyright (C) 2004-2006 Nokia Corporation. All rights reserved.
6 * Contact: Toshihiro Kobayashi <toshihiro.kobayashi@nokia.com>
8 * This program is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU General Public License
10 * version 2 as published by the Free Software Foundation.
12 * This program is distributed in the hope that it will be useful, but
13 * WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 * General Public License for more details.
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, write to the Free Software
19 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
24 #include <linux/linkage.h>
25 #include <asm/assembler.h>
29 /* Prototype: int __copy_to_user_dsp_2b(void *to, const char *from)
30 * Purpose : copy 2 bytes to user memory from kernel(DSP) memory
31 * escaping from unexpected byte swap using __copy_to_user()
32 * in OMAP architecture.
33 * Params : to - user memory
34 * : from - kernel(DSP) memory
35 * Returns : success = 0, failure = 2
38 ENTRY(__copy_to_user_dsp_2b)
42 USER( strbt r4, [r0], #1) @ May fault
43 USER( strbt r3, [r0], #1) @ May fault
53 /* Prototype: unsigned long __copy_from_user_dsp_2b(void *to, const void *from);
54 * Purpose : copy 2 bytes from user memory to kernel(DSP) memory
55 * escaping from unexpected byte swap using __copy_to_user()
56 * in OMAP architecture.
57 * Params : to - kernel (DSP) memory
58 * : from - user memory
59 * Returns : success = 0, failure = 2
62 ENTRY(__copy_from_user_dsp_2b)
64 USER( ldrbt r3, [r1], #1) @ May fault
65 USER( ldrbt r4, [r1], #1) @ May fault