[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20081229125609.GB1852@uranus.ravnborg.org>
Date: Mon, 29 Dec 2008 13:56:09 +0100
From: Sam Ravnborg <sam@...nborg.org>
To: Mike Frysinger <vapier@...too.org>
Cc: linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2] linux/uio.h: cleanup for userspace
On Mon, Dec 29, 2008 at 07:20:17AM -0500, Mike Frysinger wrote:
> Hide iov_shorten() behind __KERNEL__ since it's a prototype only. Use the
> __inline__ form for iov_length() since it's usable by userspace.
>
> Signed-off-by: Mike Frysinger <vapier@...too.org>
> ---
> v2
> - drop inline conversion stuff
>
> include/linux/uio.h | 2 ++
> 1 files changed, 2 insertions(+), 0 deletions(-)
>
> diff --git a/include/linux/uio.h b/include/linux/uio.h
> index b7fe138..bd1661b 100644
> --- a/include/linux/uio.h
> +++ b/include/linux/uio.h
> @@ -52,6 +52,8 @@ static inline size_t iov_length(const struct iovec *iov, unsigned long nr_segs)
> return ret;
> }
>
> +#ifdef __KERNEL__
> unsigned long iov_shorten(struct iovec *iov, unsigned long nr_segs, size_t to);
> +#endif
>
> #endif
Could we rearrange stuff in this file so we only get one #ifdef __KERNEL__ / endif
pair?
Sam
--
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