Commit 720cc7e3 authored by Alexander Viro's avatar Alexander Viro Committed by Linus Torvalds

[PATCH] sparse alpha: trivial parts of __user annotation

Trivial stuff in arch/alpha annotated; in two cases of
osf_proplist_syscall() dereferencing userland pointers replaced with
get_user
parent 2d6ef4c5
......@@ -91,7 +91,7 @@ osf_set_program_attributes(unsigned long text_start, unsigned long text_len,
* braindamage (it can't really handle filesystems where the directory
* offset differences aren't the same as "d_reclen").
*/
#define NAME_OFFSET(de) ((int) ((de)->d_name - (char *) (de)))
#define NAME_OFFSET(de) ((int) ((de)->d_name - (char __user *) (de)))
#define ROUND_UP(x) (((x)+3) & ~3)
struct osf_dirent {
......@@ -102,8 +102,8 @@ struct osf_dirent {
};
struct osf_dirent_callback {
struct osf_dirent *dirent;
long *basep;
struct osf_dirent __user *dirent;
long __user *basep;
unsigned int count;
int error;
};
......@@ -112,7 +112,7 @@ static int
osf_filldir(void *__buf, const char *name, int namlen, loff_t offset,
ino_t ino, unsigned int d_type)
{
struct osf_dirent *dirent;
struct osf_dirent __user *dirent;
struct osf_dirent_callback *buf = (struct osf_dirent_callback *) __buf;
unsigned int reclen = ROUND_UP(NAME_OFFSET(dirent) + namlen + 1);
......@@ -131,15 +131,15 @@ osf_filldir(void *__buf, const char *name, int namlen, loff_t offset,
if (copy_to_user(dirent->d_name, name, namlen) ||
put_user(0, dirent->d_name + namlen))
return -EFAULT;
dirent = (void *)dirent + reclen;
dirent = (void __user *)dirent + reclen;
buf->dirent = dirent;
buf->count -= reclen;
return 0;
}
asmlinkage int
osf_getdirentries(unsigned int fd, struct osf_dirent *dirent,
unsigned int count, long *basep)
osf_getdirentries(unsigned int fd, struct osf_dirent __user *dirent,
unsigned int count, long __user *basep)
{
int error;
struct file *file;
......@@ -215,10 +215,10 @@ struct osf_statfs {
int f_files;
int f_ffree;
__kernel_fsid_t f_fsid;
} *osf_stat;
};
static int
linux_to_osf_statfs(struct kstatfs *linux_stat, struct osf_statfs *osf_stat,
linux_to_osf_statfs(struct kstatfs *linux_stat, struct osf_statfs __user *osf_stat,
unsigned long bufsiz)
{
struct osf_statfs tmp_stat;
......@@ -239,7 +239,7 @@ linux_to_osf_statfs(struct kstatfs *linux_stat, struct osf_statfs *osf_stat,
}
static int
do_osf_statfs(struct dentry * dentry, struct osf_statfs *buffer,
do_osf_statfs(struct dentry * dentry, struct osf_statfs __user *buffer,
unsigned long bufsiz)
{
struct kstatfs linux_stat;
......@@ -250,7 +250,7 @@ do_osf_statfs(struct dentry * dentry, struct osf_statfs *buffer,
}
asmlinkage int
osf_statfs(char *path, struct osf_statfs *buffer, unsigned long bufsiz)
osf_statfs(char __user *path, struct osf_statfs __user *buffer, unsigned long bufsiz)
{
struct nameidata nd;
int retval;
......@@ -264,7 +264,7 @@ osf_statfs(char *path, struct osf_statfs *buffer, unsigned long bufsiz)
}
asmlinkage int
osf_fstatfs(unsigned long fd, struct osf_statfs *buffer, unsigned long bufsiz)
osf_fstatfs(unsigned long fd, struct osf_statfs __user *buffer, unsigned long bufsiz)
{
struct file *file;
int retval;
......@@ -284,13 +284,13 @@ osf_fstatfs(unsigned long fd, struct osf_statfs *buffer, unsigned long bufsiz)
* Although to be frank, neither are the native Linux/i386 ones..
*/
struct ufs_args {
char *devname;
char __user *devname;
int flags;
uid_t exroot;
};
struct cdfs_args {
char *devname;
char __user *devname;
int flags;
uid_t exroot;
......@@ -299,7 +299,7 @@ struct cdfs_args {
};
struct procfs_args {
char *devname;
char __user *devname;
int flags;
uid_t exroot;
};
......@@ -313,7 +313,7 @@ struct procfs_args {
* unhappy with OSF UFS. [CHECKME]
*/
static int
osf_ufs_mount(char *dirname, struct ufs_args *args, int flags)
osf_ufs_mount(char *dirname, struct ufs_args __user *args, int flags)
{
int retval;
struct cdfs_args tmp;
......@@ -333,7 +333,7 @@ osf_ufs_mount(char *dirname, struct ufs_args *args, int flags)
}
static int
osf_cdfs_mount(char *dirname, struct cdfs_args *args, int flags)
osf_cdfs_mount(char *dirname, struct cdfs_args __user *args, int flags)
{
int retval;
struct cdfs_args tmp;
......@@ -353,7 +353,7 @@ osf_cdfs_mount(char *dirname, struct cdfs_args *args, int flags)
}
static int
osf_procfs_mount(char *dirname, struct procfs_args *args, int flags)
osf_procfs_mount(char *dirname, struct procfs_args __user *args, int flags)
{
struct procfs_args tmp;
......@@ -364,7 +364,7 @@ osf_procfs_mount(char *dirname, struct procfs_args *args, int flags)
}
asmlinkage int
osf_mount(unsigned long typenr, char *path, int flag, void *data)
osf_mount(unsigned long typenr, char __user *path, int flag, void __user *data)
{
int retval = -EINVAL;
char *name;
......@@ -377,13 +377,13 @@ osf_mount(unsigned long typenr, char *path, int flag, void *data)
goto out;
switch (typenr) {
case 1:
retval = osf_ufs_mount(name, (struct ufs_args *) data, flag);
retval = osf_ufs_mount(name, data, flag);
break;
case 6:
retval = osf_cdfs_mount(name, (struct cdfs_args *) data, flag);
retval = osf_cdfs_mount(name, data, flag);
break;
case 9:
retval = osf_procfs_mount(name, (struct procfs_args *) data, flag);
retval = osf_procfs_mount(name, data, flag);
break;
default:
printk("osf_mount(%ld, %x)\n", typenr, flag);
......@@ -395,7 +395,7 @@ osf_mount(unsigned long typenr, char *path, int flag, void *data)
}
asmlinkage int
osf_utsname(char *name)
osf_utsname(char __user *name)
{
int error;
......@@ -434,7 +434,7 @@ sys_getdtablesize(void)
* For compatibility with OSF/1 only. Use utsname(2) instead.
*/
asmlinkage int
osf_getdomainname(char *name, int namelen)
osf_getdomainname(char __user *name, int namelen)
{
unsigned len;
int i, error;
......@@ -459,7 +459,7 @@ osf_getdomainname(char *name, int namelen)
}
asmlinkage long
osf_shmat(int shmid, void *shmaddr, int shmflg)
osf_shmat(int shmid, void __user *shmaddr, int shmflg)
{
unsigned long raddr;
long err;
......@@ -497,39 +497,39 @@ struct proplistname_args {
union pl_args {
struct setargs {
char *path;
char __user *path;
long follow;
long nbytes;
char *buf;
char __user *buf;
} set;
struct fsetargs {
long fd;
long nbytes;
char *buf;
char __user *buf;
} fset;
struct getargs {
char *path;
char __user *path;
long follow;
struct proplistname_args *name_args;
struct proplistname_args __user *name_args;
long nbytes;
char *buf;
int *min_buf_size;
char __user *buf;
int __user *min_buf_size;
} get;
struct fgetargs {
long fd;
struct proplistname_args *name_args;
struct proplistname_args __user *name_args;
long nbytes;
char *buf;
int *min_buf_size;
char __user *buf;
int __user *min_buf_size;
} fget;
struct delargs {
char *path;
char __user *path;
long follow;
struct proplistname_args *name_args;
struct proplistname_args __user *name_args;
} del;
struct fdelargs {
long fd;
struct proplistname_args *name_args;
struct proplistname_args __user *name_args;
} fdel;
};
......@@ -540,24 +540,20 @@ enum pl_code {
};
asmlinkage long
osf_proplist_syscall(enum pl_code code, union pl_args *args)
osf_proplist_syscall(enum pl_code code, union pl_args __user *args)
{
long error;
int *min_buf_size_ptr;
int __user *min_buf_size_ptr;
lock_kernel();
switch (code) {
case PL_SET:
error = verify_area(VERIFY_READ, &args->set.nbytes,
sizeof(args->set.nbytes));
if (!error)
error = args->set.nbytes;
if (get_user(error, &args->set.nbytes))
error = -EFAULT;
break;
case PL_FSET:
error = verify_area(VERIFY_READ, &args->fset.nbytes,
sizeof(args->fset.nbytes));
if (!error)
error = args->fset.nbytes;
if (get_user(error, &args->fset.nbytes))
error = -EFAULT;
break;
case PL_GET:
error = get_user(min_buf_size_ptr, &args->get.min_buf_size);
......@@ -584,7 +580,7 @@ osf_proplist_syscall(enum pl_code code, union pl_args *args)
}
asmlinkage int
osf_sigstack(struct sigstack *uss, struct sigstack *uoss)
osf_sigstack(struct sigstack __user *uss, struct sigstack __user *uoss)
{
unsigned long usp = rdusp();
unsigned long oss_sp = current->sas_ss_sp + current->sas_ss_size;
......@@ -625,7 +621,7 @@ osf_sigstack(struct sigstack *uss, struct sigstack *uoss)
}
asmlinkage long
osf_sysinfo(int command, char *buf, long count)
osf_sysinfo(int command, char __user *buf, long count)
{
static char * sysinfo_table[] = {
system_utsname.sysname,
......@@ -664,8 +660,8 @@ osf_sysinfo(int command, char *buf, long count)
}
asmlinkage unsigned long
osf_getsysinfo(unsigned long op, void *buffer, unsigned long nbytes,
int *start, void *arg)
osf_getsysinfo(unsigned long op, void __user *buffer, unsigned long nbytes,
int __user *start, void __user *arg)
{
unsigned long w;
struct percpu_struct *cpu;
......@@ -677,7 +673,7 @@ osf_getsysinfo(unsigned long op, void *buffer, unsigned long nbytes,
w = current_thread_info()->ieee_state & IEEE_SW_MASK;
w = swcr_update_status(w, rdfpcr());
if (put_user(w, (unsigned long *) buffer))
if (put_user(w, (unsigned long __user *) buffer))
return -EFAULT;
return 0;
......@@ -693,7 +689,7 @@ osf_getsysinfo(unsigned long op, void *buffer, unsigned long nbytes,
if (nbytes < sizeof(unsigned int))
return -EINVAL;
w = (current_thread_info()->flags >> UAC_SHIFT) & UAC_BITMASK;
if (put_user(w, (unsigned int *)buffer))
if (put_user(w, (unsigned int __user *)buffer))
return -EFAULT;
return 1;
......@@ -703,7 +699,7 @@ osf_getsysinfo(unsigned long op, void *buffer, unsigned long nbytes,
cpu = (struct percpu_struct*)
((char*)hwrpb + hwrpb->processor_offset);
w = cpu->type;
if (put_user(w, (unsigned long *)buffer))
if (put_user(w, (unsigned long __user*)buffer))
return -EFAULT;
return 1;
......@@ -722,8 +718,8 @@ osf_getsysinfo(unsigned long op, void *buffer, unsigned long nbytes,
}
asmlinkage unsigned long
osf_setsysinfo(unsigned long op, void *buffer, unsigned long nbytes,
int *start, void *arg)
osf_setsysinfo(unsigned long op, void __user *buffer, unsigned long nbytes,
int __user *start, void __user *arg)
{
switch (op) {
case SSI_IEEE_FP_CONTROL: {
......@@ -737,7 +733,7 @@ osf_setsysinfo(unsigned long op, void *buffer, unsigned long nbytes,
*/
/* Update softare trap enable bits. */
if (get_user(swcr, (unsigned long *)buffer))
if (get_user(swcr, (unsigned long __user *)buffer))
return -EFAULT;
current_thread_info()->ieee_state
= ((current_thread_info()->ieee_state & ~IEEE_SW_MASK)
......@@ -788,9 +784,9 @@ osf_setsysinfo(unsigned long op, void *buffer, unsigned long nbytes,
for (i = 0; i < nbytes; ++i) {
if (get_user(v, 2*i + (unsigned int *)buffer))
if (get_user(v, 2*i + (unsigned int __user *)buffer))
return -EFAULT;
if (get_user(w, 2*i + 1 + (unsigned int *)buffer))
if (get_user(w, 2*i + 1 + (unsigned int __user *)buffer))
return -EFAULT;
switch (v) {
case SSIN_UACPROC:
......@@ -835,7 +831,7 @@ struct itimerval32
};
static inline long
get_tv32(struct timeval *o, struct timeval32 *i)
get_tv32(struct timeval *o, struct timeval32 __user *i)
{
return (!access_ok(VERIFY_READ, i, sizeof(*i)) ||
(__get_user(o->tv_sec, &i->tv_sec) |
......@@ -843,7 +839,7 @@ get_tv32(struct timeval *o, struct timeval32 *i)
}
static inline long
put_tv32(struct timeval32 *o, struct timeval *i)
put_tv32(struct timeval32 __user *o, struct timeval *i)
{
return (!access_ok(VERIFY_WRITE, o, sizeof(*o)) ||
(__put_user(i->tv_sec, &o->tv_sec) |
......@@ -851,7 +847,7 @@ put_tv32(struct timeval32 *o, struct timeval *i)
}
static inline long
get_it32(struct itimerval *o, struct itimerval32 *i)
get_it32(struct itimerval *o, struct itimerval32 __user *i)
{
return (!access_ok(VERIFY_READ, i, sizeof(*i)) ||
(__get_user(o->it_interval.tv_sec, &i->it_interval.tv_sec) |
......@@ -861,7 +857,7 @@ get_it32(struct itimerval *o, struct itimerval32 *i)
}
static inline long
put_it32(struct itimerval32 *o, struct itimerval *i)
put_it32(struct itimerval32 __user *o, struct itimerval *i)
{
return (!access_ok(VERIFY_WRITE, o, sizeof(*o)) ||
(__put_user(i->it_interval.tv_sec, &o->it_interval.tv_sec) |
......@@ -878,7 +874,7 @@ jiffies_to_timeval32(unsigned long jiffies, struct timeval32 *value)
}
asmlinkage int
osf_gettimeofday(struct timeval32 *tv, struct timezone *tz)
osf_gettimeofday(struct timeval32 __user *tv, struct timezone __user *tz)
{
if (tv) {
struct timeval ktv;
......@@ -894,7 +890,7 @@ osf_gettimeofday(struct timeval32 *tv, struct timezone *tz)
}
asmlinkage int
osf_settimeofday(struct timeval32 *tv, struct timezone *tz)
osf_settimeofday(struct timeval32 __user *tv, struct timezone __user *tz)
{
struct timespec kts;
struct timezone ktz;
......@@ -914,7 +910,7 @@ osf_settimeofday(struct timeval32 *tv, struct timezone *tz)
}
asmlinkage int
osf_getitimer(int which, struct itimerval32 *it)
osf_getitimer(int which, struct itimerval32 __user *it)
{
struct itimerval kit;
int error;
......@@ -927,7 +923,7 @@ osf_getitimer(int which, struct itimerval32 *it)
}
asmlinkage int
osf_setitimer(int which, struct itimerval32 *in, struct itimerval32 *out)
osf_setitimer(int which, struct itimerval32 __user *in, struct itimerval32 __user *out)
{
struct itimerval kin, kout;
int error;
......@@ -950,7 +946,7 @@ osf_setitimer(int which, struct itimerval32 *in, struct itimerval32 *out)
}
asmlinkage int
osf_utimes(const char *filename, struct timeval32 *tvs)
osf_utimes(char __user *filename, struct timeval32 __user *tvs)
{
char *kfilename;
struct timeval ktvs[2];
......@@ -981,8 +977,8 @@ osf_utimes(const char *filename, struct timeval32 *tvs)
((unsigned long) (MAX_SCHEDULE_TIMEOUT / HZ)-1)
asmlinkage int
osf_select(int n, fd_set *inp, fd_set *outp, fd_set *exp,
struct timeval32 *tvp)
osf_select(int n, fd_set __user *inp, fd_set __user *outp, fd_set __user *exp,
struct timeval32 __user *tvp)
{
fd_set_bits fds;
char *bits;
......@@ -1081,7 +1077,7 @@ struct rusage32 {
};
asmlinkage int
osf_getrusage(int who, struct rusage32 *ru)
osf_getrusage(int who, struct rusage32 __user *ru)
{
struct rusage32 r;
......@@ -1116,7 +1112,7 @@ osf_getrusage(int who, struct rusage32 *ru)
}
asmlinkage int
osf_wait4(pid_t pid, int *ustatus, int options, struct rusage32 *ur)
osf_wait4(pid_t pid, int __user *ustatus, int options, struct rusage32 __user *ur)
{
if (!ur) {
return sys_wait4(pid, ustatus, options, NULL);
......@@ -1163,7 +1159,7 @@ osf_wait4(pid_t pid, int *ustatus, int options, struct rusage32 *ur)
* one is the time remaining.. Ho humm.. No documentation.
*/
asmlinkage int
osf_usleep_thread(struct timeval32 *sleep, struct timeval32 *remain)
osf_usleep_thread(struct timeval32 __user *sleep, struct timeval32 __user *remain)
{
struct timeval tmp;
unsigned long ticks;
......@@ -1221,7 +1217,7 @@ struct timex32 {
};
asmlinkage int
sys_old_adjtimex(struct timex32 *txc_p)
sys_old_adjtimex(struct timex32 __user *txc_p)
{
struct timex txc;
int ret;
......@@ -1316,12 +1312,12 @@ arch_get_unmapped_area(struct file *filp, unsigned long addr,
compatibility with old versions of OSF/1 where iov_len
was defined as int. */
static int
osf_fix_iov_len(const struct iovec *iov, unsigned long count)
osf_fix_iov_len(const struct iovec __user *iov, unsigned long count)
{
unsigned long i;
for (i = 0 ; i < count ; i++) {
int *iov_len_high = (int *)&iov[i].iov_len + 1;
int *iov_len_high = (int __user *)&iov[i].iov_len + 1;
if (put_user(0, iov_len_high))
return -EFAULT;
......@@ -1330,7 +1326,7 @@ osf_fix_iov_len(const struct iovec *iov, unsigned long count)
}
asmlinkage ssize_t
osf_readv(unsigned long fd, const struct iovec * vector, unsigned long count)
osf_readv(unsigned long fd, const struct iovec __user * vector, unsigned long count)
{
if (unlikely(personality(current->personality) == PER_OSF4))
if (osf_fix_iov_len(vector, count))
......@@ -1339,7 +1335,7 @@ osf_readv(unsigned long fd, const struct iovec * vector, unsigned long count)
}
asmlinkage ssize_t
osf_writev(unsigned long fd, const struct iovec * vector, unsigned long count)
osf_writev(unsigned long fd, const struct iovec __user * vector, unsigned long count)
{
if (unlikely(personality(current->personality) == PER_OSF4))
if (osf_fix_iov_len(vector, count))
......
......@@ -239,8 +239,9 @@ release_thread(struct task_struct *dead_task)
* with parameters (SIGCHLD, 0).
*/
int
alpha_clone(unsigned long clone_flags, unsigned long usp, int *parent_tid,
int *child_tid, unsigned long tls_value, struct pt_regs *regs)
alpha_clone(unsigned long clone_flags, unsigned long usp,
int __user *parent_tid, int __user *child_tid,
unsigned long tls_value, struct pt_regs *regs)
{
if (!usp)
usp = rdusp();
......@@ -464,7 +465,8 @@ dump_elf_task_fp(elf_fpreg_t *dest, struct task_struct *task)
* Don't do this at home.
*/
asmlinkage int
sys_execve(char *ufilename, char **argv, char **envp,
sys_execve(char __user *ufilename, char __user * __user *argv,
char __user * __user *envp,
unsigned long a3, unsigned long a4, unsigned long a5,
struct pt_regs regs)
{
......
......@@ -84,8 +84,8 @@ osf_sigprocmask(int how, unsigned long newmask, long a2, long a3,
}
asmlinkage int
osf_sigaction(int sig, const struct osf_sigaction *act,
struct osf_sigaction *oact)
osf_sigaction(int sig, const struct osf_sigaction __user *act,
struct osf_sigaction __user *oact)
{
struct k_sigaction new_ka, old_ka;
int ret;
......@@ -115,8 +115,9 @@ osf_sigaction(int sig, const struct osf_sigaction *act,
}
asmlinkage long
sys_rt_sigaction(int sig, const struct sigaction *act, struct sigaction *oact,
size_t sigsetsize, void *restorer)
sys_rt_sigaction(int sig, const struct sigaction __user *act,
struct sigaction __user *oact,
size_t sigsetsize, void __user *restorer)
{
struct k_sigaction new_ka, old_ka;
int ret;
......@@ -165,7 +166,7 @@ do_sigsuspend(old_sigset_t mask, struct pt_regs *reg, struct switch_stack *sw)
}
asmlinkage int
do_rt_sigsuspend(sigset_t *uset, size_t sigsetsize,
do_rt_sigsuspend(sigset_t __user *uset, size_t sigsetsize,
struct pt_regs *reg, struct switch_stack *sw)
{
sigset_t oldset, set;
......@@ -192,7 +193,7 @@ do_rt_sigsuspend(sigset_t *uset, size_t sigsetsize,
}
asmlinkage int
sys_sigaltstack(const stack_t *uss, stack_t *uoss)
sys_sigaltstack(const stack_t __user *uss, stack_t __user *uoss)
{
return do_sigaltstack(uss, uoss, rdusp());
}
......@@ -223,7 +224,7 @@ struct rt_sigframe
#define INSN_CALLSYS 0x00000083
static long
restore_sigcontext(struct sigcontext *sc, struct pt_regs *regs,
restore_sigcontext(struct sigcontext __user *sc, struct pt_regs *regs,
struct switch_stack *sw)
{
unsigned long usp;
......@@ -276,7 +277,7 @@ restore_sigcontext(struct sigcontext *sc, struct pt_regs *regs,
registers and transfer control from userland. */
asmlinkage void
do_sigreturn(struct sigcontext *sc, struct pt_regs *regs,
do_sigreturn(struct sigcontext __user *sc, struct pt_regs *regs,
struct switch_stack *sw)
{
sigset_t set;
......@@ -314,7 +315,7 @@ do_sigreturn(struct sigcontext *sc, struct pt_regs *regs,
}
asmlinkage void
do_rt_sigreturn(struct rt_sigframe *frame, struct pt_regs *regs,
do_rt_sigreturn(struct rt_sigframe __user *frame, struct pt_regs *regs,
struct switch_stack *sw)
{
sigset_t set;
......@@ -356,17 +357,17 @@ do_rt_sigreturn(struct rt_sigframe *frame, struct pt_regs *regs,
* Set up a signal frame.
*/
static inline void *
static inline void __user *
get_sigframe(struct k_sigaction *ka, unsigned long sp, size_t frame_size)
{
if ((ka->sa.sa_flags & SA_ONSTACK) != 0 && ! on_sig_stack(sp))
sp = current->sas_ss_sp + current->sas_ss_size;
return (void *)((sp - frame_size) & -32ul);
return (void __user *)((sp - frame_size) & -32ul);
}
static long
setup_sigcontext(struct sigcontext *sc, struct pt_regs *regs,
setup_sigcontext(struct sigcontext __user *sc, struct pt_regs *regs,
struct switch_stack *sw, unsigned long mask, unsigned long sp)
{
long i, err = 0;
......@@ -426,7 +427,7 @@ setup_frame(int sig, struct k_sigaction *ka, sigset_t *set,
struct pt_regs *regs, struct switch_stack * sw)
{
unsigned long oldsp, r26, err = 0;
struct sigframe *frame;
struct sigframe __user *frame;
oldsp = rdusp();
frame = get_sigframe(ka, oldsp, sizeof(*frame));
......@@ -479,7 +480,7 @@ setup_rt_frame(int sig, struct k_sigaction *ka, siginfo_t *info,
sigset_t *set, struct pt_regs *regs, struct switch_stack * sw)
{
unsigned long oldsp, r26, err = 0;
struct rt_sigframe *frame;
struct rt_sigframe __user *frame;
oldsp = rdusp();
frame = get_sigframe(ka, oldsp, sizeof(*frame));
......
......@@ -106,7 +106,7 @@ alpha_fp_emul (unsigned long pc)
__u32 insn;
long si_code;
get_user(insn, (__u32*)pc);
get_user(insn, (__u32 __user *)pc);
fc = (insn >> 0) & 0x1f; /* destination register */
fb = (insn >> 16) & 0x1f;
fa = (insn >> 21) & 0x1f;
......@@ -351,7 +351,7 @@ alpha_fp_emul_imprecise (struct pt_regs *regs, unsigned long write_mask)
* up to the first occurrence of such an instruction.
*/
while (write_mask) {
get_user(insn, (__u32*)(trigger_pc));
get_user(insn, (__u32 __user *)(trigger_pc));
opcode = insn >> 26;
rc = insn & 0x1f;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment