[Ocfs2-devel] [PATCH 1/1] ocfs2: Incorrect address of pos passed to __generic_file_aio_read()

Sunil Mushran sunil.mushran at oracle.com
Thu Dec 3 11:19:52 PST 2009


This is for ocfs2 1.6. Not mainline.

Sunil Mushran wrote:
> __generic_file_aio_read() was being passed as incorrect address for pos
> leading to a run-away read.
>
> Signed-off-by: Sunil Mushran <sunil.mushran at oracle.com>
> ---
>  kapi-compat/include/aiovec.h |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/kapi-compat/include/aiovec.h b/kapi-compat/include/aiovec.h
> index a10d5b5..a8896f1 100644
> --- a/kapi-compat/include/aiovec.h
> +++ b/kapi-compat/include/aiovec.h
> @@ -13,7 +13,7 @@ static ssize_t kapi_generic_file_aio_read(struct kiocb *iocb,
>  {
>  	BUG_ON(iocb->ki_pos != pos);
>  
> -	return __generic_file_aio_read(iocb, iov, nr_segs, &pos);
> +	return __generic_file_aio_read(iocb, iov, nr_segs, &iocb->ki_pos);
>  }
>  
>  static ssize_t __ocfs2_file_aio_read(struct kiocb *iocb,
>   




More information about the Ocfs2-devel mailing list