Yoshinori Sato 12d48739d0 h8300: fix recent uaccess breakage
Al Viro wrote:
>
> 	After that commit in asm-h8300/uaccess.h we have
>
> #define get_user(x, ptr)                                        \
> ({                                                              \
>     int __gu_err = 0;                                           \
>     uint32_t __gu_val = 0;                              \
>     ^^^^^^^^^^^^^^^^^
>     switch (sizeof(*(ptr))) {                                   \
>     case 1:                                                     \
>     case 2:                                                     \
>     case 4:                                                     \
>         __gu_val = *(ptr);                                      \
>         break;                                                  \
>     case 8:                                                     \
>         memcpy(&__gu_val, ptr, sizeof (*(ptr)));                \
>                                ^^^^^^^^^^^^^^^^
>
> which, of course, is FUBAR whenever we actually hit that case - memcpy of
> 8 bytes into uint32_t is obviously wrong.  Why don't we simply do

Cc: Al Viro <viro@ZenIV.linux.org.uk>
Signed-off-by: Yoshinori Sato <ysato@users.sourceforge.jp>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-03-13 13:11:43 -07:00
..
2007-05-15 08:54:00 -07:00
2005-09-07 16:57:21 -07:00
2007-10-19 11:53:41 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2007-07-17 10:23:11 -07:00
2005-04-16 15:20:36 -07:00
2006-01-08 20:13:39 -08:00
2005-04-16 15:20:36 -07:00
2008-02-23 17:12:16 -08:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2008-02-06 10:41:01 -08:00
2006-01-10 08:01:34 -08:00
2005-04-16 15:20:36 -07:00
2007-05-07 12:12:58 -07:00
2008-02-23 17:12:16 -08:00
2005-06-06 14:42:23 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2006-02-15 15:32:22 -08:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2008-02-08 09:22:39 -08:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2007-05-11 08:29:34 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2007-10-17 08:42:47 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2008-02-07 08:42:32 -08:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2007-10-19 11:53:34 -07:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2008-03-13 13:11:43 -07:00
2005-04-16 15:20:36 -07:00
2007-05-11 08:29:33 -07:00
2008-02-07 08:42:30 -08:00
2008-02-06 10:41:01 -08:00