qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH 1/3] linux-user: detect pwritev support on confi


From: Riku Voipio
Subject: Re: [Qemu-devel] [PATCH 1/3] linux-user: detect pwritev support on configure
Date: Fri, 7 Oct 2016 07:17:34 +0000
User-agent: Mutt/1.5.23 (2014-03-12)

On Thu, Oct 06, 2016 at 03:59:29PM +0200, Dejan Jovicevic wrote:
> Modified the configure file so that, during configuration, a check
> is performed to determine if the system call pwritev is supported
> by the host. The check for preadv support already exists.               

Since preadv/pwritev appearead at the same time (glibc 2.10), using existing
CONFIG_PREADV ifdef guard is enough. Since the oldest distributions currently
being tested (SLES11, Ubuntu 10.04, RHEL6) all have glibc 2.11 or newer,
I'm not really sure we need this check at all.

Riku

 
> Signed-off-by: Dejan Jovicevic <address@hidden>
> ---
>  configure | 17 +++++++++++++++++
>  1 file changed, 17 insertions(+)
> 
> diff --git a/configure b/configure
> index 5751d8e..f834ac8 100755
> --- a/configure
> +++ b/configure
> @@ -3318,6 +3318,19 @@ if compile_prog "" "" ; then
>  fi
>  
>  ##########################################
> +# pwritev probe
> +cat > $TMPC <<EOF
> +#include <sys/types.h>
> +#include <sys/uio.h>
> +#include <unistd.h>
> +int main(void) { return pwritev(0, 0, 0, 0); }
> +EOF
> +pwritev=no
> +if compile_prog "" "" ; then
> +  pwritev=yes
> +fi
> +
> +##########################################
>  # fdt probe
>  # fdt support is mandatory for at least some target architectures,
>  # so insist on it if we're building those system emulators.
> @@ -4902,6 +4915,7 @@ echo "RDMA support      $rdma"
>  echo "TCG interpreter   $tcg_interpreter"
>  echo "fdt support       $fdt"
>  echo "preadv support    $preadv"
> +echo "pwritev support   $pwritev"
>  echo "fdatasync         $fdatasync"
>  echo "madvise           $madvise"
>  echo "posix_madvise     $posix_madvise"
> @@ -5299,6 +5313,9 @@ fi
>  if test "$preadv" = "yes" ; then
>    echo "CONFIG_PREADV=y" >> $config_host_mak
>  fi
> +if test "$pwritev" = "yes" ; then
> +  echo "CONFIG_PWRITEV=y" >> $config_host_mak
> +fi
>  if test "$fdt" = "yes" ; then
>    echo "CONFIG_FDT=y" >> $config_host_mak
>  fi
> -- 
> 1.9.1
> 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]