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]
Message-ID: <20090728195431.GA20914@merkur.ravnborg.org>
Date:	Tue, 28 Jul 2009 21:54:31 +0200
From:	Sam Ravnborg <sam@...nborg.org>
To:	Jiri Slaby <jirislaby@...il.com>
Cc:	Alexander Viro <viro@...iv.linux.org.uk>,
	linux-fsdevel@...r.kernel.org,
	Andrew Morton <akpm@...ux-foundation.org>,
	Christoph Hellwig <hch@...radead.org>,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/1] UIO: mark uio.h functions __KERNEL__ only

On Tue, Jul 28, 2009 at 09:41:34PM +0200, Jiri Slaby wrote:
> To avoid userspace build failures such as:
> .../linux/uio.h:37: error: expected ???=???, ???,???, ???;???, ???asm??? or ???__attribute__??? before ???iov_length???
> .../linux/uio.h:47: error: expected declaration specifiers or ???...??? before ???size_t???
> move uio functions inside a __KERNEL__ block.
> 
> Signed-off-by: Jiri Slaby <jirislaby@...il.com>
> ---
>  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..693c149 100644
> --- a/include/linux/uio.h
> +++ b/include/linux/uio.h
> @@ -35,6 +35,7 @@ struct kvec {
>  #define UIO_FASTIOV	8
>  #define UIO_MAXIOV	1024
>  
> +#ifdef __KERNEL__
>  /*
>   * Total number of bytes covered by an iovec.
>   *
> @@ -53,5 +54,6 @@ static inline size_t iov_length(const struct iovec *iov, unsigned long nr_segs)
>  }
>  
>  unsigned long iov_shorten(struct iovec *iov, unsigned long nr_segs, size_t to);
> +#endif
>  
>  #endif

Can we get this fixed up so we have a single #ifdef __KERNEL__ block?
It would be prettier, and nothing the in non-kernel part would rely
on the kernel part so you can put the kernel part in the bottom of
the file.

	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

Powered by Openwall GNU/*/Linux Powered by OpenVZ