Skip to content

Commit 1024246

Browse files
committed
MIPS: sibyte: Add missing __user annotations in sb_tbprof.c
Add missing __user annotations to fix sparse errors. Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
1 parent b56d1ca commit 1024246

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

arch/mips/sibyte/common/sb_tbprof.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -437,13 +437,13 @@ static int sbprof_tb_release(struct inode *inode, struct file *filp)
437437
return 0;
438438
}
439439

440-
static ssize_t sbprof_tb_read(struct file *filp, char *buf,
440+
static ssize_t sbprof_tb_read(struct file *filp, char __user *buf,
441441
size_t size, loff_t *offp)
442442
{
443443
int cur_sample, sample_off, cur_count, sample_left;
444444
char *src;
445445
int count = 0;
446-
char *dest = buf;
446+
char __user *dest = buf;
447447
long cur_off = *offp;
448448

449449
if (!access_ok(buf, size))
@@ -512,7 +512,7 @@ static long sbprof_tb_ioctl(struct file *filp,
512512
if (err)
513513
break;
514514

515-
err = put_user(TB_FULL, (int *) arg);
515+
err = put_user(TB_FULL, (int __user *) arg);
516516
break;
517517
}
518518

0 commit comments

Comments
 (0)