summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMiloslav Trmač <mitr@redhat.com>2010-07-26 18:53:13 +0200
committerNikos Mavrogiannopoulos <nmav@gnutls.org>2010-07-26 20:24:56 +0200
commitb7c63f7f6ec4288b30f3ac0c142bda555d212502 (patch)
tree43283575651c74d08126a3bb8629602fc303082a
parent935be4945512eb37461a226c51ede5e8b05cbe24 (diff)
downloadcryptodev-linux-b7c63f7f6ec4288b30f3ac0c142bda555d212502.tar.gz
cryptodev-linux-b7c63f7f6ec4288b30f3ac0c142bda555d212502.tar.xz
cryptodev-linux-b7c63f7f6ec4288b30f3ac0c142bda555d212502.zip
sparse: Fix __user annotations
-rw-r--r--cryptodev_int.h2
-rw-r--r--cryptodev_main.c4
2 files changed, 3 insertions, 3 deletions
diff --git a/cryptodev_int.h b/cryptodev_int.h
index 3c6eca4..b4059fe 100644
--- a/cryptodev_int.h
+++ b/cryptodev_int.h
@@ -25,7 +25,7 @@
extern int cryptodev_verbosity;
/* For zero copy */
-int __get_userbuf(uint8_t *addr, uint32_t len, int write,
+int __get_userbuf(uint8_t __user *addr, uint32_t len, int write,
int pgcount, struct page **pg, struct scatterlist *sg);
void release_user_pages(struct page **pg, int pagecount);
diff --git a/cryptodev_main.c b/cryptodev_main.c
index 7ed0911..f6124cd 100644
--- a/cryptodev_main.c
+++ b/cryptodev_main.c
@@ -447,7 +447,7 @@ static int
__crypto_run_std(struct csession *ses_ptr, struct crypt_op *cop)
{
char *data;
- char __user *src, __user *dst;
+ char __user *src, *dst;
struct scatterlist sg;
size_t nbytes, bufsize;
int ret = 0;
@@ -509,7 +509,7 @@ void release_user_pages(struct page **pg, int pagecount)
#define PAGEOFFSET(buf) ((unsigned long)buf & ~PAGE_MASK)
/* fetch the pages addr resides in into pg and initialise sg with them */
-int __get_userbuf(uint8_t *addr, uint32_t len, int write,
+int __get_userbuf(uint8_t __user *addr, uint32_t len, int write,
int pgcount, struct page **pg, struct scatterlist *sg)
{
int ret, pglen, i = 0;