Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 176131
b: refs/heads/master
c: 95dfbbe
h: refs/heads/master
i:
  176129: bf7fe57
  176127: a3c9286
v: v3
  • Loading branch information
John Williams authored and Michal Simek committed Dec 14, 2009
1 parent a692f0f commit cf3c9ab
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 7 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: fd6ed51f4f9c01b5cea4a8be50bf49b0ae2fbd51
refs/heads/master: 95dfbbe4700016bddd7e8915e95a97652e70f495
12 changes: 6 additions & 6 deletions trunk/arch/microblaze/include/asm/uaccess.h
Original file line number Diff line number Diff line change
Expand Up @@ -272,8 +272,9 @@ static inline int clear_user(char *to, int size)
return size;
}

extern unsigned long __copy_tofrom_user(void __user *to,
const void __user *from, unsigned long size);
#define __copy_from_user(to, from, n) copy_from_user((to), (from), (n))
#define __copy_from_user_inatomic(to, from, n) \
copy_from_user((to), (from), (n))

#define copy_to_user(to, from, n) \
(access_ok(VERIFY_WRITE, (to), (n)) ? \
Expand All @@ -290,10 +291,6 @@ extern unsigned long __copy_tofrom_user(void __user *to,
(void __user *)(from), (n)) \
: -EFAULT)

#define __copy_from_user(to, from, n) copy_from_user((to), (from), (n))
#define __copy_from_user_inatomic(to, from, n) \
copy_from_user((to), (from), (n))

extern int __strncpy_user(char *to, const char __user *from, int len);
extern int __strnlen_user(const char __user *sstr, int len);

Expand All @@ -305,6 +302,9 @@ extern int __strnlen_user(const char __user *sstr, int len);

#endif /* CONFIG_MMU */

extern unsigned long __copy_tofrom_user(void __user *to,
const void __user *from, unsigned long size);

/*
* The exception table consists of pairs of addresses: the first is the
* address of an instruction that is allowed to fault, and the second is
Expand Down
7 changes: 7 additions & 0 deletions trunk/arch/microblaze/lib/uaccess.c
Original file line number Diff line number Diff line change
Expand Up @@ -39,3 +39,10 @@ long strncpy_from_user(char *dst, const char __user *src, long count)
__do_strncpy_from_user(dst, src, count, res);
return res;
}

unsigned long __copy_tofrom_user(void __user *to,
const void __user *from, unsigned long size)
{
memcpy(to, from, size);
return 0;
}

0 comments on commit cf3c9ab

Please sign in to comment.