lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Mon, 24 Aug 2009 14:58:06 +1000 (EST)
From:	James Morris <jmorris@...ei.org>
To:	Mimi Zohar <zohar@...ux.vnet.ibm.com>
cc:	linux-kernel@...r.kernel.org, Al Viro <viro@...iv.linux.org.uk>,
	Roland Kletzing <devzero@....de>,
	"<David Safford" <safford@...son.ibm.com>, stable@...nel.org,
	Mimi Zohar <zohar@...ibm.com>
Subject: Re: [PATCH 1/2] kernel_read: redefine offset type

On Fri, 21 Aug 2009, Mimi Zohar wrote:

> vfs_read() offset is defined as loff_t, but kernel_read()
> offset is only defined as unsigned long. Redefine
> kernel_read() offset as loff_t.
> 
> Cc: stable@...nel.org
> Signed-off-by: Mimi Zohar <zohar@...ibm.com>


Reviewed-by: James Morris <jmorris@...ei.org>

> ---
>  fs/exec.c          |    4 ++--
>  include/linux/fs.h |    2 +-
>  2 files changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/fs/exec.c b/fs/exec.c
> index 4a8849e..fb4f3cd 100644
> --- a/fs/exec.c
> +++ b/fs/exec.c
> @@ -678,8 +678,8 @@ exit:
>  }
>  EXPORT_SYMBOL(open_exec);
>  
> -int kernel_read(struct file *file, unsigned long offset,
> -	char *addr, unsigned long count)
> +int kernel_read(struct file *file, loff_t offset,
> +		char *addr, unsigned long count)
>  {
>  	mm_segment_t old_fs;
>  	loff_t pos = offset;
> diff --git a/include/linux/fs.h b/include/linux/fs.h
> index 67888a9..73e9b64 100644
> --- a/include/linux/fs.h
> +++ b/include/linux/fs.h
> @@ -2123,7 +2123,7 @@ extern struct file *do_filp_open(int dfd, const char *pathname,
>  		int open_flag, int mode, int acc_mode);
>  extern int may_open(struct path *, int, int);
>  
> -extern int kernel_read(struct file *, unsigned long, char *, unsigned long);
> +extern int kernel_read(struct file *, loff_t, char *, unsigned long);
>  extern struct file * open_exec(const char *);
>   
>  /* fs/dcache.c -- generic fs support functions */
> -- 
> 1.6.0.6
> 

-- 
James Morris
<jmorris@...ei.org>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists