[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PULL 0/7] Migration.next patches
From: |
Peter Maydell |
Subject: |
Re: [PULL 0/7] Migration.next patches |
Date: |
Thu, 9 Sep 2021 16:36:53 +0100 |
On Thu, 9 Sept 2021 at 16:23, Juan Quintela <quintela@redhat.com> wrote:
> From 964e436bdb8aef7dbebc28415e4ac3c5822b552e Mon Sep 17 00:00:00 2001
> From: Juan Quintela <quintela@redhat.com>
> Date: Thu, 9 Sep 2021 17:07:17 +0200
> Subject: [PATCH] rdma: test for ibv_advise_mr API
>
> Signed-off-by: Juan Quintela <quintela@redhat.com>
> ---
> configure | 28 ++++++++++++++++++++++++++++
> migration/rdma.c | 2 ++
> 2 files changed, 30 insertions(+)
>
> diff --git a/configure b/configure
> index 8adf2127c3..70054fd702 100755
> --- a/configure
> +++ b/configure
> @@ -339,6 +339,7 @@ whpx="auto"
> nvmm="auto"
> rdma="$default_feature"
> pvrdma="$default_feature"
> +rdma_ibv_advise_mr="no"
> gprof="no"
> debug_tcg="no"
> debug="no"
> @@ -2918,6 +2919,29 @@ EOF
> fi
> fi
>
> +# Let's see if enhanced reg_mr is supported
> +if test "$rdma" = "yes" ; then
> +
> +cat > $TMPC <<EOF &&
> +#include <infiniband/verbs.h>
> +
> +int
> +main(void)
> +{
> + int advice = wr ? IBV_ADVISE_MR_ADVICE_PREFETCH_WRITE :
> + IBV_ADVISE_MR_ADVICE_PREFETCH;
> + struct ibv_sge sg_list = {.lkey = lkey, .addr = addr, .length = len};
> +
> + ibv_advise_mr(pd, advice, IBV_ADVISE_MR_FLAG_FLUSH, &sg_list, 1);
> + return 0;
> +}
> +EOF
> + if ! compile_prog "" "-libverbs"; then
> + rdma_ibv_advise_mr="yes"
> + fi
> +fi
We don't really want new compilation tests in configure:
anything new should be done in meson.build. I think Paolo
has work in progress to migrate the remaining configure tests.
Something like
config_host_data.set('HAVE_IBV_ADVICE_MR',
cc.has_function('ibv_advise_mr', dependencies: rdma))
in the same bit of meson.build as the other has_function tests
is probably sufficient.
thanks
-- PMM
- [PULL 4/7] migration/rdma: advise prefetch write for ODP region, (continued)
- [PULL 4/7] migration/rdma: advise prefetch write for ODP region, Juan Quintela, 2021/09/09
- [PULL 1/7] multifd: Implement yank for multifd send side, Juan Quintela, 2021/09/09
- [PULL 7/7] migration: allow enabling mutilfd for specific protocol only, Juan Quintela, 2021/09/09
- [PULL 5/7] migration/ram: Don't passs RAMState to migration_clear_memory_region_dirty_bitmap_*(), Juan Quintela, 2021/09/09
- [PULL 6/7] migration: allow multifd for socket protocol only, Juan Quintela, 2021/09/09
- [PULL 3/7] migration/rdma: Try to register On-Demand Paging memory region, Juan Quintela, 2021/09/09
- Re: [PULL 0/7] Migration.next patches, Peter Maydell, 2021/09/09
- Re: [PULL 0/7] Migration.next patches, Li, Zhijian, 2021/09/09
- Re: [PULL 0/7] Migration.next patches, Juan Quintela, 2021/09/09
- Re: [PULL 0/7] Migration.next patches, address@hidden, 2021/09/10
- Re: [PULL 0/7] Migration.next patches, address@hidden, 2021/09/10
- Re: [PULL 0/7] Migration.next patches, Juan Quintela, 2021/09/10
- Re: [PULL 0/7] Migration.next patches, address@hidden, 2021/09/10
- Re: [PULL 0/7] Migration.next patches, Philippe Mathieu-Daudé, 2021/09/10
- Re: [PULL 0/7] Migration.next patches, Li, Zhijian, 2021/09/10