Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b33159b7 authored by Al Viro's avatar Al Viro
Browse files

proc_powerpc: switch to fixed_size_llseek()



Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
parent 4a1f2f38
Loading
Loading
Loading
Loading
+2 −18
Original line number Diff line number Diff line
@@ -31,23 +31,7 @@

static loff_t page_map_seek(struct file *file, loff_t off, int whence)
{
	loff_t new;
	switch(whence) {
	case 0:
		new = off;
		break;
	case 1:
		new = file->f_pos + off;
		break;
	case 2:
		new = PAGE_SIZE + off;
		break;
	default:
		return -EINVAL;
	}
	if ( new < 0 || new > PAGE_SIZE )
		return -EINVAL;
	return (file->f_pos = new);
	return fixed_size_llseek(file, off, whence, PAGE_SIZE);
}

static ssize_t page_map_read( struct file *file, char __user *buf, size_t nbytes,