Chris Zankel | 9a8fd55 | 2005-06-23 22:01:26 -0700 | [diff] [blame] | 1 | /* |
Chris Zankel | 9a8fd55 | 2005-06-23 22:01:26 -0700 | [diff] [blame] | 2 | * Xtensa doesn't handle unaligned accesses efficiently. |
| 3 | * |
| 4 | * This file is subject to the terms and conditions of the GNU General Public |
| 5 | * License. See the file "COPYING" in the main directory of this archive |
| 6 | * for more details. |
| 7 | * |
| 8 | * Copyright (C) 2001 - 2005 Tensilica Inc. |
| 9 | */ |
Harvey Harrison | 6510d41 | 2008-04-29 01:03:30 -0700 | [diff] [blame] | 10 | #ifndef _ASM_XTENSA_UNALIGNED_H |
| 11 | #define _ASM_XTENSA_UNALIGNED_H |
Chris Zankel | 9a8fd55 | 2005-06-23 22:01:26 -0700 | [diff] [blame] | 12 | |
Harvey Harrison | 6510d41 | 2008-04-29 01:03:30 -0700 | [diff] [blame] | 13 | #ifdef __XTENSA_EL__ |
| 14 | # include <linux/unaligned/le_memmove.h> |
| 15 | # include <linux/unaligned/be_byteshift.h> |
| 16 | # include <linux/unaligned/generic.h> |
| 17 | # define get_unaligned __get_unaligned_le |
| 18 | # define put_unaligned __put_unaligned_le |
| 19 | #elif defined(__XTENSA_EB__) |
| 20 | # include <linux/unaligned/be_memmove.h> |
| 21 | # include <linux/unaligned/le_byteshift.h> |
| 22 | # include <linux/unaligned/generic.h> |
| 23 | # define get_unaligned __get_unaligned_be |
| 24 | # define put_unaligned __put_unaligned_be |
| 25 | #else |
| 26 | # error processor byte order undefined! |
| 27 | #endif |
Chris Zankel | 9a8fd55 | 2005-06-23 22:01:26 -0700 | [diff] [blame] | 28 | |
Harvey Harrison | 6510d41 | 2008-04-29 01:03:30 -0700 | [diff] [blame] | 29 | #endif /* _ASM_XTENSA_UNALIGNED_H */ |