Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 61399
b: refs/heads/master
c: e122eaf
h: refs/heads/master
i:
  61397: e1f7195
  61395: 4706e8b
  61391: 3e4b315
v: v3
  • Loading branch information
Haavard Skinnemoen committed Jul 18, 2007
1 parent 244a4ce commit 5e16a49
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 24 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: a8e93ed8cb3d9aa22d192033009357526548c825
refs/heads/master: e122eaf69422e5d9ce93fc9786099098e3b9e1c4
26 changes: 3 additions & 23 deletions trunk/include/asm-avr32/unaligned.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,31 +6,11 @@
* implementation. The AVR32 AP implementation can handle unaligned
* words, but halfwords must be halfword-aligned, and doublewords must
* be word-aligned.
*
* However, swapped word loads must be word-aligned so we can't
* optimize word loads in general.
*/

#include <asm-generic/unaligned.h>

#ifdef CONFIG_CPU_AT32AP7000

/* REVISIT calling memmove() may be smaller for 64-bit values ... */

#undef get_unaligned
#define get_unaligned(ptr) \
___get_unaligned(ptr, sizeof((*ptr)))
#define ___get_unaligned(ptr, size) \
((size == 4) ? *(ptr) : __get_unaligned(ptr, size))

#undef put_unaligned
#define put_unaligned(val, ptr) \
___put_unaligned((__u64)(val), ptr, sizeof((*ptr)))
#define ___put_unaligned(val, ptr, size) \
do { \
if (size == 4) \
*(ptr) = (val); \
else \
__put_unaligned(val, ptr, size); \
} while (0)

#endif

#endif /* __ASM_AVR32_UNALIGNED_H */

0 comments on commit 5e16a49

Please sign in to comment.